My group and I are currently doing a project which requires the transmission of wireless ECG signal to labview. The components which we decided to use complete the task are:
2 x Xbee (Zigbee S1) modules,
1 x Arduino uno
1 Xbee module attached to the Arduino had been programmed with Arduino. However, due to our lack of understanding of how Arduino functions, we are unsure if the coding for the interface is valid for transmitting the Analog ECG signal wirelessly to the other Xbee module connected (USB cable) to the computer and later displayed onto waveform using labview.
Does it work if you leave out the XBee modules but use the ECG hardware on the Arduino Uno when directly connected to the computer over USB? The code as shown does nothing special for Xbees. So it is a nice test-case if the problem lies in a wrong use of the Labview interface in this program, or in the Xbees not making connection together. As the latter would be absent.
I don’t know the Labview Interface library, so I cannot comment on it if the code in your program is any good for it. I leave it to others to comment on it if Labview can even make sense out of this. Or if commands in it are valid names in the library. I’m just looking at it from an Arduino and Xbee perspective.
Also you can test the Xbee connection on their own without the Arduino. On the Xbee connected to the computer you leave it as it is. On the Xbee that would be remote (intended for the Arduino) you would connect Din and Dout together (or Arduino Uno D0 and D1, or Tx and Rx). Then any data sent out from the PC should also return to it. Arduino serial monitor (PC) → USB → local Xbee → wireless → Remote XBee → Dout → Din → Remote Xbee → wireless → local Xbee → USB → Arduino serial monitor (PC) If this works then it should also be able to send the Arduino data.
Short story: try to identify the problem by reducing the complexity. Take out the parts you don’t understand or are unsure of that it is working. Test them individually. Do this for all parts. Once you verify that each individual part works on it’s own you implement them together and see if it still works. But not all together right away.
thanks for your help we are trying out the steps you have suggested, as for the xbee to xbee communication, do we need any code to upload on arduino or just run the xbee with the usb explorer to send any PC signal via the arduino serial monitor? thanks for your help.
You can leave the Arduino out of it completely. Or if you need it to provide power for the Xbee, have a program on it that does NOT use the serial port.