Skip to content

Commit

Permalink
Documentation updates
Browse files Browse the repository at this point in the history
  • Loading branch information
benlye authored Apr 10, 2019
1 parent 9de4b88 commit 22b1693
Show file tree
Hide file tree
Showing 12 changed files with 42 additions and 11 deletions.
53 changes: 42 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This plugin can be used to flash pre-compiled firmware images to your printer from a file or URL.

<p align="center"><img alt="Firmware Updater" src="extras/img/updater.png"></p>
<p align="center"><img alt="Firmware Updater" src="extras/img/firmware-updater.png"></p>

Works with boards with Atmel AVR family 8-bit MCUs (Atmega1280, Atmega1284p, and Atmega2560) MCUs, and Atmel SAM family 32-bit MCUs (Arduino DUE).

Expand Down Expand Up @@ -56,7 +56,7 @@ sudo cp ~/BOSSA-1.7.0/bin/bossac /usr/local/bin/
In order to be able to flash firmware we need to select and configure a flash method. Once the flash method is selected additional options will be available.

### AVRDUDE Configuration
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/avrdude-settings.png"></p>
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/avrdude-config.png"></p>

The minimum settings are:
* Path to avrdude
Expand All @@ -71,23 +71,54 @@ Typical MCU/programmer combinations are:
| Atmega2560 | wiring | RAMPS, RAMbo, etc. |
| Atmega644p | arduino | Sanguinololu, Melzi |

#### Avrdude Advanced Settings
All advanced settings are optional.
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/avrdude-adv.png"></p>

### BOSSAC Configuration
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/bossac-settings.png"></p>
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/bossac-config.png"></p>
The only required setting is the path to the bossac binary.

#### BOSSAC Advanced Settings
All advanced settings are optional.
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/bossac-adv.png"></p>
### Customizing the Command Lines
The command lines for avrdude and bossac can be customized by editing the string in the advanced settings for the flash method. Text in braces (`{}`) will be substituted for preconfigured values if present.

| String | Description|
| --- | --- |
| `{avrdude}` | Full path to the avrdude executable<sup>1</sup> |
| `{bossac}` | Full path to the bossac executable<sup>2</sup> |
| `{mcu}` | Avrdude MCU type<sup>1</sup> |
| `{programmer}` | Avrdude programmer<sup>1</sup> |
| `{port}` | COM port the printer is connected to |
| `{conffile}` | Full path to the avrdude configuration file<sup>1</sup> |
| `{baudrate}` | Serial port speed<sup>1</sup> |
| `{disableverify}` | Switch to disable write verification |
| `{firmware}` | Path to the uploaded firmware file |

1. Avrdude flash method only
2. Bossac dude flash method only

#### Command Line Defaults
Command lines can be returned to the default by clicking the **Reset** button.

##### Avrdude
`{avrdude} -v -q -p {mcu} -c {programmer} -P {port} -D -C {conffile} -b {baudrate} {disableverify} -U flash:w:{firmware}:i`

##### Bossac
`{bossac} -i -p {port} -U true -e -w {disableverify} -b {firmware} -R`

### Post-flash Settings
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/post-flash-config.png"></p>

#### Post-flash Delay ####
This setting can be used to insert a delay of up to 180s after the firmware has been uploaded, before OctoPrint will try to reconnect to the printer. This can be useful if the board takes some time to restart. A delay of 20-30s is usually enough.

#### Post-flash Gcode ####
You can use the post-flash gcode settings to run gcode commands after a successful firmware flash.
<p align="center"><img alt="Firmware Updater Settings" src="extras/img/post-flash.png"></p>
The post-flash code will run more or less immediately if the printer was connected before the flash started (so reconnects automatically when the flash finishes), or whenever the printer is manually reconnected after the firmware is flashed.

## Flashing
Once the plugin is configured, flashing firmware is a simple operation:
1. Select the COM port to communicate with the board
1. Select a firmware file, either located on the filesystem or via a URL
1. Click the appropriate **Flash from** button
1. Wait for the firmware update to complete

## Troubleshooting
Log messages can be found in the OctoPrint log `octoprint.log` and the Firmware Updater's console log `plugin_firmwareupdater_console.log`.

Expand Down
Binary file removed extras/img/avrdude-adv.png
Binary file not shown.
Binary file added extras/img/avrdude-config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed extras/img/avrdude-settings.png
Binary file not shown.
Binary file removed extras/img/bossac-adv.png
Binary file not shown.
Binary file added extras/img/bossac-config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed extras/img/bossac-settings.png
Binary file not shown.
Binary file added extras/img/firmware-updater.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added extras/img/post-flash-config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed extras/img/post-flash.png
Binary file not shown.
Binary file removed extras/img/updater-settings.png
Binary file not shown.
Binary file removed extras/img/updater.png
Binary file not shown.

0 comments on commit 22b1693

Please sign in to comment.