This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

luamodbus documentation
#9
(20.06.2019, 16:59)admin Wrote: By standard response to write request contains exactly the same data. So any Luamodbus write function returns just true/false.

Does really readregister wait for this reply and read full answer? Not only number of bytes that were sent?
Because if I do this:
Code:
for index, value in ipairs(self.modbus_mapping) do
           local val,err=self.mb_aolan:writeregisters(value.register,write_val)
           if (val == nil) then
              -- here I do something with the error
             return
           end
         --os.sleep(0.1)
         os.sleep(0.05)
end
then with os.sleep lower than 0.05 I get err from the next write. Maybe it's error on the slave side but my first idea was I'm getting this error because I'm too fast and the counterpart is still sending data.

Can you please send me list of parameters for writereadregisters?

Thank you
LM5Lp, firmware: 2018.08.22 and 2021.12.15, FlashSYS v2, ARMv7 Processor rev 5 (v7l), kernel 4.4.151 and 4.4.259
Reply


Messages In This Thread
luamodbus documentation - by hummelsystemhaus - 07.02.2018, 14:40
RE: luamodbus documentation - by admin - 13.02.2018, 11:23
RE: luamodbus documentation - by admin - 15.02.2018, 09:25
RE: luamodbus documentation - by admin - 16.02.2018, 13:04
RE: luamodbus documentation - by Thomas - 20.06.2019, 15:47
RE: luamodbus documentation - by admin - 20.06.2019, 16:59
RE: luamodbus documentation - by Thomas - 21.06.2019, 11:32
RE: luamodbus documentation - by admin - 21.06.2019, 12:05
RE: luamodbus documentation - by AngelesTR - 10.01.2023, 15:19
RE: luamodbus documentation - by admin - 11.01.2023, 08:22
RE: luamodbus documentation - by AngelesTR - 11.01.2023, 10:08
RE: luamodbus documentation - by admin - 11.01.2023, 10:14
RE: luamodbus documentation - by AngelesTR - 11.01.2023, 11:57

Forum Jump: