Just getting to know embedded programming with the atmega8.
I've had some experience using the PIC chip with MicroCode Studio and have switched to using the avr-gcc tool chain with the atmega8 chip. I've been spending a good few weeks getting up to speed on transferring my knowledge of the PIC to the avr, looking over the docs and all.
I'm using a atmega8 development board from sparkfun w/ the avrisp. It works fine. In fact I've got a basic blinking program working on the dev board itself. The board comes with an 8mhz clock.
Now I'm putting the atmega8 onto a prototyping board with a 4mhz clock. I've modified the code the run on a 4mhz clock (like the delay function), but nothing happens.
When I use the exact same circuit with a 20mhz clock, I get blinking (at a ridiculous speed of course).
Seems like I'm doing some tiny thing wrong here, any thoughts as to why I don't get anything while using a 4mhz clock, but get results from a 8mhz and 20mhz clock?
Many thanks, David