demo1
parent
fb6d40571c
commit
37fdee1353
|
@ -45,8 +45,12 @@ export const DIGITAL_INPUT_FUNCTION = {
|
|||
|
||||
export const DIGITAL_OUTPUT_FUNCTION = {
|
||||
Null: "空",
|
||||
DigitalOutput: "普通输出",
|
||||
LightOutput: "灯光输出",
|
||||
DND: "DND",
|
||||
MUR: "MUR",
|
||||
DOOR_BELL:"门铃",
|
||||
OCCUPANCY: "占用状态",
|
||||
DigitalOutput: "手动配置输出",
|
||||
};
|
||||
|
||||
export const VIRTUAL_OUTPUT_FUNCTION = {
|
||||
|
|
|
@ -365,6 +365,20 @@ const onSubmit = () => {
|
|||
let code73 = '';
|
||||
Object.values(device.DIGITAL_OUTPUT).forEach((dix) => {
|
||||
switch (dix.Func) {
|
||||
case 'OCCUPANCY':
|
||||
code72 += `REG_HELPER_Output_PI5_Bit(${dix.Pin}, PI5IDX_OCCUPANCY, (PI5M_OCCUPANCY_STAFF|PI5M_OCCUPANCY_GUEST), CBL32_DO_DRIVER_CONF_DEFAULT);\n `
|
||||
break;
|
||||
case 'MUR':
|
||||
code72 += `REG_HELPER_Output_PI5_Bit(${dix.Pin}, PI5IDX_MISC_MSMD, PI5M_MUR, CBL32_DO_DRIVER_CONF_DEFAULT);\n `
|
||||
break;
|
||||
case 'DOOR_BELL':
|
||||
code72 += `REG_HELPER_Output_PI5_Bit(${dix.Pin}, PI5IDX_MISC_MSMD, CBL32_DO_FCT_GRP_SPECIAL_IDX_DOOR_BELL, CBL32_DO_DRIVER_CONF_DEFAULT);\n `
|
||||
break;
|
||||
case 'DND':
|
||||
code72 += `REG_HELPER_Output_PI5_Bit(${dix.Pin}, PI5IDX_MISC_MSMD, PI5M_DND, CBL32_DO_DRIVER_CONF_DEFAULT);\n `
|
||||
break;
|
||||
|
||||
|
||||
case 'DigitalOutput':
|
||||
code72 += `REG_HELPER_Output_PI5_Bit(${dix.Pin}, ${dix.PI5_Ofs}, ${dix.BitMask}, ${dix.ConfFlags});\n `
|
||||
break;
|
||||
|
@ -442,6 +456,11 @@ const onSubmit = () => {
|
|||
#define P5_ADDRESS \
|
||||
${ device.ADDR }
|
||||
|
||||
#define APP_ID_1 9
|
||||
#define APP_ID_2 9
|
||||
#define APP_ID_3 4
|
||||
#define APP_ID_4 4
|
||||
|
||||
//**********************************************************************************************************************
|
||||
// Constants
|
||||
//**********************************************************************************************************************
|
||||
|
|
5
x10.c
5
x10.c
|
@ -20,6 +20,11 @@
|
|||
#define P5_ADDRESS \
|
||||
${ device.ADDR }
|
||||
|
||||
#define APP_ID_1 9
|
||||
#define APP_ID_2 9
|
||||
#define APP_ID_3 4
|
||||
#define APP_ID_4 4
|
||||
|
||||
//**********************************************************************************************************************
|
||||
// Constants
|
||||
//**********************************************************************************************************************
|
||||
|
|
Loading…
Reference in New Issue