EEPROM storage on OLED

I would like to use some of the 16 OLED on board EEPROM slots.

Do I have to send the full AXE133 program each time with the slots ammended or is there an abreviated way to just change the 16 slots EEPROM slots, or some of them.

The OLED datasheet and the Picaxe manual are rather scant in their information and assume a much higher paygrade than mine.

Thank you.
 

inglewoodpete

Senior Member
The OEM software provided for the AXE133 has provision for 16 x 16-character messages to be programmed into the 18M2's EEPROM. You can of course write text to any location on the OLED module by selecting a row/column and sending data to that point, all via 18M2 module's serial port.

If you want to download alternate sets of 16 'reusable' messages, it would be possible for you to develop code that would allow you to replace the EEPROM strings in the 18M2. However that coding would be up to you.
 

Eng460

Well-known member
I have recently bought an AXE133y display kit and have it working well with my current project. Highly recommended to enhance almost any project. As Inglewood Pete says it has provision for extra messages, but I for one am finding it a bit intimidating to see how to program those messages without having to reprogram the whole 18 M2+ chip that is supplied with the software installed, with Message 1, message 2 etc. It is easy to see where to put your messages in the supplied document for the program.

I am working in the background on understanding the display data sheet and have made some progress with a lot of help from this Forum. I agree provision is also made for additional outputs from the board which forms part of the kit, though you have to programme the associated functions that you want. But I would describe it as “not for the faint hearted.”

I would suggest, as a way of moving forward, that until you are confident, you start with a separate 18M2+ chip and program that either using the programming socket on the kit, or on a separate board, so that you keep the original chip unaltered to replace it if all goes pear shaped.

I admit I am probably over cautious, or is it timid, but I can’t yet see how to insert your messages without reprogramming the chip. The software is provided in .PDF Form so should be easy to copy onto the program editor and load up to your chip. It is quite easy to see what you have to do to just program in the messages. Very happy to be corrected on that and be shown how to do it, but not urgent for me at the moment, as I don’t have enough time to follow up. In the meantime I will be most interested to follow your progress.

Eng460
 

Aries

New Member
As the 18M2+ has two slots, then - assuming all the code supplied is in Slot 0 - would it not be possible simply to program a Slot 1 with only DATA? Admittedly, it might need all the data (depending on whether the undefined values are initialised or left as is, and I'm not sure when values are left alone), but it would save having to reprogram the display part each time.
 

inglewoodpete

Senior Member
As the 18M2+ has two slots, then - assuming all the code supplied is in Slot 0 - would it not be possible simply to program a Slot 1 with only DATA? Admittedly, it might need all the data (depending on whether the undefined values are initialised or left as is, and I'm not sure when values are left alone), but it would save having to reprogram the display part each time.
The 18M2 does have two 2048-byte program slots. However, the AXE133 code only uses 180 bytes of flash.

The OP was asking about reprogramming the 18M2's EEPROM. Easily done - the source code is freely available here. The AXE133 has a programming socket on board if you want play with it (or restore it to stock if you want/need to).
 

hippy

Technical Support
Staff member
If only programming the 16 Eeprom pre-programmed messages they only need to be edited once then downloaded to the 18M2 OLED driver chip. Once downloaded they will stay as programmed. One would only have to download again if one changed a message
 

Aries

New Member
The OP was asking about reprogramming the 18M2's EEPROM.
Exactly - what I was suggesting (if it worked) was just reprogramming the EEPROM (or DATA) without touching the program at all.

HOWEVER, I have just tried this with a 20M2 (I don't have an 18M2+) and it seems that DATA/EEPROM is ignored for Slot 1. As I use multiple slots regularly on 28X2 (including setting TABLE or DATA in slots other than 0), I assumed it worked over all Picaxes with multiple slots. It seems not.
 
Thank you.

Have that working with the full program as you say.

I did try just sending EEprom data but it all went dark!

Could someone elaborate on the controls, as for the LCD I read that you can make it go printer left or right, tried it with the OLED and gobdly goop went left or right and it all stopped.

I am using a 20 M2 to send the controls and it works fine, a bit more help getting it to look nice would be great.

Will the display move using commands rather than lines and lines of programming?
 

Aries

New Member
I did try just sending EEprom data but it all went dark!
If you literally just sent the EEPROM, then you would also send an empty program, so nothing would happen and the screen would probably be unchanged. My suggestion (see #7 above for why it won't work) was to use slot 1, which would leave the original program untouched.
 

Hemi345

Senior Member
What Aries proposed above does work. I did that just a few days ago on a 20M2 with a simple program like the following code:

Code:
#picaxe 20m2
#slot 1
write 0,20,45,0,100

Run 0
Make sure to include "run 0" at the end or power cycle the PICAXE after programming is complete. For whatever reason, the M2 chips will run the 2nd slot after programming is finished. If you don't have a directive to point that program back to slot 0, it'll appear as if the main program is messed up. That threw me off since I don't believe the X2 models exhibit this behavior.
 
Last edited:

AllyCat

Senior Member
Hi,
Could someone elaborate on the controls, as for the LCD I read that you can make it go printer left or right, tried it with the OLED and gobdly goop went left or right and it all stopped.

Will the display move using commands rather than lines and lines of programming?
If you mean "Horizontal Scrolling", then yes, the characters can be moved sideways, one character at a time, but you need the program to keep sending that command each time a "step" is required. Or you can set it up such that the "cursor" (character entry point) is fixed on the screen and the previously-entered characters automatically move along. Note that both (or all 4) rows move sideways together, and I have found no way to "Vertical Scroll" (except copying all the characters from one row into the next). For the basic commands, see (in particular) my post #42 in this recent thread .

Interestingly, the SSD1306 OLED display controller does have some "continuous" scrolling features, but they look so complex to set up that I haven't seen anybody attempt to use them ! ;)

Cheers, Alan.
 
Top