Repository navigation
Feed Override
Feed override lets a host speed up or slow down the feed rate of a running job, from 5% to 200%, without stopping it. It is available from firmware build 450.05.
The settings use the same names as g2core, so a host that already drives g2core's feed override can send the same commands.
| Token | Access | Meaning | Default |
|---|---|---|---|
mfo |
read/write | Requested feed factor, 0.05 to 2.0 | 1.0 |
mfoe |
read/write | Operator feed override enable, 0 or 1 | 1 |
m48e |
read/write | Operator master override enable, 0 or 1 | 1 |
mfc |
read only | Feed factor currently in effect | 1.0 |
mcp |
read only | 1 if axis or motor speed limits capped the accepted speed | 0 |
mfe |
read only | Effective permission: 1 only if m48e, mfoe and the program all allow override |
1 |
Set them like any other setting: {"mfo":0.5} in JSON or $mfo=0.5 in text mode asks for 50%. Read them with {"mfo":null} or $mfo.
These values are never saved to EEPROM. Because of that they are accepted while a job runs, unlike saved settings, which are refused with status 117 during a job (see Changing settings while a job runs). $defa does not change them, and they are not part of a settings backup.
- A factor outside 0.05 to 2.0, or an enable other than 0 or 1, is refused with status 110 and changes nothing.
- Writing a read-only token (
mfc,mcp,mfe) is refused with status 104. -
mfo,mfc,mcpandmfecan be added to the status report list.
The reply to {"mfo":0.5} confirms that the request was accepted. The machine changes speed at the next point in the planned path where it can reach the new speed smoothly, within its acceleration and jerk limits; mfc changes to the new factor at that moment. If no remaining part of the queued path can take the change, the request waits until one can.
The factor applies to feed moves: G1, G2 and G3 in units-per-minute mode (G94), long or short, including moves that are already queued in the planner. A change is blended into the queued path, so the whole remaining job runs as if every F word had been scaled by the factor. On a test machine running a 600 mm/min job, a change to 50% started slowing the axis about 0.4 s after the request and reached the new speed within about 0.8 s, with no overshoot. Rapids (G0), inverse-time moves (G93), homing, probing and jogging are not affected.
Build 450.05 was more limited: there the factor took effect only in the constant-speed part of a long straight G1 move, each new move restarted at its programmed feed, and arcs and short moves were not slowed. Update to 450.06 or later if you depend on override for jobs made of short moves or arcs.
The factor scales the programmed feed rate. Axis and motor speed limits, acceleration and jerk still apply, so 200% does not promise twice the speed; mcp reports when a limit capped it. Read vel in a status report for the actual speed.
During a feedhold a new factor is accepted and used after resume. Changing the factor never resumes motion by itself.
Three switches must all allow override:
-
m48eandmfoe, set by the host (the operator); - the program's own permission, set by G-code in queue order:
M48enables,M49disables,M50(orM50 P1) enables andM50 P0disables. Other P values are refused with status 161.
Writing m48e or mfoe to 1 cannot override an M49 in the program. Changing permission keeps the requested factor. M48 and M49 switch spindle override on and off as well; M51 controls spindle override alone (see below).
From build 450.06 the spindle speed can be overridden the same way, from 5% to 200%, with g2core's names.
| Token | Access | Meaning | Default |
|---|---|---|---|
sso |
read/write | Requested spindle speed factor, 0.05 to 2.0 | 1.0 |
ssoe |
read/write | Operator spindle override enable, 0 or 1 | 1 |
ssc |
read only | Spindle factor currently in effect | 1.0 |
scp |
read only | 1 if the spindle speed range capped the result | 0 |
sse |
read only | Effective permission: 1 only if m48e, ssoe and the program all allow it |
1 |
Like the feed values these are never saved, so they are accepted while a job runs; out-of-range values return status 110.
- While the spindle is on (
M3orM4) the output changes at once toStimes the factor, limited to the configured spindle speed range (p1csl/p1cshfor clockwise,p1wsl/p1wshfor counter-clockwise);scpreports when the range limited it.spsreads the resulting speed. - The factor never starts a stopped spindle.
M5, an alarm, shutdown or a job kill turn the spindle off as usual, whatever the factor. - There is no change to motion planning: the factor only changes the spindle PWM output.
- Program permission:
M48/M49enable and disable both feed and spindle override;M51(orM51 P1) enables andM51 P0disables spindle override alone, following the LinuxCNC M51 definition. They execute in queue order. Other P values are refused with status 161. - A board reset, a job kill (^D) and program end (
M2/M30) restore the factor to 1.0,ssoeto 1 and the program permission to enabled, like the feed values. A feedhold stops motion only, so the spindle keeps running at the overridden speed during a hold.
A board reset, a job kill (^D) and program end (M2/M30, when it executes in the queue) restore the factor to 1.0, both operator switches to 1 and the program permission to enabled, following the LinuxCNC program-end rule. A queue flush (%) or feedhold keeps the operator's requested factor.
A host that wants to be told when the factor changes can enable events with {"rt":{"ov":1}} (0 turns them off). Events are sent at most once per status report interval, each on its own line without a footer:
{"ov":{"v":1,"q":4,"mfo":1.500,"mfc":1.500,"mfe":1,"capped":true}}
q is a revision number that increases with every change. {"rt":{"ov":null}} asks for one event even when events are off. Events stay enabled after a job ends, so the host sees the reset. See Runtime Session (rt) for the rt family; the older rt forms still work: {"rt":{"mfo":0.5}} is the same as {"mfo":0.5}, writing rt.mfe sets mfoe, and reading rt.mfe gives the effective permission mfe.
The names, ranges and the "not saved" behaviour match g2core, so the same host commands work on both. Differences:
- TinyG switches override on by default (
m48eandmfoeare 1); on g2core the host turns them on first. - TinyG keeps the program's permission (
M48/M49/M50) separate from the operator switches, so anM49in the program cannot be undone from the host. - A change also retimes moves already in the planner, as described above.
- Rapid override is not implemented: there is no
mtocontrol. - Spindle override uses the same names as g2core (
sso,ssoe) and is on by default;sseandscpare TinyG additions.
Getting Started Pages
- Home
- What is TinyG?
- Getting Started
- Connecting TinyG
- Configuring TinyG
- Sending Gcode Files
- Flashing TinyG
- Chilipeppr
Reference Pages
- TinyG Help Page
- TinyG Tuning
- TinyG Command Line
- TinyG JSON
- How TinyG Keeps Real Time
- XMEGA Performance and Peripherals
- Jogging from a Host
- Gcode Support
- Homing and Limits
- Inch and MM Units
- Alarms and Exceptions
- Coordinate Systems
- Status Codes
- Status Reports
- Runtime Session (rt)
- Power Management
- Feedhold and Resume
- Feed Override
- Licensing
- TinyG v8 Data Sheet
Discussion Topics
- Test-Drive-TinyG
- Jerk Controlled Motion
- Gcode Parsing
- Shapeoko Setup
- OX CNC TinyG Guide
- Creating Gcode Files
- Milling With Noisy Spindles
- Stepper Motors and Power Supplies
- Text Wrappers and Transaction IDs
- Using External Drivers
- TinyG Projects
Chilipeppr
- Chilipeppr
- Chilipeppr Advanced Usage
- Chilipeppr Archive and Restore Parameters
- ChiliPeppr PCB Auto Level
- Automatic Z Homing When Milling PCBs
Troubleshooting
Developer Pages