deace_nuts Posted August 17, 2017 Posted August 17, 2017 I've got a door control that I'd like one computer to run on startup, is there anyway of doing this? Quote
0 CocoVanChoco Posted August 17, 2017 Posted August 17, 2017 Ofcourse, Edit /etc/rc.d -> enabled = {} -> enabled = {"yourprogramhere"} Quote
0 Nexarius Posted August 18, 2017 Posted August 18, 2017 You could also create a file called /autorun.lua and write that stuff in there. Quote
0 deace_nuts Posted August 19, 2017 Author Posted August 19, 2017 On 8/17/2017 at 4:07 PM, CocoVanChoco said: Ofcourse, Edit /etc/rc.d -> enabled = {} -> enabled = {"yourprogramhere"} So if my program is named door.lua and it's located in /home, I would do... Edit /etc/rc.d -> enabled = {} -> enabled = {"door.lua"} Is that correct? If so it's not working, so I must have done something wrong. Quote
0 BrisingrAerowing Posted August 19, 2017 Posted August 19, 2017 The files need to be under /etc/rc.d to be runnable as a service. You may want to look at some services on here as examples on how to structure your program to work with rc. Here's a good one. Basically you need: A 'start' method A 'stop' method These can run pretty much anything, but using events should work. As for the door control thing, you may want to look at my Proximity Door Daemon, which allows for automatic doors using motion sensors. It's also extensible and very configurable. Quote
I've got a door control that I'd like one computer to run on startup, is there anyway of doing this?