WEBVTT - This file was automatically generated by VIMEO

0
00:00:10.600 --> 00:00:13.700
Hello everyone. Welcome to the section number 7 where

1
00:00:13.700 --> 00:00:16.500
 we're going to talk about the mqtt, which is

2
00:00:16.500 --> 00:00:19.400
 application layer communication protocol.

3
00:00:20.900 --> 00:00:23.800
So this is our first lecture video number 7.1

4
00:00:23.800 --> 00:00:26.500
 and we're going to talk on what is mqtt. It's

5
00:00:26.500 --> 00:00:30.200
 feature and how it works and it's architecture. So

6
00:00:29.200 --> 00:00:31.600
 guys, let's get started with that.

7
00:00:33.500 --> 00:00:36.500
So firstly mqtt is a message queue

8
00:00:36.500 --> 00:00:40.100
 Telemetry transfer protocol and it is a lightweight

9
00:00:39.100 --> 00:00:42.900
 protocol works on the pub/sub method used

10
00:00:42.900 --> 00:00:45.400
 to transport the messages from one device to

11
00:00:45.400 --> 00:00:49.800
 another device. But with the user job centralized broker.

12
00:00:50.800 --> 00:00:53.800
And it uses tcp/ip stack and

13
00:00:53.800 --> 00:00:56.500
 mqtt is preferred where

14
00:00:56.500 --> 00:00:59.500
 we have a lower bandwidth because it uses

15
00:00:59.500 --> 00:01:02.300
 a small core footprint because if we compare

16
00:01:02.300 --> 00:01:06.200
 with the HTTP and the other communication protocols, then

17
00:01:05.200 --> 00:01:09.000
 it uses less headers

18
00:01:08.100 --> 00:01:11.800
 or you can say that less overhead

19
00:01:11.800 --> 00:01:14.200
 data as compared to the other protocols because

20
00:01:14.200 --> 00:01:17.200
 it's some M2M communication protocol specifically designed for

21
00:01:17.200 --> 00:01:18.300
 devices.

22
00:01:20.100 --> 00:01:23.300
So if we talk about the feature, the first feature is a

23
00:01:23.300 --> 00:01:26.500
 lightweight and efficient and the number two benefit is

24
00:01:26.500 --> 00:01:29.800
 it is bidirectional communication and the instant communication

25
00:01:29.800 --> 00:01:32.300
 and the third benefit is it is

26
00:01:32.300 --> 00:01:36.300
 able to scale million of devices instantly and

27
00:01:35.300 --> 00:01:38.700
 the number fourth is reliable message

28
00:01:38.700 --> 00:01:41.400
 delivery because it's using tcp/ip stack

29
00:01:41.400 --> 00:01:44.700
 instead of UDP and Sport for unreliable

30
00:01:44.700 --> 00:01:48.400
 networks mean it is providing qos levels.

31
00:01:51.300 --> 00:01:54.500
And the last is security enabled it

32
00:01:54.500 --> 00:01:57.200
 provides a built-in username and

33
00:01:57.200 --> 00:02:00.200
 password authentication as well as restriction to the topics.

34
00:02:01.700 --> 00:02:04.400
So now the question is how it works.

35
00:02:05.700 --> 00:02:08.700
In the previous slide. I told you that it uses

36
00:02:08.700 --> 00:02:11.700
 pub/sub method to understand how the pub/sub method

37
00:02:11.700 --> 00:02:14.700
 works. There is example of a university and different

38
00:02:14.700 --> 00:02:17.900
 departments. So let's get started with that. Now we

39
00:02:17.900 --> 00:02:20.700
 have a university its name is Islamic Institute

40
00:02:20.700 --> 00:02:23.300
 of applied sciences and it have a four

41
00:02:23.300 --> 00:02:27.200
 different departments, which are CS saw

42
00:02:26.200 --> 00:02:29.300
 space science agriculture physics and the

43
00:02:29.300 --> 00:02:32.500
 math and every Department have two or four

