Author Topic: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive  (Read 6742 times)

fohdeesha

  • Newbie
  • *
  • Posts: 46
    • View Profile
Re: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive
« Reply #15 on: November 05, 2014, 10:26:05 AM »
If you are reading a double integer, precede the address with an L , so you would use L47198

If it is a float, then precede it with an F

wait, does the modbusRTU driver now properly read and display float values and all we have to do is prepend an L? this changes everything! I have a lot of ladder logic converting float into integer values with an implied decimal just for HMI display I can clean up now :)

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5322
    • View Profile
    • AdvancedHMI
Re: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive
« Reply #16 on: November 05, 2014, 07:19:28 PM »
If you are reading a double integer, precede the address with an L , so you would use L47198

If it is a float, then precede it with an F

wait, does the modbusRTU driver now properly read and display float values and all we have to do is prepend an L? this changes everything! I have a lot of ladder logic converting float into integer values with an implied decimal just for HMI display I can clean up now :)
You precede floats with an "F" and long integers (4 bytes) with an "L"

This should work for both reading and writing.

fohdeesha

  • Newbie
  • *
  • Posts: 46
    • View Profile
Re: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive
« Reply #17 on: November 05, 2014, 08:44:06 PM »
Err yeah I meant an F heh. That's great news, I'll have to try it out once I get a new v3.80 project going

fohdeesha

  • Newbie
  • *
  • Posts: 46
    • View Profile
Re: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive
« Reply #18 on: November 10, 2014, 05:50:49 AM »
So I went ahead and tried some meters and a basic label reading a float register and I couldn't get it to work. Was this introduced in 3.80? I'm still on 3.70

I put for instance F428681 in the plcaddressvalue field, but when I launch the app it states that is an invalid address

Maybe I'm doing something wrong, not sure! can't complain too much as reading integers and adding a decimal point works great

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5322
    • View Profile
    • AdvancedHMI
Re: Windows 7 laptop <--> usb to rs458 converter <---> Servo drive
« Reply #19 on: November 10, 2014, 06:56:55 AM »
So I went ahead and tried some meters and a basic label reading a float register and I couldn't get it to work. Was this introduced in 3.80? I'm still on 3.70

I put for instance F428681 in the plcaddressvalue field, but when I launch the app it states that is an invalid address
This was added in version 3.80

Version 3.81 will be released in a few days that fixes the problem with writing to Long integers