~toykeeper/flashlight-firmware/fsm

« back to all changes in this revision

Viewing changes to ToyKeeper/spaghetti-monster/anduril/cfg-emisar-d1v2-linear-fet.h

  • Committer: Selene ToyKeeper
  • Date: 2022-07-30 03:21:36 UTC
  • mto: (483.1.175 anduril2)
  • mto: This revision was merged to the branch mainline in revision 491.
  • Revision ID: bzr@toykeeper.net-20220730032136-24grlhftnrcus9sd
allow supporting single-color and RGB side button in the same build
(new D1v2 comes in both flavors, and it's easier for everyone if
 they can use the same firmware)

Also, removed lockout-abort bug on D1v2 (and DM11, I think).
Hopefully some day I'll have time to update to a newer compiler,
and then hopefully it won't have this issue any more... but for now,
it still uses a kludge to trick the compiler into working.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
#undef MODEL_NUMBER
7
7
#define MODEL_NUMBER "0124"
8
8
 
9
 
// ... there is no separate button LED, only the RGB LEDs
10
 
#ifdef USE_BUTTON_LED
11
 
#undef USE_BUTTON_LED
12
 
#endif
 
9
// some models use a simple button LED, others use RGB...
 
10
// ... so include support for both
 
11
#define USE_BUTTON_LED
13
12
// the aux LEDs are in the button, so use them while main LEDs are on
 
13
#define USE_AUX_RGB_LEDS
 
14
#define USE_AUX_RGB_LEDS_WHILE_ON
14
15
#define USE_INDICATOR_LED_WHILE_RAMPING
15
16
 
16
17
// safe limit: max regulated power
22
23
#undef THERM_FASTER_LEVEL
23
24
#endif
24
25
#define THERM_FASTER_LEVEL (RAMP_SIZE*9/10)  // throttle back faster when high
 
26
 
 
27
 
 
28
// work around bizarre bug: lockout mode fails when set to solid color blinking
 
29
#define USE_K93_LOCKOUT_KLUDGE