Current Monitor/Shunt

finally success!

so to recap:
download and setup an arduino IDE project out of the source file on jtag2updi. For good measure update your IDE to latest ver.
configure IDE for UNO and com port, upload code to UNO.
Then open new empty arduino IDE project, install MegaTinyCore boards, select right one.
Leave UNO connected (and doing nothing!) and wire it to Shunt:

UNO: capacitor 10-20uF from Reset to GND

UNO - Shunt wiring:
GND to GND
+5V to +5V
D6 → 4k7 resistor → Reset

following get avrdude (have latest 6.4) and run the following command (correct com port, had the hex file on the avrdude dir to avoid extra paths):

avrdude -v -p attiny1614 -C avrdude.conf -c jtag2updi -b 115200 -P "COM8" -F  -U flash:w:diyBMSCurrentMonitor_ATtiny1614.hex:i

NOTE: use the avrdude.conf file that came with the jtag2updi project and NOT the one that was with avrdude! Else it wont work (as shown in my last post log…)!

must have spent more than 6h to program the shunt…

cheers
V.

1 Like