1
00:00:00,120 --> 00:00:06,800
Our bitstream generation is successful now we will export our bitstream to NSD here, right, so file

2
00:00:06,840 --> 00:00:12,420
export export higher, they will also be including a bitstream and then will launch an SD.

3
00:00:13,750 --> 00:00:17,320
So let's start with the creation of a new application project again.

4
00:00:17,500 --> 00:00:20,680
We will be utilizing the Hallowell template.

5
00:00:20,840 --> 00:00:28,200
OK, now once we create an application project, we need to look for the drivers that are required for

6
00:00:28,200 --> 00:00:29,980
a Orix IP rate.

7
00:00:29,980 --> 00:00:37,860
So you could really see we have a single IP, which is x 8.00, OK and recommended drivers GPI.

8
00:00:38,110 --> 00:00:38,470
Right?

9
00:00:39,280 --> 00:00:46,120
So we'll start including the first year deferral, which is required for our IP that is x GPI or take

10
00:00:46,780 --> 00:00:55,060
the next one there we will be finding all the hardware related data is X parameters daughter trait.

11
00:00:55,090 --> 00:00:59,020
These are the two main driver and I will go ahead and try to.

12
00:01:00,480 --> 00:01:06,810
I understand the number of EPS which would be useful to initialize are both any right, so we required

13
00:01:06,810 --> 00:01:10,650
again to structure one is a config structure.

14
00:01:12,510 --> 00:01:21,390
Now we'll just be naming this as Tupaea, you can think, OK, and we are also required to have the

15
00:01:21,390 --> 00:01:24,780
instant structure, right, so we'll just be naming this head GPI.

16
00:01:24,840 --> 00:01:29,100
So these are the two mandatory thing now to initialize.

17
00:01:29,220 --> 00:01:30,660
I benefited.

18
00:01:30,690 --> 00:01:31,290
We will.

19
00:01:32,980 --> 00:01:37,120
Just be creating one unique function, we'll just be naming it as in it.

20
00:01:37,570 --> 00:01:40,180
OK, and then we will be adding a logic.

21
00:01:40,440 --> 00:01:46,360
So first, we need to find out the device I.D. OK, and then that device I.D. We need to feed to the

22
00:01:46,390 --> 00:01:48,690
look up config function.

23
00:01:48,700 --> 00:01:51,160
So we'll just copy this will go ahead.

24
00:01:51,480 --> 00:01:56,790
So for us, the config structure data is stored in GPO config, right?

25
00:01:56,800 --> 00:02:03,070
And then we need to specify the device I.D. rate to find out the device that you just need to explore

26
00:02:03,310 --> 00:02:10,160
experimental or take a look for GPO and then you get the device right?

27
00:02:10,380 --> 00:02:10,500
Right.

28
00:02:10,510 --> 00:02:15,430
So this is the device that you need to feed to the lookup config function.

29
00:02:15,580 --> 00:02:19,570
Then you need to utilize the CFG initialize, right?

30
00:02:19,570 --> 00:02:25,650
So we'll just go ahead and we'll call see if she initialize now again, it will require three argument.

31
00:02:25,660 --> 00:02:28,520
First, one is an instance of our IP.

32
00:02:28,600 --> 00:02:35,800
OK, so that is GPIO then config structure, which is named as GPIO config.

33
00:02:35,950 --> 00:02:37,600
OK, last one is the base, etcetera.

34
00:02:37,640 --> 00:02:44,110
So we'll just add or will access the base address from the config structure itself, right?

35
00:02:44,110 --> 00:02:48,220
So GPO config and then they'll be set to three.

36
00:02:49,030 --> 00:02:49,990
This will return.

37
00:02:51,160 --> 00:02:57,420
The status, whether initialization is successful or not, so that will be storing and variable status

38
00:02:57,430 --> 00:03:05,200
right, and then will again be verifying whether we are getting success rate safe status is equal to

39
00:03:05,210 --> 00:03:07,840
SSD success.

40
00:03:07,900 --> 00:03:16,180
OK, if that is the case, we'll just be printing the message that device initialization, it's successful,

41
00:03:16,180 --> 00:03:16,450
right?

42
00:03:16,480 --> 00:03:20,080
The device and it is success.

43
00:03:21,300 --> 00:03:26,040
As we'll just be writing, so here we'll add a new name character.

44
00:03:26,670 --> 00:03:27,000
OK?

45
00:03:27,150 --> 00:03:37,020
And again, they'll go in depth and then if that is not the case or device, then it free rate.

46
00:03:37,020 --> 00:03:41,430
So this is what you need to write to initialize your favorite, right?

47
00:03:41,430 --> 00:03:49,470
So after you call it black platform will just be calling this and this will initialize the driver required

48
00:03:49,470 --> 00:03:50,710
for our favorite rate.

49
00:03:50,940 --> 00:03:56,670
This will initialize appropriate and then we'll proceed for setting up the direction for a boat.

