DroidScript wiki

(was AndroidScript) unofficial documentation by the community

User Tools

Site Tools


built_in:nxt_setonconnect

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
built_in:nxt_setonconnect [2015/03/11 17:22]
madlyr [Example - Connect / Disconnect to NXT]
built_in:nxt_setonconnect [2015/03/11 17:26] (current)
madlyr [SetOnConnect]
Line 1: Line 1:
 ====== SetOnConnect ====== ====== SetOnConnect ======
  
-The **SetOnConnect** function allows you to set the name of a function that you would like to be called when the NXT has been successfully connected via Bluetooth. The **SetOnConnect** function allows you to set the name of a function that you would like to be called when the NXT has been successfully connected via Bluetooth. Callback function returns ​success ​status of connection (true if connection is successful, and false, if connection failed) and caller nxt object.\\ Do not use SetOnConnected while using SetOnConnect.+The **SetOnConnect** function allows you to set the name of a function that you would like to be called when the NXT has been successfully connected via Bluetooth. The **SetOnConnect** function allows you to set the name of a function that you would like to be called when the NXT has been successfully connected via Bluetooth. Callback function returns status of connection (true if connection is successful, and false, if connection failed) and caller nxt object.\\ Do not use SetOnConnected while using SetOnConnect.
 <​code>​nxt.SetOnConnect( myfunc );</​code>​ <​code>​nxt.SetOnConnect( myfunc );</​code>​
 Callback function myfunc. Function name changed to OnConnect. Callback function myfunc. Function name changed to OnConnect.
built_in/nxt_setonconnect.txt ยท Last modified: 2015/03/11 17:26 by madlyr