Friends.
Today we discuss different types of variables.
Like or you can say different types of data types available in Python and how we can call in live you.
All of these are we can call all of these data types.
And for that purpose, I just create a Python code, as you see, or here, this is my result is going
to zero.
I just define a variable.
X, which has a value.
Indentation result is equal to X and return result.
So this is my code and now I just create a V.
I already create a V.
To clear the path for this.
So I just open it.
As you see over here.
And this I just use.
The strip path.
You can drag and drop from.
Or here.
This is my strip path.
This is my build path.
So build path, strip path.
And over here, this is my current VI path.
You can find out.
This.
Our hair current.
We are so.
Just connected.
And the name over here is the same name that the file.
Here, the python file.
So I just show you over here.
This is my python code and this is my variable we are taught by.
So I just go over here.
So right now, just run it as you see.
It will create a path for me.
See user So documents python integration by code variable.
So it is.
Created.
Then I just added it.
So as you see or hear, this is.
In the name of variable.
I just use data.
Data types.
Let's.
Just.
Save it.
Then close it.
Now I just open.
Another.
By that I already create.
As you see in the name of variable.
Right here.
This is my pie.
So in this VIP, as you see, I just use.
The Python library I just show you.
This is my.
Over here.
This is my python palette, and I just drag and drop one Python session.
Python code and close Python session.
You can also check.
Or here.
I just name it.
And you see, this is my open Python session.
Which will open the code.
And right now I'm using Python 3.9.
And over here, this is my sub vi that I created.
It will build a path.
For my node.
And over here, this is my close.
So as you see or hear.
Let's say I'll just delete this.
And I want to create one data type.
For floating variable that is available in lab view.
So how we can create a floating variable over here.
The name is the variable that is given in the python.
Phi Phi Phi Phi.
So let's say I want to create a.
So just.
Create a constant floating constant as you see or hear.
This is my constant just connected over here and over here.
Just.
I create a numeric control.
Just connect it or here and it will give me the output.
Just create an indicator.
American dictator over here.
And I will get the value.
So this is the output.
And this is the input.
And in the lab view in case of lab view, if you want to create the same function, you just.
Drag and drop this one.
And connect these directly and create a loop over here.
Aid control.
So this is the code.
This code will call this Python function.
And this is like code.
So let's say.
We want to run it.
Or you can also put this function inside this loop.
Also, you not create another loop, but for the demonstration purpose, I just.
Use this.
So let's say over here I put two, one, two and in the input.
Also 2.2 I will get when I hit on run button, I will get 2.2 in both the cases, as you see.
And if I want to run it as you see in real time, I will get the value again or here.
So this is how you can.
Use different types of variable.
Or you can call floating variable.
From Python to left you.
Now I just go to the integer part, so just stop it.
I just delete this.
Now I want to make it integer type.
So for that purpose I just played this function.
Look this function.
Control.
I just drag and drop integer over here.
This is my integer.
Now, the data type is integer type, as you see.
Or here it is.
I 32.
So let's say I just drag and drop one input function and I want to just change it to 32.
So as you see or here, this is a 32.
So I can just connected or here and now I also.
Require an indicator and I also change it to integer type.
So over here, this is my indicator.
Disconnected.
So this is my output.
And this is my input.
If you want to call an integer variable from Python to live view, you can.
Use this program as you see or hear.
If I want to point to or here, it will take only eight.
So this is how you can call integer function or integer variable or integer data type from python to
let you.
Now we move further.
Right now we discuss about numeric data that is floating and integer.
Now I just go to another function that is string control.
If you want to go for string control, I just.
Put a string constant over here.
So over here, this is my string constant.
Just connect connected over here.
And I want to just drag and drop string control.
This is my input.
String and just connect this.
And over here I got the return value.
That is my output.
So over here, this is my output string.
As you see, just connect it.
Now, I hit on one button, as you see.
Say hello.
When I put hello inside this I got.
Hello.
Or here.
Hello, Sally.
So now I got this function using the string variable.
So this is how you can call string function or.
String variable from python to lab view.
Now we move further to another type.
Just stop it.
Delete this.
Now we discuss.
So for that purpose, I just go to function or here I just use a constant, as you see.
And now I just create a boolean control over here.
You can use any one of these.
Let's say I just use this push button.
Bolan and I just connect this over here and I just use an indicator ground led for that purpose.
Just connect this.
And now when I hit on run button, as you see, or here it is in the low state or in the false state.
So will it is also in all state.
This is my output.
This is my input output input output.
Input, output input.
Okay, so this is how you can use this.
Another type of variable.
Now.
So now if you want to.
Work out with another data type.
So I just gave this.
Now I work with.
Flawed variable.
After that integer.
Then, Bolan.
Then string.
Now I want to work with Eric.
Let's see.
Edit edit can be off floating type, integer type, boolean type and string type.
So let's go with.
Eddie.
So over here, I just drag and drop one blank.
Eddie, inside this, I just put or I want to make it.
Thought any.
Just.
Abbate.
Make it constant.
So as you see.
Just connect this to the upper branch as you see over here.
How.
So I want to just move this function.
Our hair.
Clean up this fire.
Now.
This is my input, Eddie.
And I just.
Copy it.
And I want to just make it output any.
And just change to indicator as you see over here.
Connect this.
So over here, let's say this is one dimensional, Larry.
It don't unbutton when I put some value inside it.
I will get the value in real time.
So this is my.
One dimensional Eddie that is floating type, as you see.
So now I want to work with two dimensional.
So for that purpose you need not do make changes.
So just drag and drop over here.
Just increase the indexing when you increase the indexing.
As you see, I got two dimensional area over here.
If you want to work with.
So this is my two dimensional area over here.
So let's say I put something inside this and when I hit on one button, I got the value.
So over here, this is.
Just stop it.
I want to just.
Increase the size.
Because right now in this.
Five elements are there.
So as you see, when I hit on the button over here, I say it is 5.5.
I got the value.
So this is how you can work with.
It is an LED view.
Or you can say we are calling.
By Concord.
I variable code in live view.
Right now I work with a flawed integer boolean string array.
If you want to work with cluster also the same way we can work out, just delete this.
This.
So mainly in basics of live view and basics of Python.
We generally use these variables.
So right now I just go with another variable that is my cluster, which is which contain different types
of data array contains same type of data cluster will contain different types of data.
Let's say over here, this is my.
Plus one is nomadic.
Second one is bullion, and third one is my string control.
Or here I just put inside this range or downsizing size to fit.
The control panel.
You can change your hair.
As you see right now, this is my input cluster.
I just make it input.
This is my input cluster.
I just copy this.
This is my output cluster.
And just make it.
Get the type.
Change the indicator, as you see.
And I also copied this.
And I just want to change to constant.
You see.
Now you just connect this or here.
This is my input cluster connect.
Or here.
This is my cluster like this.
And I hit on red button, as you see now, I put some value inside it to point to on string name is
Let's see Celine I got.
So these are the major types or major different types of variables using Python and live view and how
we can call these functions from Python to net view.
So now I just want to change some.
Inside this VA.
Let's say I want to connect this or here.
What is the effect of this?
So I don't run button.
As you see, you can you can connect over here or you can connect over here.
It is the same way it will give the output.
So this is how you can work with Python integration with LED view for different types of different data
types.
Or you can say different variables.
Thank you.