Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --
- -- Control an active cooled reactor from Big reactors (http://big-reactors.com/).
- -- Profiler
- -- run this script before running the reactor control script
- -- run this script every time you change your reactor layout
- --
- -- Author: El_Loko_
- --
- -- Save as "startup"
- --
- --
- --
- -- Constant values (configuration)
- -- ===============================
- local rodLevel = 100
- local reactor
- reactor = peripheral.wrap("bottom")
- local hold = 20 -- as higher the hold value that more accurate are the values
- local profile = fs.open("profile.txt", "w")
- reactor.setActive(true)
- rod = 100
- repeat
- reactor.setAllControlRodLevels(rod)
- sleep(hold)
- print("R: " .. rod .. " Heat: " .. reactor.getFuelTemperature() .. " Steam: " .. reactor.getEnergyProducedLastTick())
- profile.writeLine(rod .. ";" .. reactor.getFuelTemperature() .. ";" .. reactor.getEnergyProducedLastTick())
- rod = rod - 1
- if(reactor.getEnergyProducedLastTick() > 8000) then
- rod = 0
- end
- until rod == 0
- reactor.setActive(false)
- profile.close()
Add Comment
Please, Sign In to add comment