BOB_SANTANA
Joined: 16 Oct 2006 Posts: 110 Location: HOVE, EAST SUSSEX
|
18F452 Bootloader that works for 20mhz |
Posted: Mon Jan 01, 2007 5:05 pm |
|
|
Hi All
Over the last couple of weeks a fews people including myself have being
finding it difficult to get a suitable bootloader for 18f452 @ 20Mhz
The following bootloader works at 20Mhz and should take you about 5 mins to get everything running.
http://www.microchipc.com/
1. Download to program
Note that the Hex file you need for the 18f452 @ 20mhz is
written as
_12200_PIC18F452-bootldr-20.000MHz_v1-5.HEX
There was a typo so _12200 baud should be 19200
Thats it
with this you don't have to use CCS Bootloader .C and press B3 etc
Just include the following line of code to your C program as below
#ORG 0x7000,0x7FFF {}
i hope this would help someone else
Code: |
if defined(__PCH__)
#include <18F452.h>
#ORG 0x7000,0x7FFF {} // Added for bootloader
#fuses HS,NOWDT,NOPROTECT,NOLVP
#use delay(clock=20000000)
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7)
#endif
|
_________________ BOB_Santana |
|