View unanswered posts | View active topics It is currently Sat Jun 23, 2018 11:35 pm

Reply to topic  [ 3 posts ] 
Bluetooth Message Sending? 
Author Message

Joined: Sun Oct 12, 2008 7:36 am
Posts: 1
Post Bluetooth Message Sending?
I want to send the message from the pc to the nxt to move motor for certain degrees,i cant get it workout...i also tried to connect using the rawdata mode ,and the setBluetoothRawDataMode()
method never seems to be done as i debug it step wise..the core is not going into the raw data mode.. please any code samples or advice..

Sun Oct 12, 2008 7:55 am
User avatar

Joined: Wed Jan 31, 2007 3:39 am
Posts: 299
Location: San Diego, California. USA
Post Re: Bluetooth Message Sending?
Hi mohammad_talha,

Have you tried looking at the sample bluetooth files that come with RobotC, they may guide you in the right direction. If you are running Robotc v1.45, you can click Open Sample Program in the file menu, and select the Bluetooth folder for allot of sample code.

Hope this helps B-)

Mmmm Legos B-)

My Robot Projects:

Mon Oct 13, 2008 12:59 pm
Profile WWW

Joined: Sat Dec 15, 2007 5:08 am
Posts: 7
Post Re: Bluetooth Message Sending?

I have the same problem and I can't manage sending data from PC to NXT.
I have build an application on PC that uses COM port of bluetooth key to communicate with NXT brick in both direction.
I can now read data from NXT with PC. NXT uses cCmdMessageWriteToBluetooth() and I can see protocol byte before my data bytes. It is described in the Lego Bluetooth developpement Kit.
Byte 0 : 0x00
Byte 1 : 0x80
byte 2 : 0x00 (mailbox1)
Byte 3 : message size
byte 4-N : my data
final Byte : 0x00

So I used the same protocol and so the same bytes to send from PC to NXT, hoping the brick could read the message via cCmdMessageRead().
But here is the problem. NXT can't see anything, even with example robotC programs.
Does someone have written such a program, I mean sending data from PC via bluetooth COM port, and know what is the solution of my problem?
I would take any idea to solve it.


Mon Nov 03, 2008 7:17 pm
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.