pc to picaxe

idema

New Member
might it be possible use the programming cable to read a file from the pc
to a picaxe and write it to an external eeprom?
 

inglewoodpete

Senior Member
Yes, it can be done. Something like this will take a fair bit of coordination of software so that the PICAXE is ready to receive the data from the PC when it is downloaded. The PICAXE will then need to be told to write the data to the EEPROM. This may need to be done in "packets" of data if there is a lot of data to download.

You can get a lot of help from forum members but you will need to design a (software and hardware) solution that you can build. Success will depend on your level of experience.
 

idema

New Member
Thanks inglewoodpete, the file is a .txt file of 5008 bytes of decimal #'s. I would need a program on the pc side to open it and make it
available to the picaxe to read via uart and to then convert the format to .bin for the eeprom. But what pc progam for the interface?
I'm supposing that finding a way to do this would be useful to other picaxe users as well?
 

BeanieBots

Moderator
HyperTerminal used to be shipped free with Windows but stopped after XP.
A very good alternative that works under Win7/8 is TeraTerm.
I would expect PuTTy to be capable but have not tried it myself.
They are all free downloads.

You will need external EEPROM to store that amount of data.
 

lbenson

Senior Member
PC to Picaxe to load external eeprom

This is what I've used to download text files to up to 4K eeproms--a lua program on the PC which writes 16-byte chunks with pauses between chunks, and a picaxe program.

The only particular trick in the lua program (after you get lua set up on the PC) is this which inserts the pause:

Code:
m = 1, 11 do
    os.execute("dir > nul") -- delay for a while
end
For PCs faster than the one I was using, "11" needs to be increased, perhaps by a lot.

The picaxe program contains some extraneous stuff, because the eeprom was on an RTC module and I was testing the clock as well. If your program isn't text, you'd have to convert it before sending it.

I don't think that squirting the text out with HyperTerminal or PuTTY would work, because characters would be dropped after each 16-byte write. Maybe at a very slow baud rate it would work.

Remove the ".txt" extension to make the lua and bas files.
 

Attachments

Top