Commit Graph

135 Commits

Author SHA1 Message Date
yuquanjun 28970fddf0 chore: drop committed __pycache__ and ignore Python bytecode
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 15:05:49 +08:00
yuquanjun a495717883 test: unified K1 HIL harness + RTT inject hooks (tm1617/adc/bin2/sticky)
tools/k1_harness: one CLI over existing COM/BLE/RTT scripts covering
App SysEx 01-06, BLE smoke, TM1629/TM1617 key inject, 1/2/3.bin pack
checks with pick/outro regression, and UI nav (log status/TAP/DUMP).
Unified PASS/FAIL/SKIP/SENT markdown report to Doc/reports.

firmware hooks in app_log.c: 'tm1617 key N', 'adc key N on|off',
'tone bin2 [idx]', 'chord key N hold' (sticky inject survives physical
idle scan so normal-mode pick tests can hold a chord).

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 15:05:17 +08:00
yuquanjun daee47a457 tools: add BLE/RTT/pick test and flash helper scripts
- ble_log_pull.py: pull field logs over BLE (midi/uart transport)
- rtt_flash_log_dump.py / log_decode.py: dump and decode RAM/flash logs via J-Link RTT
- _test_normal_pick.py: semi-automated normal-mode pick regression (RTT + physical pad)
- _ble_channel_matrix.py / _probe_ble_rtt.py / _usb_midi_sysex_probe.py: GATT/BLE/USB-MIDI diagnostics
- build_artist_kit.py: package artist tone kit
- flash_boot_app_v024.py: flash boot+app images

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 14:58:11 +08:00
yuquanjun f841d9e7b1 Normal mode: pick sounds held chord; release stops accompaniment.
Require left-hand pad held (PressFlag) before pick starts; skip the default I-chord fallback in normal mode. Release (key 0) stops AutoBand immediately instead of looping.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 12:55:22 +08:00
yuquanjun 713a768733 Disable fretboard chord/stop side-effects in universal mode.
Ignore TM1629 keys 0-21 in universal so pad no longer changes KEY_ID or arms OutTime_Stop; keep tap-tempo and stop. Clear stale KEY_ID/PressFlag when entering universal tab.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 12:36:39 +08:00
yuquanjun 24261942d8 Map universal section-4 to Postamble outro and share AutoBand_StartOutro with ADC.
Exit piece mode before Postamble so universal chord loops can switch into the style outro stage once 3.bin has PostambleMIDI.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 12:24:35 +08:00
yuquanjun 1cf6562236 Add bass/chord register mapping with RTT inject and bin1/3 probes.
Intercept AutoBand MIDI by channel (bass ch8, drum ch9), add chord-key RTT cmds, and ship scripts to verify 1.bin/3.bin pitch rules on device.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-13 21:21:11 +08:00
yuquanjun 91b270d856 Revert "Lower accompaniment by one octave for #IV and V-VII chords."
This reverts commit 439ccf439d.
2026-09-11 14:59:23 +08:00
yuquanjun 439ccf439d Lower accompaniment by one octave for #IV and V-VII chords.
AutoBand ignores input octave, so shift engine MIDI output by -12 for those chords (except drums) to keep the range from low #IV up to natural IV.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 22:08:09 +08:00
yuquanjun 2d62e1e41a Stop drawing status volume bar on mixer page to avoid erasing the back button.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 19:29:47 +08:00
yuquanjun 4aad989263 Reapply master volume at boot/mode-entry/play-start and sync volume bar on settings hub.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 18:58:24 +08:00
yuquanjun 295a2a6fa3 Fix song-name trailing ghost by clearing the full text row before redraw.
When switching from a longer title to a shorter one, the old gradient-only clear left uncovered glyph fragments outside the pill bounds.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 10:46:11 +08:00
yuquanjun b65b762d92 Refresh git_user_fw_ver.h after 0.2.8 release rebuild.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 07:03:20 +08:00
yuquanjun 30c4ea9c0d Refresh git_user_fw_ver.h for 0.2.8 release commit.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 07:02:22 +08:00
yuquanjun 05ccf28a4b Release 0.2.8: harden BLE SysEx receive path for app stability.
Bump firmware version after BT recv stack/log fixes and pitch/chord bounds so Phoenix Atelier map/LED traffic no longer stack-smashes the MCU.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 07:02:22 +08:00
yuquanjun 59c11f3f93 Fix BT recv stack smash and harden pitch/chord SysEx paths.
Enlarge BT recv stack, move large handlers/log buffers off the stack, clamp key indexes, and yield in W25Q busy-wait so BLE protocol tests stay stable.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-10 06:51:32 +08:00
yuquanjun 24ffe87527 Refresh bottom nav with 0909 enlarged icons and aligned label art.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 20:24:39 +08:00
yuquanjun 5bb403cd11 Add artist self-serve tone pack tool for USB IAP updates of 1/2/3.bin.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 16:37:29 +08:00
yuquanjun a818065c2e Fix mixer knob outline at max volume by seating the knob on the track capsule ends.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 16:33:03 +08:00
yuquanjun c1b32c0351 Refresh git_user_fw_ver.h for 0.2.7 release commit.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 12:18:00 +08:00
yuquanjun bb6d9ae7f9 Release 0.2.7: refresh rhythm 1.bin pack with fixed BIN3 layout checks.
Update pack/publish to enforce 41KB song limit, verify 1/2/3.bin at fixed addresses, and emit .res aliases for the tone and ALL extflash images.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 12:17:42 +08:00
yuquanjun 99f7ed3e5a Pin BIN3 to fixed 0xA71AC and reject packs where 2.bin drift shifts it.
Variable 2.bin length previously moved 3.bin; firmware still read 0xA71AC and saw zeros. Pack now pads to the fixed slot and publish verifies DAB headers before shipping ALL.res.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 11:47:15 +08:00
yuquanjun cd21e4e45e Always enable loop on universal-mode pick so accompaniment can play.
Without SetLoopMode the piece path often produced no audible output when the chord pad was not held.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 11:35:14 +08:00
yuquanjun 92e5e32de3 Diagnose BIN3 LoadPreset failures and add flash bin3 tooling.
Log Flash magic on load failure, expose RTT flash bin3, and document the 0903 pack offset for the universal bank.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 11:32:40 +08:00
yuquanjun 015417dc3d Enlarge bottom nav touch zones to full-width 60x55 cells under the section buttons.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 11:01:40 +08:00
yuquanjun 6f2f7b6b75 Remove mode-select top stripe cover that left an extra line.
The ROW_BG full-width fill over the universal row top corners showed as a second separator under the status bar; source art no longer needs it.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 08:00:06 +08:00
yuquanjun ba110565f1 Use chevron asset for factory-reset row instead of solid triangle.
Matches 0902-07: restore is a drill-in row with thin > (ICON_CHEVRON), not the prev/next filled triangle.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 07:50:08 +08:00
yuquanjun ad0d990c55 Center indexed param/timbre labels as one block and nudge section digits.
Fixes the left-biased index+name layout, unifies index-name gap across rows, and shifts play-section numbers +2px per UI markup.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 07:34:48 +08:00
yuquanjun f1f9520637 Fix settings BT/restore icons and soft-off BLE protocol plumbing.
Point system-settings rows at the correct Flash icons, keep Main/UI alive across soft-off, and expose git build id for 01 0C with matching BLE tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-09 07:03:52 +08:00
yuquanjun 57448b3da8 Harden BLE protocol test for Windows pairing and flaky notifies.
Default --unpair on Windows, probe/reconnect on first timeout, resync FrameParser on duplicate F0, and retry query once.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 22:14:18 +08:00
yuquanjun 0aedb45e6e Make BLE SysEx UID and fw-code MIDI-safe for BLE-MIDI.
Encode 01 07 UID as hex ASCII and use 01 0F (keep 01 FF alias) so high-bit bytes are not dropped as timestamps.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 22:02:06 +08:00
yuquanjun 7b08f5e098 Start BLE UART4 App protocol receive on power-on.
TaskBTRecvThread previously started only after mode select, so GATT SysEx never reached the parser until then; verified BLE-MIDI 01 01 now replies with GATT notify.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 21:46:14 +08:00
yuquanjun f762348883 Merge branch 'main' into develop 2026-09-08 18:15:45 +08:00
yuquanjun 7138123201 Release 0.2.6: refresh HKTK 2.bin from Doc/音色文件/0908/2ss_2.bin.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 18:09:15 +08:00
yuquanjun 8febbd7742 Align BLE SysEx style/transpose replies with Doc protocol and add BLE test harness.
Drop ineffective Dream BT rename SysEx; fix 03 04 boot/list/total and 03 07 read length.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 18:05:04 +08:00
yuquanjun bd22246942 Use AT32 UID for unique PHON_ name and push it to Dream over SysEx.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 12:37:29 +08:00
yuquanjun 725ac495ba Merge main: bring Release 0.2.5 (2ss.bin tone pack) into develop.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 10:18:06 +08:00
yuquanjun f1e4177e92 Release 0.2.5: refresh HKTK 2.bin from Doc/音色文件/0908/2ss.bin.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 10:13:06 +08:00
yuquanjun 01bc2a592c Implement full BLE SysEx protocol handlers and app-sim test.
Wire missing 01/02/03/05 commands, fix chord-map reply and section/End dispatch, and add UART4 protocol regression script.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 10:00:55 +08:00
yuquanjun a6259b5fca Release 0.2.4: package Boot with UI0902 flash-mode screen.
EOF

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-08 05:51:58 +08:00
yuquanjun 4544f8706a Release 0.2.3: fix local song HKTK load/play and keep tone map logs.
Use 41KB preset buffer with compressed 2.bin, expert/normal StartWithNote path, Flash Map address logs, and ship flash-mode/hub assets plus flash helpers.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 21:48:54 +08:00
yuquanjun c4852aca5d Restore WenQuanYi 择 glyph matching the known-good UI shot.
Drop the hand-tuned/mislabeled variants; use the 9pt Song bitmap that matched the first-version 弦音色选择 look.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 15:22:10 +08:00
yuquanjun 4d0b015a07 Restore first-version 择 bitmaps for mode-home labels.
Keep GBK D4F1 mapping but revert glyph data to the pre-regeneration art that matched the known-good UI look.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 15:18:22 +08:00
yuquanjun 68aec080c8 Fill 择 to full cell with clearer hand-tuned strokes.
Label-size glyph now matches neighbors edge-to-edge (0..10) with a stronger 扌 so 弦音色选择 stays readable.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 15:14:00 +08:00
yuquanjun c4969c895c Redraw 择 glyph full-cell from WQY 16px source.
Label-size 择 was inset and hard to read; scale the clear 16px bitmap into each size so it matches neighbors edge-to-edge.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 14:51:19 +08:00
yuquanjun e11ec36ca5 Fix missing 择 on mode-home timbre label.
Font table had wrongly mapped GBK 议 (D2E9) as 择; remap to D4F1 and regenerate the MiSans glyph so 弦音色选择/歌曲选择 render fully.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 13:48:18 +08:00
yuquanjun 0e5a8efdd8 Rename timbre row label from 选议 to 选择.
Fixes the GBK UI string shown above the string-timbre control on all three mode home screens.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 12:14:27 +08:00
yuquanjun 45686415a7 Nudge transpose/tempo main values up 3px and right 3px.
Only the center KEY/BPM digits move; chevrons, plus/minus, and labels stay put across all three modes.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 11:58:49 +08:00
yuquanjun 50e847e2ee Use 0907 hub icons and full-screen flash-mode artwork.
Replace settings-hub mixer/gear bitmaps, and show Boot IAP screen from UI0902_FLASH_MODE in external Flash.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 11:16:45 +08:00
yuquanjun 8c941905e7 Refresh UI0902 address map after transparent icon pack rebuild.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 09:30:59 +08:00