I have two Pro XBee Pro S3B, one is connected to my computer through USB, meanwhile the other is connected to a microcontroller AT90CAN64.
Here are the settings for each XBee, which I configured using XCTU:
- A (coordinator)
CE: Indirect Msg Coordinator [1]
ID: 71FF
SH: 13A200
SL: 418CCABF
DH: 13A200
DL: 418CCAB4
- B (router)
CE: Standard Router [0]
ID: 71FF
SH: 13A200
SL: 418CCAB4
DL: 418CCABF
I have both in Transparent Mode.
If I connect both A and B in my computer, if I use the XCTU terminal, I am able to exchange messages between them.
My main issue is the following: after I turn on the AT90CAN64, if I connect DIN/DOUT (XBee) to TX/RX (AT90CAN64), load the XCTU and try to exchange messages, I am not successful. However, if I do not connect TX/RX - DIN/DOUT, wait some time, then I connect TX/RX - DIN/DOUT, and then load XCTU, I am able to exchange messages.
I have looked in the documentation and forums and nothing touches this problem. Has any one any idea of what may be the issue or any clue on how to tackle it?
Below you find the code running in the microcontroller:
#ifndef __cplusplus
#define __cplusplus
#endif
#ifndef F_CPU
#define F_CPU 16000000
#endif
#include
#include
#include "usart.h"
void sendTest(void);
void sendTest(){
USART0_Transmit8(0x07);
}
int main(){
DDRG |= (1 << PG0)|(1 << PG1)|(1 << PG2)|(1<