# LabVIEW

cancel
Showing results for
Did you mean:

Solved!
Go to solution

Message 1 of 7
(673 Views)

## Re: Join 2 modbus registers

If you need negative numbers then you shouldn't you be using SIGNED integers?

What is the device and do you have a manual for it?

========================
=== Engineer Ambiguously ===
========================
Message 2 of 7
(672 Views)

## Re: Join 2 modbus registers

If you are expecting a value of -17.20, obviously all your "blue" solutions are out unless there is some scaling (or FXP interpretation) involved. As has been said, we simply need to see the manual.

(and if you primary number is integer, you probably want to simply change the indicator to I32 or convert to I32 for further processing. Do you know the byte order?)

Message 3 of 7
(662 Views)
Solution
Accepted by BibianoFlores

## Re: Join 2 modbus registers

@BibianoFlores wrote:
but when the encoder becomes negative, my first modbus register is = 24635 and the second is = 65533 (1 = 24635, 2 = 65533), it should give me a value of (-17.20)

Wild guess (you can change the 10k to SGL if you want a SGL result, but it does not matter for the value):

Message 4 of 7
(656 Views)
Solution
Accepted by BibianoFlores

## Re: Join 2 modbus registers

Divide that by 10000 and you get -17.1973, I think that's probably it.

Edit: Was beat to it, the previous post wasn't there when I clicked Reply...

Message 5 of 7
(655 Views)

## Re: Join 2 modbus registers

Thanks Friend, It worked perfect. I appreciate your cooperation.

Message 6 of 7
(635 Views)

## Re: Join 2 modbus registers

Thanks Friend, It worked perfect. I appreciate your cooperation.

Kyle97330
altenbach

Either of the 2 solutions worked great

Message 7 of 7
(634 Views)