loading
 
RoboRealm Webserver set_variables
Anonymous from United States  [28 posts]
6 years
I can't seem to get the set variable command to update anything on the interface. If I open Watch_Variables, I should be able to see if any variables are updated from the webserver, but nothing changes.

I added a line in the setVariable javascript function at the end to get the variable that was just set, just to show the updated variable, but it always grabs the variable that is CORRECT in the RR interface, like the setVariable itself isnt updating correctly. If there were a file (like a .php) for the set_variable routine, I could possibly debug it, but does anyone have any ideas why it doesnt update?

I can post code if need be, but I'm using the standard index.html and index_alt.html files included with roborealm, and I have the latest version. Any help would be GREATLY appreciated, I have a rush project i've GOTTA get done asap, www.raverover.com

Thanks!
Anonymous from United States  [28 posts] 6 years
I'm installing another seat on my laptop to attempt the same thing, see if I can get the server module working there, just to rule out a PC problem.
Anonymous from United States  [28 posts] 6 years
Running a new .robo file and just loading the Watch Variables and logging into this other PC, it DOES update the 'move' and 'preset' variable....very strange indeed.
Anonymous 6 years
Chris,

Can you post the JS code that you are using to set the variable? I.e. the full onclick button code.

STeven.
Anonymous 6 years
Verify that you are using the right port number and not another webserver.

Also, be sure that RR is connected to something that will cause the pipleline to refresh. If nothing is connected you will have to cause RR to update its image in order to see the variable be updated. Being connected to a camera will solve this refresh problem.

STeven.
Anonymous from United States  [28 posts] 6 years
Yeah, I don't have any cameras connected to it, I'm just using it for the joystick/httpd interfacing. Very interesting.

The Javascript code is the default .html files, I've not changed anything besides the one line just to display the variable after updating.

The .robo file is running perfectly, I have a Serial box that is always updating an Arduino, which is great.

Anonymous from United States  [28 posts] 6 years
I can access that 'rover' pc without any problems, and now I am running it on my laptop as well. Connecting to the Laptop RR httpd, it will update the variables. Connecting to the 'rover' RR httpd, it does not. I'm going to do some more playing though.

I did change a few variable names on the rover PC, but the laptop I left everything stock, I'll go back to stock on the rover and see if it works.
Anonymous from United States  [28 posts] 6 years
Okay, I got it working, had to think outside the box.

Basically the pipe was updating the variable I was trying to update as well, so the solution was to update a NEW variable 'WebMode', if this variable was set to something, I could overwrite my function in the vbscript with the WebMode value, else I would continue on doing something else.

This works extremely well, and I can't wait to get this whole thing together!

This forum thread has been closed due to inactivity (more than 4 months) or number of replies (more than 50 messages). Please start a New Post and enter a new forum thread with the appropriate title.

 New Post   Forum Index