Jump to content

Modbus RTU error code -1 and status code -11


Recommended Posts

hi every one.

i try put one more device in my modbus rtu network.

this device can communicate very well with my pc over one serial port 485.

but if i put this device on the last slot  of my net work, he canot work...

the list with the status code in help file have explanation until the value -7.

but i have the status value -11 or some time -12.

please help me find tis problem

Link to comment
Share on other sites

3 hours ago, alexandre_poliplanta said:

but if i put this device on the last slot  of my net work, he canot work...

Please explain this statement in more detail.

What is the node address of the device?

What is the node address of the pc?

What is the node address of the PLC?

It would be helpful if you post a link to the device type and attach your PLC program to a post.

Joe T.

Link to comment
Share on other sites

ok then...

in config we can see the parameter of the modbus rtu network in use.

in config specs we can see the hardware in use.

in config status we can see the data over this global network data online.

*the value of the status is 3, i guess it is a problem.

* the tag tensaoPeletStatus the value is -11 and  some time this value is 13 - these values are some kind of error code but we cant have the intire errorcode list...

in config weg address we can see some registers input avaliable and the most import,,, the type of format data

FLOAT...

and de clp unitronics will work with format REAL.

weg tel me some thing about the format float in use... this float are in format float point IEEE 754.

can this plc unitronics work with this format data?

when a try cath othes values for test only... is the registers are format int, every gone well. but when a try change for other values ( float) i cath this error code.

rtu config #1.png

rtu config #1 specs.png

rtu config  #1 status.png

rtu config #1 weg address.png

Link to comment
Share on other sites

yes... i can...

the slave are configurade as the followed way:

remote slave ID: 11

 baud rate:  9600

Data bit: 8

Paraty: none

Stop bit: 1

-------------------------------------------------------------------------------------------------------

this time i try use the adress register number 2... now i dont care this number... i need catch some value float.

is it work i will chose the correct register float.

Config.png

Link to comment
Share on other sites

On 2/16/2021 at 7:56 AM, alexandre_poliplanta said:

but if i put this device on the last slot  of my net work, he canot work..

Does this mean you have connected it as the last thing on the loop?   To me it sounds like you may have missed adjusting EOL resistors to suit the new configuration.  You may have devices that include EOL on/off via dipswitches which will make it easy, or you need to physically change resistor(s) around.

This would also explain why it works on the PC but not on the loop.  RTU is very forgiving and will often run ok without resistors on a direct connection to the PC, but in the field things can be very different.

cheers, Aus 

Link to comment
Share on other sites

I agree that in the field the scenario is much more complicated ...

the point is that in the field, using the unitronic clp to read registers of the entire type, exactly from the same equipment provided by the company WEG.

values of whole registers I can read with the clp.

values of float registers I can't read from that same weg equipment.

for some reason, the clp is unable to read float values. even when the register created in the clp is of the real type.

Link to comment
Share on other sites

And the answer to my question is.....? 

Some types of requests can be handled by an incorrectly set up loop, whereas others won't work.  This is not an airy fairy suggestion.  I've had it happen to me when I've forgotten to change things correctly on additional devices being added to a loop.  Lots of Head Smack at the time.  So it's worth checking the physical wiring is totally correct.

Link to comment
Share on other sites

I UNDERSTAND THE RELEVANCE OF THE REQUIREMENT FOR A GOOD ELECTRICAL CONNECTION.

BUT AN INTERESTING THING ANSWERS.

CLP GETS READ VALUES IN THE ENTIRE FORMAT THAT EXISTS IN THIS ENERGY METER FROM THE WEG COMPANY.

CLP CANNOT READ VALUES IN THE FLOAT FORMAT OF THIS SAME ENERGY METER.

IS IT POSSIBLE THAT THIS IS AN ELECTRICAL WIRING PROBLEM?

A TYPE OF DATA CAN BE READ.
OTHER TYPE OF DATA CANNOT READ.

SAME EQUIPMENT, SAME SETUP AND SAME INSTALLATION.

Link to comment
Share on other sites

34 minutes ago, alexandre_poliplanta said:

A TYPE OF DATA CAN BE READ.
OTHER TYPE OF DATA CANNOT READ.

This means your wiring, baud rate, and everything else physically is good.  This is NOT a wiring problem.  It's a Weg + Unitronics problem.  

Unitronics is probably choking on the byte order.

We've had this conversation before about reading float values from energy meters via Modbus.  Most of the time the energy meter manufacturer and Unitronics have different ideas about endianness.  If you're not familiar with that term Google it up and you'll see pages that explain it much better than I can here.

Take a look at this post:

 

Try to read your floating point variables into a Buffer array tag that's at least four elements long per variable.  Right now you're trying to get good read status. 

If you understand the content of the above post you'll be able to re-arrange the buffer elements into valid floating point data.  If you're having trouble post your program with questions.

Joe T.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...