0
1
00:00:21,130 --> 00:00:21,820
Hello.
1

2
00:00:21,840 --> 00:00:28,620
In this video we are going to learn SFTR-L shifting bit instruction sftr means
2

3
00:00:28,710 --> 00:00:29,160
right.
3

4
00:00:29,160 --> 00:00:35,190
So that means it is shifting bits to the right side SFTL means our left.
4

5
00:00:35,370 --> 00:00:37,860
So it is shifting bits to the left side.
5

6
00:00:37,920 --> 00:00:40,710
Initial device in which value is shifted.
6

7
00:00:40,860 --> 00:00:47,280
S and D means similar but the important point is here and one is length, length of the thought which
7

8
00:00:47,280 --> 00:00:51,090
is shifted and to number of bits forming group.
8

9
00:00:51,150 --> 00:00:55,900
And imagine you have a line and here boxes are coming.
9

10
00:00:55,950 --> 00:00:59,640
The products are coming and you are looking okay.
10

11
00:00:59,650 --> 00:01:01,110
This have a barcode.
11

12
00:01:01,110 --> 00:01:01,830
This okay.
12

13
00:01:01,830 --> 00:01:02,550
This is not.
13

14
00:01:02,550 --> 00:01:03,240
This is okay.
14

15
00:01:03,240 --> 00:01:04,440
This is not so.
15

16
00:01:04,560 --> 00:01:06,540
Each time if you wait here.
16

17
00:01:06,540 --> 00:01:12,210
If you are looking to these products are there any barcode or not.
17

18
00:01:12,270 --> 00:01:13,260
What will happen.
18

19
00:01:13,260 --> 00:01:14,840
This line will be stopped.
19

20
00:01:14,940 --> 00:01:15,780
A lot of times.
20

21
00:01:15,870 --> 00:01:20,420
Imagine that it is working or it is running very high speeds.
21

22
00:01:20,460 --> 00:01:23,910
So you need to separate them to the left or right.
22

23
00:01:23,910 --> 00:01:29,240
For example imagine this your mechanical system is like that that moment.
23

24
00:01:29,340 --> 00:01:32,640
What should you do without stopping the line.
24

25
00:01:32,640 --> 00:01:40,550
You need to separate these products that moment shifting bit instruction is going to help us.
25

26
00:01:40,620 --> 00:01:51,350
So let's create the one project in the ISPSoft and in here we will add a small project to Plc and
26

27
00:01:51,420 --> 00:01:54,540
we will understand how it is working.
27

28
00:01:54,720 --> 00:02:03,980
New project is created now let's say LD X0.0
28

29
00:02:03,980 --> 00:02:08,780
This is will be rising edge for example.
29

30
00:02:08,840 --> 00:02:11,690
This is just detecting 2.
30

31
00:02:12,110 --> 00:02:24,090
I will put here x0.0 detecting products and x0.1 detecting barcodes.
31

32
00:02:24,600 --> 00:02:27,990
And I will put here SFTR command.
32

33
00:02:28,230 --> 00:02:35,190
So what we need now for example x0.1 is detecting barcodes.
33

34
00:02:35,230 --> 00:02:39,070
So we will use x0.1 in here.
34

35
00:02:39,100 --> 00:02:40,160
It will help us.
35

36
00:02:40,180 --> 00:02:49,180
So how many products that we are going to detect in one just time or in the in this bits groups.
36

37
00:02:49,300 --> 00:02:57,310
For example in this example I will use for product and each time I will shift the bits one by one.
37

38
00:02:57,310 --> 00:03:01,990
And this is one and which bits is going to be one or zero.
38

39
00:03:01,990 --> 00:03:05,650
It will start from M to a..
39

40
00:03:05,680 --> 00:03:06,580
This is okay.
40

41
00:03:06,580 --> 00:03:13,810
This is just very very small basic example I will go online and I will say okay the project is compiling
41

42
00:03:13,810 --> 00:03:23,120
now I will send it to simulator and we will check what will happen if m 20 
42

43
00:03:23,160 --> 00:03:28,520
Will it be 0 or 1 or how it is going to be worked.
43

44
00:03:28,540 --> 00:03:34,700
First of all first product let's say it's OK it is with the barcode.
44

45
00:03:34,870 --> 00:03:42,470
So this is detected the barcode but you can say just said on this is with the barcode.
45

46
00:03:42,490 --> 00:03:57,130
The first product and set on this is finished and off and I will say release all and the second one
46

47
00:03:58,440 --> 00:04:01,260
I will say release X and Y.
47

48
00:04:01,560 --> 00:04:03,500
Again this is okay.
48

49
00:04:03,690 --> 00:04:08,400
And the second one will be not with barcode.
49

50
00:04:08,400 --> 00:04:21,650
So this should be set on again force and force and release and then third one will be set on and fourth
50

51
00:04:21,650 --> 00:04:30,270
set on and fourth release X and Y or release all yes.
51

52
00:04:30,540 --> 00:04:35,690
And the fourth one will be without barcode.
52

53
00:04:35,840 --> 00:04:50,380
Just set on get on and force release all yes force release x and y again.
53

54
00:04:50,390 --> 00:04:53,050
I'm clicking That's okay.
54

55
00:04:53,440 --> 00:04:57,580
So what we did we said just go online it
55

56
00:05:01,380 --> 00:05:06,080
one okay to not okay.
56

57
00:05:06,100 --> 00:05:08,510
Three okay and four not okay.
57

58
00:05:08,550 --> 00:05:14,820
So what we are waiting M 20 should be on M 21 should be off M22.
58

59
00:05:14,820 --> 00:05:18,390
Should be all and M 23 should be of.
59

60
00:05:18,510 --> 00:05:20,150
This is what we are waiting.
60

61
00:05:20,220 --> 00:05:26,310
And then I will go to device monitor table and I will create a new one monitor table and I will add from
61

62
00:05:26,310 --> 00:05:35,130
twenty adjust four device so you can see m20 is on M 21 is of M22 is on and M23
62

63
00:05:35,130 --> 00:05:43,330
is off this is how we are shifting the bits we are activating for example this two condition.
63

64
00:05:43,350 --> 00:05:45,320
So this is okay and this is okay.
64

65
00:05:45,330 --> 00:05:52,770
That moment we are activating the first bit and then it is working like this it is starting from here
65

66
00:05:53,100 --> 00:06:01,620
and on and it is shifting to the up upside so also it is the meaning of SFTR command.
66

67
00:06:01,620 --> 00:06:10,440
It is shifting to the right in the and you can see it shifted to the right on off on and off .
67

68
00:06:10,650 --> 00:06:14,150
So this is how SFTR command  works.
68

69
00:06:14,310 --> 00:06:24,510
So you can you can just try SFTL command you can you can use and you can just
69

70
00:06:24,510 --> 00:06:37,970
do an exercise with yourself just put here SFTL and do similar things like me and just watch
70

71
00:06:37,970 --> 00:06:43,940
the results with the device monitor table and you can understand better how these instructions works
71

72
00:06:44,300 --> 00:06:47,240
and for this video I'm finished here.
72

73
00:06:47,240 --> 00:06:52,610
I hope this instruction is going to help you a lot in your projects because this is this is really really
73

74
00:06:52,610 --> 00:07:00,860
important instruction for the production lines for the Plc projects and I hope this video
74

75
00:07:00,860 --> 00:07:10,250
is help you to understand this instruction this is just really basic example but it helps to understand
75

76
00:07:10,250 --> 00:07:11,740
it professionally.
76

77
00:07:11,840 --> 00:07:13,730
See you again in the next video.
