Creating on/off button with a 2 hours timer


guest

Recommended Posts

Hello,

I am a new to DAQFACTORY and I want to control a fan by using an on/off button. Also, i want the button to turn off after 2 hrs (using a timer). Please help if you can

Note: I am using DAQFACTORY with LabJack u3

Link to comment
Share on other sites

I recommend going through the DAQFactory - LabJack application guide and the Guided Tour.  Its a PDF installed with DAQFactory.  

That will guide you through most of what you need.  Making something turn off after two hours is a basic sequence script that you would run when the button is clicked.  But NOT in the Action of the button, it has to be a sequence that gets started on its own.  The script is something like:

fan = 1 // turn fan on
delay(7200)  // wait 2 hours
fan = 0  // turn fan off

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.