Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Sven Greiner
rampinglight
Commits
674b1aad
Commit
674b1aad
authored
Jul 07, 2019
by
Sven Greiner
Browse files
Fix
#9
: Stealth beacon mode
parent
9840b642
Changes
2
Show whitespace changes
Inline
Side-by-side
README.md
View file @
674b1aad
...
...
@@ -29,8 +29,9 @@ This firmware is compatible with the driver commonly found in Convoy flashlights
1.
Mode memory on or off
1.
Freeze on high
1.
Start on high
1.
Stealth beacon mode
The default is: no strobe, ramping UI, no mode memory, do not freeze on high, start on low
The default is: no strobe, ramping UI, no mode memory, do not freeze on high, start on low
, no stealth beacon
### Ramping UI
...
...
rampinglight.c
View file @
674b1aad
...
...
@@ -101,6 +101,7 @@ typedef union {
unsigned
freeze_on_high
:
1
;
unsigned
start_high
:
1
;
unsigned
strobe
:
1
;
unsigned
stealth_beacon
:
1
;
};
}
Options
;
...
...
@@ -540,8 +541,10 @@ int main(void) {
case
kBeacon
:
set_pwm
(
TURBO_PWM
);
blink
(
2
,
3
);
if
(
!
options
.
stealth_beacon
)
{
set_pwm
(
BEACON_PWM
);
enable_output
();
}
delay_s
();
delay_s
();
break
;
...
...
@@ -570,6 +573,7 @@ int main(void) {
toggle_option
(
options
.
raw
^
0
b00000010
,
flashes
++
);
// Mode memory
toggle_option
(
options
.
raw
^
0
b00000100
,
flashes
++
);
// Freeze on high
toggle_option
(
options
.
raw
^
0
b00001000
,
flashes
++
);
// Start with high
toggle_option
(
options
.
raw
^
0
b00100000
,
flashes
++
);
// Stealth beacon
break
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment