mirror of
https://github.com/Team254/cheesy-arena-lite.git
synced 2026-03-09 13:46:44 -04:00
Decode ArmorBlock status register from PLC and surface individual statuses on Match Play page.
This commit is contained in:
27
plc/armorblock_string.go
Normal file
27
plc/armorblock_string.go
Normal file
@@ -0,0 +1,27 @@
|
||||
// Code generated by "stringer -type=armorBlock"; DO NOT EDIT.
|
||||
|
||||
package plc
|
||||
|
||||
import "strconv"
|
||||
|
||||
func _() {
|
||||
// An "invalid array index" compiler error signifies that the constant values have changed.
|
||||
// Re-run the stringer command to generate them again.
|
||||
var x [1]struct{}
|
||||
_ = x[redDs-0]
|
||||
_ = x[blueDs-1]
|
||||
_ = x[shieldGenerator-2]
|
||||
_ = x[controlPanel-3]
|
||||
_ = x[armorBlockCount-4]
|
||||
}
|
||||
|
||||
const _armorBlock_name = "redDsblueDsshieldGeneratorcontrolPanelarmorBlockCount"
|
||||
|
||||
var _armorBlock_index = [...]uint8{0, 5, 11, 26, 38, 53}
|
||||
|
||||
func (i armorBlock) String() string {
|
||||
if i < 0 || i >= armorBlock(len(_armorBlock_index)-1) {
|
||||
return "armorBlock(" + strconv.FormatInt(int64(i), 10) + ")"
|
||||
}
|
||||
return _armorBlock_name[_armorBlock_index[i]:_armorBlock_index[i+1]]
|
||||
}
|
||||
Reference in New Issue
Block a user