Post by StefanPendl on Mar 26, 2011 3:34:56 GMT -5
Hardware communication is not implemented yet.
Don't know where on the ToDo list of Carl it is placed.
[b]Stefan[/b] - [a href=http://stefanpendl.runbasichosting.com/]Homepage[/a][br][br][b]Please give credit if you use code I post, no need to ask for permission.[/b][br][br]Run BASIC 1.01, Fire-/Waterfox (IE11, Edge), Windows 10 Professional x64, Intel Core i7-4710MQ 2.5GHz, 16GB RAM
Barry Not sure exactly what you want to do. Is the device you are monitoring on the client or the server side. If it's on the server side you can use the shell$() command. If you are using windows of particular interest is the ECHO command. www.computerhope.com/echohlp.htm RunBasic was not built for real time. So if your device must respond in sub-seconds it could be a problem.
Using Linux it's a little easier.
If the device is on the client, it gets a little tricky. The big problem is how much traffic? It can start to eat bandwidth if you have to constantly send data.. In that case I'd look at writing something locally and only sending exceptions to the server..
I have a application where I'm watching a couple thousand tanks. RunBasic is not designed to do this and just can't handle it. However it handles the database and reporting the tank information perfectly. So I use another language to monitor the tanks and report information to the server every couple minutes, and when there are problems.
Post by David den Haring on Mar 26, 2011 9:26:57 GMT -5
Over Ethernet, Run BASIC can communicate using the httpget$() and httppost$() functions. A lot of hardware has embedded web servers these days, so maybe that's an option.
For serial port and other forms of hardware access, you could look at using Liberty BASIC and the shell$() function as Dan mentioned above. The advantage there is that you're using a similar BASIC dialect.
David den Haring[br]Proprietor, Run BASIC Hosting Service[br][url]http://runbasichosting.com[/url]