27 posts
Posted 20 March 2012 - 04:21 PM
hi ive watched to the topic how to work with a modem or else but i still dont know how to send a command to a turtle wireless
can anybody help?
473 posts
Location
Poland
Posted 20 March 2012 - 04:39 PM
you actually need quite a bit of code:
while true do
local _,command=rednet.receive(1)
local exec=loadstring(command)
command()
end
and this is about the most basic setup you will find. there is also quite a lot of software for this on the forum, just look for it.
27 posts
Posted 20 March 2012 - 04:40 PM
if looked XD! btw TNX
27 posts
Posted 20 March 2012 - 04:55 PM
it says now ::attempt to call string::?
473 posts
Location
Poland
Posted 20 March 2012 - 05:02 PM
ah, sorry, simple mistype, it should be:
exec()
not command()
27 posts
Posted 20 March 2012 - 05:04 PM
it does say now ::attempt to call nil::
473 posts
Location
Poland
Posted 20 March 2012 - 05:07 PM
have you sent a proper command?, e.g.
rednet.send(11,"turtle.dig()")
if so, try
while true do
local _,command=rednet.receive()
local exec=loadstring(command)
command()
sleep(1)
end