|
28 | 28 | <command device="dummy" function="W_COIL" address="0x0000" noanswer="1"><data value="0xff00" /></command> |
29 | 29 | </initlist> |
30 | 30 | <commands> <!-- Command function sequences and HAL pin assignments --> |
31 | | - <command device="bldc" function="R_REGISTERS" address="0x0020" modbustype="U_AB" haltype="S32" scale="1"> |
| 31 | + <command device="bldc" function="R_REGISTERS" address="0x0020" modbustype="U_AB" haltype="SINT" scale="1"> |
32 | 32 | <pin name="rtpwm"/> |
33 | 33 | <pin name="rtcurrent"/> |
34 | 34 | <pin name="comfreq" modbustype="S_AB"/> |
35 | 35 | <pin skip="1" /> |
36 | 36 | <pin name="rtpos" modbustype="S_ABCD" scale="0"/> |
37 | 37 | </command> |
38 | 38 | <!-- Gives us the following pins: |
39 | | - - hm2_modbus.0.bldc.rtpwm (out, s32) (range [0..65535]) |
40 | | - - hm2_modbus.0.bldc.rtpwm.offset (in, u64) |
41 | | - - hm2_modbus.0.bldc.rtpwm.scale (in, float) (must be set to 0.1) |
42 | | - - hm2_modbus.0.bldc.rtpwm.scaled (out, float) |
43 | | - - hm2_modbus.0.bldc.rtcurrent (out, s32) (range [0..65535]) |
44 | | - - hm2_modbus.0.bldc.rtcurrent.offset (in, u64) |
45 | | - - hm2_modbus.0.bldc.rtcurrent.scale (in, float) (must be set to 0.01) |
46 | | - - hm2_modbus.0.bldc.rtcurrent.scaled (out, float) |
47 | | - - hm2_modbus.0.bldc.comfreq (out, s32) (range [-32768..+32767]) |
48 | | - - hm2_modbus.0.bldc.comfreq.offset (in, s64) |
49 | | - - hm2_modbus.0.bldc.comfreq.scale (in, float) (must be set to 0.1) |
50 | | - - hm2_modbus.0.bldc.comfreq.scaled (out, float) |
51 | | - - hm2_modbus.0.bldc.rtpos (out, s32) (range [-2147483648..+2147483647]) |
| 39 | + - hm2_modbus.0.bldc.rtpwm (out, sint) (range [0..65535]) |
| 40 | + - hm2_modbus.0.bldc.rtpwm.offset (in, uint) |
| 41 | + - hm2_modbus.0.bldc.rtpwm.scale (in, real) (must be set to 0.1) |
| 42 | + - hm2_modbus.0.bldc.rtpwm.scaled (out, real) |
| 43 | + - hm2_modbus.0.bldc.rtcurrent (out, sint) (range [0..65535]) |
| 44 | + - hm2_modbus.0.bldc.rtcurrent.offset (in, uint) |
| 45 | + - hm2_modbus.0.bldc.rtcurrent.scale (in, real) (must be set to 0.01) |
| 46 | + - hm2_modbus.0.bldc.rtcurrent.scaled (out, real) |
| 47 | + - hm2_modbus.0.bldc.comfreq (out, sint) (range [-32768..+32767]) |
| 48 | + - hm2_modbus.0.bldc.comfreq.offset (in, sint) |
| 49 | + - hm2_modbus.0.bldc.comfreq.scale (in, real) (must be set to 0.1) |
| 50 | + - hm2_modbus.0.bldc.comfreq.scaled (out, real) |
| 51 | + - hm2_modbus.0.bldc.rtpos (out, sint) (range [-2147483648..+2147483647]) |
52 | 52 |
|
53 | 53 | The start will be suspended (see top). The .scale pins will be set in |
54 | 54 | the hal-file. Offset pins are automatically initialized to zero. |
|
58 | 58 | <command device="wavebox" function="R_INPUTS" address="0x0000" count="8" name="switch" /> |
59 | 59 | <!-- Gives us the following pins: |
60 | 60 | - Eight switch inputs on the box are HAL output pins |
61 | | - * hm2_modbus.0.wavebox.switch-00 (out, HAL_BIT) |
| 61 | + * hm2_modbus.0.wavebox.switch-00 (out, HAL_BOOL) |
62 | 62 | * ... |
63 | | - * hm2_modbus.0.wavebox.switch-07 (out, HAL_BIT) |
| 63 | + * hm2_modbus.0.wavebox.switch-07 (out, HAL_BOOL) |
64 | 64 | --> |
65 | 65 |
|
66 | 66 | <!-- |
|
74 | 74 | <command device="wavebox" function="W_COILS" address="0x0000" count="8" name="relay" /> |
75 | 75 | <!-- Gives us the following pins: |
76 | 76 | - Eight relay outputs on the box are HAL input pins |
77 | | - * hm2_modbus.0.wavebox.relay-00 (in, HAL_BIT) |
| 77 | + * hm2_modbus.0.wavebox.relay-00 (in, HAL_BOOL) |
78 | 78 | * ... |
79 | | - * hm2_modbus.0.wavebox.relay-07 (in, HAL_BIT) |
| 79 | + * hm2_modbus.0.wavebox.relay-07 (in, HAL_BOOL) |
80 | 80 | --> |
81 | 81 | </commands> |
82 | 82 | </mesamodbus> |
0 commit comments