web service on SBC3 - help needed!

General PhidgetSBC Discussion.
Post Reply
mariusz7
Phidgetly
Posts: 18
Joined: Sun Nov 11, 2012 10:51 am
Contact:

web service on SBC3 - help needed!

Post by mariusz7 »

I need help!
-
I am trying to find how the web service works on SBC3 from documentation and I am running in circles, being linked back to where I started.
-
What is working:
I can use SSH terminal to login to linux console.
I can login to SBC from Chrome browser: 192.168.10.23
Looking at the:
http://192.168.10.23/cgi-bin/phidgets-status.sh
I can see Phidget Interface Kit 8/8/8 - great!
looking at:
http://192.168.10.23/cgi-bin/phidgets-webservice.sh
I see that Webservice is running and port is 5001 - great!
calling:
http://192.168.10.23:5001
I am getting:
net::ERR_EMPTY_RESPONSE
not cool.
Is it a RESTfull API? where is the documentation?
How I can get/set the IO point on interface kit?
Is it a web socket server?
What events are emitted? Where is the documentation?
--
Please help!
explode
Fresh meat
Posts: 1
Joined: Thu Apr 27, 2017 9:08 pm
Contact:

Re: web service on SBC3 - help needed!

Post by explode »

No answers yet, so I will try.

The Webservice isn't officially documented, you are expected to interact with the dll - there are plenty of code examples to follow. The reason given is the the Webservice might change. I think this is a shame, because it's now very easy to interact with the webservice.

You can have a look at how nodePhidgets does it:
https://github.com/evantahler/nodePhidgets

I have also done it myself in Go, using Wireshark to figure it out the details - it's not too hard. There is also this post here with some information:
viewtopic.php?f=7&t=2734

Good luck :-)
mariusz7
Phidgetly
Posts: 18
Joined: Sun Nov 11, 2012 10:51 am
Contact:

Re: web service on SBC3 - help needed!

Post by mariusz7 »

thanks @explode
This explains why I could not find what I was looking for (non existing documentation for webservice)

@patric
You promised JavaScript support to be implemented in 2017.
viewtopic.php?f=7&t=6407
from your post:
viewtopic.php?f=7&t=8076
it looks that it will not happen, It is pointless to have NodeJS ver 0.10 in year 2017.
It would be better for Phidgets future to have language independent support via http, RESTfull APIs and websockets.
-
Now I am running a USB connected Phidgets Interface Kits to RaspberryPi thanks to:
https://github.com/RIAEvangelist/node-phidget-API
I am still working on how to use my Phidgets SBC3 with RaspberryPI connected with Ethernet.
Any help/suggestions on that?
Post Reply

Who is online

Users browsing this forum: No registered users and 23 guests