How does EEPROM work
Computeruser
Posts: 16
I have been working through the online documentation here as well as my book "Robotics with the Boe-Bot V3.
I have the Basic Stamp Robot running and it will do straight lines forward and back. I am going to work on some turns next.
But I look ahead and see the topic "Building Complex Maneuvers in EEPROM". I reviewed this topic and I have a couple of questions:
1. On the module, there appears to be a microcomputer and 2 EEPROM chips, each holding 1Kb of memory (2048 bytes total). Is this correct?
2. Is there any other memory (other than the 32 working bytes in the microcomputer)? I think not, but I am not sure.
3. When I run any program (even the first ones) do they all just go into EEPROM? I think they must.
4. Does each and every program go to the beginning of EEPROM and overwrite the previous program?
I want to try EEPROM Navigation and also try Avoiding a Table edge.
I have the examples in the book and can key them into the software on my computer. Can the programs be downloaded from your site? It would save time keying in programs.
Thanks, .... C
I have the Basic Stamp Robot running and it will do straight lines forward and back. I am going to work on some turns next.
But I look ahead and see the topic "Building Complex Maneuvers in EEPROM". I reviewed this topic and I have a couple of questions:
1. On the module, there appears to be a microcomputer and 2 EEPROM chips, each holding 1Kb of memory (2048 bytes total). Is this correct?
2. Is there any other memory (other than the 32 working bytes in the microcomputer)? I think not, but I am not sure.
3. When I run any program (even the first ones) do they all just go into EEPROM? I think they must.
4. Does each and every program go to the beginning of EEPROM and overwrite the previous program?
I want to try EEPROM Navigation and also try Avoiding a Table edge.
I have the examples in the book and can key them into the software on my computer. Can the programs be downloaded from your site? It would save time keying in programs.
Thanks, .... C
Comments
2. Nope. Use a Propeller (32k ram) or a fancy BS2 module (e.g. BS2e or BS2px) (64 or 128 bytes scratch-pad ram + 32 bytes normal ram) if you need more memory.
3. Yes, there's no where else they could possibly fit.
4. Program memory starts at the end and fills towards the bottom. Push Ctl+M for the memory window. The blue stuff at the bottom is your program, and a 16 byte line will only get overwritten if there's blue in it.
Do this if you're afraid your program will get too big and overwrite your data:
Replace "ptr" with where you want to put your data. Leave out the "@ptr," if you just want to put the data at the beginning (I think). "Count" represents how many bytes you want not to be overwritten.
.... C
There is one EEPROM on the Basic Stamp. Th schematic is here:
http://www.parallax.com/Portals/0/Downloads/docs/prod/schem/BS2-IC-Schematic-Rev-J.pdf
All the information is available on the lower right hand side of the product page:
http://www.parallax.com/Store/Microcontrollers/BASICStampModules/tabid/134/ProductID/1/List/1/Default.aspx?SortField=UnitCost,ProductName
So between the first post and now, I entered the EEPROM Navigation Program and tested it. It works, but as the manual notes, I need to make it a square.
Now all this is in my basement workshop with an old XP machine to do the programming. I stand in the workshop, and it is not comfortable to enter long programs. So I move the computer to my home office, entered the program, took it back to the shop, and tested everything.
Also entering programs (I do save them) is not entertaining work.
Is there a source of BASIC source code text on this site where I can download programs?
Thanks, .... C
My production machine for client work is a new(ish) Windows 8 Pro 64-bit machine. I don't know if the Basic Program will run on this machine, and anyway, I cannot confine it to my workshop.
I can make a folder on this machine to download some PDF's with sample code, extract the code, and then network this to the XP machine and move the code to it. It sounds longer than it actually is, so I will do it that way.
Thanks again, .... C