Struggling to write to External EE with the latest version

Coding and general discussion relating to the compiler

Moderators: David Barker, Jerry Messina

Post Reply
CHRISHODDYSON
Registered User
Registered User
Posts: 9
Joined: Tue Jul 03, 2007 8:55 pm
Location: SOUTHAFRICA

Struggling to write to External EE with the latest version

Post by CHRISHODDYSON » Mon Oct 21, 2013 3:37 pm

Hi I am struggling to write to to External EE "24LC512" with the latest version
My previous program compiles work fine
CHRISO

bitfogav
Registered User
Registered User
Posts: 169
Joined: Sat Oct 09, 2010 1:39 pm
Location: United Kingdom

Post by bitfogav » Mon Oct 21, 2013 4:35 pm

You need to give us more information of what exactly your problem is writing to the 24LC512, Do the compiler give you any code errors? Can you post any code?.

CHRISHODDYSON
Registered User
Registered User
Posts: 9
Joined: Tue Jul 03, 2007 8:55 pm
Location: SOUTHAFRICA

Post by CHRISHODDYSON » Mon Oct 28, 2013 6:47 am

I have 8 memory chips the code bellow writes to number 3 . My program is huge 80333 bytes on a PIC18f4685. I am not sure about the jump limitations. I can read the eeprom but not write. My program runs smoothly with the previous compiler version.


EEPROM_Address = %011
EEPROM_Family = %1010
EEPROM_Control = (EEPROM_Family << 4) Or (EEPROM_Address << 1) // put the controll byte together
DelayMS(100)

TransactionsM2.byte0 = EEPROM_Read(0)
DelayMS(100)
TransactionsM2.byte1 = EEPROM_Read(1)
DelayMS(100)

If TransactionsM2 = 65535 Then
EEPROM_Write(0,0)
DelayMS(100)
EEPROM_Write(0,1)
DelayMS(100)
EndIf
CHRISO

Jerry Messina
Swordfish Developer
Posts: 1469
Joined: Fri Jan 30, 2009 6:27 pm
Location: US

Post by Jerry Messina » Tue Oct 29, 2013 10:43 am

Code: Select all

If TransactionsM2 = 65535 Then
EEPROM_Write(0,0)
DelayMS(100)
EEPROM_Write(0,1)
DelayMS(100)
EndIf
Is that the only write that doesn't seem to work, or is it just an example?

Post Reply