View previous topic :: View next topic |
Author |
Message |
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
CCS Bootloader and Hyperterminal |
Posted: Mon Oct 02, 2006 8:42 am |
|
|
Guys,
I am at the beginning of what I image will be a long road. I wish to use the CCS booloader in my PIC18F6620 but I am experimenting with a development board that has a PIC18F458 currently on board. I am using PCWH 4.009. I have successfully deployed the bootloader and can then upload my simple app using SIOW.exe. However, I no not appear to be able to do the same using Hyperterminal. My rational for using Hyperterminal is that I will ultimately need to write my own uploading app as my project has a serial to Ethernet transciever in it on the PICs com port, so I will need an Ethernet app. If I can completely understand how it all works then porting to Ethernet should not be a problem.
Does anyone have any experience with using Hyperterminal and the CCS bootloader? A couple of threads talk about issues with Hyperterminal and XON/XOFF but I don't appear to be able to find what I am looking for. Which transfer protocol should I use, or should I just use Send a Text File...? Do I need to do anything special with my hardware or software to use XON/XOFF? Any other thoughts or resources greatfully received.
Regards,
Jason. |
|
|
asmallri
Joined: 12 Aug 2004 Posts: 1635 Location: Perth, Australia
|
Re: CCS Bootloader and Hyperterminal |
Posted: Mon Oct 02, 2006 8:49 am |
|
|
jamesjl wrote: | Guys,
...my project has a serial to Ethernet transciever in it on the PICs com port, so I will need an Ethernet app. |
serial to Ethernet transciever?
Do you mean an Ethernet controller? Or do you mean you have a serial to Ethernet gateway? _________________ Regards, Andrew
http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!! |
|
|
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
|
|
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
|
Posted: Mon Oct 02, 2006 2:07 pm |
|
|
Guys,
It seems like 2 hours of research yielded an answer of sorts. It seems that the hex file is sent as ascii encoded integers, i.e. each hex value is sent as two acsii chars. I guess that's why HyperTerminal doesn't work with CCS bootloader!!
That being said the whole bootloader topic seems very complex and the information difficult to come by: reset vetors, moving interrupts, moving memory addresses to 0x400, #build, #org aaahhhh.
Does anyone know of a concise resource for implementing bootloaders with all of their Idiosyncrasies to help me develop my project to allow down the wire upgrading of my networked PIC project using Ethernet and CAN?
Many thanks in advance,
Jason. |
|
|
asmallri
Joined: 12 Aug 2004 Posts: 1635 Location: Perth, Australia
|
|
Posted: Mon Oct 02, 2006 7:38 pm |
|
|
I have had a (very) brief look at the gizzo you are using.
Quote: | Does anyone know of a concise resource for implementing bootloaders with all of their Idiosyncrasies to help me develop my project to allow down the wire upgrading of my networked PIC project using Ethernet and CAN? |
I make Ethernet bootloaders for PICs but these work with Microchip's ENC28J60 or Realtek's RTL8019AS Ethernet controllers. The PIC's bootloader and the programming application on the PC communicate natively using UDP. In my implementation the bootloader implements its own network stack. In your case the digi implements the stack. You should be able to port my bootloader to your platform. The programming application on the PC should not require any modification.
This will certainly be a lot quicker doing this than trying to develop your own bootloader from scratch. _________________ Regards, Andrew
http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!! |
|
|
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
|
Posted: Tue Oct 03, 2006 1:37 am |
|
|
Andrew,
since the Digi simply connects to the serial port on the PIC, shouldn't I just be able to use the standard bootloader, perhaps with some minor modifications?
Any thoughts?
Jason. |
|
|
asmallri
Joined: 12 Aug 2004 Posts: 1635 Location: Perth, Australia
|
|
Posted: Tue Oct 03, 2006 1:41 am |
|
|
jamesjl wrote: | Andrew,
since the Digi simply connects to the serial port on the PIC, shouldn't I just be able to use the standard bootloader, perhaps with some minor modifications?
Any thoughts?
Jason. |
As I said, I only looked at the device briefly. It appears to me (rightly or wrongly) that you would speak to this device with IP. Even if you could use either method (serial or IP), you need to find a solution for the PC end. _________________ Regards, Andrew
http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!! |
|
|
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
|
Posted: Tue Oct 03, 2006 1:49 am |
|
|
Andrew,
you are correct in your thoughts. I do indeed need to speak to this using IP. I already do this with an existing VB.NET app that I am writting, to send and receive control information from the PIC, so adapting this to transmit the .hex file to the PIC shouldn't be too arduous (at least that's what I'm hoping...)
Jason. |
|
|
asmallri
Joined: 12 Aug 2004 Posts: 1635 Location: Perth, Australia
|
|
Posted: Tue Oct 03, 2006 2:02 am |
|
|
jamesjl wrote: | Andrew,
you are correct in your thoughts. I do indeed need to speak to this using IP. I already do this with an existing VB.NET app that I am writting, to send and receive control information from the PIC, so adapting this to transmit the .hex file to the PIC shouldn't be too arduous (at least that's what I'm hoping...)
Jason. |
Is this for a hobby project or a work project? _________________ Regards, Andrew
http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!! |
|
|
jamesjl
Joined: 22 Sep 2003 Posts: 52 Location: UK
|
|
Posted: Tue Oct 03, 2006 2:22 am |
|
|
Andrew,
work I'm afraid. It's a distributed monitoring and management solution that connects to its PC controller using Ethernet and then each Ethernet controller connects to up to 100 remote monitors using CAN. I want to be able to upgrade the main and remote controllers using a bootloader over the wire. This is just a small (hahaha) part of the project and is only really for maintenance and whilst I could live without it there is enough room left on the PIC18F6620 (Ethernet Controller) and PIC18F4585 (remote controller) to accommodate a bootloader I hope. Finding out about the whole bootloader thing just seems very disjointed as mentioned about; knowing where to place the app, how to use #build, #org and others, how to redirect my ISRs, discovering that the .hex file is sent using two ascii chars per hex value, and a whole load of other stuff that I haven't even thought of yet. There does seem to be a lot on the forum but it just takes a lot of digging through. If I ever get this thing working I may just have to write it all down and post if somewhere.
Any more ideas where I might look to help me on my way?
Regards,
Jason. |
|
|
|