Page 1 of 1

Replacing the firmware

Posted: Mon Dec 14, 2020 7:42 pm
by xopxe
Hi to all.

I assembled a Geiger Counter and successfully log it through the serial.
I was thinking of replacing the stock firmware with a version that would not report once per second as now, but send a message on each click. So no accumulation or computation would be made on the microcontroller, just send something on each led blink. All the accumulation, averaging, etc, would be done on the host. Or the micro could send a timestamp, and then this could be used as a hardware random number generator, for example.

I see there are the sources, and it would be easy to modify from them, but Is there a tutorial on flashing the ATtiny2313? Never flashed one of those, only some old Microchip stuff (PIC16, PIC18) and "powerful" stuff like Cortex-M or ESP32s.

Re: Replacing the firmware

Posted: Sat Jan 02, 2021 11:27 am
by mightyohm
Hi there,

This is a good suggestion - I don't think that I ever wrote a tutorial on how to do this.

You'll need an AVR programmer and a toolchain. The tools have changed a bit since I wrote the code for the kit, but at the time I used Atmel's AVR Studio for development. However, there are open toolchains as well. What operating system are you using?

I've used a few different programmers, but one option is the Adafruit USBtinyISP:

Re: Replacing the firmware

Posted: Sat Apr 24, 2021 1:04 pm
by xopxe
Oh, sorry for the late response, I just assumed I would be notified by email :(
I normally work in Linux, but have no problem using whatever is necessary (when I used Microchip programmers they only worked in Windows).
So, if I understand right, there's no bootloader on the AVR, so you burn the firmware using a programmer through the ICSP lines?
A tutorial would be very welcome.


Re: Replacing the firmware

Posted: Sat Jun 12, 2021 2:34 pm
by mightyohm
Yes, you have to use an AVR programmer and the ICSP lines. Thanks for the feedback, I agree that a tutorial would be helpful.