Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
tsb:home [2019/04/08 14:45] – Pedro Ramilo | tsb:home [2019/10/24 12:23] (current) – [Configurable Timeout, Password, Magic Bytes] Pedro Ramilo | ||
---|---|---|---|
Line 4: | Line 4: | ||
The Tinysafeboot is a compact, feature-rich bootloader for ATMEGA and ATTINY devices.\\ | The Tinysafeboot is a compact, feature-rich bootloader for ATMEGA and ATTINY devices.\\ | ||
- | It was originally written by [[Julien Thomas|http:// | + | It was originally written by [[http:// |
===== Main Features ===== | ===== Main Features ===== | ||
Line 16: | Line 16: | ||
* Capable of individually initiating a bootloader session (for firmware update, for example) with multiple devices connected in a daisy chain (each device needs a unique password, for individual activation) | * Capable of individually initiating a bootloader session (for firmware update, for example) with multiple devices connected in a daisy chain (each device needs a unique password, for individual activation) | ||
- | ===== Improvements and New Features ===== | + | ===== Improvements and New Features |
All our improvements and new features are published open source in the Github repository above. | All our improvements and new features are published open source in the Github repository above. | ||
So far we have: | So far we have: | ||
- | * Written a new PC side software in Mono (compatible with Windows/ | + | * Written a new PC side software in Mono (compatible with Windows/ |
* Written a GUI (Windows, C#) to to offer a Graphical Interface for the command line options | * Written a GUI (Windows, C#) to to offer a Graphical Interface for the command line options | ||
* Fixed a bug in the password checking that impaired operation when multiple devices are daisy chained (backwards compatible fix) | * Fixed a bug in the password checking that impaired operation when multiple devices are daisy chained (backwards compatible fix) | ||
- | * Added Configurable "Magic Bytes" where you can program 2 bytes (identify different models, batch numbers, ...). This is stored separately from the program Flash and EEPROM areas for protection. | + | * Added Configurable "Magic Bytes" where you can program 2 bytes (identify different models, batch numbers, ...). This is stored |
Line 45: | Line 45: | ||
The Timeout, Password and Magic bytes are stored in the Last Page of the Program area (just below the bootloader). | The Timeout, Password and Magic bytes are stored in the Last Page of the Program area (just below the bootloader). | ||
- | This is a safe way to ensure configuration | + | Because this Last Page is within the program area, it can be re-written using commands to write FLASH contents.\\ |
+ | Since only the bootloader can write program pages, storing this data in a program page is a safe way to ensure configuration won't be overwritten inadvertently. | ||
- | Because | + | The TSB binary on the device ensures |
- | Furthermore, | + | |
+ | Programmers | ||
**Configuration Data** is stored in the **Last Page** of Program space, in the following manner: | **Configuration Data** is stored in the **Last Page** of Program space, in the following manner: | ||
Line 64: | Line 66: | ||
[1] Password byte 1 | [1] Password byte 1 | ||
[0] TIMEOUT (byte) | [0] TIMEOUT (byte) | ||
- | BOTTOM | + | START OF LAST PAGE |
</ | </ | ||
'' | '' | ||
- | The **Magic Bytes** and **0x00 fix** at the top of Last page are only possible when using Seed RObotics' PC side loader tool; the old/ | + | The **Magic Bytes** and **0x00 fix** at the top of Last page are only possible when **using Seed Robotics' PC side loader tool**; the old/ |
+ | These features are compatible with all firmware versions of the TSB bootloader (even older versions before the Seed Robotics contributions), | ||
+ | |||
+ | In reality, if you refer to the source code of our loader tool, you will see the TSB binary on the ATMEL device gives you a command to write whatever you want to the remaining space in Last Page, after the Timeout and Password are written.\\ | ||
+ | For us, at Seed Robotics, we felt it could be leveraged by adding a storage space for 2 magic bytes. Nevertheless the possibilities are endless as the bootloader on the device side gives you access to write the full page contents. | ||
Copyright © 2015-2023 Seed Robotics Ltd