Life-giving to Atmega8

I have got two ATmega microcontrollers from my friend. He stated that they are burned and can be thrown into the garbage. He also mentioned that they stopped responding after they were programmed. So I asked him to give those to me to try them. I had in my mind that this is a result of a bad usage of security bits. There is always confusion in these bits because of writing ‘0’ values program security bits and unprogrammed with ‘1’. I didn’t really expect to make them working again as my friend did quite rude experiments with them. What can I say – he was right by saying they are burned. But I guess some of you will like to see what I was doing to recover them. I decided that he unprogrammed all four security bits ( CKSEL0, CKSEL1, CKSEL2, CKSEL3 )by writing ‘1’ to them. This situation means that Atmega8 has to be clocked from an external clock signal. I was supposed to program those bits to work ATmega normally with a quartz resonator.

Continue reading