Jaffry
Member level 1
Dear all,
I am using PIC18f4550 while using winPIC programmer for downloading, the thing is that I want to generate the clock and although this is the simplest thing just toggle the port I cannot do that.
Also I tried to just glow the LED constantly, even then it is not glowing, instead it is lighting intermittently which is of course not proper, It seems to be so smallest of tasks but I am all messed up for two days and cannot even glow a constant LED. following is the code, please suggest. I had the deadline to complete this till tomorrow and had to present some results in our lab meeting but now I cannot.
If any one has used the winPIC downloader program, I think there is some problem with the configuration bits
Thanks
I am using PIC18f4550 while using winPIC programmer for downloading, the thing is that I want to generate the clock and although this is the simplest thing just toggle the port I cannot do that.
Also I tried to just glow the LED constantly, even then it is not glowing, instead it is lighting intermittently which is of course not proper, It seems to be so smallest of tasks but I am all messed up for two days and cannot even glow a constant LED. following is the code, please suggest. I had the deadline to complete this till tomorrow and had to present some results in our lab meeting but now I cannot.
If any one has used the winPIC downloader program, I think there is some problem with the configuration bits
Code:
#include <htc.h>
__CONFIG(1,0x0F24);
__CONFIG(2,0X0000);
void main()
{
//Initialize PORTD
//PD0 as Output
TRISD=0b11111100;
//Now loop forever blinking the LED.
while(1) { LATD=0B00000011; //PORTD0 = HIGH }
}
Thanks