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

I cant find it...

Started by Hellreaper, 13 March 2016 - 04:20 PM
Hellreaper #1
Posted 13 March 2016 - 05:20 PM
Im pretty sure this is already on here but I cant seem to find it.
What I wanna do is have a wireless pc in my inventory and be able to send a signal to one of my computers so I can turn a machine on or of. I need to be able to control it with the pocket version cuz I wanna have other people have the same(or other ) control over machines, doors, power system etc.

Redirect me if i missed something, but I couldnt find it…
Bomb Bloke #2
Posted 13 March 2016 - 09:36 PM
You haven't actually explained the bit where you got stuck, but it sounds like you may be after this?:

http://www.computercraft.info/wiki/Rednet_%28API%29
lecrouch #3
Posted 13 March 2016 - 09:42 PM
I control multiple turtles this way for tandem mining efforts.
Here's an example of what I use:

On the turtle:
http://pastebin.com/WdesZaa3

On the pocket computer:

local programParam = { ... }
rednet.open("back")
rednet.broadcast(programParam[1], "startComb")

To execute on the pocket computer, I just type "startComb xx" where xx is a number.
I would guess that with the link to the rednet.api and that example code you can probably get things going!
Hellreaper #4
Posted 15 March 2016 - 05:00 PM
finally my account shows me my posts that was kinda weird…

I figured I could run a receive program on the computer and when it recieves a certain string it executes the program I want it to.
At least that worked for me