EZ-I2C reading from FLASH

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
HuEl_264296
Level 5
Level 5
First like given 25 sign-ins First solution authored

I need to implement an EZ-I2C EEPROM emulator which can hold about 4kB of read-only data. This is obviously far too much to hold in RAM, but would easily fit in FLASH. This is for a CY8C3666LTI-079

   

 

   

However, the EZ-I2C API only lets me pass a void* pointer (which I assume can only point to RAM).

   

 

   

Is there some way I can make it take data from a FLASH array?  Or could the component easily be modified to enable this?

   

 

   

Hugo

0 Likes
5 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

A pointer in PSoC3 differs from "normal" pointers in that in the upper address-part the type of source (data, xdata,code) is encoded. So the chance that a pointer which addresses flash wil be quite normal to handle for I2C.

   

Nevertheless a small program for proof of concept would be helpful, I admit.

   

 

   

Bob

0 Likes
HuEl_264296
Level 5
Level 5
First like given 25 sign-ins First solution authored

 OK thanks. I will try this.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Oops, I just realize that eeprom size seems to be restricted to 2k maximum. There should be a workarpund for that, I'll investigate a bit more.

   

Bob

0 Likes
HuEl_264296
Level 5
Level 5
First like given 25 sign-ins First solution authored

 2048 bits? That's 256 bytes, or 8-bit address.

   

 

   

The EZ-I2C also supports 16-bit addresses.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Who is talking about Bits??? 2K Byte EEPRom of course.

   

And a pointer in C51 is 24 or 32 Bits(!) wide (Handled fully by compiler)

   

 

   

Bob

0 Likes