PICcoder.co.uk Forum  


::post new topic::
Problem with bootloader
Date: 2009/05/31 16:15 By: carl123 Status: Visitor  
 
Hi.some1 plz help me here.

I have recently constructed a PIC18F4550 bootloader.

My problem is, when i program my testing code into the PIC through the bootloader. Then place the PIC back into the circuitry. nothing happen.

However when i program my testing code through a PIC programmer.Then place back into the same circuitry. it work as i intended it to do.(blinking LEDs)

**************************************************************************************
My testing code:


#include <htc.h>

void delay()
{
int i;
for (i=5000;i>0;i--)
{
NOP();
NOP();
}
}

void init()
{
TRISB=0x00;
PORTB=0;

void led()
{
char i;
while(1)
{
PORTB=0b11111110;
for(i=8;i>0;i--)
{
delay();
delay();
delay();
PORTB=PORTB>>1;
}
PORTB=0;
}
}

void main()
{
init();
led();
}



*************************************************************************************

I have just started in these recently. Plz teach me.
Thanks
reply | quote

::post new topic::