44
00:02:32.500 --> 00:02:35.200
 different classes. For example, if we want to

45
00:02:35.200 --> 00:02:38.400
 give a notice to the all students of the University, then we

46
00:02:38.400 --> 00:02:42.600
 will put the notice on the main gate where

47
00:02:41.600 --> 00:02:45.700
 all the students will read. What

48
00:02:45.700 --> 00:02:49.100
 are the next instruction from the University management what

49
00:02:48.100 --> 00:02:51.500
 for example if we want to talk specific to

50
00:02:51.500 --> 00:02:54.200
 the Department of computer science, then what I will

51
00:02:54.200 --> 00:02:56.500
 do I will not place that notice on the

52
00:02:57.500 --> 00:03:00.700
University gate I will place that notice on

53
00:03:00.700 --> 00:03:03.700
 the departmental notice board because I

54
00:03:03.700 --> 00:03:06.500
 only want to Target that department students for

55
00:03:06.500 --> 00:03:09.300
 that specific notice. But what if I want to

56
00:03:09.300 --> 00:03:12.900
 send a message to the agriculture department and

57
00:03:12.900 --> 00:03:15.400
 specific to the MS agriculture class

58
00:03:15.400 --> 00:03:19.000
 then what I will do is then the university management will

59
00:03:18.100 --> 00:03:21.200
 do is they will visit the class or

60
00:03:21.200 --> 00:03:24.600
 they will put the message on their lab because the

61
00:03:24.600 --> 00:03:27.300
 only want to Target that Ms. Students

62
00:03:27.300 --> 00:03:30.600
 as compared to other students. So same way

63
00:03:30.600 --> 00:03:33.100
 that topics will work. Now you

64
00:03:33.100 --> 00:03:36.400
 need to consider is that this University is your home or

65
00:03:36.400 --> 00:03:39.800
 your industry and if you want to monitor?

66
00:03:41.300 --> 00:03:44.300
Actually mqtt uses slashes to

67
00:03:44.300 --> 00:03:47.500
 distinguish the topics now, for example, this is

68
00:03:47.500 --> 00:03:50.400
 our home and these are the one two three

69
00:03:50.400 --> 00:03:53.700
 four rooms and in every room. We have a different sensors and

70
00:03:53.700 --> 00:03:56.300
 equitators. And this is our

71
00:03:56.300 --> 00:03:59.400
 home name and this is our room name. Okay, and if

72
00:03:59.400 --> 00:04:02.400
 I want to send a specific for example,

73
00:04:02.400 --> 00:04:04.100
 this is our ball.

74
00:04:06.100 --> 00:04:09.700
Okay. Sorry. My writing is not good too

75
00:04:09.700 --> 00:04:13.100
 much, but you can consider it that it is well, okay,

76
00:04:12.100 --> 00:04:15.800
 then I will use slash room one.

77
00:04:15.800 --> 00:04:18.700
 Sorry. This is my home name and

78
00:04:18.700 --> 00:04:21.200
 this is the room and this is the

79
00:04:21.200 --> 00:04:24.500
 device that I want to control that. I want to receive the

80
00:04:24.500 --> 00:04:25.600
 message from that device.

81
00:04:26.300 --> 00:04:29.300
What is the benefit is that for example, if we have another

82
00:04:29.300 --> 00:04:32.700
 room or other home? Then the name will be changed

83
00:04:32.700 --> 00:04:33.700
 from here?

84
00:04:35.100 --> 00:04:38.200
Don't worry, we will discuss in deeply in when

85
00:04:38.200 --> 00:04:41.900
 we're going to do some exercises in that upcoming videos. So

86
00:04:41.900 --> 00:04:44.700
 this is the main architecture behind the topic system

87
00:04:44.700 --> 00:04:46.000
 how pops up works?

88
00:04:47.500 --> 00:04:50.700
Now there are single level Plus in topics. For

89
00:04:50.700 --> 00:04:54.000
 example. Yeah, this is the good example I created

