From 8d19129ec6b8ff6d3848da717f8c5fe080c5432b Mon Sep 17 00:00:00 2001 From: thesai <1021828630@qq.com> Date: Thu, 1 Aug 2024 14:25:45 +0800 Subject: [PATCH] =?UTF-8?q?[bug]=E4=BF=A1=E5=8F=B7=E6=9C=BA=E7=94=B5?= =?UTF-8?q?=E8=B7=AF=E7=B3=BB=E7=BB=9F=E9=80=BB=E8=BE=91=E6=B2=A1=E6=9C=89?= =?UTF-8?q?=E6=AD=A3=E7=A1=AE=E5=A4=84=E7=90=86=E9=A9=B1=E5=8A=A8=E7=8A=B6?= =?UTF-8?q?=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sys/circuit_sys/signal_2xh1.go | 31 ++++++++++++++++------ sys/circuit_sys/signal_3xh1.go | 47 +++++++++++++++++++++++++-------- sys/circuit_sys/signal_3xh2.go | 41 +++++++++++++++++++++------- sys/circuit_sys/signal_3xh3.go | 40 +++++++++++++++++++++------- sys/circuit_sys/signal_3xh4.go | 38 +++++++++++++++++++------- sys/circuit_sys/signal_dcxh.go | 28 +++++++++++++------- sys/circuit_sys/signal_jckxh.go | 35 +++++++++++++++++------- sys/circuit_sys/signal_jdxh.go | 37 ++++++++++++++++++-------- 8 files changed, 219 insertions(+), 78 deletions(-) diff --git a/sys/circuit_sys/signal_2xh1.go b/sys/circuit_sys/signal_2xh1.go index 730457d..13a9e38 100644 --- a/sys/circuit_sys/signal_2xh1.go +++ b/sys/circuit_sys/signal_2xh1.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type Signal2XH1System struct { @@ -20,21 +21,35 @@ func NewSignal2XH1System() *Signal2XH1System { // Update world 执行 func (s *Signal2XH1System) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.Signal2XH1ElectronicType.Get(entry) - lsq := component.Signal2XH1LsqType.Get(entry) - lsc := component.Signal2XH1LscType.Get(entry) + circuit := component.Signal2XH1ElectronicType.Get(entry) + excite2xh1ByCiDrive(circuit, wd) + //lsq := component.Signal2XH1LsqType.Get(entry) + //lsc := component.Signal2XH1LscType.Get(entry) lights := component.SignalLightsType.Get(entry) Z2XH1_L := lights.GetLightByTag(component.LdTag) Z2XH1_H := lights.GetLightByTag(component.HdTag) - s.calculateLsq(state, lsq) - s.calculateL(state, Z2XH1_L) - s.calculateH(state, Z2XH1_H) - s.calculateDJ(state, Z2XH1_L, Z2XH1_H) - s.calculateLsc(state, lsc) + //s.calculateLsq(circuit, lsq) + s.calculateL(circuit, Z2XH1_L) + s.calculateH(circuit, Z2XH1_H) + s.calculateDJ(circuit, Z2XH1_L, Z2XH1_H) + //s.calculateLsc(circuit, lsc) }) } +func excite2xh1ByCiDrive(circuit *component.Signal2XH1Electronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.Z2XH1_DDJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z2XH1_DDJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z2XH1_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z2XH1_LXJ).Td = bit + } +} + // 联锁驱 func (s *Signal2XH1System) calculateLsq(state *component.Signal2XH1Electronic, lsq *component.Signal2XH1Lsq) { ddj := component.RelayDriveType.Get(state.Z2XH1_DDJ) diff --git a/sys/circuit_sys/signal_3xh1.go b/sys/circuit_sys/signal_3xh1.go index 8e63ef6..cd8f145 100644 --- a/sys/circuit_sys/signal_3xh1.go +++ b/sys/circuit_sys/signal_3xh1.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type Signal3XH1System struct { @@ -20,25 +21,49 @@ func NewSignal3XH1System() *Signal3XH1System { // Update world 执行 func (s *Signal3XH1System) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.Signal3XH1ElectronicType.Get(entry) - lsq := component.Signal3XH1LsqType.Get(entry) - lsc := component.Signal3XH1LscType.Get(entry) + circuit := component.Signal3XH1ElectronicType.Get(entry) + excite3xh1ByCiDrive(circuit, wd) + //lsq := component.Signal3XH1LsqType.Get(entry) + //lsc := component.Signal3XH1LscType.Get(entry) lights := component.SignalLightsType.Get(entry) Z3XH1_L := lights.GetLightByTag(component.LdTag) Z3XH1_H := lights.GetLightByTag(component.HdTag) Z3XH1_U := lights.GetLightByTag(component.UdTag) - // - s.calculateLsq(state, lsq) - s.calculateU(state, Z3XH1_U) - s.calculateL(state, Z3XH1_L) - s.calculateH(state, Z3XH1_H) - s.calculateDJ(state, Z3XH1_H, Z3XH1_L, Z3XH1_U) - s.calculate2DJ(state, Z3XH1_U) - s.calculateLsc(state, lsc) + + //s.calculateLsq(circuit, lsq) + s.calculateU(circuit, Z3XH1_U) + s.calculateL(circuit, Z3XH1_L) + s.calculateH(circuit, Z3XH1_H) + s.calculateDJ(circuit, Z3XH1_H, Z3XH1_L, Z3XH1_U) + s.calculate2DJ(circuit, Z3XH1_U) + //s.calculateLsc(circuit, lsc) }) } +func excite3xh1ByCiDrive(circuit *component.Signal3XH1Electronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.Z3XH1_DDJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH1_DDJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH1_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH1_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH1_ZXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH1_ZXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH1_YXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH1_YXJ).Td = bit + } +} + // 联锁驱 func (s *Signal3XH1System) calculateLsq(state *component.Signal3XH1Electronic, lsq *component.Signal3XH1Lsq) { ddj := component.RelayDriveType.Get(state.Z3XH1_DDJ) diff --git a/sys/circuit_sys/signal_3xh2.go b/sys/circuit_sys/signal_3xh2.go index b926b03..0b691a8 100644 --- a/sys/circuit_sys/signal_3xh2.go +++ b/sys/circuit_sys/signal_3xh2.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type Signal3XH2System struct { @@ -20,24 +21,44 @@ func NewSignal3XH2System() *Signal3XH2System { // Update world 执行 func (s *Signal3XH2System) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.Signal3XH2ElectronicType.Get(entry) - lsq := component.Signal3XH2LsqType.Get(entry) - lsc := component.Signal3XH2LscType.Get(entry) + circuit := component.Signal3XH2ElectronicType.Get(entry) + excite3xh2ByCiDrive(circuit, wd) + //lsq := component.Signal3XH2LsqType.Get(entry) + //lsc := component.Signal3XH2LscType.Get(entry) lights := component.SignalLightsType.Get(entry) Z3XH2_L := lights.GetLightByTag(component.LdTag) Z3XH2_H := lights.GetLightByTag(component.HdTag) Z3XH2_U := lights.GetLightByTag(component.UdTag) - s.calculateLsq(state, lsq) - s.calculateU(state, Z3XH2_U) - s.calculateL(state, Z3XH2_L) - s.calculateH(state, Z3XH2_H) - s.calculateDJ(state, Z3XH2_L, Z3XH2_H) - s.calculate2DJ(state, Z3XH2_U) - s.calculateLsc(state, lsc) + //s.calculateLsq(circuit, lsq) + s.calculateU(circuit, Z3XH2_U) + s.calculateL(circuit, Z3XH2_L) + s.calculateH(circuit, Z3XH2_H) + s.calculateDJ(circuit, Z3XH2_L, Z3XH2_H) + s.calculate2DJ(circuit, Z3XH2_U) + //s.calculateLsc(circuit, lsc) }) } +// 根据联锁驱动给继电器励磁 +func excite3xh2ByCiDrive(circuit *component.Signal3XH2Electronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.Z3XH2_DDJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH2_DDJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH2_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH2_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH2_YXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH2_YXJ).Td = bit + } +} + // 联锁驱 func (s *Signal3XH2System) calculateLsq(state *component.Signal3XH2Electronic, lsq *component.Signal3XH2Lsq) { ddj := component.RelayDriveType.Get(state.Z3XH2_DDJ) diff --git a/sys/circuit_sys/signal_3xh3.go b/sys/circuit_sys/signal_3xh3.go index 3f01aa7..635e25f 100644 --- a/sys/circuit_sys/signal_3xh3.go +++ b/sys/circuit_sys/signal_3xh3.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type Signal3XH3System struct { @@ -20,23 +21,42 @@ func NewSignal3XH3System() *Signal3XH3System { // Update world 执行 func (s *Signal3XH3System) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.Signal3XH3ElectronicType.Get(entry) - lsq := component.Signal3XH3LsqType.Get(entry) - lsc := component.Signal3XH3LscType.Get(entry) + circuit := component.Signal3XH3ElectronicType.Get(entry) + excite3xh3ByCiDrive(circuit, wd) + //lsq := component.Signal3XH3LsqType.Get(entry) + //lsc := component.Signal3XH3LscType.Get(entry) lights := component.SignalLightsType.Get(entry) Z3XH3_H := lights.GetLightByTag(component.HdTag) Z3XH3_U := lights.GetLightByTag(component.UdTag) - // - s.calculateLsq(state, lsq) - s.calculateU(state, Z3XH3_U) - s.calculateH(state, Z3XH3_H) - s.calculateDJ(state, Z3XH3_U, Z3XH3_H) - s.calculate2DJ(state, Z3XH3_U) - s.calculateLsc(state, lsc) + + //s.calculateLsq(circuit, lsq) + s.calculateU(circuit, Z3XH3_U) + s.calculateH(circuit, Z3XH3_H) + s.calculateDJ(circuit, Z3XH3_U, Z3XH3_H) + s.calculate2DJ(circuit, Z3XH3_U) + //s.calculateLsc(circuit, lsc) }) } +func excite3xh3ByCiDrive(circuit *component.Signal3XH3Electronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.Z3XH3_DDJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH3_DDJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH3_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH3_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH3_YXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH3_YXJ).Td = bit + } +} + // 联锁驱 func (s *Signal3XH3System) calculateLsq(state *component.Signal3XH3Electronic, lsq *component.Signal3XH3Lsq) { ddj := component.RelayDriveType.Get(state.Z3XH3_DDJ) diff --git a/sys/circuit_sys/signal_3xh4.go b/sys/circuit_sys/signal_3xh4.go index 11dc948..f4729a1 100644 --- a/sys/circuit_sys/signal_3xh4.go +++ b/sys/circuit_sys/signal_3xh4.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type Signal3XH4System struct { @@ -20,24 +21,43 @@ func NewSignal3XH4System() *Signal3XH4System { // Update world 执行 func (s *Signal3XH4System) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.Signal3XH4ElectronicType.Get(entry) - lsq := component.Signal3XH4LsqType.Get(entry) - lsc := component.Signal3XH4LscType.Get(entry) + circuit := component.Signal3XH4ElectronicType.Get(entry) + excite3xh4ByCiDrive(circuit, wd) + //lsq := component.Signal3XH4LsqType.Get(entry) + //lsc := component.Signal3XH4LscType.Get(entry) lights := component.SignalLightsType.Get(entry) Z3XH4_H := lights.GetLightByTag(component.HdTag) Z3XH4_L := lights.GetLightByTag(component.LdTag) Z3XH4_U := lights.GetLightByTag(component.UdTag) // - s.calculateLsq(state, lsq) - s.calculateU(state, Z3XH4_U) - s.calculateL(state, Z3XH4_L) - s.calculateH(state, Z3XH4_H) - s.calculateDJ(state, Z3XH4_H, Z3XH4_L, Z3XH4_U) - s.calculateLsc(state, lsc) + //s.calculateLsq(circuit, lsq) + s.calculateU(circuit, Z3XH4_U) + s.calculateL(circuit, Z3XH4_L) + s.calculateH(circuit, Z3XH4_H) + s.calculateDJ(circuit, Z3XH4_H, Z3XH4_L, Z3XH4_U) + //s.calculateLsc(circuit, lsc) }) } +func excite3xh4ByCiDrive(circuit *component.Signal3XH4Electronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.Z3XH4_DDJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH4_DDJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH4_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH4_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.Z3XH4_ZXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.Z3XH4_ZXJ).Td = bit + } +} + // 联锁驱 func (s *Signal3XH4System) calculateLsq(state *component.Signal3XH4Electronic, lsq *component.Signal3XH4Lsq) { ddj := component.RelayDriveType.Get(state.Z3XH4_DDJ) diff --git a/sys/circuit_sys/signal_dcxh.go b/sys/circuit_sys/signal_dcxh.go index b7a162d..e1fb561 100644 --- a/sys/circuit_sys/signal_dcxh.go +++ b/sys/circuit_sys/signal_dcxh.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type SignalDCXHSystem struct { @@ -20,23 +21,32 @@ func NewSignalDCXHSystem() *SignalDCXHSystem { // Update world 执行 func (s *SignalDCXHSystem) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.SignalDCXHElectronicType.Get(entry) - lsq := component.SignalDCXHLsqType.Get(entry) - lsc := component.SignalDCXHLscType.Get(entry) + circuit := component.SignalDCXHElectronicType.Get(entry) + exciteDcxhByCiDrive(circuit, wd) + //lsq := component.SignalDCXHLsqType.Get(entry) + //lsc := component.SignalDCXHLscType.Get(entry) lights := component.SignalLightsType.Get(entry) DCXH_A := lights.GetLightByTag(component.AdTag) DCXH_B := lights.GetLightByTag(component.BdTag) - // - s.calculateLsq(state, lsq) - s.calculateA(state, DCXH_A) - s.calculateB(state, DCXH_B) - s.calculateDJ(state, DCXH_B, DCXH_A) - s.calculateLsc(state, lsc) + + //s.calculateLsq(circuit, lsq) + s.calculateA(circuit, DCXH_A) + s.calculateB(circuit, DCXH_B) + s.calculateDJ(circuit, DCXH_B, DCXH_A) + //s.calculateLsc(circuit, lsc) }) } +func exciteDcxhByCiDrive(circuit *component.SignalDCXHElectronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.DCXH_DXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.DCXH_DXJ).Td = bit + } +} + // 联锁驱 func (s *SignalDCXHSystem) calculateLsq(state *component.SignalDCXHElectronic, lsq *component.SignalDCXHLsq) { dxj := component.RelayDriveType.Get(state.DCXH_DXJ) diff --git a/sys/circuit_sys/signal_jckxh.go b/sys/circuit_sys/signal_jckxh.go index 9333027..fdd51b0 100644 --- a/sys/circuit_sys/signal_jckxh.go +++ b/sys/circuit_sys/signal_jckxh.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type SignalJCKXHSystem struct { @@ -20,24 +21,38 @@ func NewSignalJCKXHSystem() *SignalJCKXHSystem { // Update world 执行 func (s *SignalJCKXHSystem) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.SignalJCKXHElectronicType.Get(entry) - lsq := component.SignalJCKXHLsqType.Get(entry) - lsc := component.SignalJCKXHLscType.Get(entry) + circuit := component.SignalJCKXHElectronicType.Get(entry) + exciteJckxhByCiDrive(circuit, wd) + //lsq := component.SignalJCKXHLsqType.Get(entry) + //lsc := component.SignalJCKXHLscType.Get(entry) lights := component.SignalLightsType.Get(entry) JCKXH_H := lights.GetLightByTag(component.HdTag) JCKXH_B := lights.GetLightByTag(component.BdTag) JCKXH_U := lights.GetLightByTag(component.UdTag) - // - s.calculateLsq(state, lsq) - s.calculateU(state, JCKXH_U) - s.calculateB(state, JCKXH_B) - s.calculateH(state, JCKXH_H) - s.calculateDJ(state, JCKXH_H, JCKXH_B, JCKXH_U) - s.calculateLsc(state, lsc) + + //s.calculateLsq(circuit, lsq) + s.calculateU(circuit, JCKXH_U) + s.calculateB(circuit, JCKXH_B) + s.calculateH(circuit, JCKXH_H) + s.calculateDJ(circuit, JCKXH_H, JCKXH_B, JCKXH_U) + //s.calculateLsc(circuit, lsc) }) } +func exciteJckxhByCiDrive(circuit *component.SignalJCKXHElectronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.JCKXH_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.JCKXH_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.JCKXH_DXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.JCKXH_DXJ).Td = bit + } +} + // 联锁驱 func (s *SignalJCKXHSystem) calculateLsq(state *component.SignalJCKXHElectronic, lsq *component.SignalJCKXHLsq) { dxj := component.RelayDriveType.Get(state.JCKXH_DXJ) diff --git a/sys/circuit_sys/signal_jdxh.go b/sys/circuit_sys/signal_jdxh.go index 7311f65..711bd9e 100644 --- a/sys/circuit_sys/signal_jdxh.go +++ b/sys/circuit_sys/signal_jdxh.go @@ -4,6 +4,7 @@ import ( "joylink.club/ecs" "joylink.club/ecs/filter" "joylink.club/rtsssimulation/component" + "joylink.club/rtsssimulation/entity" ) type SignalJDXHSystem struct { @@ -20,25 +21,39 @@ func NewSignalJDXHSystem() *SignalJDXHSystem { // Update world 执行 func (s *SignalJDXHSystem) Update(w ecs.World) { + wd := entity.GetWorldData(w) s.query.Each(w, func(entry *ecs.Entry) { - state := component.SignalJDXHElectronicType.Get(entry) - lsq := component.SignalJDXHLsqType.Get(entry) - lsc := component.SignalJDXHLscType.Get(entry) + circuit := component.SignalJDXHElectronicType.Get(entry) + exciteJdxhByCiDrive(circuit, wd) + //lsq := component.SignalJDXHLsqType.Get(entry) + //lsc := component.SignalJDXHLscType.Get(entry) lights := component.SignalLightsType.Get(entry) JDXH_H := lights.GetLightByTag(component.HdTag) JDXH_L := lights.GetLightByTag(component.LdTag) JDXH_U := lights.GetLightByTag(component.UdTag) - // - s.calculateLsq(state, lsq) - s.calculateL(state, JDXH_L) - s.calculateU(state, JDXH_U) - s.calculateH(state, JDXH_H) - s.calculateDJ(state, JDXH_L, JDXH_H) - s.calculate2DJ(state, JDXH_U) - s.calculateLsc(state, lsc) + + //s.calculateLsq(circuit, lsq) + s.calculateL(circuit, JDXH_L) + s.calculateU(circuit, JDXH_U) + s.calculateH(circuit, JDXH_H) + s.calculateDJ(circuit, JDXH_L, JDXH_H) + s.calculate2DJ(circuit, JDXH_U) + //s.calculateLsc(circuit, lsc) }) } +func exciteJdxhByCiDrive(circuit *component.SignalJDXHElectronic, wd *component.WorldData) { + bit, err := wd.QueryQdBit(component.UidType.Get(circuit.JDXH_LXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.JDXH_LXJ).Td = bit + } + + bit, err = wd.QueryQdBit(component.UidType.Get(circuit.JDXH_YXJ).Id) + if err == nil { + component.RelayDriveType.Get(circuit.JDXH_YXJ).Td = bit + } +} + // 联锁驱 func (s *SignalJDXHSystem) calculateLsq(state *component.SignalJDXHElectronic, lsq *component.SignalJDXHLsq) { lxj := component.RelayDriveType.Get(state.JDXH_LXJ)