#avr Logs

Aug 26 2020

#avr Calendar

01:41 AM rue_bed2: oh yea, I'm supposed to bring myself a bluepill and work out the usb serial emulation via C
05:49 AM polprog: https://youtu.be/rlxUHdo-okI
06:34 AM s-ol: hey, I'm having trouble setting the fuses on an ATMega16U2. It seems to be running fine, I already programmed it once via DFU and I can read the fuses with avrdude too (via arduinoISP)
06:35 AM s-ol: but now I want to switch from the 1MHz to 8MHz runmode, so using the fuse calculators I see I should change lfuse from 0x5E to 0xDE to disable the CKDIV8 bit
06:36 AM s-ol: however i always get a verification error and the fuse jumps back to the factory value (0x5E)
06:36 AM s-ol: what could be the cause of this? I have an external 8MHz oscillator with the two caps on the board.
06:46 AM cehteh: s-ol: just leave the clkdiv bit untoched and set the divider in your main() thats slightly more reliable as it doesnt depend on correct clkdiv setting
06:47 AM cehteh: check the rest of the fuses and is your programmer configured for faster speeds?
07:16 AM s-ol: cehteh: what do you mean by 'faster speeds'? the serial baud of the programmer?
07:17 AM s-ol: i'll try the frequency change in main though
07:18 AM cehteh: that wont fix it, but is jsut a suggestion
07:19 AM cehteh: i dont know the setup you have, but bootloaders for example often have to be compiled for the clockspeed they run under
07:23 AM s-ol: hm, i'm just using the stock USB-DFU (flip) bootloader and microchip only provides one binary for each MCU
07:24 AM cehteh: i never did such
10:19 AM [1]MrMobius is now known as MrMobius
11:45 PM day_ is now known as day