Hello all this is my first post
i recently downloading arduino and try a single example in protues we take atmega 168 and program of led blink and run led is blink but delay is not 1 sec it is 10 sec or 12 sec for on and off if i reduse
delay(10)[/b] in program then it blink for 1 sec .my questation is
1)is there any setting for atmega168 f(i.e. bootloader size,fuse bit and etc) in protues because i set all to default
2)is any other defining of crystal frequnce in programing
You need to reprogram the fuse bytes to say the mcu is running with a 16MHz clock, otherwise it defaults to internal 8MHz clock divided by 8. For the atmega328 the fuse bytes should be low 0xFF, high 0xDE, extended 0x05. The 168 is probably the same but I haven't checked. You can calculate the correct values at http://www.engbedded.com/fusecalc/.