SemlerPDX

Stationeers IC10 - S01E02 Solar Tracking & Power Control v1

Dec 16th, 2025
5,427
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | Gaming | 0 0
  1. #Solar Tracking & Power Systems Control v1
  2. # by SemlerPDX Dec2025
  3.  
  4. define SolarPanels -539224550
  5. define DaylightSensors 1076425094
  6. define Generators 813146305
  7. define Batteries -400115994
  8.  
  9. define ChargeMin 0.10 # 10%
  10. define ChargeMax 0.50 # 50%
  11.  
  12. define SensorOffset 90 #0, 90, 180, or 270
  13.  
  14. # Threshold for "dark"
  15. define IrradianceMin 1
  16.  
  17. define DawnVertical 165
  18. define DawnHorizontal 180
  19.  
  20. main:
  21. yield
  22.  
  23. #Range Based Toggle == IC10 Schmitt Trigger
  24. lb r0 Batteries Ratio Average
  25. lb r1 Generators On Maximum
  26. select r1 r1 ChargeMax ChargeMin
  27. slt r0 r0 r1
  28. sb Generators On r0
  29.  
  30. lb r0 DaylightSensors SolarIrradiance Maximum
  31. blt r0 IrradianceMin nightSleep
  32.  
  33. lb r0 DaylightSensors Vertical Maximum
  34. lb r1 DaylightSensors Horizontal Maximum
  35. add r0 r0 SensorOffset
  36. add r1 r1 SensorOffset
  37. sb SolarPanels Vertical r0
  38. sb SolarPanels Horizontal r1
  39. j main
  40.  
  41. nightSleep:
  42. sb SolarPanels Vertical DawnVertical
  43. sb SolarPanels Horizontal DawnHorizontal
  44. j main
Advertisement
Add Comment
Please, Sign In to add comment