'Add a Hardware object named Hardware1
Sub Globals
End Sub
Sub App_Start
Form1.show
Hardware1.New1
msgbox("Device ID: " & Hardware1.GetDeviceID)
Hardware1.BackLightOn 'Prevents the back light from suspending
Hardware1.RunAppAtEvent(AppPath & "\MyApp.exe", Hardware1.evWakeup) 'MyApp will be launched each time the device is turned on
Hardware1.RunAppAtTime (AppPath & "\MyApp.exe", TimeAdd(now,0,5,0)) 'MyApp will be launched in 5 minutes
AddTimer("Timer1")
Timer1.Interval = 5000 '5 seconds
Timer1.Enabled = true
TextBox1.Focus
Hardware1.KeyPress(asc("1")) 'Writes 1
Hardware1.KeyDown(160) 'Holds the left shift down
Hardware1.KeyPress(asc("1")) 'Writes !
Hardware1.KeyUp(160) 'Frees the left shift
End Sub
Sub Timer1_Tick
Hardware1.KeepAlive 'Resets the system idle timers
End Sub