1
00:00:05,000 --> 00:00:06,000
Hello, friends.

2
00:00:06,000 --> 00:00:16,000
Today I just tell you how to control digital input output using digital input.

3
00:00:17,000 --> 00:00:20,000
For that purpose, I use my previous code.

4
00:00:20,000 --> 00:00:28,000
In my previous video that is for digital read and digital write that is individually write the data

5
00:00:28,000 --> 00:00:30,000
and individually read the data.

6
00:00:30,000 --> 00:00:33,000
Right now I just use the same data.

7
00:00:34,000 --> 00:00:43,000
In this case, I just read the data from elders and according to that data, I want to generate signals

8
00:00:43,000 --> 00:00:45,000
for different LEDs.

9
00:00:45,000 --> 00:00:49,000
Okay, so for that purpose I just use the same code.

10
00:00:49,000 --> 00:00:56,000
As you see over here in this code, I am not changing anything.

11
00:00:56,000 --> 00:00:58,000
So same code I just use.

12
00:00:58,000 --> 00:01:04,000
I just close this code and I just make some changes inside the LabVIEW code.

13
00:01:04,000 --> 00:01:12,000
As you see over here in this case, in place of manual buttons, I just delete these buttons.

14
00:01:13,000 --> 00:01:20,000
Control B and according to these buttons, the signal comes from LDR one.

15
00:01:20,000 --> 00:01:27,000
It goes to over here and LDR to the signal goes to over here.

16
00:01:28,000 --> 00:01:36,000
Okay, so based on these signals, it will generate signal for my LEDs that are connected to four and

17
00:01:36,000 --> 00:01:37,000
five pins.

18
00:01:37,000 --> 00:01:41,000
Okay, so right now I just select the com port as you see.

19
00:01:41,000 --> 00:01:43,000
Com eight is available over here.

20
00:01:43,000 --> 00:01:55,000
I just run it when I just run it as you see D read buffer will read d d and after substring we get over

21
00:01:55,000 --> 00:02:03,000
here and when I just place my hand over the AVR, as you see, after some time, I just got a signal

22
00:02:03,000 --> 00:02:04,000
over here.

23
00:02:04,000 --> 00:02:06,000
LEDs goes high.

24
00:02:06,000 --> 00:02:11,000
The Led that is connected to the pin.

25
00:02:11,000 --> 00:02:13,000
This one, it goes high.

26
00:02:13,000 --> 00:02:21,000
Okay, so right now I just remove my hand because the data is buffered.

27
00:02:21,000 --> 00:02:27,000
Or you can say it is stored inside this data buffer.

28
00:02:27,000 --> 00:02:31,000
And according to this, it will generate signals.

29
00:02:31,000 --> 00:02:39,000
Now, I just put my hand over the LDR two, as you see over here, when I just put my hand after some

30
00:02:39,000 --> 00:02:43,000
time it will generate signal for LDR one.

31
00:02:43,000 --> 00:02:46,000
Also, it is taking some time.

32
00:02:48,000 --> 00:02:55,000
As you see right now, it is equal to C and it will generate signal for the PIN number.

33
00:02:57,000 --> 00:03:05,000
Right now it is generating C and it goes to the Led one.

34
00:03:05,000 --> 00:03:07,000
Maybe it is loose.

35
00:03:17,000 --> 00:03:19,000
Let's check for this also.

36
00:03:22,000 --> 00:03:28,000
So using this code, you can generate signals for both the cases.

37
00:03:30,000 --> 00:03:33,000
I just make change over here.

38
00:03:34,000 --> 00:03:41,000
In this case, the data is buffered, so let's stop this code.

39
00:03:43,000 --> 00:03:46,000
There are some errors, as you see.

40
00:03:46,000 --> 00:03:49,000
I just make it reset.

41
00:03:51,000 --> 00:03:52,000
Now.

42
00:03:52,000 --> 00:03:58,000
I just delete this one and run it again.

43
00:03:59,000 --> 00:04:08,000
And when I just put my hand over here, it will generate signal for me for an instant and you need to

44
00:04:08,000 --> 00:04:13,000
just check what happened if some delay is not there.

45
00:04:14,000 --> 00:04:17,000
So I just put again delay over here.

46
00:04:18,000 --> 00:04:20,000
Let's say it is three milliseconds.

47
00:04:25,000 --> 00:04:34,000
So as you see over here, it will turn on my Led and it will turn on my second Led.

48
00:04:34,000 --> 00:04:38,000
And right now my hand is on the both the elders.

49
00:04:38,000 --> 00:04:41,000
That's why both the LEDs goes high.

50
00:04:41,000 --> 00:04:46,000
If you want to just place your hand over here as you see.

51
00:04:47,000 --> 00:04:56,000
So this is how you can generate signals or you can acquire signal through LDR and generate signal for

52
00:04:56,000 --> 00:05:00,000
Led in a single VI using visa.

53
00:05:00,000 --> 00:05:02,000
So this is all about today's lecture.

54
00:05:02,000 --> 00:05:03,000
Thank you.

