Search the Community
Showing results for tags 'autorun'.
Found 4 results
hello. i have password lock on my computer and i want to run it automaticaly. i looked to internet and i find some about autorun.lua file (HERE) and i create the file, edit /autorun.lua and writed this to it : os.execute(/home/door) (i have file named "door") i save it and reboot the OS and for 0.3second there is some red text and after it it goes normaly to /home/ menu i edited the code to os.execute(/home/door.lua) and there is still the same red text and it goes again to /home menu. what i am doing wrong ? edit: i recorded the error and slowed down it in sony vegas and looked to error and i have missing quotes
Hi there, I've been messing around with some basic robots and autorun.lua. My aim was to be able to plug a floppy disk into a robot, start the robot up and have the robot copy the program that would be stored on the floppy disk. Once the file was on the internal drive, the robot would run it. The idea was that I'd be able to set the robot's functionality by hotswapping floppy disks. Trouble is, the robot autorun hasn't really been behaving. When I run the program in the shell, it works every time. However, when the robot starts up it works... sometimes. The program I told it to run just tells it to turn left - but it only does that every second boot or so (not in a regular pattern) I've been trying to figure out why this is happening for a while now and I still don't understand it! I sent the program to sleep for a few seconds to see what goes on during initialisation and found this https://imgur.com/a/WA7SK SpoooOOoky! My best guess at the moment for why it's acting up is the usage of os.execute() Although it still isn't particularly consistent with other parts of the program https://pastebin.com/9DeP5fng Here's some source code so you can have a clue what I'm on about! Oh and the robot is a collection of tier one parts with a floppy drive.
I'm putting together an autorun for a program that lives on a floppy. It started like this: local fs = require "filesystem" local os = require "os" local proxy = ... fs.mount(proxy, "/mst") os.execute("/mst/portal.lua")Unfortunately, this doesn't work; the first few lines from the program show up, and then the OpenOS banner suddenly tramples over it to present me the shell prompt, because that's obviously what I wanted to have happen when I ran os.execute.This thread seems to describe exactly my problem, and I attempted the suggested solution like so: local fs = require "filesystem" local os = require "os" local event = require "event" local proxy = ... fs.mount(proxy, "/mst") event.timer(2, function () os.execute("/mst/portal.lua") end)But that didn't work either; the OpenOS banner shows up, and a moment later, there are busy lights and working noises from the computer and floppy drive, as though it were doing what it was supposed to, but nothing actually happens on-screen.Why doesn't this work? Should I be doing something differently? Is there a better way to tell OpenOS to stop helping? (I also tried shell.execute, but that didn't seem to do anything different.)
I have a program at /usr/bin/cc.lua that I want to run after booting is complete. If possible, add an argument as well (i.e. cc v ) I tried cp /usr/bin/cc.lua /autorun.lua and nothing. Then tried adding cc /usr/bin/cc.lua os.execute("cc.lua v") -- really expected this one to work os.execute(cc.lua) os.shell(cc.lua) os.shell("cc.lua v") to a clean autorun.lua and still nothing. Grr. What is the correct way to do this?