tinySA | Main / Updating the firmware (2024)

Should you update the firmware?

The firmware of the tinySA can be updated by the user. If your device is functioning well there is no need to upgrade the firmware. A new firmware can add new functionality or even improve performance but if your tinySA is performing well there is no need to upgrade.
Updating the firmware is a safe as it is impossible to brick the tinySA. If an upgrade failed you may have to open the tinySA basic case and connect two points on the PCB (BOOT0 and VDD) to be able to try to upgrade again. For the tinySA ultra just press the jog button and power cycle to try again.

Saving your device specific configuration data (optional step)

If you have a new device and you did not change device specific configuration data you can skip this step

Part of the CONFIG data are the leveloffset for high and low mode as set by LEVEL CAL or ACTUAL LEVEL and the frequency dependent correction data. These will be reset to factory defaults when you do a clearconfig or when you install a FW with new/changed configuration or setting items. You can list the data using console mode and restore after updating and/or clearconfig.
The correction table is specific for a HW version and newer or older FW's may have a different correction table or you may have improved the correction table values.These are the commands you need to enter at the console prompt and the example responses:

ch> leveloffset
leveloffset low -3.0
leveloffset high 100.0
leveloffset low output 0.0
leveloffset high output 0.0
leveloffset switch 0.0
ch> correction low
index frequency value
correction low 0 10000 6.0
correction low 1 100000 2.8
correction low 2 200000 1.6
correction low 3 500000 -0.4
correction low 4 30000000 0.0
correction low 5 140000000 -0.4
correction low 6 200000000 0.4
correction low 7 300000000 3.0
correction low 8 330000000 4.0
correction low 9 350000000 8.1

A leveloffset of 100.0 implies the level has not yet been calibrated.

The next step is to update the firmware. This can be done either using a .dfu file or using the .bin file. Only one of these updates is needed, not both.

Video guide

Searching YouTube for "tinySA firmware update" will bring up several videos, one of the better is: https://youtu.be/i8CYCua8vqQ?t=396

Getting new firmware

New versions of the tinySA firmware can be downloaded from:

A sub folder contains all the old FW versions so you can go back to a previous version if needed.
Download the applicable tinySA_{version_number}.bin file to your PC

Updating the firmware using TinySA-App(Windows)

tinySA | Main / Updating the firmware (1)

Next step:

tinySA | Main / Updating the firmware (2)

Updating the firmware using a bin file and STM32CubeProgrammer(Windows)

WARNING: STM32CubeProgrammer version 2.16 has a bug and is NOT able to update the tinySA. Use version 2.15

For a nice guide to update using STM32CubeProgrammer and a bin file see this document: http://athome.kaashoek.com/tinySA/DFU/tinySA_Firmware_Update_STM32CubeProgrammer.pdf

When you can not connect using STM32CubeProgrammer and you are using a PC with USB 3.0 or newer a possible solution is to use an old USB 2.0 hub between the PC and the tinySA. Or you may try the next option, dfu-util.

Another possible problem with loading the DFU driver is an additional protection in Windows 10 and 11 that is enabled by default on some computers and that will block the DFU driver from loading. For more information see this post: https://groups.io/g/tinysa/message/10816

Updating the firmware using a bin file and dfu-util(Windows, Linux and Mac)

This is an alternative to using STM32CubeProgrammer

Get the tinySA_version_number.bin file from http://athome.kaashoek.com/tinySA/DFU/ or for the tinySA Ultra from http://athome.kaashoek.com/tinySA4/DFU/ and also download from there the files with names starting with DFU

Rename the downloaded file to tinySA.bin

Connect the tinySA with USB and activate the DFU mode:

  • tinySA: switch the tinySA on and enter DFU mode.
  • tinySA Ultra: press the jog button before switching on the tinySA Ultra. Switch on and the screen should stay black.

Download dfu-util from http://dfu-util.sourceforge.net/releases/ and check that you can execute it.

For windows, open a command window and go to the folder with the downloaded files and run DFU_LOAD_BIN.bat. The tinySA should now be updating with the tinySA.bin file using dfu-util-static.exe

On Linux and Mac make sure dfu-util can run from the command prompt. Go to the folder where you downloaded and renamed tinySA.bin and execute
dfu-util -a 0 -s 0x08000000:leave -D tinySA.bin

If the upgrade fails and you get a white or black LCD screen.

If the upgrade fails for some reason (wrong file, power failure) you may get a tinySA that seems to be bricked. Luckily it is impossible to brick the tinySA. Follow these steps to unbrick:

tinySA

  • Switch off.
  • Open the case by removing the 4 screws at the back
  • Connect the two pcb edge points marked VDD and BOOT0
  • Switch on.
  • Lcd turns white
  • You can disconnect the VDD and BOOT0 if needed
  • Connect to PC using the USB cable
  • Just to be double sure, open the device manager or Linux equivalent and check a DFU device is added and the driver is correctly loaded (no yellow exclamation mark)
  • Update firmware

tinySA Ultra

  • Switch off.
  • Press the Jog button down.
  • Switch on.
  • Lcd stays black
  • Connect to PC using the USB cable
  • Make sure you hear the happy sound from your PC to be sure a driver is correctly loaded. If this does not happen, try a different USB cable, a USB 2.0 port or different computer
  • Just to be double sure, open the device manager or Linux equivalent and check a DFU device is added and the driver is correctly loaded (no yellow exclamation mark)
  • Update firmware

After upgrading the firmware

Once the FW is upgraded reset the tinySA by switching off and on. The normal scanning screen should appear and the tinySA (if still connected) should appear as a serial over USB device in the Windows device manager or as a /dev/tty device under Linux

The FW maintains a checksum over the config data to detect if the structure of this data has changed with a new FW version. It is however good practice to clear the config data to be absolutely sure no old data remains possibly causing problems. This can be done with the CONFIG/MORE/CLEAR CONFIG command. After clearing the config the tinySA will automatically reset

Restoring your settings (if previously saved)

To restore the config, using the data recorded when saving the configuration above, issue these commands at the console prompt where the numbers are replaced by the data saved from your tinySA

leveloffset low -3.0
leveloffset high 100.0
leveloffset low output 0.0
leveloffset high output 0.0
leveloffset switch 0.0
correction low 0 10000 6.0
correction low 1 100000 2.8
correction low 2 200000 1.6
correction low 3 500000 -0.4
correction low 4 30000000 0.0
correction low 5 140000000 -0.4
correction low 6 200000000 0.4
correction low 7 300000000 3.0
correction low 8 330000000 4.0
correction low 9 350000000 8.1
saveconfig

tinySA | Main / Updating the firmware (2024)

References

Top Articles
Latest Posts
Article information

Author: Margart Wisoky

Last Updated:

Views: 5495

Rating: 4.8 / 5 (78 voted)

Reviews: 85% of readers found this page helpful

Author information

Name: Margart Wisoky

Birthday: 1993-05-13

Address: 2113 Abernathy Knoll, New Tamerafurt, CT 66893-2169

Phone: +25815234346805

Job: Central Developer

Hobby: Machining, Pottery, Rafting, Cosplaying, Jogging, Taekwondo, Scouting

Introduction: My name is Margart Wisoky, I am a gorgeous, shiny, successful, beautiful, adventurous, excited, pleasant person who loves writing and wants to share my knowledge and understanding with you.