Update PLC inputs and outputs.

This commit is contained in:
Patrick Fairbank
2019-08-04 14:04:46 -07:00
parent 06a91b8a3c
commit 865f071cda
3 changed files with 29 additions and 31 deletions

View File

@@ -15,18 +15,23 @@ func _() {
_ = x[stackLightRed-4] _ = x[stackLightRed-4]
_ = x[stackLightBlue-5] _ = x[stackLightBlue-5]
_ = x[stackLightBuzzer-6] _ = x[stackLightBuzzer-6]
_ = x[red1EthernetDisable-7] _ = x[fieldResetLight-7]
_ = x[red2EthernetDisable-8] _ = x[cargoShipMagnetRed-8]
_ = x[red3EthernetDisable-9] _ = x[cargoShipMagnetBlue-9]
_ = x[blue1EthernetDisable-10] _ = x[cargoShipLightRed-10]
_ = x[blue2EthernetDisable-11] _ = x[cargoShipLightBlue-11]
_ = x[blue3EthernetDisable-12] _ = x[sandstormUpRed-12]
_ = x[coilCount-13] _ = x[sandstormUpBlue-13]
_ = x[rocketLightRedNear-14]
_ = x[rocketLightRedFar-15]
_ = x[rocketLightBlueNear-16]
_ = x[rocketLightBlueFar-17]
_ = x[coilCount-18]
} }
const _coil_name = "heartbeatmatchResetstackLightGreenstackLightOrangestackLightRedstackLightBluestackLightBuzzerred1EthernetDisablered2EthernetDisablered3EthernetDisableblue1EthernetDisableblue2EthernetDisableblue3EthernetDisablecoilCount" const _coil_name = "heartbeatmatchResetstackLightGreenstackLightOrangestackLightRedstackLightBluestackLightBuzzerfieldResetLightcargoShipMagnetRedcargoShipMagnetBluecargoShipLightRedcargoShipLightBluesandstormUpRedsandstormUpBluerocketLightRedNearrocketLightRedFarrocketLightBlueNearrocketLightBlueFarcoilCount"
var _coil_index = [...]uint8{0, 9, 19, 34, 50, 63, 77, 93, 112, 131, 150, 170, 190, 210, 219} var _coil_index = [...]uint16{0, 9, 19, 34, 50, 63, 77, 93, 108, 126, 145, 162, 180, 194, 209, 227, 244, 263, 281, 290}
func (i coil) String() string { func (i coil) String() string {
if i < 0 || i >= coil(len(_coil_index)-1) { if i < 0 || i >= coil(len(_coil_index)-1) {

View File

@@ -59,13 +59,7 @@ const (
type register int type register int
const ( const (
red1Bandwidth register = iota registerCount register = iota
red2Bandwidth
red3Bandwidth
blue1Bandwidth
blue2Bandwidth
blue3Bandwidth
registerCount
) )
// Coils // Coils
@@ -79,12 +73,17 @@ const (
stackLightRed stackLightRed
stackLightBlue stackLightBlue
stackLightBuzzer stackLightBuzzer
red1EthernetDisable fieldResetLight
red2EthernetDisable cargoShipMagnetRed
red3EthernetDisable cargoShipMagnetBlue
blue1EthernetDisable cargoShipLightRed
blue2EthernetDisable cargoShipLightBlue
blue3EthernetDisable sandstormUpRed
sandstormUpBlue
rocketLightRedNear
rocketLightRedFar
rocketLightBlueNear
rocketLightBlueFar
coilCount coilCount
) )

View File

@@ -8,18 +8,12 @@ func _() {
// An "invalid array index" compiler error signifies that the constant values have changed. // An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again. // Re-run the stringer command to generate them again.
var x [1]struct{} var x [1]struct{}
_ = x[red1Bandwidth-0] _ = x[registerCount-0]
_ = x[red2Bandwidth-1]
_ = x[red3Bandwidth-2]
_ = x[blue1Bandwidth-3]
_ = x[blue2Bandwidth-4]
_ = x[blue3Bandwidth-5]
_ = x[registerCount-6]
} }
const _register_name = "red1Bandwidthred2Bandwidthred3Bandwidthblue1Bandwidthblue2Bandwidthblue3BandwidthregisterCount" const _register_name = "registerCount"
var _register_index = [...]uint8{0, 13, 26, 39, 53, 67, 81, 94} var _register_index = [...]uint8{0, 13}
func (i register) String() string { func (i register) String() string {
if i < 0 || i >= register(len(_register_index)-1) { if i < 0 || i >= register(len(_register_index)-1) {