
mcbaker01
USA
Asked
— Edited
I saw that you can open up a telnet connection to ez-builder.
That's very cool.
I really want to use JavaScript to program my robot.
If I could connect to ARC via an html5 web socket, where all data that comes in from the ez-b is transferred across the connection, that would be very cool.
Will ez-robot ever support something like this?
Also, I'm asking about new functionality.
In a component config panel, I imagine there would be an "event definition" section.
For example, an accelerometers config panel would allow:
If the x vector reaches value N trigger event "tip" sending values x and N.
If the x vector changes at a rate (r) above value M, trigger event "bump" sending values x, r and M
These "events" would be pushed out over the socket along with contextual event data.
Also, web sockets allow for binary data transfer while telnet is text only. This would allow a camera on a robot to send image data to ARC which would then send an event "photograph" along with raw image data.
Implementing a web socket event server would be a programmers dream come true
Worth looking into at least.
- The camera image can already be obtained by the built-in HTTP server
- Enabling the Connection Control TCP Server but disabling Script Interfae will allow direct EZ-Robot Protocol Commands to be sent. This can either be another ARC instance, or your own application. To reference the EZ-Robot Protocol, visit the EZ-OpenBot library: http://code.google.com/p/ez-openbot
I could add an EZ-Script interface to the HTTP Server. It is now added to the to-do list
For example, for an ARC temperature control, if the temp hits say 90C, event "hot" occurs which pushes "hot:90" out the web socket.
The parameters and names for these event would be user entered of course.
There is a large manual of EZ-Script commands in ARC. Click the link to install. The add control button will allow you to scroll throug the categories of controls with the arrow keys
The scripting section might be of most interest to you
I'll play around with it, see if I can make it work.
It will be interesting to see how the HTTP service works out.
HTTP is stateless, not a dedicated connection so it seems like it would be more useful for some operations more than others.