Question on ext. EEPROM and 08M

Mx5Daz

New Member
Is there a way of using an external EEPROM with a PICAXE-08M?

I know I can use an 18X and i2c a lot more easily but the due to the lower cost of these chips I'm experimenting to see if I can use an 08M.

The EEPROM I want to use for development purposes is the 24LC512. If there are other more suitable EEPROMs I'm all ears, but that's what I have to work with at the moment.

I'm sure this has been covered before but I promise I did search. Nothing came up that seemed to cover it though.

Cheers

Darren
 

hippy

Ex-Staff (retired)
Have a read of the following thread which discusses some of the issues of I2C with 08M -

http://www.picaxeforum.co.uk/showthread.php?t=13792

I've included an 08M driver for byte addressed I2C Eeprom ( up to 24LC16 ) but going to word addressed means updating the code. Not sure when I will have the time to do that though you should be able to do it yourself.

The current easy options then are; 08M plus smaller I2C Eeproms, 18X and upwards for larger I2C Eeproms.
 

westaust55

Moderator
Untested by myself, but a possible alternative to an i2c Serial EEPROM might be an SPI Serial EEPROM. (eg 25LC512)

http://ww1.microchip.com/downloads/en/DeviceDoc/22065B.pdf

The bit-bash code for the SHIFTIN and SHIFTOUT commands in the PICAXE Manual 2 could be adapted.

would require 3 wires instead of 2 however.

Whether you could still get this usefully into an 08M and have program space remaining for your application ?????
 

Mx5Daz

New Member
Thanks for the input guys.

The program itself is quite simple, the interface code would take up most of it.

I think I'm rapidly running out of i/o though, so I don't think it's looking like a viable option. No, in fact it won't because I need minimum 2 ADC inputs, plus EEPROM interface and DAC out, it just won't all squeeze into an 08M.

A 14M might work but since I don't have any I'd have to buy one to experiment with and that's kind of negating the point. Going up from that just gets me closer cost-wise to the 18X/20X2 that I already have.

I think I'll make my life easier and use an 18X or 20X2. They just seem like overkill for the task!

Hippy: I might have a go at your i2c code at some point to see if I can get it to work with word addressed chips, just for the sake of interest. There used to be a trick on old 8bit computers where concatenating lines of code would take less space by a couple of bytes. Does this trick work with PICAXE? I'd guess not since it's compiled code not interpreted but it's worth an ask!

Thanks for the help.

Daz
 

hippy

Ex-Staff (retired)
I tried tweaking the code for word addressed Eeprom but it just doesn't seem to pss all tests and I don't have the time to investigate.

No, concatenating lines doesn't save any memory use on the PICAXE. Turning mutliple math manipulating lines into a single line usually will.
 
Top