Author Topic: ModbusRTU  (Read 1269 times)

vitico bon

  • Jr. Member
  • **
  • Posts: 57
    • View Profile
ModbusRTU
« on: December 28, 2016, 11:49:57 AM »
Hi again Archie,

I am having problems communicating with more than one device (RS485) simultaneously and searching through previous message I see that you referees a lot to a "ModbusBase" file. I don't have that file, I only have "ModbusRTUCom" and "ModbusTCPCom". Is that "ModBusBase" something that was eliminated in newer releases?

Also I will appreciate if you can take a look at this topic where I am explaining the problems I am having right now, and make some suggestions.

http://advancedhmi.com/forum/index.php?topic=1566.0

Thanks a lot!
« Last Edit: December 28, 2016, 11:52:03 AM by vitico bon »

bachphi

  • Hero Member
  • *****
  • Posts: 643
    • View Profile
Re: ModbusRTU
« Reply #1 on: December 28, 2016, 12:51:33 PM »
I 'll give my 2cent thought:  create with 1 driver ( not 2), then when you need to read sta 2, set disable subscription to true, set address to sta .2, then re-enable the subscription
===================================================
This is NOT alt.read.my.mind.
No such thing is sh^t-for-brains unless you are posting to alt.read.my.mind.
===================================================

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5269
    • View Profile
    • AdvancedHMI
Re: ModbusRTU
« Reply #2 on: December 28, 2016, 05:28:15 PM »
This issue is being addressed. It may be a couple weeks before there is a resolution, but I will keep you posted.

vitico bon

  • Jr. Member
  • **
  • Posts: 57
    • View Profile
Re: ModbusRTU
« Reply #3 on: December 28, 2016, 05:37:09 PM »
Thank you very much Archie and I'm sorry for being such a pain, at least now I know that even if we can not offer at the moment the PC application to our customers I can move on from this and continue with other tests and plans for future projects. Just keep me posted.

Happy new year!

bachphi

  • Hero Member
  • *****
  • Posts: 643
    • View Profile
Re: ModbusRTU
« Reply #4 on: December 29, 2016, 02:53:26 PM »
While waiting for Archie fixing the driver, do you feel like to try what I suggested. I am just curious to see if it will work. Add a timer, enable it and some codes like below:
Code: [Select]
Private Sub Timer1_Tick_1(sender As Object, e As EventArgs) Handles Timer1.Tick

        If READ_STA2_FLAG Then
            ModbusRTUCom1.DisableSubscriptions = True
            ModbusRTUCom1.StationAddress = 2
            ModbusRTUCom1.DisableSubscriptions = False
            GoReadSta2()
            READ_STA2_FLAG = False
        Else
            ModbusRTUCom1.DisableSubscriptions = True
            ModbusRTUCom1.StationAddress = 1
            ModbusRTUCom1.DisableSubscriptions = False
            GoReadSta1()
            READ_STA2_FLAG = True
        End If
    End Sub

===================================================
This is NOT alt.read.my.mind.
No such thing is sh^t-for-brains unless you are posting to alt.read.my.mind.
===================================================