50
00:03:56,700 --> 00:03:58,560
Now, remember, we have to change, right?

51
00:03:58,890 --> 00:04:04,950
So we already know that our first channel will be used a switch and then the second channel will be

52
00:04:04,950 --> 00:04:06,810
used for an A-League, right?

53
00:04:06,810 --> 00:04:10,470
So let it just go away and try to throw, said the Derek.

54
00:04:10,590 --> 00:04:14,780
Right now when we consider this one direction.

55
00:04:14,820 --> 00:04:21,060
So we already know that for setting up the pin a specific pin as an input.

56
00:04:21,510 --> 00:04:21,860
OK.

57
00:04:22,080 --> 00:04:26,820
We need to apply what else we need to apply zero rate.

58
00:04:26,820 --> 00:04:29,190
So this required an instance pointer.

59
00:04:29,370 --> 00:04:32,270
Then we have a China and the direction mutsuki.

60
00:04:32,280 --> 00:04:33,600
So let's just go ahead.

61
00:04:34,980 --> 00:04:38,200
Now, Chinalco will have 32 bit.

62
00:04:39,460 --> 00:04:44,820
That basically means Chinalco support by 32 votes, right?

63
00:04:45,150 --> 00:04:48,740
So here we only have four switches and four really.

64
00:04:48,810 --> 00:04:54,780
So utilising a mosque would be really helpful in ignoring the rest of the rhetoric, so will go ahead

65
00:04:55,140 --> 00:04:55,590
first.

66
00:04:55,590 --> 00:04:58,490
And then here we will be first setting up the direction.

67
00:04:58,500 --> 00:05:02,680
So here we need to specify an instance which is stupid.

68
00:05:02,840 --> 00:05:03,840
Oh OK.

69
00:05:03,930 --> 00:05:08,850
Then we have the China number, so China number is.

70
00:05:09,540 --> 00:05:12,480
So you have Unsane China to the North China?

71
00:05:12,510 --> 00:05:14,160
No, it is China, right?

72
00:05:14,210 --> 00:05:21,480
Or if we just explore what you'd expect from a user is China and India, China, GPI one or two to operate

73
00:05:21,480 --> 00:05:21,630
on.

74
00:05:21,810 --> 00:05:28,650
So we have a multiple China law here, but just be it two because we have included both the chain,

75
00:05:28,680 --> 00:05:28,910
right?

76
00:05:29,400 --> 00:05:29,880
And then.

77
00:05:30,960 --> 00:05:32,730
The last argument is.

78
00:05:33,870 --> 00:05:35,340
The direction must great.

79
00:05:36,490 --> 00:05:41,560
So the second argument is a final number, so we already know that our first China lists, which we're

80
00:05:41,560 --> 00:05:44,200
going to consider it as an input, we need to apply one.

81
00:05:44,240 --> 00:05:44,500
Great.

82
00:05:44,500 --> 00:05:46,970
So we'll just specify an argument has one.

83
00:05:47,020 --> 00:05:47,350
OK.

84
00:05:47,530 --> 00:05:52,770
And to set it as an input, we just need to apply for one, because we have four switches, right?

85
00:05:52,780 --> 00:06:00,670
So we're just by Senator Decimal left, which basically mean for once or we are configuring the AI.

86
00:06:00,670 --> 00:06:09,220
Let's be full Bake Off Channel one as an input port, right, will utilize the same API to set the Layla's

87
00:06:09,220 --> 00:06:13,180
before bit of our second channel as an output pool together.

88
00:06:13,180 --> 00:06:15,180
And to do that, we just need to apply zero.

89
00:06:15,670 --> 00:06:20,650
OK, and here we need to select the channel number, which is two in this case, OK, and this could

90
00:06:20,650 --> 00:06:21,960
be verified for us.

91
00:06:21,970 --> 00:06:26,140
Channel one a switch which should be set as an input port and Channel two is in.

92
00:06:27,280 --> 00:06:33,400
Output to it is connected to an so here we should apply zero rate, and that is what we are doing over

93
00:06:33,400 --> 00:06:33,700
here.

94
00:06:33,970 --> 00:06:40,600
Channel one, which represent our channel where we connect the switch and second where we connected

95
00:06:40,600 --> 00:06:41,070
in LCD.

96
00:06:41,080 --> 00:06:46,210
So we apply zero over here again when a four one over here, right?

97
00:06:46,220 --> 00:06:52,480
So this setup, the direction, once we are completing the process of adding an addiction now, we could

98
00:06:52,840 --> 00:06:54,290
build up our main logic, right?

99
00:06:54,300 --> 00:07:00,160
So what we want to do is we will be sensing the value that we have on a switch and then that value will

100
00:07:00,160 --> 00:07:01,650
be applying to energy.

101
00:07:01,660 --> 00:07:07,000
So to hold the value that we have on a switch, we required to have a utility to read it just named

