Asked
— Edited
Hey guys. Little project I want to look into.
As I mentioned in this thread, I want to make a webpage/custom web server layout and run the ez-b through this. I have html background, so designing the webpage should be no problem, but I know little of getting ARC stuff into that page. I tried setting up the http server but it wouldn't work. So, who's up for helping me try this?
Ahhhh I see it now. Hmmm... I guess I need another way to trigger scripts over the webserver. Any ideas people?
I am not sure if this will work but... try this?
That didn't work, but thanks for the try.
Here's the camera code, which, if tweaked and reengineered, I think we can get it to do what we want it to do.
We'll need to takeout the reload interval, and change the address to what we need. for the html, i'm not sure. This script gets the url of the camera, so I wander if it could work for the scripts(it uses fragments of the address with variables).
HTML(maybe change to a button):
That's going at the bottom of the page, right? It needs to either be at the bottom or use $(document).ready().
For the previous problem, does it work if you use encodeURIComponent(), eg.
and have you checked for errors in the javascript console?
The code I just posted was the canera code which I thought we could change to work with the script trigger idea. I'll test the encode idea when I get home.
Is that the camera code that ARC's web server creates?
It just requests an image every so often. Loading it into the page. I'm not sure how it will help you - you're just trying to trigger a script to load, right?
What I gave you should work I believe. There may be other problems stopping it from working. It would be best to check the console for errors.
Believe it or not, your last idea appears to have started working!
The camera code is what I found and modified from another forum. The generic url is: "http://localhost:8080/CameraImage.jpg?c=Camera"
That's good to hear!
I thought it would. Was it with, or without, the encodeURIComponent()? I wasn't sure whether it would work better with, or without, that.