init.lua 588 B

1234567891011121314151617181920212223242526
  1. DEBUG = true
  2. SETUP = false
  3. SETUP_TIMEOUT = 120000
  4. STARTUP_DELAY_TIMER = 0
  5. INTERRUPT_TIMER = 1
  6. INDEX_TIMER = 2
  7. SETUP_INACTIVITY_TIMER = 3
  8. WIFI_WAIT_TIMER = 4
  9. SUCCESS_SETUP_TIMER = 5
  10. print("3 second startup delay using timer " .. STARTUP_DELAY_TIMER .. '...')
  11. tmr.alarm(STARTUP_DELAY_TIMER, 3000, 0, function ()
  12. print("Starting.")
  13. -- yo recipient file must exist
  14. yoRecipientExists = file.open('yorecipient.txt', 'r')
  15. file.close()
  16. if yoRecipientExists == nil then
  17. file.open('yorecipient.txt', 'w+')
  18. file.close()
  19. end
  20. dofile("interrupt.lua")
  21. end)