416 Commits

Author SHA1 Message Date
ac9bf24606 flake: update rustc
All checks were successful
Hydra kirdy Hydra build #195207 of mcu:kirdy:kirdy
2026-03-24 21:44:39 +08:00
e9bb9611ae flake: update dependencies 2026-03-24 21:38:46 +08:00
cf0e783bee flake: use nixpkgs pglive 2026-03-24 21:37:56 +08:00
5a88fe680c README: update w/gui instructions 2026-01-27 05:25:34 +08:00
cb4db1c634 pyproject.toml: Change jsonschema version 2026-01-21 10:33:22 +08:00
16d8ccdfb0 Add missing pyproject.toml dependencies 2026-01-20 18:40:20 +08:00
16edcc71e0 flake: switch to nixpkgs 25.11 2026-01-19 08:15:10 +08:00
a3a57d57e1 put default IP address outside of M-Labs DHCP range 2026-01-07 14:53:01 +08:00
a65500d1d3 flake: Add missing pykirdy lib
- `nix run .#kirdy_gui` failed to run without running `nix develop`
    first as this library was missed
2026-01-06 15:16:49 +08:00
aa99bfddde ld: Wait for 8V stability before current read/set
- During the initial power up of 8V rails, ILIM readings look erroneous
    to the user. ILIM may report 10-25mA output current initially while
    the user may have set 0mA output current on the LC variant.
- With this commit, the ILIM readings are only reported and output
    current starts ramping up only after 8V power rail is deemed to be
    stable.
2025-11-11 18:00:28 +08:00
9f61368379 gpio: Fix wrong hw_rev, ld_hw_variant detection
- PE8, PE9, PE10, PE11 pins may float on hardware initially. A small
    delay is added after configuring pull-down resistors to allow
    voltage levels to settle and prevent reading incorrect values.
- The occurrence of such event is very consistent on some boards when
    you power the board via the 12V Power Jack.
2025-11-11 11:13:58 +08:00
9f21f88169 rm unused print 2025-11-11 11:13:58 +08:00
a5ea5c642d gui: display ld_i_set and readings with 6 digits 2025-11-11 11:13:58 +08:00
91301fdc7a gui: cfg ld_i_set_graph y-axis limit upon connection 2025-11-11 11:13:58 +08:00
aef7d7404b ld: document LT3045 ILIM offset 2025-11-11 11:13:50 +08:00
71a521d4e1 adc: reset enh_filt_en when cfg sinc3multch 2025-10-23 18:13:59 +08:00
cd1d9c8e04 thermostat: Clear default odr when getting settings summary 2025-10-23 18:08:25 +08:00
25753b4001 drop aenum dependency 2025-10-23 15:12:29 +08:00
fb941baf85 aioclient: replace aenum with custom NoAlias implementation 2025-10-23 15:09:21 +08:00
5ad55e003d gui: fix MsgBox btn wrong sig connections
- Previously, if you click import btn twice, two files diag windows are opened
2025-10-14 16:07:04 +08:00
f773543680 driver: fix pd_mon_params not being applied to connected device bug 2025-10-13 21:32:34 +08:00
caa2c1f3cd firmware: support factory rst via jumper 2025-10-13 21:05:29 +08:00
9f549e8e7d firmware: Add default to settings types 2025-10-13 21:05:14 +08:00
5c5f4c13f9 net: Add fn to update ip settings after init 2025-10-13 21:05:14 +08:00
88759c8843 driver: fix typo on loading_settings_from_dict fn 2025-10-13 21:05:14 +08:00
9c024941d8 driver: update import & export settings fns for rev1_0 2025-10-13 21:05:14 +08:00
8d4f6d9e52 Add hw rev checking for some specific cmds
- Affected commands: SetPdTransconductance, SetPdFinGain cmd
2025-10-13 20:58:11 +08:00
50899f607e driver: Update docs 2025-10-13 11:38:01 +08:00
1d558ca73c gui: fix typo 2025-10-10 21:06:11 +08:00
61898f2afa gui: update settable ld output current limit with recv-ed Status Report 2025-10-10 21:05:30 +08:00
a8645ec6bd gui: add LD output current monitoring to graph 2025-10-10 21:05:30 +08:00
af4d4cf840 firmware: add lock switch functionality
- Ld Output Current will only flow if the lock switch is in the Unlock
    position
