K33rg4t3
Full Member level 3
Hey, I am trying to blink LED with PIC32MX220F032B.
Led is connected with resistor to pin RB5.
I am using microC pro for PIC32 IDE/compiler.
I am programming it with ICSP and the hex is written correctly.
This is my code:
I have tried various config bits configurations, I have tried connecting oscillator (12MHz or so) but the LED is always on no matter what I do.
The PIC is not in reset state because I've added the 10k resistor to MCLR as always.
Can anyone help me? Any suggestions are welcome.
Led is connected with resistor to pin RB5.
I am using microC pro for PIC32 IDE/compiler.
I am programming it with ICSP and the hex is written correctly.
This is my code:
Code:
#include <stdio.h>
#include <stdlib.h>
void main() {
TRISB = 0; // Set PORTB as output
LATB = 0;
while(1)
{
Delay_ms(1000);
LATB = ~LATB;
}
}
The PIC is not in reset state because I've added the 10k resistor to MCLR as always.
Can anyone help me? Any suggestions are welcome.
Last edited: