Pages: [1]   Go Down
Author Topic: ATMega8 No Crystal  (Read 1400 times)
0 Members and 1 Guest are viewing this topic.
Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
   I would like to progam an ATMega8 to run without a crystal. I am reasonably confident that I can set up my current UNO to act as an ISP with optiLoader, which conveniently has an image for an ATMega8 boot loader built in.

   Looking at the ATMega8 datasheet I see that I would need to change some of the fuse settings to get it to run from an internal 8Mhz oscillator.

   Looking at the optiLoader source code, I see that the current fuses are set as follows -

during programming - 0x3F, 0xBF, 0xCC, 0, 0

after programming - 0x2F, 0xBF, 0xCC, 0, 0

However I have not been able to work out why there are apparently 5 bytes here.

I am making the dangerous assumption that the first two bytes are the low and high fuse bytes ?

From there I am going further out on a limb -

By using the fuse tool at this link I have attempted a configuration for the 8Mhz Internal Oscillator which gives me 24,BF for the low high fuses.

http://www.engbedded.com/fusecalc/

Can anyone confirm that my approach is correct and review my fuse settings ?

Your help is very much appreciated,
Thanks

  Duane B

rcarduino.blogspot.com

Logged


Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Well, if no one is going to stop me, there is only one thing to do.

Fingers crossed !

   
Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 33
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

did it work?
Logged

Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
   I noticed that my ATMega8's were actually a variety of different versions, some 16Mhz, some 8Mhz, at that point I got side tracked by some 328s that arrived from a back order I haven't gone back to the 8's yet but I still have them so will get around to this sometime soon.

Duane B
Logged


Norfolk UK
Offline Offline
Edison Member
*
Karma: 52
Posts: 2214
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I would like to progam an ATMega8 to run without a crystal. I am reasonably confident that I can set up my current UNO to act as an ISP with optiLoader, which conveniently has an image for an ATMega8 boot loader built in.
I think you need a bootloader suitable for use at 8mHz (or whatever internal clock speed you decide on). I burned a couple of ATmega8 chips using ArduinoISP on my UNO v2 board and they work well. Only small gripe is the bootloader is old and waits about 8 seconds from reset to starting the main program but it does not matter enough to de-solder the chips and put a better bootloader on as they only get re-booted once per day at most.
Logged

Handle every stressful situation like a dog. If you can't eat it or hump it. Piss on it and walk away.

Värmland, Sweden
Offline Offline
Sr. Member
****
Karma: 9
Posts: 261
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I think you need a bootloader suitable for use at 8mHz (or whatever internal clock speed you decide on). I burned a couple of ATmega8 chips using ArduinoISP on my UNO v2 board and they work well. Only small gripe is the bootloader is old and waits about 8 seconds from reset to starting the main program but it does not matter enough to de-solder the chips and put a better bootloader on as they only get re-booted once per day at most.

Did you ever try the Optiboot bootloader that I posted?
http://arduino.cc/forum/index.php/topic,116404.0.html
Logged

Norfolk UK
Offline Offline
Edison Member
*
Karma: 52
Posts: 2214
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Did you ever try the Optiboot bootloader that I posted?
http://arduino.cc/forum/index.php/topic,116404.0.html
Sorry perhof I never got round to it but I will be ripping one of the 8's out of service in a week or two (nearer two as I'm on holiday next week) and will try it then and let you know.
Logged

Handle every stressful situation like a dog. If you can't eat it or hump it. Piss on it and walk away.

Pages: [1]   Go Up
Jump to: