nicolad76
04-27-2008, 09:17 PM
Hi,
I have found above driver (designed for AT24C1024) and I adapted it for 24FC1025. It seems working fine..only thing I did was to proprly change the device_address·to properly address my chip.
I have run the below test
imgtc is defined as byte imgt[512]
· 'start eeprom driver
· eeprom.start(8, 9, 0)
· debug.start(31,30)
·
· ' put some data in array
· repeat c from 0 to 511
·· imgt[c]:=c // 255
· 'write·to EEPROM
· eeprom.write(@imgt, $00, 512)
· repeat until eeprom.IsDone
· 'clean up array
· repeat c from 0 to 511
·· imgt[c]:=$00
· 'read back array
· eeprom.read(@imgt, $00, 512)
· repeat until eeprom.IsDone
· repeat c from 0 to 511
·· debug.bin(imgt[c],8)
well...the output shows like this one
·[10000001]
·[10000010]
·[10000011]
·[10000100]
·[10000101]
·[10000110]
·[10000111]
·[10001000]
·[10001001]
·[10001010]
·[10001011]
it seems taking the first bit as sign??? which means it takes 7 bit data...
am I doing anything wrong here or I should work on the driver?
I have found above driver (designed for AT24C1024) and I adapted it for 24FC1025. It seems working fine..only thing I did was to proprly change the device_address·to properly address my chip.
I have run the below test
imgtc is defined as byte imgt[512]
· 'start eeprom driver
· eeprom.start(8, 9, 0)
· debug.start(31,30)
·
· ' put some data in array
· repeat c from 0 to 511
·· imgt[c]:=c // 255
· 'write·to EEPROM
· eeprom.write(@imgt, $00, 512)
· repeat until eeprom.IsDone
· 'clean up array
· repeat c from 0 to 511
·· imgt[c]:=$00
· 'read back array
· eeprom.read(@imgt, $00, 512)
· repeat until eeprom.IsDone
· repeat c from 0 to 511
·· debug.bin(imgt[c],8)
well...the output shows like this one
·[10000001]
·[10000010]
·[10000011]
·[10000100]
·[10000101]
·[10000110]
·[10000111]
·[10001000]
·[10001001]
·[10001010]
·[10001011]
it seems taking the first bit as sign??? which means it takes 7 bit data...
am I doing anything wrong here or I should work on the driver?