rts-sim-module/component/relay.go

19 lines
730 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package component
import "joylink.club/ecs"
// 无极继电器和偏极继电器稳态为落下,也就是后接点(8组采集接点中的1,3接点1为中接点)吸气为前接点1,2接点
// 有极继电器是定位反位双稳态(有永久磁钢),前接点为定位,后接点为反位
// 有极继电器对于道岔中的2DQJ励磁接点12接通为反位34接通为定位
// 定义继电器状态时false表示落下/反位/后接点true表示吸起/定位/前接点
// 继电器标签
var RelayTag = ecs.NewTag()
// 继电器控制请求组件
type RelayActionRequest struct {
Xq bool // true吸起
}
var RelayActionRequestType = ecs.NewComponentType[RelayActionRequest]()