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

WirelessControl - Control your base with wireless redstone over rednet

Started by unobtanium, 04 April 2014 - 09:23 PM
unobtanium #1
Posted 04 April 2014 - 11:23 PM
Hello everybody,


i watched Etho's FTB episode lately (yesterday?) when he was using mobs to protect his castle. He wanted to set up some sort of wireless redstone with noteblocks, but i said "meh that sucks!" and made a fancy program for CC for it. It can be used for everything which requires a redstone signal.
Basically you are using a 4x4 advanced monitor screen to display your buttons in different color, size and text, which can be toggled on and off while sending the correct rednet message.


WirelessControl








WirelessControl 1.0 Download (Pastebin Ingame) & Installation:

For using the ComputerCraft build-in pastebin downloader, the HTTP API has to be enabled in the server properties.

Give your computer a label by typing in the computer screen:

label set <name>

Download the program for the advanced computer and the monitor screen:

pastebin get faNYCykU startup

Download the program for the normal computer to receive the rednet messages and toggle the redstone signal on and off:

pastebin get m8MmwvX7 startup

Start the programs with:

startup



Setup:

You need one advanced computer and 16 advanced monitor. Place the monitor in a 4x4 pattern on the right side of the advanced computer.
Attach a wireless modem on any side of the advanced computer.
Start the program you downloaded above. You now can RIGHTCLICK on the monitor to interact with it.
In the top left you see a red cross (+) which access the ADD MODE. You can quit the mode by clicking the cross again.
By clicking on a free spot, you are creating a new button.
Clicking on an existing button, selects the button. Once selected you can click on a free spot again to reposition the button.
By clicking on the top left corner of the button you access the button menu. You have to open up the advanced computer screen to do so.
While changing the color, text and size of the button you are receiving a preview in the top of the screen.
The text of the button is important to activate the correct computer to toggle the redstone signal on and off.
You also can delete the button by clicking on the "DELETE". You can save your changes by clicking on the "BACK".






For your receiver computer you just have to place the computer next to the block which requires a redstone signal and attach a wireless modem to it (the computer).
Start the program you downloaded above and hit a button to change the text/id. Press Enter to finish.
You can have multiple receiver computer with the same text/id and will create a group which can all be toggled on and off with only one button.
The text has to be the same like the button text on the monitor screen.





If you are not in the ADD MODE you can click on the buttons to change their state and send a broadcast message to all near computer receiver to change their redstone state as well.




Thanks for checking out this program. Hopefully someone will find a nice use for it. Have fun :)/>
unobtanium
Edited on 17 April 2014 - 12:26 PM
gollark8 #2
Posted 05 April 2014 - 05:47 PM
I'd like an adv. PDA version of this.
unobtanium #3
Posted 05 April 2014 - 07:18 PM
Dont know how to make that yet. Will have to look into it.
AmigaLink #4
Posted 16 April 2014 - 12:54 AM
Very nice. I like it. :)/>
Csstform #5
Posted 16 April 2014 - 12:06 PM
Dont know how to make that yet. Will have to look into it.
Advanced PDA is just a wierdly shaped Advanced Computer. Also, if the double L on controll is on purpose, you messed up the topic.
Blue #6
Posted 16 April 2014 - 05:35 PM
I Love the customizability of this! Good job! This is so good that you should convert it into an os(runs programs instead of sending signals)
apemanzilla #7
Posted 16 April 2014 - 06:10 PM
I Love the customizability of this! Good job! This is so good that you should convert it into an os(runs programs instead of sending signals)
An OS is a lot more than a bunch of buttons that start programs, as people here seem to think they are.
unobtanium #8
Posted 17 April 2014 - 02:43 PM
Someone knows how i activate rednet with pocket computers? Because since they dont have a side specified i cant call rednet.open(side).
What is the resolution on these pdas?
apemanzilla #9
Posted 17 April 2014 - 04:16 PM
Someone knows how i activate rednet with pocket computers? Because since they dont have a side specified i cant call rednet.open(side).
What is the resolution on these pdas?
rednet.open("top")

Check the config for the resolution.
Csstform #10
Posted 18 April 2014 - 03:48 PM
Someone knows how i activate rednet with pocket computers? Because since they dont have a side specified i cant call rednet.open(side).
What is the resolution on these pdas?
rednet.open("top")

Check the config for the resolution.
No, Im pretty sure its rednet.open("back").

Default res it somewhere around 19x25
Dog #11
Posted 18 April 2014 - 07:02 PM
Default res is 20x26
Csstform #12
Posted 18 April 2014 - 08:38 PM
Default res is 20x26
Dangit, one off.
Blue #13
Posted 19 April 2014 - 08:27 AM
I Love the customizability of this! Good job! This is so good that you should convert it into an os(runs programs instead of sending signals)
An OS is a lot more than a bunch of buttons that start programs, as people here seem to think they are.
I know I was just saying that he should make it into what this forum defines as an "os" even though all of them are either graphical shells or a bunch of programs
chrdov #14
Posted 20 April 2014 - 05:46 PM
Wow… this looks so cool, I can't wait to try it, but If you need any more help in making the requested pda version of this, I'd love to do that. keep up the good work!
unobtanium #15
Posted 20 April 2014 - 07:10 PM
It wont be much of a change. Just some monitor redirect and event changes as well as a new layout for the box settings. I just have to go and sitdown for an hour and then one more to somehow test it :P/>
Sparrow #16
Posted 20 April 2014 - 08:11 PM
This is exactly what I've been looking for/trying to make myself. Unfortunately there appears to be a problem, after restarting the game in SSP redstone/rednet signal is not broadcasted any more, the button is still in active state, tho.
unobtanium #17
Posted 20 April 2014 - 09:16 PM
Oh shit, i suck >.<

I made a change where the receiver computer checks its state when restarting its program.
That might fixes your problem and if not check if the computer did restart (startup) and is placed in loaded chunks.


edit: I am working with the new CC version 1.63 and i cant get my save files loaded. Be it at normal advanced computers or pdas. It seems to return nil if i am telling something like

box = textutils.unserialize(file.readLine())
Is it still a bug or does someone know further information about that?
Edited on 20 April 2014 - 09:09 PM
Sparrow #18
Posted 21 April 2014 - 11:36 AM
Works like a charm now, thank you very much for a quick fix.
Lyqyd #19
Posted 21 April 2014 - 03:26 PM
I am working with the new CC version 1.63 and i cant get my save files loaded. Be it at normal advanced computers or pdas. It seems to return nil if i am telling something like

box = textutils.unserialize(file.readLine())
Is it still a bug or does someone know further information about that?

Look at the contents of the files. The serialization format changed. They aren't single-line strings any more.
unobtanium #20
Posted 21 April 2014 - 06:46 PM
Are you kidding me?
Do i have to save these in different files now?
Edited on 21 April 2014 - 04:47 PM
unobtanium #21
Posted 28 April 2014 - 05:47 PM
So how do i save a lot of arrays into a single file now?
moomoomoo3O9 #22
Posted 04 June 2015 - 08:24 PM
So how do i save a lot of arrays into a single file now?
Would textutils.serialize(table):gsub("\t",""):gsub("\n","") do what you want? (That would just remove all tabs and newline characters)
jakejakey #23
Posted 26 June 2016 - 05:25 PM
This program gives me a ton of errors! I REALLY love it, but it wont work with CC 1.73, please fix it :(/> This program is EXACTLY what I need but it wont work.
Bomb Bloke #24
Posted 27 June 2016 - 01:33 AM
The author hasn't logged in for a few months, so you may have to update it yourself.