caddish12:
Hi JPrust,
Maybe you will need this line of code:
modbus_configure(&Serial, 19200, SERIAL_8N2, DEVICE_ID, TxEnablePin, HOLDING_REGS_SIZE, holdingRegs);
// modbus_update_comms(baud, byteFormat, id) is not needed but allows for easy update of the
// port variables and slave id dynamically in any function.
modbus_update_comms(19200, SERIAL_8N2, 1);
As you declared in your code, register of VAL_LED is READ register (address 0) and VAL_POT(address 1) is WRITE register. So, in HMI you can access with address 40001 for VAL_LED (HMI write value into this register such as button input) and 40002 for VAL_POT(HMI will read from this register such as number display?).
Why 40001 and 40002? Because in Delta HMI register address, address 0 will be 40001, so if you need to access register 10, it will be 40011 in Delta HMI. and the data will be WORD.
Hop it will help.
Thanh Nguyen
caddish12:
Hi JPrust,
Maybe you will need this line of code:
modbus_configure(&Serial, 19200, SERIAL_8N2, DEVICE_ID, TxEnablePin, HOLDING_REGS_SIZE, holdingRegs);
// modbus_update_comms(baud, byteFormat, id) is not needed but allows for easy update of the
// port variables and slave id dynamically in any function.
modbus_update_comms(19200, SERIAL_8N2, 1);
As you declared in your code, register of VAL_LED is READ register (address 0) and VAL_POT(address 1) is WRITE register. So, in HMI you can access with address 40001 for VAL_LED (HMI write value into this register such as button input) and 40002 for VAL_POT(HMI will read from this register such as number display?).
Why 40001 and 40002? Because in Delta HMI register address, address 0 will be 40001, so if you need to access register 10, it will be 40011 in Delta HMI. and the data will be WORD.
Hop it will help.
Thanh Nguyen
caddish12:
Hi JPrust,
Maybe you will need this line of code:
modbus_configure(&Serial, 19200, SERIAL_8N2, DEVICE_ID, TxEnablePin, HOLDING_REGS_SIZE, holdingRegs);
// modbus_update_comms(baud, byteFormat, id) is not needed but allows for easy update of the
// port variables and slave id dynamically in any function.
modbus_update_comms(19200, SERIAL_8N2, 1);
As you declared in your code, register of VAL_LED is READ register (address 0) and VAL_POT(address 1) is WRITE register. So, in HMI you can access with address 40001 for VAL_LED (HMI write value into this register such as button input) and 40002 for VAL_POT(HMI will read from this register such as number display?).
Why 40001 and 40002? Because in Delta HMI register address, address 0 will be 40001, so if you need to access register 10, it will be 40011 in Delta HMI. and the data will be WORD.
Hop it will help.
Thanh Nguyen
caddish12:
Hi JPrust,
Maybe you will need this line of code:
modbus_configure(&Serial, 19200, SERIAL_8N2, DEVICE_ID, TxEnablePin, HOLDING_REGS_SIZE, holdingRegs);
// modbus_update_comms(baud, byteFormat, id) is not needed but allows for easy update of the
// port variables and slave id dynamically in any function.
modbus_update_comms(19200, SERIAL_8N2, 1);
As you declared in your code, register of VAL_LED is READ register (address 0) and VAL_POT(address 1) is WRITE register. So, in HMI you can access with address 40001 for VAL_LED (HMI write value into this register such as button input) and 40002 for VAL_POT(HMI will read from this register such as number display?).
Why 40001 and 40002? Because in Delta HMI register address, address 0 will be 40001, so if you need to access register 10, it will be 40011 in Delta HMI. and the data will be WORD.
Hop it will help.
Thanh Nguyen
Hi vietnam friend you made the tube modbus communication dop panel, send me the arduino library
Mail.: ismailsef@gmail.com
Send me the dop panel delta display software + arduino libraries + circuit diagram