1
00:00:05,000 --> 00:00:06,000
Hello, friends.

2
00:00:07,000 --> 00:00:11,000
Today I will tell you how to write.

3
00:00:13,000 --> 00:00:25,000
A signal or how to write through the analog output of any USB DAC 6001 using Python programming for

4
00:00:25,000 --> 00:00:27,000
that purpose, I just open.

5
00:00:30,000 --> 00:00:32,000
Python idle.

6
00:00:32,000 --> 00:00:36,000
And from here, I just open a new file.

7
00:00:36,000 --> 00:00:38,000
And over here, this is my new file.

8
00:00:38,000 --> 00:00:40,000
And over here we have the code.

9
00:00:40,000 --> 00:00:50,000
So first you have to just import deck Max, because already in the previous video I installed this API

10
00:00:50,000 --> 00:00:55,000
to my system with deck max dot task.

11
00:00:55,000 --> 00:01:05,000
You have to start a task and in this case, we have to just write a signal to a pin.

12
00:01:05,000 --> 00:01:07,000
That is my analog output pin.

13
00:01:07,000 --> 00:01:20,000
In this case I am using my device name is DEV1 oblique AO0AO stands for analog output over here and

14
00:01:20,000 --> 00:01:27,000
this is my channel and the maximum and minimum value shown over here that is maximum value is five and

15
00:01:27,000 --> 00:01:28,000
minimum value is zero.

16
00:01:28,000 --> 00:01:38,000
So over here I'm just start the task task dot analog output underscore channels dot add underscore analog

17
00:01:38,000 --> 00:01:41,000
output as a voltage through the channel.

18
00:01:41,000 --> 00:01:42,000
This one okay.

19
00:01:43,000 --> 00:01:51,000
Right now the value of the signal is two that I have to generate through my DAC card.

20
00:01:51,000 --> 00:02:01,000
Then you have to start the task task dot write your value and in this case value is two and task dot

21
00:02:01,000 --> 00:02:01,000
stop.

22
00:02:01,000 --> 00:02:12,000
So right now when you do this, the two volt signal generated at the output port of analog output port

23
00:02:12,000 --> 00:02:13,000
of the DAC card.

24
00:02:13,000 --> 00:02:14,000
Okay.

25
00:02:14,000 --> 00:02:16,000
So you have to just run it.

26
00:02:19,000 --> 00:02:20,000
Module five.

27
00:02:22,000 --> 00:02:27,000
So it will generate a two volt signal through analog output port zero.

28
00:02:28,000 --> 00:02:30,000
So in this case.

29
00:02:31,000 --> 00:02:37,000
So now I just go to my hardware part in the hardware part.

30
00:02:38,000 --> 00:02:44,000
As you see over here, this is my USB DAC card.

31
00:02:44,000 --> 00:02:45,000
6001.

32
00:02:45,000 --> 00:02:50,000
And over here I'm just connecting analog.

33
00:02:51,000 --> 00:02:56,000
One led to the analog zero port and the ground port.

34
00:02:57,000 --> 00:02:58,000
This one is the positive pin.

35
00:02:58,000 --> 00:03:02,000
This one is the negative pin of my LED.

36
00:03:02,000 --> 00:03:09,000
Right now the value is two volt because the threshold value of the LED is above three volt.

37
00:03:09,000 --> 00:03:11,000
So that's why it is not going on.

38
00:03:12,000 --> 00:03:16,000
So now I just change the value.

39
00:03:17,000 --> 00:03:17,000
Of.

40
00:03:19,000 --> 00:03:20,000
From 2 to 3.

41
00:03:20,000 --> 00:03:21,000
Let's check.

42
00:03:23,000 --> 00:03:25,000
It is right now.

43
00:03:25,000 --> 00:03:25,000
Three.

44
00:03:25,000 --> 00:03:27,000
So now just run it.

45
00:03:29,000 --> 00:03:30,000
It will ask me.

46
00:03:30,000 --> 00:03:32,000
You have to save the code.

47
00:03:32,000 --> 00:03:33,000
So I just put.

48
00:03:33,000 --> 00:03:43,000
Okay, So now as you see, the LED goes on in this case, right now, LED goes on.

49
00:03:43,000 --> 00:03:57,000
So if you want to off this led, you just change the value from below to below three let's it is 2.5.

50
00:03:57,000 --> 00:04:01,000
So again hit on run button.

51
00:04:02,000 --> 00:04:02,000
Save it.

52
00:04:04,000 --> 00:04:08,000
As you see it, is going off right now.

53
00:04:08,000 --> 00:04:11,000
My LEDs off in off condition.

54
00:04:12,000 --> 00:04:19,000
So as you see, this is in off condition or you can say it is running with low value.

55
00:04:19,000 --> 00:04:20,000
Okay.

56
00:04:20,000 --> 00:04:22,000
So this is all about today's lecture.

57
00:04:23,000 --> 00:04:23,000
Thank you.