- Ld Ldo cannot be turned on at Lock position
- Ld Ldo will be shutdown if Lock Switch is changed from Unlock to Lock
    position
2025-10-10 21:05:30 +08:00
df4c5fff9e firmware: blink status led while calibrating
- On: calibration has been completed and device is operating normally
- Blink: calibration in progress
2025-10-10 21:05:30 +08:00
0ca7ce9c54 thermostat: calibrate dac with ad7172-2
- Dac Vref is based on 3V3A. But, 3V3A takes a long time to reach its
    preset output voltage. So, use Ad7172-2 to monitor and wait for 3V3A
    to be stable before calibrating the dac
2025-10-10 21:05:30 +08:00
37917a497a driver, gui: support mult_ch filter rate config 2025-10-10 21:05:25 +08:00
28683fb8a2 ad7172: support multi_ch filter rate configuration 2025-10-10 21:05:19 +08:00
16af4f769a firmware: add LD Current Monitoring for rev1_0 2025-10-10 21:05:15 +08:00
63b5413af1 ad7172-2 fix wrong u8 -> RefSource conversion 2025-10-10 21:05:10 +08:00
0c2de49e30 ad7172-2: fix incorrect voltage conversion 2025-10-10 21:05:06 +08:00
2ff2731e04 ld_pwr_exc_protector: add auto-ranging for rev1_0
- Implement auto-ranging by software instead of Adc Analog Watchdog
- Rewrite iir_filter in f32 or else there would be significant
    quantization error in setting up the threshold
    - About 30% slower than u32 implementation
2025-10-10 21:05:00 +08:00
8ac59b09ca pwr_rail_mon: Fix incorrect err assertion at startup
- Check pwr_good 1ms after en is set high
    LDO's PG requires pwr to be active. A startup delay is needed to
    evaluate pwr good correctly.
- Change the pwr rail startup order
2025-10-02 12:31:31 +08:00
d98fff6ccc pwr_rail_mon: fix typo 2025-10-02 12:24:08 +08:00
7ffd8da4a4 cargo fmt 2025-10-02 12:24:01 +08:00
da0d0ac2a8 ad5680: rm time.sleep for sync signal
- the time used for prep-ing the DMA for SPI TX is longer than the
    specified minimum sync high time (33 ns)
2025-09-05 19:12:14 +08:00
6128f1e941 ad5680: send SPI data with DMA 2025-09-04 18:09:48 +08:00
55adf3ab13 gui: display the SysWarning msg upon receival 2025-09-03 16:12:26 +08:00
19e6ade824 driver: handle the new SysWarning msg type 2025-09-03 16:12:26 +08:00
d72547a83e firmware: add startup pwrseq & report sys failures
- only applicable for rev1_0 or above hardware
- BREAKING: Python driver
    - Upon the receival of the new SysWarning type message, driver would
        disconnect with the Kirdy
- add analog startup power sequence to limit inrush current
    - See HW repo Issue #32, #33, #34
- any pwr failure triggers irq(s) to turn off laser diode driver
- any pwr failure except P8V0 pwr rail triggers irq to turn off the
    thermostat
- prevent laser diode driver and thermostat from powering up during
    power rail failure
- send a new SysWarning message type message to notify the connected
    host upon pwr failure and laser diode power excursion
2025-09-03 16:12:19 +08:00
a4526c9158 eeprom: read eui-48 mac address at startup 2025-08-25 15:32:15 +08:00
06d1a7f438 ld: detect LD HW Variant 2025-08-25 15:26:20 +08:00