Profinet communication error with S7-1500 PLC

Hi everybody,

So, this last week I have been trying to connect the UR5 to a S7-1500 PLC, following the guide that can be found here in the website, plus some videos in youtube. I follow all the steps and it looks like there is a connection between the robot and the PLC, as you can see in this images. (Sorry the page only allows me to put a SINGLE image and two links, so this difficults a lot explaining the process…)

plcr1

As you can see, the robot is detected and all the checks are green.

So I start and try to send a bit to the robot. For that I define a easy program in TIA Portal, as shown here.
I press a button and this activates “URO”.“Reg 1”.Bits.Register[0]

In the robot I define a variable, called LECT_BIT with an initial value of 0, and then, in the program tree, LECT_BIT := read_input_boolean_register(0)

The first problem I am getting is this: "The left side of the expression awaited an “int” type, but found “bool” type.
Am I doing something wrong in the definition of this variable? I don’t think so.

So, as I cannot read a bit, I try to send a bit from the robot to the PLC, using the following expression → write_output_boolean_register (1, True), and create a simple program in TIA Portal, with “URI”.Bits.Register[1]

And again, nothing is happening. I am going to show you the definition of my variables, but I think that part is fine, as I have seen it done that way in some youtube videos.
URI → UR_T2O → %I1000.0
URO → UR_O2T → %Q2000.0

I really don’t know where the error is. So please, if you can help, or if you need more info, please, I’ll be glad to give it.

Thanks in advance!

Hello @jonander.maiz,

maybe I can help you.

The first problem I am getting is this: "The left side of the expression awaited an “int” type, but found “bool” type.
Am I doing something wrong in the definition of this variable? I don’t think so.

By setting the Initial value to “0” u define that variable as a n Integer.
Instead of using the Initial value “0” set the initial value to “False”.

As a kind hint:
Instead of define ur variable “LECT_BIT” = "read_input_boolean_register(0), define the variable directly at the Installation.
Then you don´t have to use always those long “read_input_boolean_register…” commands.
See:

So in my Progrm i can directly use the signals (without writing that “long” read… command":

Here I say IF “Freigabe Pick = True” (this Freigabe Pick is my Variable from the boolean input register(1)

At my PLC the signal is created like this:

It´s working well.
Hope this will help.
If u need more infos let me know

Kind regards from Luxembourg!