10-27-2006 02:18 PM
Kjeld and James,
Thanks for your help!!
Kjeld, I know we originally talked about using the BT Messages and mailbox system in the NXT to send data, but I have found that using the SendDirectCommand.vi works great for collecting data from the sensors and commanding the NXT to move its motors.
Our plan is to use LabVIEW running on our desktops to do heavy calculations like Fuzzy Logic, Neural Nets and Genetic Algorithms and simply use the BlueTooth-connected NXT has a physical manifestation of the modeled software robot.
I have attached our first LabVIEW 8.0 code for collecting data and sending commands via BlueTooth. It is based on the NXT configuration of the "TriBot", that is all three motors connected, and the Touch sensor in Channel 1.
We are working to talk to the sound and light sensor and then moving on to talk to the Sonar device.
Please let me know if it works for you.
Many thanks!
-Bill =]
11-07-2006 09:26 AM
11-15-2006 05:21 AM - edited 11-15-2006 05:21 AM
Message Edited by JacoNI on 11-15-2006 05:22 AM
11-16-2006 03:21 AM
11-16-2006 05:01 AM
01-18-2008 06:58 AM
06-10-2009 05:01 AM
01-22-2012 01:14 PM
Otherwise I can read and write files, retrieve device data but sendDirectCommand does not do anything to my Lego Mindstorms NXT.
// this should play a tone
ViUInt8 directCommandBuffer[] = {0x03, 0x7F, 0x18, 0xE0, 0x0F,0x01 };
// it should play a tone but it does nothing. It generates status 0xBFFF003E
nxtPtr->sendDirectCommand(false,directCommandBuffer,sizeof(directCommandBuffer),NULL,0,status);
My NXT is not responding to any direct command from the consol. Please any help would be wonderful!