90
00:04:53.100 --> 00:04:56.200
 for you guys. For example in the

91
00:04:56.200 --> 00:04:59.600
 house. We have a two floors and on each floor. We

92
00:04:59.600 --> 00:05:02.200
 have a two rooms and we are monitoring the

93
00:05:02.200 --> 00:05:05.300
 temperature. I mean you can say that we have deployed the temperature

94
00:05:05.300 --> 00:05:08.800
 devices in every room. So how we can distinguish.

95
00:05:08.800 --> 00:05:09.800
 So this is the house

96
00:05:11.100 --> 00:05:14.500
This is the floor ground floor. And this is the floor one

97
00:05:14.500 --> 00:05:17.500
 and this is the room one and the room two

98
00:05:17.500 --> 00:05:20.800
 and here are the temperatures. Okay, for example

99
00:05:20.800 --> 00:05:21.700
 if I want to

100
00:05:23.900 --> 00:05:26.900
temperature of room to from

101
00:05:26.900 --> 00:05:27.300
 which floor

102
00:05:28.200 --> 00:05:30.400
From the first floor. So this is the house.

103
00:05:31.200 --> 00:05:33.500
And this is the floor one.

104
00:05:36.300 --> 00:05:39.400
And Slash and we need to mention the room.

105
00:05:41.200 --> 00:05:44.200
room one and this is the temperature of

106
00:05:44.800 --> 00:05:47.600
that room. So how in this

107
00:05:47.600 --> 00:05:50.400
 way the topics will work. For example, I want

108
00:05:50.400 --> 00:05:52.500
 to monitor the temperature of

109
00:05:53.200 --> 00:05:56.900
All the ground floor rooms, so I don't

110
00:05:56.900 --> 00:06:00.000
 want to use again and again this so how

111
00:05:59.200 --> 00:06:02.400
 we will monitor the our ground

112
00:06:02.400 --> 00:06:05.900
 floor devices by using the plus topic the

113
00:06:05.900 --> 00:06:08.300
 plus topic will eliminate all the

114
00:06:08.300 --> 00:06:11.700
 stuff and listen whatever is coming to the ground floor.

115
00:06:11.700 --> 00:06:14.500
 So this is the single level while card to

116
00:06:14.500 --> 00:06:17.600
 avoid from that. Okay, and next we

117
00:06:17.600 --> 00:06:17.800
 have a

118
00:06:19.200 --> 00:06:22.600
multi-level wired card, for example, I want

119
00:06:22.600 --> 00:06:25.500
 to monitor all the temperature of that

120
00:06:25.500 --> 00:06:28.800
 house. So we have a two sensors

121
00:06:28.800 --> 00:06:29.400
 on the ground floor.

122
00:06:30.600 --> 00:06:34.300
And two sensors on the floor one and ever

123
00:06:33.300 --> 00:06:36.400
 since I have a different rooms. So here

124
00:06:36.400 --> 00:06:39.400
 we have a multi wild card one add one is that and

125
00:06:39.400 --> 00:06:42.400
 the other is that to remove that?

126
00:06:43.800 --> 00:06:45.100
from that scenario

127
00:06:47.100 --> 00:06:48.700
we will use ash.

128
00:06:51.300 --> 00:06:52.500
and this will be our

129
00:06:53.300 --> 00:06:56.900
Final topic that slash house hash whatever

130
00:06:56.900 --> 00:06:59.900
 is coming and floor or

131
00:06:59.900 --> 00:07:02.900
 room or whatever. We need only temperature

132
00:07:02.900 --> 00:07:03.800
 from

133
00:07:05.400 --> 00:07:08.500
those rooms. Okay. So this is

134
00:07:08.500 --> 00:07:11.400
 the multi-level wildcard and topics.

135
00:07:13.400 --> 00:07:17.000
Now it's time to talk about the application real-time communication

136
00:07:16.300 --> 00:07:19.100
 and the lightweight communication is a

137
00:07:19.100 --> 00:07:22.000
 priority for every iot solution. So

