Posted 19 December 2012 - 06:34 PM
This program allows a user to view the current state of their nuclear reactors heat VIA wifi. It is codded very simple and the base of this software can be used in a host of other applications outside of power management that requires long range connectivity and/or control-ability without direct contact. The codes format is written to only view the state of 4 reactors but again can be modified, the second program goes onto any computer that will be using and seeing this information, and the third program goes onto your turtle to shut off the nuclear reactor in an emergency situation.
Please leave me request and feed back on all my codes to try thanks!!!
This is for the master computer and should be a startup file (the one sending all the data)
note: 85 should be changed to the id number of your slave computer and 92 should be changed to your turtles id number.
Please leave me request and feed back on all my codes to try thanks!!!
This is for the master computer and should be a startup file (the one sending all the data)
note: 85 should be changed to the id number of your slave computer and 92 should be changed to your turtles id number.
rednet.open("top")
while true do -- loop from here
os.pullEvent("redstone")
if rs.getInput("left") then -- basically you'll want to set your core or cores to have its thermometers going to each side of the pc
rednet.send(85, "Blue Core Hot") -- sending a message to the slave that...
print("Blue core Overheating")
print("Please check Coolant levels")
end
if rs.getInput("right") then
rednet.send(85, "Yellow Core Hot")
print("Yellow Core Overheating")
print("Please check coolant levels")
end
if rs.getInput("bottom")then
rednet.send(85, "Red Core Hot")
print("Red Core Overheating")
print("Please check coolant levels")
end
if rs.getInput("back") then
rednet.send(85, "Green Core Hot")
print("Green Core Overheating")
print("Please check coolant levels")
end
if rs.getInput("front") then --this is the part that controls emergency shutoff you can again change to whatever side suits your design.
rednet.send(85, "ERS Restart must be initiated on site")
sleep(3) -- for some reason it wont send a message to the turtle unless it sleeps first idk but it works so...
rednet.send(92, "ERS MODE") -- starting the turtle to destroy the block or fuse that shuts of all power and or clears uraniun from the core
print("Emergency Reactor Shutdown")
print("Venting active. Clean in 30 seconds, cooldown time is 1 minute.")
break -- ends the loop here
end
end