Shop OBEX P1 Docs P2 Docs Learn Events
EEPROM smaller than 32K? — Parallax Forums

EEPROM smaller than 32K?

pedwardpedward Posts: 1,642
edited 2012-02-13 10:19 in Propeller 1
What does the Prop do if an EEPROM is smaller than 32K? Does it choke? Does the EEPROM return $FF for every byte past the end?

I've got (500) 1K EEPROMs sitting in tubes, I've wondered if I could put a small SPIN program on them and use them for the prop.

Comments

  • RaymanRayman Posts: 14,845
    edited 2012-02-13 02:55
    I tried a 16kB ROM chip a long ago. I think it didn't work. It may have been the Prop Tool that didn't like it though...
    Maybe if it were programmed a different way, it would work?
  • BeanBean Posts: 8,129
    edited 2012-02-13 04:04
    I think it will just wrap around and load the same bytes over again (or over and over for the 1K part).

    Bean
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-02-13 06:07
    If you write the EEPROM using the Prop loader it always writes 32K to the EEPROM, so when it's done a 1K EEPROM will contain the last 1K of the 32K. This would be all zeros for any program less than 31K in size. You could write the EEPROM yourself, and use it for booting. On boot up the Prop will fill the RAM with 32 copies of the 1K EEPROM. This will work OK as long as you don't depend on the area beyond the program being zero. However, you'll probably run into a problem with the page size of the 1K EEPROM. The boot loader uses a page size of 64 bytes.
  • pedwardpedward Posts: 1,642
    edited 2012-02-13 08:51
    Encouraging comments; I use BST and it only programs the amount of data your program takes.

    I'll toss a chip on the board and try it, wanted to float the idea and see if it might be possible.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-02-13 09:11
    pedward wrote:
    I use BST and it only programs the amount of data your program takes.
    I'm not sure I believe that. Upper EEPROM has to be zeroed. That's how global variables get initialized at boot-up, i.e when upper RAM is loaded with those zeroes.

    -Phil
  • Mark_TMark_T Posts: 1,981
    edited 2012-02-13 10:04
    I'm not sure I believe that. Upper EEPROM has to be zeroed. That's how global variables get initialized at boot-up, i.e when upper RAM is loaded with those zeroes.

    -Phil

    Judging by the upload times BST uploads the full 32k to the EEPROM but only the minimum necessary when just to the Propeller chip itself.
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-02-13 10:19
    The source for the booter program is located at http://forums.parallaxinc.com/forums/default.aspx?f=25&p=1&m=252691 along with the interpreter and runner programs. The booter program is loaded in cog 0 on powerup/reset. It drives the serial port and reads and writes the EEPROM. It will zero out the remaining portion of the RAM if only part of it is loaded from the serial port, and it will write all 32K of RAM to the EEPROM if commanded to do so. If it is used to load from the EEPROM it will load the entire 32K image into RAM. It uses a page size of 64 bytes.
Sign In or Register to comment.