138
00:07:23.100 --> 00:07:26.100
In tracking of assets or you

139
00:07:26.100 --> 00:07:26.500
 can say that.

140
00:07:28.300 --> 00:07:31.000
Logistics monitoring then mqtt is a good

141
00:07:31.300 --> 00:07:35.000
 to go because it is a lightweight protocol and instant

142
00:07:34.900 --> 00:07:37.200
 a protocol to San and receive

143
00:07:37.200 --> 00:07:40.500
 messages by pub/sub Method and the next is smart

144
00:07:40.500 --> 00:07:43.700
 building and smart cities for example in different

145
00:07:43.700 --> 00:07:46.200
 scenarios. For example, we are

146
00:07:46.200 --> 00:07:49.700
 monitoring the weather we can use a lot of van and I'm

147
00:07:49.700 --> 00:07:50.400
 mod a

148
00:07:51.400 --> 00:07:54.600
it doesn't make some issues but for example if you are monitoring the

149
00:07:55.500 --> 00:07:55.900
smoke

150
00:07:56.900 --> 00:07:59.600
Of the building our fire alarms

151
00:07:59.600 --> 00:08:02.400
 then mqtt is a good application layer protocol

152
00:08:02.400 --> 00:08:05.300
 to send instant messages to the cloud or

153
00:08:05.300 --> 00:08:08.600
 you can say the specific authority to get alerts and

154
00:08:08.600 --> 00:08:11.300
 in the smart Healthcare where critical operations are going

155
00:08:11.300 --> 00:08:14.600
 on mqtt is a good option to consume and

156
00:08:14.600 --> 00:08:17.100
 in smart agriculture. It's a good

157
00:08:17.100 --> 00:08:20.600
 to monitor the soil moisture sensor and temperature but to

158
00:08:20.600 --> 00:08:24.000
 control the water watering

159
00:08:23.200 --> 00:08:26.200
 system. It is good to use

160
00:08:26.200 --> 00:08:29.500
 the mqtt for instant on and off. And in iot.

161
00:08:29.500 --> 00:08:32.400
 We also have a different use cases

162
00:08:32.400 --> 00:08:33.400
 where we need to

163
00:08:35.200 --> 00:08:39.000
communicate instantly for to

164
00:08:38.300 --> 00:08:41.700
 monitor the critical operations just like machines are

165
00:08:41.700 --> 00:08:44.100
 going on and if something is

166
00:08:44.100 --> 00:08:47.700
 happened, then we can use the mqtt protocol

167
00:08:47.700 --> 00:08:50.600
 to send instant messages. For example, if we deploy the

168
00:08:50.600 --> 00:08:53.500
 smoke sensor in the processing Hall and

169
00:08:54.400 --> 00:08:57.400
we want to monitor that if there is any fire

170
00:08:57.400 --> 00:09:01.200
 there is a smoke which means there is some issue so mqtt

171
00:09:00.200 --> 00:09:03.800
 will sort out your issue to send instant

172
00:09:03.800 --> 00:09:06.400
 message to Cloud to get

173
00:09:06.400 --> 00:09:09.400
 the notifications. So these are the different use cases

174
00:09:09.400 --> 00:09:12.500
 we can assume and there are a lot of other use

175
00:09:12.500 --> 00:09:15.500
 cases, but I just pick up some of use cases

176
00:09:15.500 --> 00:09:15.700
 there.

177
00:09:17.400 --> 00:09:20.400
So guys in the next video. We're going to talk about

178
00:09:20.400 --> 00:09:23.300
 there are different mqtt Brokers, and we will

179
00:09:23.300 --> 00:09:27.600
 install the emqx mqtt broker.

180
00:09:27.600 --> 00:09:30.600
 So guys, you can also start installing and exploring

181
00:09:30.600 --> 00:09:33.200
 different type of Brokers to get prepared for

182
00:09:33.200 --> 00:09:35.700
 the next video. So guys see you in the next video. Have a good day. Bye.
