Showing
1 changed file
with
4 additions
and
2 deletions
... | ... | @@ -16248,8 +16248,8 @@ class HandleDataInteraction { |
16248 | 16248 | ]) |
16249 | 16249 | |
16250 | 16250 | if (method == '16') { |
16251 | - const hexValue = UseLayUi.numberToHex(value).split(' ') | |
16252 | - value = [parseInt(hexValue.slice(0, 2).join(''), 16), parseInt(hexValue.slice(2, 4).join(''), 16)] | |
16251 | + const hexValue = UseLayUi.numberToHex(value).split(' ').join('') | |
16252 | + value = [parseInt(hexValue.slice(0, 4), 16), parseInt(hexValue.slice(4, 8), 16)] | |
16253 | 16253 | } |
16254 | 16254 | |
16255 | 16255 | if (validate.begin()) flag = true |
... | ... | @@ -16319,6 +16319,8 @@ class HandleDataInteraction { |
16319 | 16319 | registerValues: Array.isArray(registerValue) ? registerValue.map(item => Number(item)) : [Number(registerValue)] |
16320 | 16320 | } |
16321 | 16321 | |
16322 | + console.log(params) | |
16323 | + | |
16322 | 16324 | const command = await ConfigurationNodeApi.getModbusCommand(params) |
16323 | 16325 | |
16324 | 16326 | return command | ... | ... |