Upload files using Marlin Binary File Transfer Mark II
Install via the bundled Plugin Manager or manually using this URL:
https://github.com/charleswillis3/OctoPrint-MarlinBft/archive/master.zip
This will transfer a file to a printer using Marlin firmware's experimental binary file transfer protocol.
General use:
Updating firmware on BigTreeTech boards:
bin
is in the "Accept file extensions" listM997
(marlin reset)firmware.bin
file. Click OK.It's also possible to transfer a file using the http api.
files
apiconnection
apimarlinbft
api:
POST /api/plugin/marlinbft
Content-Type: application/json
X-Api-Key: abcdef...
Body: { "command": "start_transfer", "handler_type": "api" "port": "/dev/ttyACM0", "baudrate": 250000, "local_path": "marlinbft/firmware.bin", "comm_timeout_ms": 1000, "wait_after_connect_ms": 3000, "post_transfer_gcode_enable": true, "post_transfer_gcode": ["M997"] }
The properties:
`command`
: required. must be the value "start_transfer"
`api`
: required. must be the value "api"
`port`
: required. the serial port the printer is connected on
`baudrate`
: required.
`local_path`
: required. the local path on the server to the uploaded file
`comm_timeout_ms`
: optional, settings override, int. the communication timeout
`wait_after_connect_ms`
: optional, settings override, int. if provided, how long to wait after establishing connection
`post_transfer_gcode_enable`
: optional, settings override, bool. whether to send gcode after the transfer completes
`post_transfer_gcode`
: optional, settings override, string array. the gcode to send
For settings override properties, if no value is provided the current configuration will be used.