PDA

View Full Version : Program to convert & send eeprom dump!!!



mister_e
- 26th September 2004, 20:39
Hi,
This is maybe off topic but is there any existing program to take an EEPROM dump (.bin, .hex...) from a PC an send it by COM port??? I know that can be done easily but why reinvent the wheel???

many regards to all of you.

Dwayne
- 27th September 2004, 14:44
Hello Mister-e,

M>>This is maybe off topic but is there any existing program to take an EEPROM dump (.bin, .hex...) from a PC an send it by COM port??? I know that can be done easily but why reinvent the wheel???<<

Lets first get this straight.... Are you wanting to take data from your computer and transfer it to the PIC chip? or Take data from the PIC chip and transfer it to the computer?

Either way, PBP has serial communication that you can do data transfer with... Both directions. You may have to go at a slow baud rate...2400 or less (probably 300 for solid reliablity). I have used the old Procomm communication program for dos, to send/receive data to the PIC chip.

If this is not in the general direction of your question, I am sorry... I guess I misunderstood your quesiton.

Dwayne

mister_e
- 27th September 2004, 17:49
Hi Dwayne,
the goal of it is to update eeprom attach to an existing PIC Based project by software. Since we are able to update software of PIC by ICSP why not include a hidden function to update eeprom connected to it if it need to.

So i can edit my eeprom dump with the usual software on computer, save it to disk, and after it send it to PIC who will update the eeprom.

Sorry if i was not really clear in my questions.

thanks for help.

regards

Dwayne
- 27th September 2004, 18:13
Hello Mister-e,

Ok, then (if I understand correctly). Lets write a simple program to so such..

DEFINE CHAR_PACING 1000 '1 millisecond between characters.


Send Routine
ReadData var byte
For a = 0 to (length of EEPROM) step 1
Read ReadData
Serout PinX, ReadData, T300
Next a


'another kind of send routine useing FF for done with sending.
Send Routine

ReadData var byte
Counter var byte

Counter=0
ReadData=1
while ReadData!=FF
Read Counter, ReadData
Counter =Counter + 1
Serout PinX, ReadData, T300
Wend






Receive Routine
ReadData=1
Counter var byte

Counter=0
while ReadData != 255 'flag for end of transmission
Serin PinX, ReadData, T300
Write Counter, ReadData 'write data to EEPROM
Counter=Counter + 1 'next EEPROM place
Wend


Now to trigger these routines, its up to you... Maybe look for a pin toggle? Or use a special sequence... like

Serin Pinx, ReadData, ["XYZ"],DataRead
if DataRead="T" gosub Transmit_routine
if DataRead="R" gosub Receive_routine
goto where_ever you want to go for no good pin.


The transmit and Recieve code I wrote above has not been tested, but I would not be surprised if it is very close to the correct code you may be looking for.

Dwayne

mister_e
- 27th September 2004, 18:27
Hi Dwayne,
he he, i'm ok for the PIC software, what i need is a PC software to send the file (.BIN) already on hard disk to the COM port. That's it!!!.

your code seems to be o.k. but i really apologize if i wasn't enough clear this time. I already find RealTerm wich seems to be O.K. If not i will probably build my own in VB.

thanks for reply. Any other idea are welcome.

regards

Dwayne
- 27th September 2004, 19:28
Then you would want Procomm for DOS, it is shareware/freeware. It will do just about anything you want to do with a COM port...Hyerterminal (which comes with windows) would work too, but its not as elaborate.

Dwayne

mister_e
- 28th September 2004, 03:16
Hi Dwayne,
i get this DOS based ProComm program and it seems to work well like RealTerm. They are both do the job for me now.
I see also that the newest version is now provide by Symantec... why not??? i'll try to find on share place like Limewire or in worst case dumb Kazaa bulsh... site.

Thanks for help. I'll do mine anyway since i want more specific function for future project. The only thing i need is a couple of free hours to do it as i want. Everybody understand what i mean :0) Free time... is somebody have it???

many regards