Repository navigation
FM1Kit 0.7.0
FM1Kit and fm1probe can now work with an FM-1 through the FM-1 Transporter without its web app, check a firmware package before release, compare two packages or backups part by part, and run a simulated FM-1 as virtual CoreMIDI ports. FM1Rescue's built-in flash loader is now m-bootloader's 1.3, from its release v2.3. On an FM-1, the Transporter commands passed with both flash loaders, including an install over another firmware, and flash-backup, flash-restore and flash-install passed with loader 1.3. Not yet seen on hardware: --port NAME with a firmware that actually renames its USB port.
Nothing in the API was removed or changed in a way that breaks 0.6 code. Use .upToNextMinor(from: "0.7.0").
Added
FlashPlan.installingWithTransporter(_:onto:flashID:)andFlashPlan.transporterWritable: plans a firmware install for the FM-1 Transporter, which reaches the chip's boot ROM when no firmware starts, against its backup of the FM-1. The plan'stargetis the full flash image its web app writes; a firmware reaching past 0x92FFF, which it won't write, is refused withFlashPlanError.outsideTransporterRange(_:).- fm1probe's
flash-image FILE.fwsc BACKUP.bin IMAGE.bin [--flash-id HEX]saves that image, talking to no device. Transporter,SerialTransporterLinkandSimulatedTransporter: work with an FM-1 through the FM-1 Transporter's data port, without its web app.waitForBootMode(timeout:waiting:)waits for the FM-1 to be switched on (or asks a running V15 to switch),sendLoader(_:status:)sends m-bootloader's flash loader, built in, or jl-uboot-tool'swl82loader.binafter checking its SHA-256 (Transporter.Loader). m-bootloader's needs Transporter firmware whoseldrrequest takes a loader's address and size; with v0.1.0's,TransporterError.loaderNotTakensays to usewl82loader.bin.chip()refuses a chip that isn't an FM-1's,backUp(_:progress:)reads the flash twice against the Transporter's CRC-32, andwrite(_:progress:)checks the flash still matches the plan's backup, writes only the changed sectors from the top down and reads it all back. Errors areTransporterError.- fm1probe's
transporter status|check|backup|install|restore|start, with--loader wl82loader.bin(instead of m-bootloader's),--port PATH,--wait SECONDSand--simulated BACKUP.bin. It finds the Transporter by the name it gives itself on USB, needs no sudo, saves the flash before writing, and writes only after the person types YES (tested on hardware in November 2026, with both loaders). FlashPlan.afterwards: what to do once a plan is written. Installing with the Transporter over another firmware warns that its saved data stays (the Transporter can't write it), and says to install again in download mode with--erase-saved-dataonce the firmware runs. V15 over Jiant FM played every note with portamento (seen on hardware in November 2026).PackageCheck: a pre-release report on a firmware package, read from the package alone. It checks that the image is enciphered for the FM-1's chip key with whole files, which flash chips its code checks for, and that its saved data is whole sectors clear of the image and of0xFC000onwards. It also says which firmwares will install it, by the update loader it brings, how people can switch from it to V15 and V16 with V15's bootloader or m-bootloader, and whether the FM-1 Transporter can put it back. fm1probe'scheck FILE.fwsc [--strict]prints it and exits with 1 on a failure, or on a warning with--strict.- fm1probe's
devices,identify,inspectandchecktake--json: one JSON object on standard output, whoseformatnames its layout and version (fm1probe-devices-1,fm1probe-identify-1,fm1probe-inspect-1,fm1probe-check-1). Fields that aren't known are left out, and anything else goes to standard error. FM1MessageDescription: names a SysEx message to or from an FM-1 and what it carries: the handshake and identities, the update protocol's reads, finishes and responses, V15's voice bank messages, open firmware's capability, arming and project library messages, and MIDI's device inquiry. A known command with a bad checksum says so.- fm1probe's
monitornames each message, shows the bytes of those it doesn't know (--hexfor all), and with--log FILEwrites every message, bytes and all, asinstall --logdoes.replay LOG.csvprints such a log, summing up each run of image reads (--allfor each one), then counts by kind, the identities in order and the longest silence. Older logs replay too. FlashComparison,FwscPackage.compared(with:)andFlashBackup.compared(with:): two flash images compared part by part: the boot area, the app table, each file (deciphered), each region declared for saved data (such asVM,BTIF,USRorSEQ64), the data every firmware keeps from0xFC000, the factory data from0xFF000, and everything else. Differences are given as runs of 4 KB sectors. fm1probe'sdiff FIRST SECOND [--json]prints it for two packages or two backups, after what differs about the files as a whole, and exits with 0, 1 or 2 as diff(1) does.CoreMIDIVirtualDevice: publishes aSimulatedFM1, or anyMIDITransport, as virtual CoreMIDI ports, so other apps (M-UPGRADE, a web updater, your own) can talk to it as to an FM-1. When it restarts into its update loader, the ports go away and come back, as a USB device's do.- fm1probe's
simulate [FILE.fwsc] [--identity ID] [--loader] [--flash-chip HEX] [--seconds N]runs one, reporting V15 unless told otherwise, checks every byte an updater sends against the package, and prints each message and what the simulated FM-1 does.fm1probe installwas run against it end to end, from V15 to AMB-1, through CoreMIDI. SimulatedFM1says when it ignores the upgrade command because it wasn't given a package.fm1probe --version, andfm1probe licences, which prints the licences of the code and files it contains. A Homebrew formula inocean/tapis on its way.FM1Updater(transport:timing:device:alsoProbing:)andFM1Updater.probes(_:): an updater also probes the ports a person chose, for a firmware that renames its USB port soisProbeable(_:)leaves it out. Each name matches a port's name or USB product name exactly, ignoring case, so the choice holds when the FM-1 comes back on a new port. fm1probe'sdevices,install,install-bootloader,restore-voices,backupanddownload-modetake--port NAME.- A Release workflow checks each release's tag matches
fm1probeVersion, then opens a pull request in ocean/homebrew-tap that moves the formula to the release.
Changed
- FM1Rescue's built-in flash loader is m-bootloader's 1.3, from its release v2.3, in place of 1.2. It's the same loader code, built with no JieLi toolchain. Every download-mode command uses it (tested on hardware in November 2026).
- FM1Rescue builds m-bootloader's flash loader into its code, rather than shipping it in a resource bundle, so fm1probe is one file and an app using FM1Rescue has no bundle to copy. Without the bundle beside it, fm1probe's download-mode commands used to crash.
scripts/embed-flash-loaders.pyregenerates the code fromSources/FM1Rescue/Resources/, and a test checks it matches them and m-bootloader v2.3's published SHA-256s.
Fixed
- SysEx arriving in a CoreMIDI event packet longer than 64 words was cut short and lost. FM-1s send short packets over USB, but CoreMIDI joins a long message into one packet between apps.