choura
Member level 1
hi this my first program with uart ; so, I want to know is this program true or not
I'm going to use it with RF module
if there is faults tell me
how to declare the errors of signals when i send it to another pic
this is my program
unsigned char i;
void main() {
TRISA = 0xff; //set all pin of port A as an input
TRISB = 0x00; //set all pin of port B as an output
PORTB=0;
UART1_Init(9600); // initialize UART module
while (1) {
if (portA.f0==1) //if push button is pressed
UART1_Write('f'); //send forword signal
delay_ms(500);
}
}
my circuit in file attachments
I'm sorry for my english
thank U before
- - - Updated - - -
I have tested it with my circuit but the signal I got is not true
- - - Updated - - -
I have tested it with my circuit but the signal I got is not true
I'm going to use it with RF module
if there is faults tell me
how to declare the errors of signals when i send it to another pic
this is my program
unsigned char i;
void main() {
TRISA = 0xff; //set all pin of port A as an input
TRISB = 0x00; //set all pin of port B as an output
PORTB=0;
UART1_Init(9600); // initialize UART module
while (1) {
if (portA.f0==1) //if push button is pressed
UART1_Write('f'); //send forword signal
delay_ms(500);
}
}
my circuit in file attachments
I'm sorry for my english
thank U before
- - - Updated - - -
I have tested it with my circuit but the signal I got is not true
- - - Updated - - -
I have tested it with my circuit but the signal I got is not true