Solved

Communicate with modbus RTU via vb.net

Posted on 2015-01-16
3
376 Views
Last Modified: 2015-02-19
I normally use Mitsubishi PLCs and have all the code to open and close communication lines, read and write data to and from vb express 2010.

I recently bought a Modbus RTU unit and would like to be able to do similar basic tasks from vb.

Has anyone an example of vb.net code that actually works.  There are quite a few snippets on the net but I cant find any that work.

Thank you in advance
0
Comment
Question by:SweetingA
  • 2
3 Comments
 
LVL 15

Expert Comment

by:ChloesDad
ID: 40554569
I tried to write a Modbus RTU class in VB for work, and although I was able to get a simple program that would respond to a single message it was no good in our application as it would not work in an environment that had multiple messages respecting the 3.5 character lengths between messages. In the end we bought a vb.net plugin. Is the unit a slave, and you want to be a master to communicate to it, or vice versa?
0
 

Author Comment

by:SweetingA
ID: 40555112
I have also bought a plugin as i became super frutsrtated.

I bought msbus.dll but it i can't identify where to put it so that i can pick it up in in my toolbox.

Any advice would be most welcome.
0
 
LVL 15

Accepted Solution

by:
ChloesDad earned 500 total points
ID: 40555134
You need to add it as a reference to the project.

Right click on the project and select properties, then click on the tab for references and add it there. You should then be able to either add it to the toolbox or create the control at runtime.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
Over the years I have built up my own little library of code snippets that I refer to when programming or writing a script.  Many of these have come from the web or adaptations from snippets I find on the Web.  Periodically I add to them when I come…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
As a trusted technology advisor to your customers you are likely getting the daily question of, ‘should I put this in the cloud?’ As customer demands for cloud services increases, companies will see a shift from traditional buying patterns to new…

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now