View unanswered posts | View active topics It is currently Wed Jun 19, 2013 4:45 pm



Reply to topic  [ 4 posts ] 
 Need help with variable/timer 
Author Message

Joined: Jan 29, 2011
Posts: 11
Post Need help with variable/timer
I use a wheelchair that can tilt back 50 degrees, which is awesome, except that on more than one occasion I've tilted all the way back and mindlessly removed my hand from the joystick, at which point I didn't have the strength to reach the joystick (or my iPhone, mounted right next to it) and have gotten stuck till someone found me! (Injuring my pride more than anything.)

So I'd like to have a Control Page with a button I have to push every 45 minutes (less, actually) - if 45 minutes goes by without me pushing it, and presumably resetting a variable, emails will be sent to my care team (actually, eventually I plan to hack my LifeLine alert switch with an I/o Linc, but emails are cool for now).

I've tried a couple of ways of measuring time, but so far no luck. Any thoughts?


Thu Jul 14, 2011 7:23 am
Profile

Joined: Jul 09, 2009
Posts: 270
Location: SW Florida
Post Re: Need help with variable/timer
The user contribution library contains a timer script that works great for my uses. Seems like it might be what you're seeking:

http://www.perceptiveautomation.com/fil ... .php?id=98


Thu Jul 14, 2011 8:39 am
Profile
Site Admin
User avatar

Joined: Mar 19, 2008
Posts: 6856
Location: Austin, Texas
Post Re: Need help with variable/timer
That timer script is one way of doing it.

Seems like you could do it with a couple of pieces:
  • A schedule that decrements a variable once a minute.
  • A trigger that fires when said variable gets to 0 that sends the email. That trigger can also reset the variable to something smaller (maybe like 5) so that when the variable again decrements to 0 again it sends another email - kinda of a pester function.
  • An action on the control page that resets the variable to 45 when touched.

Of course you would also want to have actions on the control page to enable/disable the first trigger above - so it wouldn't go off while you're asleep for instance. But I think you get the point.

_________________
Jay (Indigo Support)
Image


Thu Jul 14, 2011 9:06 am
Profile WWW
User avatar

Joined: Dec 24, 2008
Posts: 386
Location: Mission Viejo, CA
Post Re: Need help with variable/timer
There is something like this example in the wiki, like if the garage door is left open for 30+ minutes, I get a text message telling me at what time it was opened every 30 minutes until it is closed. There is also an example alerting me with a text message if it is still open by 11PM.

_________________
Indigo 6.x w/ Dual-Band PLM 2413U
Mac OS X 10.6.x Snow Leopard
2006 Mac Mini Core Solo


Thu Jul 14, 2011 11:03 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 4 posts ] 

Who is online

Users browsing this forum: T-Power and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.   Template designed by STSoftware.