Repository navigation
Releases
v1.56.0: homing check spots a bad reference; clearer buttons
1.56.0: homing check spots a bad reference; buttons that look like buttons
The homing check spots an odd reference. On the machine, every homing over five days read about +6 mm in X and +6 mm in Y from the Oct 29 reference, all within 0.4 mm of each other. Homing was repeatable; the reference homing was the odd one. Now, when 3 checks in a row are off by more than 1 mm and by the same amount (within 1 mm), the check says so and how to fix it, instead of suggesting a dragging hose.
Tool setter: "Retake the reference at the next homing". The next homing check saves the setter's centre as the new reference, instead of shifting positions to match the old one. That way it can never save a centre that has already been shifted.
Secondary buttons (for example "The setter was moved: find and save its centre") had no border and grey text, so on the controller's screen they looked disabled. They're now outlined, with normal text.
Test: homecheck.mjs. The odd reference is spotted on the 3rd homing, not the 2nd; a different offset doesn't count; a retake adopts the new centre without shifting, and the next homing reads close to it. Screen tests pass. Same motion-board hex as 1.55.1.
v1.55.1: probe touch resumes when the board reports HOLDING without its counter
1.55.1: probe touch resumes when the board reports HOLDING without its counter
On Nov 3 the hands-off squareness run hung at its last run, the same way as on Nov 2, even with 1.54.2's fix in place. After a touch, the motion board reported {"v":0,"xx":"HOLDING"}. The controller asked for every variable again, as 1.54.2 does, but the answer carried the same state counter and pause reason as before. Nothing changed, so the touch was never resumed.
Fix: the controller now treats the state itself changing as a state change, the same as a new counter. It still asks for every variable again, so a pause reason it hasn't heard yet arrives as well.
Why 1.54.2's test passed while the machine hung: the simulator handed the controller every reported value. The real controller only passes on values that changed, so to the simulator a repeated, unchanged counter looked new. The simulator now passes on only changed values, as the controller does. It also has a mode that behaves like this machine's board: it keeps the pause reason between touches and sends a bare HOLDING with no new counter. On 1.55.0's code that mode hangs at touches 5 and 9. Touch 8 is where the machine hung on Nov 2. On 1.55.1 the run finishes with identical touches.
Also: a large homing-check offset now first says that moving the feet or gantry (squaring the machine) explains it. In that case the correction is right: the machine moved on the bed.
All Python tests, probing simulations and screen tests pass. Same motion-board hex as 1.55.0.
v1.55.0: Squareness Run 3 times hands-off
1.55.0: Squareness "Run 3 times, hands-off"
On Nov 2, the Squareness check's runs and their average lived only on the screen that ran them. A phone couldn't see or save them, and each run needed a press.
Run 3 times, hands-off (on the Squareness check's first step, and on the Square the machine wizard's Check step):
- One start runs all 3 checks as one program on the controller, the same way Tune the probe automatically has since 1.48.0. No pressing between runs, and the screen can sleep.
- Every screen shows the same run and its result. The average of the 3 is saved by itself by whichever screen is open when it finishes, or the next time one opens.
- Only the squareness result is saved. The stylus size already saved is used as it is and never touched.
- If the homing hasn't been checked since the machine was homed, that's done first, as in Tune the probe automatically.
The one-at-a-time check is unchanged. The 6-run Tune the probe automatically program is unchanged, byte for byte.
Tests: square-run3.mjs starts on the controller's screen, closes that screen mid-run, and checks a phone shows the same run and saves the average, with the stylus size untouched. tune-sim.py runs squareness only through the planner code. All other screen tests and simulations pass. Same motion-board hex as 1.54.2.
v1.54.2: Squareness check fixes found on the machine
1.54.2: Squareness check fixes found on the machine
Three problems found on Nov 2 while checking squareness on the machine. The measuring itself (the touches, the maths and the saved results) is unchanged.
A probe touch was never resumed, and the check hung. After a touch, the motion board's report of the pause ({"v":0,"xx":"HOLDING"}) came without its state counter. The controller only acts on a state change that carries the counter, so it waited for ever. Now, when the state changes without its counter, the controller asks the board for every variable again, the same way it has handled a garbled line since 1.43.1. The answer carries the counter and the pause reason, and the touch resumes. The simulation hangs with the old code on exactly that report; with the new code it finishes with identical touches.
"Measure again" E-stopped. Every run ends with the stylus up at the travel height. The next run only searched 25 mm down from there, so it touched nothing and stopped. A repeat run now goes back over the block the last run measured: it moves up to the travel height and over the block's middle, then down to 5 mm above its top with a guarded move. If something is in the way on the way down, it stops and says why. Position again still lets you place the stylus by hand. The first run is exactly as before.
Stop was off the screen during a run. On the controller's own screen (1278×718), the run's move list pushed the dialog's buttons below the edge. Dialogs now scroll their contents and keep their buttons on screen. The test runs at the controller's screen size: the old layout put Stop at 953 px.
Tests: garble-sim, square-sim and squareness.py were extended; all Python tests, probing simulations and screen tests pass. Same motion-board hex as 1.54.1.
v1.54.1: squaring wizard number boxes have their own keypad
1.54.1: squaring wizard number boxes have their own keypad
On the machine, the Square the machine wizard's boxes (rail spacing, diagonals) couldn't be typed into from the controller's touch screen. Typing on that screen comes from a "Virtual Keyboard" Chrome extension on the original card. The new OS in slot B doesn't have it.
The wizard's number boxes now bring up their own keypad under the box when tapped: digits, decimal point, delete, clear and Done. The keys don't take the focus away, so a real keyboard (from a PC) still works.
Other text boxes on the new OS probably have no touch keyboard either. That is not yet checked on the machine, and fixing it is separate work.
Test: test/square-machine.mjs types a value on the keypad (40 checks). Same motion-board hex as 1.54.0.
v1.54.0: Square the machine corrects with the probe
1.54.0: Square the machine corrects with the probe
A tape can't measure a frame's diagonals much better than a millimetre. The probe's Squareness check reads to about 0.1 mm over 400 mm. This version uses the check itself to square the frame.
After a check that isn't square, the wizard's Check step offers Correct it with the feet. It turns the reading into a foot move, in one of two ways:
- Slide the rail on the side away from the locked foot along its length: error ÷ 400 × rail spacing. This is the smaller move, and it keeps the machine lined up with the table.
- Move the far pair of feet sideways: error ÷ 400 × frame length.
A round loosens the gantry bolts, moves the feet, seats the gantry against the front feet again, homes and checks again. The wizard explains how to move a foot a measured amount: a clamped block plus a feeler gauge or the calipers' depth rod.
Which way to move isn't known at first. How the check's sign maps onto a particular frame hasn't been established, so the first round moves half the geometric amount in the direction you pick. Every later round works out the direction and size from what the last round changed, and suggests the full move. A change smaller than the check repeats to (0.1 mm over 400 mm) isn't trusted.
Rounds are listed with their before and after readings. Test: test/square-machine.mjs (37 checks) runs two rounds against a model machine and lands square. Not yet used on the machine.
No homing, probing or squareness code changed. Same motion-board hex as 1.53.0.
v1.53.0: Square the machine wizard
1.53.0: Square the machine wizard
Probe setup → Square the machine walks through squaring a Onefinity from start to finish, then checks the result with the 1-2-3 block.
The frame (feet)
- Lock one foot and loosen the other three.
- Let the gantry set the rail spacing: jog to the back, snug the back feet; jog to the front, snug the loose front foot.
- Type in the rail spacing and both diagonals, where the shafts go into the feet. The wizard works out which pair of feet to move, which way and how far. It also shows the error that leaves over 400 mm, and how much a 1 mm misread of a diagonal changes the move.
- Put the feet down flat (shim rather than pull down) and tighten.
For a frame with spacing W and diagonals dA (front-left to back-right) and dB, the back pair's offset is s = (dA² − dB²) / 4W. This is exact for a parallelogram.
The gantry (Onefinity's method)
These steps are from the method posted by the Onefinity CNC Official account on the Onefinity forum (Oct 2022):
- Controller off; loosen the 8 bolts holding the X rail to the Y carriages.
- Back on and don't home: jog Y forward until both sides sit against the front feet. The wizard uses slow 1 or 5 mm steps.
- Tighten the bolts and restart.
Check
Home, watching that both Y sides reach their front feet, then run the existing Squareness check. The new result is shown next to the one before.
Safety
- Nothing homes while the feet are loose.
- The wizard keeps its place when the controller is turned off part way.
- On an A/B card with a slot on trial, it warns that a restart would start the other slot, and its restart button stays off.
No homing, probing or squareness code changed. Test: test/square-machine.mjs (Playwright, 800×480, against the mock). Same motion-board hex as 1.52.0.
v1.52.0: A/B card patch files and USB sticks
1.52.0: A/B card patch files and USB sticks
Changing one file in the other slot meant sending a whole operating system (917 MB over the controller's ~0.3 MB/s Wi-Fi, or a USB stick written raw on a PC). This version adds two ways to avoid that.
Patch files
A patch file holds only the files that change, typically a few kilobytes. Admin > SD card > Load a patch into slot X writes those files over the other slot.
- Nothing else in the slot is erased, and existing folders keep their owners and permissions.
- Only
root/(the system) andboot/(the slot's boot files) may be written. Anything else in the file is refused. - An optional checksum and an optional OS match (for example
trixie) keep a patch off the wrong system. - Each patch is recorded on the slot. A patched slot must be tried again before it can be made the normal slot.
scripts/os-image/build-patch.shmakes patch files.
USB sticks
Admin > SD card > Look on the USB stick lists the OS files and patch files in the top folder of a stick plugged into the controller. Each can be written or patched into the other slot straight from the stick. The stick is mounted read-only, so a normal FAT32 stick works. On the 2017 system the controller couldn't see sticks at all: its udev mounts them where other programs can't reach them.
Fix
An upload that was cut off part way left the SD card page "being written" until the controller restarted (seen Oct 31). An upload quiet for two minutes no longer counts.
API
GET /api/abcard/usbPUT /api/abcardwith{"action": "write_file" | "patch_file", "path": ...}(only files on a USB stick)PUT /api/abcard/upload?kind=patchfetchwith"kind": "patch"
Tests: patch and USB on loop-device cards, the web API, and the page (Playwright, 800×480). ab-card and Web.py compile and run under the 2017 card's Python 3.5. Controller code is otherwise as in 1.51.2. Same motion-board hex.
v1.51.2: trial check measures its wait with a monotonic clock
1.51.2: slot B trial check measures its wait correctly
On Oct 31, slot B (1.51.1) was written onto the machine's A/B card. Slot A wrote it from a USB stick. B started on the machine with everything working:
- Wi-Fi connected (Smith5-ext, 192.168.4.89);
- X and the browser up;
- nothing on the "not working" list.
It still went back to slot A after 3 minutes. The Pi has no clock battery, so B starts at the image's build date. The system clock then jumped about 26 days forward when network time arrived, and ab-card trial-check measured its 7-minute wait with that clock, so the wait looked long over.
Fix: trial-check measures its wait and the 60-second steady period with a monotonic clock, which the network time doesn't move. There's a new test where the clock jumps in the middle of the check. It fails on 1.51.1 and passes on 1.51.2.
Everything else is as in 1.51.1. Same motion-board hex.
v1.51.1: slot B fixes: Wi-Fi on, touch turned, trial check needs the network
1.51.1: slot B fixes found on the machine
The 1.51.0 A/B card went into the controller on Oct 31. Slot A (the original 1.48.0 system) started normally. Try slot B worked on the Pi 3: B started, and a power cycle went back to A, as designed. B had two faults:
- No Wi-Fi. Raspberry Pi OS ships NetworkManager with Wi-Fi switched off (
WirelessEnabled=false) until its first-start wizard sets a country. The image disables that wizard. The radio is now switched on in the image and checked at every start. NetworkManager also uses only its own connection files now, so the old system'sinterfaces.d(carried into a slot by the A/B tool) can't take wlan0 away from it. - Touch mirrored. The old card turns the touch 180° along with the screen (
TransformationMatrix "-1 0 1 0 -1 1 0 0 1"in 40-libinput.conf, the line the screen-rotation setting writes). The new OS now has it too.
ab-card trial-check now also needs a network address before a slot on trial counts as working. A slot that goes back records why: NetworkManager state, rfkill, addresses, the X session log and failed units. It records this in ab-trial.json on the boot partition, and the normal slot shows it on the SD card page (trial_ended in /api/abcard).
New: scripts/os-image/build-bundle.sh makes the OS file that ab-card write takes. The running slot can then replace the other slot over the network (Admin > SD card), without the card coming out.
Rehearsed before the machine. On a copy of the card, slot A's own 1.48.0 tool (Python 3.5) wrote this bundle into slot B. That rehearsal found and fixed two bundle problems first:
- tar's rename had also rewritten relative symlink targets;
- the 2017 tar can't recreate the
/devand/etc/mtablinks, which the new OS makes at boot anyway.
The same bug in ab-card bundle's rename is fixed too.
Controller code otherwise the same as 1.50.0/1.51.0. Same motion-board hex.