Jump to content
News about the LabVIEW Wiki! Read more... ×
simone marchetti

RS232 Modbus RTU - LabView 2017 RT

Recommended Posts

Hi all,

I'm working with CompactRIO 9045. This plc is equipped with the rs232 and the rs485. I need to communicate with two devices in Modbus RTU. 

I have no problems with RS485 (ASRL2::INSTR) communication. This is initialization VI:

image.png.8467f300c088961bed7eb42de2a412ac.png

I do the same operation with rs232 port (ASRL1::INSTR):

image.png

But I have this error:

Error -1073807246 occurred at Property Node (arg 1) in SubVIs.lvlibSmiley frustratoerial Shared Components.lvlib:Configure Serial Port.vi->SubVIs.lvlibSmiley frustratoerial Master.lvclass:Initialize Master.vi->Modbus Master.lvclass:Initialize.vi->Modbus Master.lvclass:Create Master Instance (Serial).vi->readExdSh1.vi

Possible reason(s):

VISA: (Hex 0xBFFF0072) The resource is valid, but VISA cannot currently access it.

 

The resource can't be occupied...

I have seen all  national guides and tutorial, but I don't find the solution.

Can you help me?

 

Thank you.

 

 

Share this post


Link to post
Share on other sites

Do you have ASRL1 open any where else, say in MAX or another part of your program?

Is it possible the CONSOLE OUT switch is enabled which will then use the COM1 port?

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P9zxSAC&l=en-US

Edit: Just noticed after finally finding a picture of the 9045 on the NI Website 👾 that it doesn't look like it has DIP switches for CONSOLE OUT.  So not sure if you can check in MAX to see if its enabled.

 

<\rant> Its impossible to find anything on the NI website nowadays.  Its gotten so bad, that I now wish they would just create one giant webpage for each product line (cRIO, PXI, etc) that has every single document in pdf format for each piece of hardware in alphabetical order in plain text.   This BS of clicking on something and then having the website perform a search of the website is ridiculous  :frusty:</rant>

Edited by bbean

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×

Important Information

By using this site, you agree to our Terms of Use.