Uploading UART bootlader on ATtiny806 and flashing

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi, I am looking to upload a UART bootloader which is provided by microchip( AN2634 application note) on my ATtiny806. Currently I flash my Firmware using Atmel ICE and UPDI interface. Now I am looking to flash the firmware using a USB to UART chip (MCP2200). How can I add that bootloader provided by microchip on my application firmware and what are the changes I need to make in that bootloader for ATTiny806? I am using IAR IDE.

 

Thank you.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What is it you actually want to do? If your only aim is to use your MCP2200 to flash firmware to your tiny806, a bootloader is not required; just use pymcuprog.

How can I add that bootloader provided by microchip on my application firmware

Normally, you don't add the bootloader to your application. You would typically flash the bootloader to the chip using your Atmel ICE. You could then load your firmware to the t806 using UART and the python script AN2634 includes. The application will have to be compiled with options set to shift the application code to memory located after bootloader space. This is done using the ".text=0x.." option for avr-ld, but I don't know how this would be achieved in IAR, never having used it. The application note sets these steps out quite well.

If, in fact, you do want to add your bootloader to the application code (for e.g, to use in a production setup), an application called srec-cat (included in the avr-gcc toolchain) would do the job. 

what are the changes I need to make in that bootloader for ATTiny806

Just compile the project for ATtiny806, I don't think any other changes are required on the bootloader side of things. If you add any code to the bootloader, calculate and set the BOOTEND fuse accordingly.

-Sam

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Sanka1p wrote:
How can I add that bootloader provided by microchip on my application firmware
Build both programs as .hex then use srec_cat to join the two .hex into one.