Page 1 of 1

web server how to stop and start events

Posted: Tue Jan 27, 2009 2:46 pm
by back_ache
I want to control a volume control from a web interface but I don't want to have to repeatedly press the button, just press and hold as you would a normal remote control

On other systems I've started a "volumeup" event on "button down" and stopped it on "button release" how can I do this with event ghost?

Re: web server how to stop and start events

Posted: Thu Jan 29, 2009 12:19 am
by Bitmonster
Take a look at the webserver demo: http://www.eventghost.org/downloads/

Basically you have to start the event with "http://url/mypage.html?eventname&withoutRelease" and stop it with "http://url/mypage.html?ButtonReleased".

Re: web server how to stop and start events

Posted: Thu Jan 29, 2009 8:45 am
by back_ache
That's demo's a nice piece of HTML!

Is there anywhere we can see the eventghost configuration that goes with it.

In my tests so far I have been sending eg.TriggerEnduringEvent("world") on buttondown and eg.EndLastEvent() on buttonup.

Unfortunately this results in a never-ending loop! I don't know whether this is because of a misunderstanding on my part or whether it is too busy processing the loop to notice the stop!

BTW So people can benefit from what I am finding out I've been putting my thoughts in http://www.eventghost.org/wiki/Webserver and have put together a simple ajax example

Re: web server how to stop and start events

Posted: Mon Feb 02, 2009 2:04 pm
by Bitmonster
I've updated the webserver demo to AJAX with working button endurance.