aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
| * | went back to slower clk/128 ADC timingSelene ToyKeeper2020-03-139-9/+9
| | |
| * | went back to continuous lowpass because it had the best noise reductionSelene ToyKeeper2020-02-282-52/+74
| | | | | | | | | | | | | | | (also, now treating smoothed ADC values as 11-bit, with the lowest 5 bits chopped off to eliminate noise)
| * | brute force method for reducing ADC noise -- average a ridiculous number of ↵Selene ToyKeeper2020-02-052-20/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | samples (because, for some reason, even though 64 samples is plenty in a test program, it ends up being extremely erratic when used inside Anduril... and I'm not sure why) also, use 15-bit ADC values instead of 16 bits, in the temperature logic (to help protect against integer overflows) ... but this code still doesn't work well. It regulates down *very* fast, and then gradually rises until the next extra-fast drop-down. :( ... also, tempcheck mode sometimes changes by 4-5 C between readouts, which is worrisome. ... and factory reset is still broken.
| * | still doesn't work, but at least it's a bit less broken than before...Selene ToyKeeper2020-02-051-8/+12
| | | | | | | | | | | | | | | | | | (ceiling value was all wrong, and the response magnitude was way too big) (also, temperatures here are unsigned, since freezing is about 270 in ADC units)
| * | first pass at a smaller simpler thermal regulation algorithm...Selene ToyKeeper2020-02-051-75/+52
| | | | | | | | | | | | ... doesn't work well, but I'm saving it so I can experiment with other methods and maybe revert back later.
| * | replaced Anduril's gradual adjustment speed code with a smaller simpler versionSelene ToyKeeper2020-02-051-43/+17
| | |
| * | saving state of ADC / WDT refactoring before doing more changes... what ↵Selene ToyKeeper2020-01-305-76/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | changed so far: - removed LVP lowpass and thermal regulation lowpass logic; it's probably redundant now - slowed ADC deferred logic timing to 4X per second instead of 16X, because there doesn't seem to be much reason to do it any faster - reduced thermal event rate-limit to just 1 second, for more responsive regulation - added "EV_temperature_okay" signal, to help stop adjustments at an appropriate time instead of going to far - sped up sleep LVP to one measurement every 8 seconds instead of 16, to help the aux LEDs respond to voltage changes faster (effect on standby time is negligible) - make sure the WDT doesn't set the ADC channel or counter... except in standby mode
| * | switched to a pseudo-rolling-average method to reduce noise, set prescaler ↵Selene ToyKeeper2020-01-3010-17/+22
| | | | | | | | | | | | back to 64
| * | increased effective ADC resolution by switching from continuous-lowpass to ↵Selene ToyKeeper2020-01-291-64/+43
| | | | | | | | | | | | sum-of-discrete-window method
| * | remove truncation noise by adding 0.5 to each resultSelene ToyKeeper2020-01-291-24/+22
| | | | | | | | | | | | | | | (keeps stable values within ~0.46 to ~0.54 range, so truncated result has no noise)
| * | rewrote ADC code to use a continuous lowpass system on all measurements, to ↵Selene ToyKeeper2020-01-2914-139/+203
| | | | | | | | | | | | | | | | | | eliminate noise and maybe increase precision (thermal code still needs to be rewritten though)
* | | mention the maximum allowed temperature in the manualSelene ToyKeeper2020-02-031-1/+1
|/ /
| * merged from fsm, mostly to get thermal regulation updatesSelene ToyKeeper2019-12-177-9/+187
| |\ | |/ |/|
* | fixed too-slow thermal response (was introduced in the irq-refactor branch)Selene ToyKeeper2019-12-171-5/+8
| |
* | added support for Fireflies ROT66 G2 and PL47 G2Selene ToyKeeper2019-12-112-0/+109
| |
* | added a compile-time flag to enable/disable momentary mode (suggested by Agro)Selene ToyKeeper2019-12-041-1/+18
| |
* | fixed compile errors to handle a couple USE_ flags better:Selene ToyKeeper2019-12-041-2/+8
| | | | | | | | | | | | - beacon mode off (suggested by Agro) - tenclick shortcut on with thermal regulation off
* | added a FW3A build with the FET turned off completelySelene ToyKeeper2019-12-031-0/+36
| |
* | adjusted lantern tint ramping power correction again, based on measurements ↵Selene ToyKeeper2019-12-031-1/+1
| | | | | | | | of the previous attempt
* | adjusted BLF Lantern (Sofirn LT1) tint ramping power correction factor to ↵Selene ToyKeeper2019-11-292-1/+8
| | | | | | | | | | | | | | match production units (also made the factor configurable per build target)
| * changed voltage colors to better match Noctigon K1Selene ToyKeeper2019-11-282-5/+5
| |
| * renamed Emisar D1S V2 -> Noctigon K1Selene ToyKeeper2019-11-252-6/+8
| |
| * merged upstream fsm branchSelene ToyKeeper2019-11-2511-31/+73
| |\ | |/ |/|
* | enabled muggle mode again in all build targets, since it fits nowSelene ToyKeeper2019-11-244-23/+0
| |
* | merged d4v2-buttonled branch, which makes the D4V2's lighted button workSelene ToyKeeper2019-11-246-8/+75
|\ \
| * \ merged from upstream fsm branch to get a whole bunch of kernel-level ↵Selene ToyKeeper2019-11-2421-318/+446
| |\ \ | |/ / |/| | | | | improvements
* | | added -fwhole-program gcc flag, suggested by Agro. Signficantly reduces ROM ↵Selene ToyKeeper2019-11-221-1/+1
| | | | | | | | | | | | size! :)
| * | merged changes from fsm branch, including version check and stuck-button safetySelene ToyKeeper2019-10-1518-58/+596
| |\ \
| * | | slowed down rainbow RGB mode, added a ramp-down on stuck-button for safety ↵Selene ToyKeeper2019-09-071-1/+7
| | | | | | | | | | | | | | | | purposes
| * | | added button LED support to D4v2Selene ToyKeeper2019-09-066-7/+72
| | | | | | | | | | | | | | | | | | | | (in a way which doesn't break backward compatibility... ... but it really needs some refactoring to reduce code duplication)
| | | * increased Noctigon K1's default temperature limit to 55 CSelene ToyKeeper2019-11-251-0/+4
| | | |
| | | * calibrated Noctigon K1, changed voltage divider calibration values to 10-bit ↵Selene ToyKeeper2019-11-254-7/+9
| | | | | | | | | | | | | | | | (was 8-bit before)
| | | * made the button LED turn off in momentary mode, instead of staying on foreverSelene ToyKeeper2019-11-201-2/+7
| | | |
| | | * merged more updates from fsm / irq-refactor branches, finishing up previous ↵Selene ToyKeeper2019-11-209-59/+98
| | | |\ | |_|_|/ |/| | | | | | | changes
* | | | merged tiny fix from irq-refactor branch (fixed spurious wakeup)Selene ToyKeeper2019-11-201-2/+2
|\ \ \ \
| * | | | fixed unintentional wakeup right after going to sleepSelene ToyKeeper2019-11-201-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | (by enabling the PCINT slightly sooner, before setting its "handled" flag)
* | | | | merged irq-refactor branch, which fixes some small but long-standing issues:Selene ToyKeeper2019-11-1916-310/+399
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - fixed occasional short/aborted frames in aux LED sleep animation - fixed rare case of bogus voltage and/or temperature values - fixed issue where nice_delay_ms() didn't work in setup() - fixed theoretical possibility of extra-noisy buttons causing a hang - fixed reboot loop which happened after any crashes - fixed issue where button press in sleep mode could occasionally crash (but the issue may have been created by this branch before being fixed by it) - reduced occasional missed button events while asleep (still seems to happen but not nearly as much) Also does some other things: - cleans up the ADC code significantly - cleans up the WDT code - adds a voltage stabilizer/lowpass option (enabled on t1634 builds) - greatly reduces time spent per interrupt, which might make a future PWM-DSM technique possible - moves most interrupt-handling logic to a non-critical code path, deferring that code until timing doesn't matter as much - sped up button state measurements - very slightly reduces power used in sleep mode
| * | | | Mateminco MF01S can fit muggle mode again, barelySelene ToyKeeper2019-11-191-3/+3
| | | | |
| * | | | reduced build size by a few bytesSelene ToyKeeper2019-11-192-3/+3
| | | | |
| * | | | the Q8 can just barely fit muggle mode againSelene ToyKeeper2019-11-191-3/+3
| | | | |
| * | | | enabled prevent_reboot_loop() on all builds, to reduce the impact of any ↵Selene ToyKeeper2019-11-191-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | potential crashes (even though I just fixed the only known bug which could trigger an unintentional reboot)
| * | | | fixed ADC cycles running 2X as fast as intendedSelene ToyKeeper2019-11-191-8/+8
| | | | |
| * | | | cleaned up WDT code a bit, reduced total size,Selene ToyKeeper2019-11-192-29/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fixed bug where ticks_since_last could have the wrong value sometimes, reduced power use in sleep mode very slightly by skipping button-handling code while asleep
| * | | | fixed issue where button-press-during-sleep could occasionally cause a rebootSelene ToyKeeper2019-11-181-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | (by turning off PCINT when the light is awake)
* | | | | added SOS mode to the BLF LT1 Lantern build, because people wanted itSelene ToyKeeper2019-11-182-7/+44
| | | | |
| | | | * merged fsm updates / irq-refactor branch, to get more stable voltage readingsSelene ToyKeeper2019-11-1424-268/+566
| | | | |\ | | | | | | | | | | | | | | | | | | | | | | | | (and otherwise get recent bugfixes)
| | | | | * merged irq-refactor branch, which fixes some small but long-standing issues:Selene ToyKeeper2019-11-1416-266/+353
| |_|_|_|/| |/| | | |/ | | | |/| | | |/| | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - occasional missed button events while asleep - occasional short/aborted frames in aux LED sleep animation - rare case of bogus voltage and/or temperature values - fixed issue where nice_delay_ms() didn't work in setup() - fixed theoretical possibility of extra-noisy buttons causing a hang Also does some other things: - cleans up the ADC code significantly - adds a voltage stabilizer/lowpass option (enabled on t1634 builds) - greatly reduces time spent per interrupt, which might make a future PWM-DSM technique possible - moves most interrupt-handling logic to a non-critical code path, deferring that code until timing doesn't matter as much - sped up button state measurements - turned off muggle mode on a couple builds which were too big
| * | | | turned off muggle mode on Q8 and MF01S, to make builds small enough againSelene ToyKeeper2019-11-142-0/+11
| | | | |
| * | | | oops, put voltage lowpass on the wrong D4SSelene ToyKeeper2019-11-142-3/+4
| | | | |
| * | | | added a lowpass filter for battery voltage measurementsSelene ToyKeeper2019-11-143-37/+29
| | | | | | | | | | | | | | | | | | | | | | | | | (but only on attiny1634 devices, since it costs a bit of space and isn't strictly necessary)