2023-10-10 16:15:56 +08:00
|
|
|
package component
|
|
|
|
|
|
|
|
import "joylink.club/ecs"
|
|
|
|
|
2023-10-11 15:43:48 +08:00
|
|
|
// 按钮标签
|
|
|
|
var (
|
|
|
|
// 非自复式按下接通式按钮
|
|
|
|
NoResetPressBtn = ecs.NewTag()
|
|
|
|
// 非自复式拉起接通式按钮
|
|
|
|
NoResetUpBtn = ecs.NewTag()
|
|
|
|
// 自复式按下接通式按钮
|
|
|
|
ResetPressBtn = ecs.NewTag()
|
|
|
|
// 自复式拉起接通式按钮
|
|
|
|
ResetUpBtn = ecs.NewTag()
|
|
|
|
)
|
|
|
|
|
|
|
|
// 蜂鸣器驱动
|
|
|
|
type FMQDrive struct {
|
|
|
|
Td bool
|
|
|
|
}
|
|
|
|
|
|
|
|
// 蜂鸣器驱动组件
|
|
|
|
var FMQDriveType = ecs.NewComponentType[FMQDrive]()
|
|
|
|
|
2023-10-10 16:15:56 +08:00
|
|
|
// SPK继电器控制电路
|
|
|
|
type SpkControlElectronic struct {
|
|
|
|
SPKSXPLA_BTN *ecs.Entry
|
|
|
|
SPKSX1J_BTN *ecs.Entry
|
|
|
|
SPKSX3J_BTN *ecs.Entry
|
|
|
|
SPKSX1J *ecs.Entry
|
|
|
|
SPKSX3J *ecs.Entry
|
|
|
|
|
|
|
|
SPKSSPLA_BTN *ecs.Entry
|
|
|
|
SPKSS2J_BTN *ecs.Entry
|
|
|
|
SPKSS4J_BTN *ecs.Entry
|
|
|
|
SPKSS2J *ecs.Entry
|
|
|
|
SPKSS4J *ecs.Entry
|
|
|
|
}
|
|
|
|
|
|
|
|
// SPK继电器元器件组件
|
|
|
|
var SpkControlElectronicType = ecs.NewComponentType[SpkControlElectronic]()
|
|
|
|
|
|
|
|
// SPK标识电路
|
|
|
|
type SpksStateElectronic struct {
|
|
|
|
SPKSX1J *ecs.Entry
|
|
|
|
SPKSX3J *ecs.Entry
|
|
|
|
SPKSS2J *ecs.Entry
|
|
|
|
SPKSS4J *ecs.Entry
|
|
|
|
|
|
|
|
SPKSXPLAJ *ecs.Entry
|
|
|
|
SPKSSPLAJ *ecs.Entry
|
|
|
|
|
2023-10-11 15:43:48 +08:00
|
|
|
SPKSX1D *ecs.Entry
|
|
|
|
SPKSX3D *ecs.Entry
|
|
|
|
SPKSS2D *ecs.Entry
|
|
|
|
SPKSS4D *ecs.Entry
|
|
|
|
SPKSXPLAD *ecs.Entry
|
|
|
|
SPKSSPLAD *ecs.Entry
|
2023-10-10 16:15:56 +08:00
|
|
|
|
|
|
|
SDA *ecs.Entry
|
|
|
|
}
|
|
|
|
|
|
|
|
// SPK继电器元器件组件
|
|
|
|
var SpksStateElectronicType = ecs.NewComponentType[SpksStateElectronic]()
|
|
|
|
|
|
|
|
// EMP 控制电路
|
|
|
|
type EmpControlElectronic struct {
|
|
|
|
EMP1_BTN *ecs.Entry
|
|
|
|
EMP3_BTN *ecs.Entry
|
|
|
|
EMP5_BTN *ecs.Entry
|
|
|
|
EMPX_BTN *ecs.Entry
|
|
|
|
XEMPFA_BTN *ecs.Entry
|
|
|
|
XEMPJ *ecs.Entry // 继电器
|
|
|
|
|
|
|
|
EMP2_BTN *ecs.Entry
|
|
|
|
EMP4_BTN *ecs.Entry
|
|
|
|
EMP6_BTN *ecs.Entry
|
|
|
|
EMPS_BTN *ecs.Entry
|
|
|
|
SEMPFA_BTN *ecs.Entry
|
|
|
|
SEMPJ *ecs.Entry // 继电器
|
|
|
|
}
|
|
|
|
|
|
|
|
var EmpControlElectronicType = ecs.NewComponentType[EmpControlElectronic]()
|
|
|
|
|
|
|
|
// EMP 标识状态电路
|
|
|
|
type EmpStateElectronic struct {
|
2023-10-11 15:43:48 +08:00
|
|
|
XEMPJ *ecs.Entry // 继电器
|
|
|
|
XEMPD *ecs.Entry
|
2023-10-10 16:15:56 +08:00
|
|
|
|
2023-10-11 15:43:48 +08:00
|
|
|
SEMPJ *ecs.Entry // 继电器
|
|
|
|
SEMPD *ecs.Entry
|
2023-10-10 16:15:56 +08:00
|
|
|
|
2023-10-11 15:43:48 +08:00
|
|
|
SDA *ecs.Entry // 按钮
|
2023-10-10 16:15:56 +08:00
|
|
|
QBA *ecs.Entry // 非自复位按钮
|
2023-10-11 15:43:48 +08:00
|
|
|
FMQ *ecs.Entry // 蜂鸣器
|
2023-10-10 16:15:56 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
var EmpStateElectronicType = ecs.NewComponentType[EmpStateElectronic]()
|