View unanswered posts | View active topics It is currently Wed Aug 20, 2014 6:47 pm






Reply to topic  [ 5 posts ] 
Remote Program start 
Author Message
Senior Roboticist
User avatar

Joined: Wed Sep 28, 2011 10:13 pm
Posts: 630
Location: If I told you, I'd have to kill you.
Post Remote Program start
Is it possible to start a program on a NXT through BlueTooth from another NXT?

_________________
A.K.A. inxt-generation
Self-proclaimed genius, and future world dominator.
My Brickshelf Folder
"Don't they teach recreational mathematics anymore?" - The Tenth Doctor
Bow down to Nikola Tesla, King of the Geek Gods.


Tue Feb 21, 2012 2:38 pm
Profile WWW
Expert

Joined: Tue Feb 28, 2012 3:10 pm
Posts: 195
Post Re: Remote Program start
Did you not got any response on this? Do you still need it? I haven't done it yet but I don't think it would take too long if you still need it.

_________________
Mike aka Spiked3
http://www.spiked3.com


Mon Jul 09, 2012 1:37 am
Profile
Senior Roboticist
User avatar

Joined: Wed Sep 28, 2011 10:13 pm
Posts: 630
Location: If I told you, I'd have to kill you.
Post Re: Remote Program start
No, I didn't. I don't need it right this second, but it would be useful for any BT communicable project. For example, a RC vehicle; Just run the program on the remote, it automatically connects and runs the vehicle program. Easy as toast (yah know, because pie is one of the most difficult foods there is to make. Toast is very easy).

I know that in NXC there's a command called "nxtRemoteProgramStart" or some such. In fact, NXC has all the direct commands for the NXT. The vehicle wouldn't even need a program.

_________________
A.K.A. inxt-generation
Self-proclaimed genius, and future world dominator.
My Brickshelf Folder
"Don't they teach recreational mathematics anymore?" - The Tenth Doctor
Bow down to Nikola Tesla, King of the Geek Gods.


Mon Jul 09, 2012 8:29 am
Profile WWW
Expert

Joined: Tue Feb 28, 2012 3:10 pm
Posts: 195
Post Re: Remote Program start
NeXT-Generation wrote:
... "nxtRemoteProgramStart" or some such. ...


if we look in our trusty bluetooth direct commands documentation from LEGO, we see that nxtRemoteProgramStart just sends the bytes;
22, 0 ,0x80, 0x00, 20 bytes of "program name" (with null terminator)

basically 2 bytes of length, low byte first = 22
0x80 = direct command, no reply wanted
0x00 = command to run program

using setBluetoothRawDataMode and nxtWriteRawBluetooth, its fairly easy to send this. problem is there is no way out of it, according to the help file. So a remote control would not be able to send 'messages' after using it (which seems like a rather burdening restriction that others have gotten around), and be stuck with only using raw bluetooth mode (which would work fine, just not what you are used to).

So, probably not exactly what you wanted for that purpose. I'll keep an eye out for a way to kick it back out of raw mode.

_________________
Mike aka Spiked3
http://www.spiked3.com


Mon Jul 09, 2012 11:36 am
Profile
Moderator
Moderator
User avatar

Joined: Wed Jan 31, 2007 3:39 am
Posts: 299
Location: San Diego, California. USA
Post Re: Remote Program start
Here is the lego documentation if you haven't seen it before, this is the official zip file that contains the pdfs strait from the website.

Trusty Bluetooth Direct Commands Documentation B-)

Hope this helps!
Scott B-)

_________________
Mmmm Legos B-)

My Robot Projects:
http://www.freewebs.com/robotprojects/


Wed Jul 11, 2012 12:06 am
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 5 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.