reported: a ) B a ttery Level (0 to 4) b) B a ttery Percent a ge (0 to 100) c) Wireless Sign a l (0 or 1) f) Over a ll Qu a lity (0 to 100) g) Qu a lity per Sensor (0 to 4) – ex a mple is showing Emotiv Insight with 5 sensors. 7
reported: a ) Active <?> is true if the detection of this metrics is running properly. It is f a lse if the detection c a nnot run. This c a n h a ppen if the EEG sign a l from the he a dset is of poor qu a lity. b) Focus: sust a ined a ttention on a single t a sk. c) Eng a gement: immersion in a n a ctivity. d) Excitement: intensity of re a ctions to stimuli. e) Interest: a ttr a ction or a version to stimuli. f) Rel a x a tion: c a lm a fter a period of intense concentr a tion. g) Emotion a l Stress (Insight/EPOC): tension experienced when completing a t a sk. h) Cognitive Stress (MN8): ment a l str a in c a used by ch a llenging t a sks or environments. 12
a lue every 7 milliseconds) it is reported: a ) Counter (0 to 127): b) Interpol a ted: FALSE if this s a mple w a s received from the he a dset. TRUE if this s a mple w a s interpol a ted by Emotiv Softw a re. c) Cont a ct Qu a lity d) AF3, T7, Pz, T8, AF4: v a lues in microvolts (sc a led) 16
reported: a ) Eye (Action): neutr a l, blink, left wink (winkL), right wink (winkR) b) Upper F a ce (Action a nd Power): neutr a l, r a ised eyebrows (surprise), furrowed brows (frown) – v a lue 0 to 1 c) Lower F a ce (Action a nd Power): neutr a l, smile, l a ugh, smirkRight, smirkLeft, a nd clenched teeth (clench) – v a lue 0 to 1 20
reported: a ) Counter (0 to 31) b) Interpol a ted: FALSE if this s a mple w a s received from the he a dset. TRUE if this s a mple w a s interpol a ted by Emotiv Softw a re. c) Accelerometer. X, Y, Z a xis of the a ccelerometer ( a pprox. -2.0 to +2.0 g) d) M a gnetometer. X, Y, Z a xis of the m a gnetometer ( a pprox. -150.0 to +15.0 µtesl a s) e) Qu a ternions of the gyroscope (-1.0 to 1.0) – orient a tion in a unit sphere 24
y, z, w]: • • Roll - rot a tion a round X- a xis: • Pitch - rot a tion a round Y- a xis: • Y a w - rot a tion a round Z- a xis: qnormalized = [ x norm , y norm , z norm , w norm ] ϕ = atan2(2(wx + yz),1 − 2(x2 + y2)) θ = asin(2(wy − zx)) ψ = atan2(2(wz + xy),1 − 2(y2 + z2)) 25 norm = x2 + w2 + z2 + w2
ge Queuing Telemetry Tr a nsport) is a lightweight, publish-subscribe network protocol. • Designed for constr a ined devices a nd low-b a ndwidth, high-l a tency, or unreli a ble networks. Key Fe a tures • Simple a nd e a sy to implement. • Low b a ndwidth consumption. • Reli a ble mess a ge delivery. • Sc a l a ble to millions of devices. 30
a t h a ndles mess a ge distribution. • Ex a mples: Mosquitto, HiveMQ, EMQX, AWS MQ. Clients • Devices or a pplic a tions th a t publish (send) a nd subscribe (receive) mess a ges. • Ex a mples: Sensors, mobile a pps, a nd IoT devices. Topics • Hier a rchic a l n a mesp a ces for org a nizing mess a ges. • Ex a mple: home/livingRoom/temper a ture. 31
broker. Subscribe • Clients subscribe to topics of interest. Publish • Clients publish mess a ges to topics. Receive • Clients receive mess a ges from topics they a re subscribed to. Disconnect • Clients disconnect from the broker. 32
a ho? • A set of MQTT client libr a ries developed by the Eclipse Found a tion. • It supports multiple l a ngu a ges, such a s J a v a , Python, J a v a Script, etc. J a v a Dependency (M a ven) <dependency> <groupId>org.eclipse.paho</groupId> <artifactId>org.eclipse.paho.client.mqttv3</artifactId> <version>1.2.5</version> </dependency> 36
This option is suitable when message loss is acceptable, as it doesn't require acknowledgment or persistence. • 1 – "at least once": This option should be chosen when message loss is unacceptable, and your subscribers can handle duplicate messages. • 2 – "Exactly once": This option is ideal when message loss is unacceptable, and your subscribers cannot handle duplicate messages. 39
2025 Copyright. These slides can only be used as study material for the class CSC 570 at Cal Poly. They cannot be distributed or used for another purpose.