Program a PicAxe with PicAxe

mortifyu

New Member
Hi All,

Is it possible to program a PicAxe chip with another PicAxe chip?

ie: I'd like to create a piece of hardware that would allow me to dial up certain values to be written to particular eeprom addresses in a secondary PicAxe chip along with the main program so that no computer was required to do this task.

Kind of like bulk programming chips, but also being able to change certain eeprom values as desired prior to downloading to the chip.


Hope my question makes sense.


Regards,
Mort.
 

hippy

Technical Support
Staff member
There is no publicly available mechanism to be able to program a PICAXE from anything but a computer running the PICAXE programming software; PE6 etc.

It is entirely possible that the program downloaded to the PICAXE can be coded so it sets the values it uses from external hardware, a keypad, IR remote, via serial, even another PICAXE.
 

Flenser

Senior Member
Mort,

You said
that would allow me to dial up certain values to be written to particular eeprom addresses ... along with the main program
Are you aware that this is the way that PE already works? Checkout the description of the EEPROM command.

As Hippy has already said, you are limited to using the PICAXE programming software, PE, AXEpad, etc to program a PICAXE chip, so you will not be able to program one PICAXE using a second PICAXE. The closest you might get to this is to find a small single board computer running Linux or Windows and use that. The two examples that come to mind are a RaspberryPi running Linux or a cheap tablet running Windows, not android.
 

mortifyu

New Member
There is no publicly available mechanism to be able to program a PICAXE from anything but a computer running the PICAXE programming software; PE6 etc.

It is entirely possible that the program downloaded to the PICAXE can be coded so it sets the values it uses from external hardware, a keypad, IR remote, via serial, even another PICAXE.
Hi Hippy,

Thanks for the response.

I am hoping Tex's booti2c suggestion contradicts your comment.


Regards,
Mort.
 

mortifyu

New Member
Mort,

You said


Are you aware that this is the way that PE already works? Checkout the description of the EEPROM command.

As Hippy has already said, you are limited to using the PICAXE programming software, PE, AXEpad, etc to program a PICAXE chip, so you will not be able to program one PICAXE using a second PICAXE. The closest you might get to this is to find a small single board computer running Linux or Windows and use that. The two examples that come to mind are a RaspberryPi running Linux or a cheap tablet running Windows, not android.
Hi Flenser,

Thanks for the response.

Yep, I fully understand and have used the EEPROM command on many occasions.

From what Tex has mentioned 'booti2c' coupled with the EEPROM command and a bit of smarts will allow me to achieve my goal.

Overall my goal is to be able to mass produce a particular circuit and effectively plug it into a custom built hardware picaxe programmer that will load the 'USER PROGRAM' and also any EEPROM values.



Regards,
Mort.
 

techElder

Well-known member
If so, is there some information/directions how to load the 'USER PROGRAM' to the external EEPROM?
Mort, I know that if you search here on the forum you'll find posts referencing how to use booti2c. I have only a small idea what you are trying to do, but I have used booti2c to update a preprogrammed product. It isn't "...possible to program a PicAxe chip with another PicAxe chip...", but this was a way to get my job done.

PS. :D I would not even try to "contradict" a post by hippy! :D
 

mortifyu

New Member
Mort, I know that if you search here on the forum you'll find posts referencing how to use booti2c. I have only a small idea what you are trying to do, but I have used booti2c to update a preprogrammed product. It isn't "...possible to program a PicAxe chip with another PicAxe chip...", but this was a way to get my job done.

PS. :D I would not even try to "contradict" a post by hippy! :D

Thanks for the TIP mate. I'll do some scouring of the forum.

Contradicting Hippy... Yeah nah, probably a strong word to have used. From my experiences here, when I have read any of Hippy's responses, the term 'Elite Individual' in this field comes to mind ;)


Regards,
Mort.
 

hippy

Technical Support
Staff member
PS. :D I would not even try to "contradict" a post by hippy!
I'm all up for being contradicted. Bring it on, do your worst !

I believe there's a lot to be gained from arguing over how to do things and why it might not work, and how one might get round that. All insights are useful and I have learned a thing or two from those.

the term 'Elite Individual' in this field comes to mind
Nah; I have just been doing it for a very long time, and PICAXE is my day-to-day job. But there's plenty I can overlook at times, always some angle or clever trick I may miss or have forgotten about.

From what Tex has mentioned 'booti2c' coupled with the EEPROM command and a bit of smarts will allow me to achieve my goal.
Possibly. It really depends on exactly what you want to do, the effort you are willing to go to, the costs you're prepared to carry to achieve it.

You can use BOOTI2C to get a program into a PICAXE, or to update EEPROM, but how are you going to get an initial program into the PICAXE which executes that BOOTI2C command to let that happen ?

I imagined you wanted something like a production line, where you would take your PCB, stick a factory fresh PICAXE into its socket, then program it from your 'magic box', and that 'magic box' would have a PICAXE in it, no computer involved.

I can't see how you would achieve that initial serial download without using a computer.

For updating product already in the field BOOTI2C can work. But you will need to use an X2 chip, and have designed the hardware and software to be upgradeable that way.

And if anything does go wrong during an upgrade you may have to resort to 'initial programming' to rescue it, get it working again.
 

mortifyu

New Member
Er... yeah... the initial boot2ic being in the PICAXE. Looks like I am rolling back to Post #4 from Flenser. Raspberry Pi here I come ;)

Thanks guys. PICAXE FORUM... #1 for brains, and helpful experienced operators.
 
Top