Tim Generation is successfully completed now, we'll just go ahead and export and hide the file to investigate
file export export hardware.
We'll also be including a bitstream day and then we will be launching an SD.
So now we started to file a new application project again.
We will be considering adding the Halloway template, so that will give us an access to some of the
fundamental blueprints such as you are OK, which would be very helpful in debugging, right?
So am I.
This will be our application.
You will click next and we'll select Helloworld.
Right click Finish.
Now we go ahead to an dark see where we have our meeting application, right?
So if you go to a file, OK, you have something called in system dot emesis, so that will give us
an idea about which driver should be better.
If you want to work around with a GPA, right, so if you go to a system, the time is right, you just
need to look for GPI.
So here we have a GPO and the recommender driver is GP IOPS, right?
So we'll go ahead without asking you.
OK, we just need to add an X and then the driver, which is been suggested by Mrs.
Right, right.
So GP, I'll start and then we just need to see you.
So if it's able to recognise this driver, it will automatically queue a successful right.
So that is what is happening over here.
Then we could exclude the function that we have within this driver.
So we already know the fundamental about utilising its driver.
So here also, we need to create and structure, right?
So first structure is.
This went right, so which basically is an Traver instance.
OK, so all the GPIO related data will be printed within this.
So we'll just copy this and we'll be naming it as an entity, right?
The one that we require is a config structure, which is over here, right?
So that will give us an access to the obese address as well as do I say right?
So we'll just name this as ADT config.
And again, this should be a pointer.
Right?
So when we use a lookup config, we could directly connect a LED config over there right now will declare
a first function, which will be used to initialize UPI.
So we'll just be naming it as in it.
OK.
And then to see whether initialization is successful or not, we'll just be declared one integer variable,
which is status, right?
The first function that we require to initialize are GPO driver is to look for the device that is present
in a vector, right?
So we'll just copy this function and then we'll specify the driver I.D..
OK.
The device ID for GPI so that it just go ahead and connect a little config OK to be close to this function.
OK?
Because this function already does the config pointer right, and this is the same variable that we
declare so we could directly connected and document that we required is a device.
So where you find the device?
So you just need to use parameter thought that you're gay.
In fact, you could find this strawmen hardware specification, but the easiest way is to go ahead and
utilize X parameters starting right.
Let it just try to explore experimental data and try to find out UPI.
Right now here you could get all the information related to hardware, so we required just the device.
ID will copy this and we'll write it over here, right?
So we'll be getting the data which config structure required, right?
So once you have your config structure data now we could proceed initialization of our GPI, right?
So for that, we have a specific API which will initialize and basically return this data, which will
be connecting to the integer that we declare for a C does and then we'll be checking whether it is equal
to one or not.
So if it is equal to one, that basically means the device initialization a successful LS device initialization
is free, right?
So this requires the argument.
First one is in the structure that we declared for a GPIO instance data, OK, which is then the config
structure and then effectuate, so that could be accessed from the config structure itself.
Right.
So we'll go ahead.
So students should be close to the first argument for this is the structure which will hold all the
data related to our GPA, which is elite.
So since here we require to.
Bicep pointer will just be specifying an actress of our structure, right?
The next one that we have, it's a conflict pointer, so we'll just be adding any de-conflict.
The last one is to be said to us so early on.
And then we try to access the base just like this right now will also develop the check to verify this
status is one more than oxidative status is equal to one or instead of one.
They could use the standard way, which is access to success.
OK, so if this returns, the C to the standard B is to compare the status with an existing success
rate.
So if you just explore and find out the value that you get for an next sex, that's a zero L rate.
So if that is the case, we could see, OK, we just need to send the message on to a the device.
Initialization is successful so we could use either a or the standard we will be to utilize that they'll
print a break.
So here we could just have to message the device.
Initialization is successful, right?
We'll also be adding a new line connector right else as we call again useful printer.
And here we could just add device in it.
Three.
Right.
So this will help us to debug a case.
If you are not getting an expected is great.
So this will be our complete init function.
OK, this will be used to initialize that UPI or tribal state just see backward.
OK, so this will automatically and you will be finding that we have not committed any syntax at all
right now.
Let me just go back to a main quote here.
This is used to initialize are you are right.
The next thing that we'll be doing is to call this in right now.
This will automatically initialize both the thing that is you want also, as well as the GPI right now,
we need to set the direction we are utilizing aliases.
OK, so if you just explore the tribal that you have for AGP, so we could either work on and bank.
So, OK, so bank or we could work on a pin.
So here we know that we have an entity connected at PIN number seven to instead of working on a bank,
we prefer to work on a pin number, right?
So first, we need to set the direction.
OK, so to set the direction, we have this function.
So let's just copy and add it over here, OK?
And then we'll be exploring what is the container and an argument that our function requires.
So if you press any three.
So this required an instance pointer, which is GPO instance, and then we required a pin number and
the direction right now for our direction.
If we had a value of zero, so that will behave as an input one and that will behave as an output.
Great.
So let me just go ahead.
So first is an instance, so here we will be adding.
The next one that we have is the pin number, so we already know.
From the reference manual that is connected at number seven Hang, we want to set it as an output for
an output, we need to write this.
We already know you just signed a lease or an output.
We need to apply.
What already decide went along with this.
We also need to enable an output rate, so just setting a direction won't be enabling an output to to
enable an output.
We have this function rate, so set output and everything will just be copying and pasting it over here.
OK, and then if you just press three, this will.
He goes to the behavior and expected argument that this function requires first.
One is and it's just pointer, then the pin number and being able to one for enabling an output and
zero for disabling.
Great.
So first one is an instance of instances a lady named a pin number is again seven.
And what rate?
So this will considered in my opening number seven as an output.
Now we are ready to send the signal.
So what we could do is we will be generating a cooling effect in an interval of one second.
So we'll be turning on R&D for one second and then we'll be keeping it off for one second.
Right.
So to write the data, we must be having some of the functions present in the driver.
So if you just go ahead, we do have a right.
Right.
So we took an instance point up pin number and added.
So let me just go ahead and try to add this function because it will just be turning on RLG.
OK, so to do that, the instances have VIN number is seven and we'll just be sending the data over,
right?
So this will turn on reality.
We'll wait for one second.
And for that, we have a sleep function, OK?
And we'll just specify an argument in a second.
So very quiet wait for one second.
We'll just add an argument.
Nice, we.
We'll just copy this to function, and then we will be.
Sending a seed I keep waiting for.
One second rate, and since we are riding it all the logic inside of whilo OK, which is always true,
so this will be continuously working until unless we apply a automated to the power from the right.
So what we could do here is we could just add one.
So when we call it, we will be knowing whether device initialization is successful or not safe device
initialization is successful.
We can just add a message that we are starting to execute our code.
Great.
So starting.
Giu.
Email.
Lady District, so this will give us an access, whether we reached in here, that is we successfully
come out of dysfunction, OK, and then we will be analyzing an output on that heart of it.
Right.
So this computer code?
So when we considered an email, we need to exactly find out on which pin number are hardware disconnected
and then utilizing the drivers that are provided for a specific paper.
We could work around great.
So far, GPI, which consistently open ended, is Robert, and we just need to find out the function
which can be used to read and write the signal.
And that is what we did with you.
Right?
So first thing after we complete the code is to program any 3G, right?
So after we finish programming, and if we do, we go to an instigator and we'll be connecting as you
get terminal hook by considering the output that we have, right?
Once you see this message now we are ready to perform an execution of this, right?
So let just right click on a cooler where you have had the or C and then run as launch on heart rate.
So if everything goes fine on and console, you could see device initialization is successful.
OK, so everything is fine with the GPIO LCD.
Driver, right?
And then we also see a message, so we successfully come out of an added function and we are starting
the GPIO, am I OLED to straight?
And if you observe in highway, you could actually see a blinking at an interval of one sec.