Skip to main content



      Home
Home » Eclipse Projects » Kura » Error write with modbus_driver
Error write with modbus_driver [message #1781157] Fri, 02 February 2018 03:20 Go to next message
Eclipse UserFriend
Hi guys, I have a problem using the modbus_asset: when I try to write a float in a channel, it fails to update the value after the comma, updating only the whole part. I also noticed that by changing the data.type field to fit the float, I get an error in the ui web client. I show you the screens I've done. Any idea?
  • Attachment: 1.png
    (Size: 13.90KB, Downloaded 218 times)
  • Attachment: 2.png
    (Size: 13.19KB, Downloaded 184 times)
  • Attachment: 3.png
    (Size: 50.34KB, Downloaded 174 times)
  • Attachment: 4.png
    (Size: 100.08KB, Downloaded 180 times)
  • Attachment: 5.png
    (Size: 343.49KB, Downloaded 160 times)
Re: Error write with modbus_driver [message #1781535 is a reply to message #1781157] Thu, 08 February 2018 04:30 Go to previous message
Eclipse UserFriend
Hi Stefano,

A possible explanation can be the following:

1. At the beginning you tried to write a float to a channel having an integer type in the data.type column (for example UINT16, which is the default), in this case floats will be coerced into integers by the driver, the decimal part will be discarded and the result will be placed in a single modbus register (register at address 1 basing on your config).

2. If you set FLOAT as data.type the driver will preserve the decimal part but it will try to write a 32 bit float value, spanning two modbus registers (registers at addresses 1 and 2 from your config). If the previous scenario worked and this one not it is possible that your modbus device/simulator does not allow you to read/write modbus register at address 2.

Best regards
Nicola

Previous Topic:How to write/add tabs in a configurable bundle
Next Topic:Kura Emulator - missing native library for RXTX
Goto Forum:
  


Current Time: Tue Jul 15 15:19:11 EDT 2025

Powered by FUDForum. Page generated in 0.07011 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top