Rednet cable computercraft interaction

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

wowartic

New Member
Jul 29, 2019
3
0
0
Hello,
I need help with rednet cable x computercraft interaction .
when I am trying set output with computercraft with command :
redstone.setBundledOutput("bottom", colors.orange)
nothing happens my computer is just not sending signal to the cable and when I try to check if it is sendig something with command:
redstone.getBundledOutput("bottom")
then I am getting output 2 on the screen but not in the cable nothing connected to orange line is getting signal
so I tryed to check it with rednet meter and no signal is in the cable.
when I am using levers everything is working as it should so its probably something with computercraft.
do you have any idea why its not working ?
sorry for my english its not my first launguage.
 
Last edited:

Azzanine

New Member
Jul 29, 2019
2,706
-11
0
I don't think the newer versions of CC support rednet cable (or is it the other way around).
Test if the computer will send a regular signal through an uncolored cable.
 

wowartic

New Member
Jul 29, 2019
3
0
0
I am not sure how to send classic redstone signal in cc so I google it and I found redstone (API) here:http://www.computercraft.info/wiki/Redstone_(API)
and I tryed commmands from there and it doesnt seem to be working for instance when I try check redstone dust bellow computer with command:
redstone.getOutput("bottom")
I get:
lua:1: attempt to call nil
is possible that I dont have redstone (API) in cc and if so how can I get it ?
 

Azzanine

New Member
Jul 29, 2019
2,706
-11
0
The API should be native like it was in the past iterations of CC.
What version of CC are you using? and what version of Minecraft.
I hear in 1.7 the redstone API has been changed up a little.
 

wowartic

New Member
Jul 29, 2019
3
0
0
I am using minecraft 1.6.4 and I am not sure where to find cc version but jar file is named COMPUTERCRAFT1.63 so I guess it will be 1.63
I am not programer or something but I have bassic understandig how code works and I can find logic behind it I am trying to make program that will control mining machine moving it with mffs adn minig with mining wells
I tryed to use design from direwolf20 but his code was not working for me so I was checking whats wrong and found out that my computer is not interacting with rednet cables how it should
do yo uknow about some other metod whitch allows you to send multiple signals on 1 wire ?
 

casilleroatr

New Member
Jul 29, 2019
1,360
0
0
I am not sure how to send classic redstone signal in cc so I google it and I found redstone (API) here:http://www.computercraft.info/wiki/Redstone_(API)
and I tryed commmands from there and it doesnt seem to be working for instance when I try check redstone dust bellow computer with command:
redstone.getOutput("bottom")
I get:
lua:1: attempt to call nil
is possible that I dont have redstone (API) in cc and if so how can I get it ?
Make sure you spell it exactly right. Attempt to call nil means you a calling a null value (i.e something that isn't a function). Function names (like all variable names) are case sensitive. Unfortunately there are know other redstone cables that are compatible with the bundled redstone commands just now. I tested the project red ones recently.

I wrote a program that uses the networking cable so a single computer can coordinate others to do certain redstone functions. There are two programs actually. The first is an API (called modstone) that you can use to interface with other computers. The other is a main program (called redstoner) that you run on the computer you wish to be controlled (this computer will then emit redstone etc)

For example. You have two computers, A and B. Computer A has modstone installed. You use the API to write a program that will cause computer B to emit redstone high and low on a 2 second cycle. It could look like this.

Code:
local modem = peripheral.wrap("left") -- You need modems on all computers for this to work, wired or wireless
local value = true -- The initial redstone value you will set
local channel = 1 -- The modem channel you communicate on (redstoner receivers listen to only one channel)
local filter = "Hello" -- This is an extra filter that enables you to restrict which receivers act on the API's commands
local side = "left" -- The side you want the receiver to emit redstone from.

while true do
  modstone.setRedstone(modem, channel, filter, side, value)
  value = not value -- Inverts the value from true to false and false to true
  sleep(2)
end

This example is a demo only and may have errors - I didn't test it.
The modstoner API can also getRedstoneOutput and getRedstoneInput but there are no other features. It is rough and was written quickly so I could do a specific thing.

Modstone API: http://pastebin.com/2LWnz5iA

You also need to install the redstoner program on a receiver for this to have any effect. You can set the filter and the listening channel in program arguments. If you leave these blank, the filter will be nil and it will select a random channel (it prints out these channels). It will sit and wait for messages and act accordingly if it gets one. If you want a receiver that will respond to the example program above, download it via pastebin at

Redstoner: http://pastebin.com/SQ3yF33b

and make a new startup program and type this code

shell.run("redstoner", 1, "Hello")

If it doesn't work, sorry about that. I just wrote it quickly a couple of days ago and I am sharing because it might be useful, but I am not promising any support for it if it doesn't work properly. It should work though (it works for what I wanted it to do.

I should mention that you can have many receivers operating at once being controlled by the same program (more than 16 at least, but I don't know how laggy it could get)