This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
YUGATUG's profile picture

redstone API syntax help?

Started by YUGATUG, 14 March 2015 - 12:58 AM
YUGATUG #1
Posted 14 March 2015 - 01:58 AM
I can't figure out how to get my mining turtle to pulse redstone. I've tried redstone.setOutput(left, true) and redstone.setAnalogOutput(left, 10) in the lua interperater, but both of them gave me syntax errors. I'm am trying to get my mining turtle to pulse a redstone signal of at least 5 to the left for 2 ticks. Does anyone know how to do this?
Bomb Bloke #2
Posted 14 March 2015 - 02:28 AM
redstone.setOutput("left", true)  -- Don't forget your quotes.
sleep(0.1)  -- Tenth of a second = 2 MineCraft ticks, or 1 redstone tick.
redstone.setOutput("left", false)
YUGATUG #3
Posted 14 March 2015 - 02:51 AM
Thanks!