navigationGo.pngQuick Navigation
allprojects32.pngAll projects
hardware32.pngHardware
links32.pngLinks

favoriteStar32.pngTop projects
Alan numitron clock
Clapclap 2313/1386
SNES Pi Webserver
USB Volume/USB toys
Smokey amp
Laser cutter
WordClock
ardReveil v3
SNES Arcade cabinet
Game boy projects
cameleon
Home Presence Detector

github32.pngGitHub
AlanFromJapan

navigationMail.pngContact me

alanfjmail.png
3flags.pngWho's Alan?


Akizukidenshi
Elec-lab
Rand Nerd Tut
EEVblog
SpritesMods
Switch-science
Sparkfun
Suzusho
Datasheet Lib
Reddit Elec
Ermicro
Carnet du maker (fr)
Marutsu
ATmel blog (defunct)

ATmega88

kalshagar - atmega88

ATMega 88

Memo fact sheet

  • Code : 8192 Bytes / EEPROM : 512 Bytes / RAM : 1024 Bytes

Why use a ATMega88 instead of a 328 ? Well, ... price difference, if you have some in your toolbox, if you feel ashame of wasting a ATMega328 for writing that 2kb of code that does some bling-bling. Otherwise, no particular reason since those are basically the same. Except that you will suffer to have those working, since ARDUINO software doesn't support them. So you have to go to the WinAVR and rewrite basically whatever you need. That's a good occasion to make a micro kernel or understand what is really happening behind the Serial.println().

Setup working environment

Setup the avrdude

You need that to have avrdude able to upload the code. Basically, use the m88 and clone it to m88p (copy-paste).
To do this, in the avrdude.conf clone the m88 to one named m88p and update the signature to signature = 0x1e 0x93 0x0F; (see http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&p=564029)

...
#------------------------------------------------------------
# ATmega88P
#------------------------------------------------------------
 
part
    id               = "m88p";
    desc             = "ATMEGA88P";
     has_debugwire = yes;
     flash_instr   = 0xB6, 0x01, 0x11;
     eeprom_instr  = 0xBD, 0xF2, 0xBD, 0xE1, 0xBB, 0xCF, 0xB4, 0x00,
                 0xBE, 0x01, 0xB6, 0x01, 0xBC, 0x00, 0xBB, 0xBF,
                 0x99, 0xF9, 0xBB, 0xAF;
    stk500_devcode   = 0x73;
#    avr910_devcode   = 0x;
    signature        = 0x1e 0x93 0x0F;
...

Setup the fuses

Force to run using the 16 MHz crystal (by default, it use its internal 8MHz oscillator). Note the m88p to say we use a ATmega 88. You have to add its definition in the avrdude.conf file.
avrdude -v -v -c avrispv2 -p m88p -P com1 -U lfuse:w:0xd7:m
All content on this site is shared under the MIT licence (do what u want, don't sue me, hat tip appreciated)
electrogeek.cc ~ Formerly known as Kalshagar.wikispaces.com (AlanFromJapan [2009 - 2019])