Repository navigation
Deluge SDK v0.1.1
Fixed
-
The app-loader boots from the stock Deluge bootloader again. In 0.1.0 it was linked at
0x20020000, where the stock bootloader runs while it copies the image into SRAM: the copy
overwrote its own loop about 11 KB in, and the half-copied app-loader died with a data abort
at every power-on. It now builds with deluge-bsp'szero-init-below-image, which starts the
image above the bootloader (about0x2004A000, as before 0.1.0), and its link fails if
_startis ever below0x20040000. -
usb_classes::midi: the MIDI 2.0 alternate setting works on Linux. The Group Terminal Block
descriptors now answer the standardGET_DESCRIPTOR(0x26 << 8 | alternate) the USB MIDI 2.0
spec defines, instead of a class request no host sends, so Linux no longer gives up with
"Failed to parse GTB"; and the block declares MIDI 2.0 (bMIDIProtocol0x11), not MIDI 1.0
with timestamps (0x02). -
The black encoders (the four with detents) start counting from the detent's resting state
instead of the pins as read at boot. A boot read that caught contact bounce put every click
out of step until the next reboot, and the first click after each reversal did nothing. The
gold encoders still start at the pins as read.
Added
deluge-image::slot: the boot-slot layout (SlotLayout; the Deluge's is a constant) and the variant
codes a stage-0 accepts are parameters (parse_with,validate_with,encode_header_with); the
Deluge's are unchanged.selectpicks the
slot to boot from both slots and the watchdog flag: the newest valid, a pending one tried, rolled
back to the other if the watchdog killed its last boot, or tried again when it is the only one.
mkslottakes--variant-code,--slot-len,--slot-b, the slot offsets and--corrupt-body-b.deluge-flash-protect: the status-register protection core (recipe,plan,apply,SrBus)
moved out ofdeluge-bspinto a chip-neutral crate, whichdeluge_bsp::flash::protect
re-exports. It adds the AT25QF641B (8 MB, bottom 1 MB),protected_range_forany capacity, and
lift_volatile/restore_volatile: open a protected region for one program through the
volatile status register, leaving the non-volatile protection alone (a failed write is undone
by a software reset).rza1-rt'szero-init-below-imagefeature (passed through bydeluge-bsp) places.bss
and the MMU translation table below the vector table instead of after the image, for an app
whose heap starts at the image's end and reclaims its boot-only tail. The default layout is
unchanged, andlink.xnow refuses a__sram_heap_basethat lies below the zero-init data.usb_classes::midiandusb_classes::midi_packetscan run more than one USB-MIDI device:
MidiStateandPacketQueueshold a device's queues and flags (onestaticeach per device),
withbuild_with, therun_*_withendpoint tasks andMidiState::end_sessionfor a session
dropped without a bus reset. The free functions,buildandrun_*keep working, on
DEFAULT_STATE.ClockOut::start,set_period,stopandis_running.set_periodandset_pulse_width
take effect at the next period boundary, so a tempo change never gives a short or doubled
pulse. Periods are clamped to 1 ms–2 s and the pulse width to under the period; the first
clamp of each is logged atwarn.
Changed
deluge_bsp::flash::protect'sWriteMethod,SrBus,Goal,planand the rest come from
the newdeluge-flash-protectcrate.WriteMethodis now that crate's type, not
rza1_hal::spibsc::WriteMethod: an outsideSrBusimplementation converts with
protect::hal_methodwhen it calls the HAL.- In bare-metal builds
ClockOut's edges come from the MTU2 channel 4 timer, so its timing no
longer depends on the executor; native Linux and the simulator use a software loop.
Dropping aClockOutstops the clock and leaves the gate low, andpulse()while the clock
runs returns at once. Deluge::clock_out(ch)panics up front for a gate channel of 4 or more; the Deluge has
gates 0–3.- The
clock_jacksexample free-runs a 24 ppqn clock and switches its tempo on PLAY. Its clock
in no longer echoes to the clock out: it only toggles the SYNC LED and shows its BPM.