I’m able to communicate with the XBEE module using the X-CTU and Hyper Terminal applications so I know the hardware is working fine.
I’m busy developing software (WIN32) to talk to the module and have run into the following problem.
I’m able to open a file handle using the CreateFile API. To enter command mode i send ‘+++’ but get no response from the module. I know the module receives the string because the green LED flashes when data arrives. Shortly after that the orange LED should flash to indicate that data has been sent ‘out’, but this does not happen.
The write command looks as follows:
*** MASM 32
szPlus db ‘+++’,0 ; command mode string
hConn dword ? ; connection / file handle
bytes dword ? ; received bytes counter
invoke WriteFile, hConn, addr szPlus, sizeof szPlus, addr bytes, NULL