microlo75
Joined: 13 Apr 2010 Posts: 23
|
Problem with PIN_RF_13 |
Posted: Tue Feb 08, 2011 4:04 am |
|
|
Hello everyone,
I have this problem:
I use a PIC24FJ256GB110 and UART ports.
Code: |
#include <24FJ256GB110.h>
#fuses HS,PR_PLL,NODEBUG,NOWDT,ICSP2, NOPROTECT, PLL5
#DEVICE ADC=10
#define BUTTON_1 PIN_D6
#pin_select U2TX = PIN_B15
#pin_select U2RX = PIN_F13
#use rs232(UART1, baud=1200, xmit=PIN_B15,rcv=PIN_F13, parity=N,errors, bits=8, STREAM=RS232)
#int_rda
void serial_isr1()
{
PIPPO = fgetc(RS232);
}
void main(void)
{
enable_interrupts(INT_RDA);
enable_interrupts(INTR_GLOBAL);
while(1)
{
if(!input(BUTTON_1))
{
fprintf(RS232,"hello");
}
}
}
|
TX=OK
RX=NO INTERRUPT
If use "rcv = PIN_F13", the interrupt does not work !!!
If use "rcv = PIN_F12 o other", the interrupt work !!!
I never had problems with other PIN, use other 2 UART, no problems
Why? There is a bug?
I designed my own PCB, to use the PIN and now I have to do it again?
Thanks to all
Alex |
|