how_to:atmega2560:upload_rflink_firmware

Upload the RFLink firmware

The reference guide to upload the RFLink firmware using the CLI interface of avrdude is here.

The d-diot image is shipped with a copy of the RFLink firmware, including the license file, and it is located at the following path /home/pi/atmega2560/rflink.
At the time of writing this guide, the last release of RFLink is R48; visit this page to download other releases or to look for updates.

To upload RFLINK to the ATmega2560 follow the steps below.

Stop Home Assistant if the RFLink is configured.

pi@d-diot:~ $ sudo systemctl stop home-assistant@homeassistant

Stop mysensors nrf24 process and then set the jumper JP2 to RST position, bridging the P33 and RST pin.

pi@d-diot:~ $ sudo killall mysgw-nrf24

Upload the RFLink firmware

pi@d-diot:~ $ avrdude -v -p atmega2560 -c wiring -P /dev/serial0 -b 115200 -D -U flash:w:/home/pi/atmega2560/rflink/RFLink.cpp.hex:i

To exit, if something goes wrong, press CTRL + ALT + c

Set the jumper JP2 to IRQ bridging he P33 and IRW pin, restart MySensors nrf24 gateway and Home Assistant.

pi@d-diot:~ $ sudo nohup /home/pi/MySensors/nrf24/bin/./mysgw-nrf24 >/dev/null 2>&1 &
pi@d-diot:~ $ sudo systemctl start home-assistant@homeassistant

Set the jumper 4 fo the DIP switch to ON and the jumpers 3 and 5 to OFF, then upload the RFLink firmware

pi@d-diot:~ $ avrdude -v -p atmega2560 -c wiring -P /dev//dev/ttyAMA1 -b 38400 -D -U flash:w:/home/pi/atmega2560/rflink/RFLink.cpp.hex:i

To exit, if something goes wrong, press CTRL + ALT + c

Set the jumper 4 fo the DIP switch to OFF and restart home assistant

pi@d-diot:/home/pi/atmega2560/arduino-mk $ sudo systemctl start home-assistant@homeassistant

  • how_to/atmega2560/upload_rflink_firmware.txt
  • Last modified: 2020/07/26 15:13
  • by franzunix