??? 01/17/13 02:11 Read: times |
#189207 - Some links to reduce work Responding to: ???'s previous message |
James Brzycki said:
To jim, I will look into doing the two eeprom thing as I can get my hands on a multiplexer and more eeproms. And it would be exactly what I asked, sounds rather simplier that the memory connections that I have going now. To handle the PC end, & most of the handshake stuff, it is best to find existing software. This page has good general lists http://bit.kuas.edu.tw/~8051/ and the link to here http://chaokhun.kmitl.ac.th/~kswichit.../easy2.htm has PC software and source code for PC read/write to parallel pins. So it is very close to what you need - in code flow terms, it is 100%. Only the lowest level port writes will need modifies, & strip out all Vpp stuff. For your pair of EEPROM device, look at SST39SF010A series. These are cheaper/more avail than 64K parts, and you can jumper wire A16, as a wear-leveling mechanism. With 20us single byte writes, (Baud rate is slower) write is easy Only the 100ms block erase needs a specific delay You will need to modify that code, to remove all the static Port access, and replace with XDATA Read/Write. (MOVX opcodes) Place that code (via work programmer) into your ROM wired device (WE#=HI,OE#=PSEN), and wire the RUN device as SRAM. (WE#=WRN, OE#=RDN) (do not add the Multiplex until this part is all working ) Then edit-and-retry your ROM code, until you can get all these steps working while(1) { getcommand(); prompting(); setcounter(); erase(); write(); read(); lock(); printchksum(); getinfo(); PGMparameters(); } A useful early test, is to comment out the Chip-action-lines inside erase(); write(); lock(); functions (but keep the handshake and delays), and thus test in READ only mode. Use your programmer to place a known pattern in the RAM part, and give that file to the PC link end. When you have full link operation, the PC will verify the device against the test pattern file you used to program it. Then, you can enable Erase action lines, and check you can read FFH's Finally enable the Write() action lines, & test. When all that is 100%, do a speed-up pass, to remove the unnecessary delays. SST39SF010A data will tell you what time is needed. Finally, add your Multiplexer to flip from Boot Download, to Run. Then, send your tested & commented code to the Author in link #2. |