102
00:07:07,000 --> 00:07:10,180
this as which data initialize it was to right.

103
00:07:10,210 --> 00:07:18,090
So the functions that we have to read, the details x GPIO discrete read and you do see that you read

104
00:07:18,250 --> 00:07:19,120
utility rates.

105
00:07:19,120 --> 00:07:24,980
So we already declared the variable of same time to hold the data here when we go.

106
00:07:25,000 --> 00:07:28,090
We will just be adding such data will be equal.

107
00:07:28,100 --> 00:07:29,440
Stoup OK?

108
00:07:29,800 --> 00:07:34,770
And document that we need to apply is the instance pointer and the channel number eight.

109
00:07:34,780 --> 00:07:42,510
So the instance pointer vs. GPIO and then the chaining number where we have a switches channel one,

110
00:07:42,520 --> 00:07:42,790
right?

111
00:07:42,790 --> 00:07:48,850
So we'll just be specifying Channel one over here, then we need to apply this to an to do that, we

112
00:07:48,850 --> 00:07:54,640
have a discrete write function where we need to pass an instance pointer channel number and Musk, right?

113
00:07:55,530 --> 00:08:01,960
Now here, if you explore, you have an instance point as opposed to argument and the China number and

114
00:08:01,960 --> 00:08:08,820
then finally, our data, right, so we'll go ahead and we will be specifying an instance, which is

115
00:08:09,400 --> 00:08:10,240
GPI.

116
00:08:10,290 --> 00:08:15,470
Oh, then we have a China number where we have an LLC is China number two and then the data.

117
00:08:15,480 --> 00:08:19,300
So the data that we are reading from a switch will be applying the same data, right?

118
00:08:19,650 --> 00:08:25,530
And to verify whether the call is working and to dynamically debug it, what are we going to do is as

119
00:08:25,530 --> 00:08:30,150
we change the value of search, we'll also be displaying the same value on and you are great.

120
00:08:30,150 --> 00:08:36,720
So this will help us to match the value that we are sending one to any lady and the suggested rates

121
00:08:36,720 --> 00:08:41,040
or switch value and will be printing the value in a decimal format.

122
00:08:41,070 --> 00:08:44,940
And we already know the variable that is holding those values, which data, right?

123
00:08:45,480 --> 00:08:49,380
The new value will be read after an interval of one second.

124
00:08:49,420 --> 00:08:49,710
Right.

125
00:08:50,010 --> 00:08:54,600
So this is a complete logic that we need to do only the difference between the previous cases where

126
00:08:54,600 --> 00:08:56,010
we are working on a single channel.

127
00:08:56,010 --> 00:09:01,230
We required to have a multiple instances OK to configure the IP.

128
00:09:01,440 --> 00:09:03,600
Then we need to again set direction.

129
00:09:03,630 --> 00:09:05,370
We'll give it a single IP.

130
00:09:05,580 --> 00:09:11,970
We could use a multiple channel rate only you need to keep track of this channel number correctly rate.

131
00:09:12,930 --> 00:09:16,050
The rest of the thing is exactly what we did in a previous case.

132
00:09:16,080 --> 00:09:20,100
Now we'll go ahead and first try to program an FPGA.

133
00:09:22,160 --> 00:09:27,230
So once programming is successful, will go ahead and will launch on high today.

134
00:09:27,500 --> 00:09:35,600
OK, but before that, we will just be connecting a sticky terminal to the respective comfort where

135
00:09:35,600 --> 00:09:37,160
we have our FPGA right.

136
00:09:37,520 --> 00:09:39,860
We'll also be adding a new line character here.

137
00:09:39,890 --> 00:09:46,030
No, let me just go ahead and try to perform execution of a code on and heart, right?

138
00:09:46,040 --> 00:09:51,410
So if everything goes fine, you are able to see device initialization is successful and the such value

139
00:09:51,410 --> 00:09:52,490
that has been rated zero.

140
00:09:52,730 --> 00:09:56,000
Now I'll try to change the value of the switch one by one.

141
00:09:56,360 --> 00:09:56,660
Right.

142
00:09:57,020 --> 00:10:03,890
So if I just turn on an MSP switch, you'll be getting it because you have no one zero zero zero.

143
00:10:03,890 --> 00:10:08,210
So that basically give it and it now the next switch, if I turn on.

144
00:10:08,210 --> 00:10:15,050
So you get, well, the next one, you get 13 and then, OK, so the next one is basically 14, right?

145
00:10:15,320 --> 00:10:18,110
And then you get 50 right.

146
00:10:18,710 --> 00:10:23,990
So you could see if you could dynamically value the value of a sutures and the same value the status

147
00:10:23,990 --> 00:10:25,970
you could see on an LCD also.

148
00:10:26,720 --> 00:10:26,980
Right.

149
00:10:26,990 --> 00:10:30,650
So this is how you utilize our multi-channel on any side.
