M01 Introduction
M01 Introduction
Mani Srivastava
mbs@ucla.edu
Networked & Embedded Systems Lab
CS & ECE Departments
UCLA
2
ffi
ffi
Enrollment and Prerequisites
• Enrollment
‣ Prioritize (i) MENG IoT Track Students, (ii) PhD students working for embedded
systems faculty in ECE and CS, (iii) Other ECE and CS students, (iv) The rest.
‣ Most PTEs already handed out (MENG and PHD students)
‣ Another 4-6 PTEs split equally between ECE and CS, based on waiting list position
after con rmation of interest in the class
‣ The class capacity will not be increased
‣ Many students drop out as there is a lot of over-enrollment
• Prerequisites
‣ The course material should be accessible to anyone with the typical Computer
Engineering coursework
‣ You should have done coursework in computer organization and data structures /
algorithms
‣ Your should be very comfortable with programming
- both systems programming (e.g. C/C++) and application programming (e.g. Python)
‣ It would be highly bene cial if you have done an undergraduate level ML course
3
fi
fi
Class Protocols
• I record the lectures (laptop screen plus audio) for students who may
occasionally need it due to medical, conference, or such reasons
‣ Your voice might be incidentally captured and become a part of the video
‣ YouTube playlist link will be shared on Piazza after the rst lecture
‣ I reserve the right to stop posting the videos if I see low attendance or
consistent skipping of lectures by students
4
ffi
fl
fi
fl
About the course…
Embedded, Wearable Mobile Planetary-scale Cloud
Devices Devices Network Services
Embedded, Wearable Mobile Planetary-scale Cloud
Devices Devices Network Services
-
-
[Wikipedia]
An embedded system is a computer system with a
dedicated function within a larger mechanical or electrical
system, often with real-time computing constraints.
9
Related Concept: Internet of Things (IoT)
10
fi
fi
IoT Examples
11
From Passive IoT to Active IoT
12
Related Concept: Ubiquitous or Pervasive Computing
13
Tactical (CPS)
Related Concept: Cyber-Physical Systems Edge: A Huma
State
Infer Decide
• Perception-Cognition-Action Loops
State
actuator
actuator
sensor
sensor
computation and its dynamics
actuator
actuator
sensor
sensor
‣ di erential equations, stochastic processes,
etc. vs. algorithms and programs
14
http://cyberphysicalsystems.org
ff
Not just CPS, but Human-Cyber-Physical Systems
Human Cyber‐Physical Systems (h‐CPS)
CPS that operate in concert with humans
© Rethink Robotics
15
Sanjit Seshia, Berkeley
Related Concepts: Edge Computing, Fog Computing
• Loosely speaking: extend cloud closer to devices
producing and consuming the data
• Wikipedia
‣ Edge Computing is a distributed computing paradigm
which brings computation and data storage closer to the
location where it is needed, to improve response times
and save bandwidth.
‣ Fog Computing is architecture that uses edge devices
to carry out a substantial amount of computation, Doing all processing & storage in the cloud is impractical
storage, communication locally and routed over the (scalability, latency, privacy, security etc.)
internet backbone.
16
Why the interest?
New Instruments for
Pervasive Awareness and Knowledge Discovery
workplace
analytics
mPerf
18
ff
From Knowledge Discovery to
PS-IoT System Evolution
Just-in-Time Adaptive Interventions and Control
CPS-IoT System Evolution
19
Cyber-Physical and IoT Systems
CPS-IoT System Evolution
CPS-IoT System Evolution
Measurements & Events Inferences & Interventions
Measurements & Events Inferences & Interventions
Sensor Interventions
Markers Predictors (manual, autonomous)
Data
20
Eventually: Pervasive Autonomy
21
Distributed or Logically Centralized?
Network Network
database for Big Data applications. It will allow ag- – Assessment of the physical space
gregate behavioral goals to be specified a declara- ComputationallyWired and veryWireless
intensiveNetworks
tive language, and it will then compute detailed• de-Real time control •
vice behaviors to implement those goals. The third – A revised plan (actions) to devices:
layer uses these facilities to create domain-specific location, velocity, trajectory, what to
BCP requires servicesaddressing
such as activemany tough
sensing and deep reinforce- sense, … Devices
challenges
ment learning. Low latency computationally intensive with
Figure 1: System overview for managing collaborative device
predictability
BCP will execute on large clusters of servers in swarms.
23
both edge and core datacenters. In order to handle
http://platformlab.stanford.edu/Seminar%20Talks/Big-Control-Expedition-pres-PL-retreat-June2016-v0.1.pdf
A Rich Ecosystem of Interlinked Technologies
Cloud, Network, Mobile, Embedded….
Analytics
Sharing
Storage
New Technologies Leading to “AIoT”
A Nexus of Enabling Technologies Leading to “AIoT”
25
Specialized Mass-market
Sensors “Universal” Sensors
+ +
Low-dimensionality High-dimensionality
Structured Unstructured
Data Data
+ +
Low-cost High-cost
First-Principles Data-Driven
Mechanistic Models AI/ML Models
26
Complex Inferences from Simple Sensors
Complex Inferences from Simple Sensors
https://arxiv.org/pdf/1707.03502.pdf
27
Reduced Cost of Sensing
Reduced Cost of Sensing
Lidar-like dense depth by fusing cameras with small, cheap, low-power mmWave radars
+ =
28
Richer and Deeper Awareness
• 3D-imaging-guided RF-vibrometry
•‣ Association:
3D-imaging-guided RF-vibrometry between internal state and object
establish correspondence
‣ Accuracy: provides
‣ Association: prior forcorrespondence
establish estimation of intrinsic statesinternal
between of objects
state and object
‣ Latency: avoids
‣ Accuracy: exhaustive
provides search
prior over all possible
for estimation distances/angles
of intrinsic to locate vibration
states of objects
‣ Latency: avoids exhaustive search over all possible distances/angles to locate vibration
8
29
Common Three-tier IoT Systems:
Device-Gateway-Cloud (DGC)
Embedded
Gateway
Device
Physical World
Embedded Gateway
Embedded
Device
Wearable
Device
Implantable
Device Storage, Learning, Inferencing,
Mobile Gateway Decisions, Personalization, Interventions
PC Gateway
Multiple processor cores, 32/64b, Arm A / Intel Atom, Single processor, 16/32b, Arm M or low-end RiscV,
~1 GHz / several GB RAM / many GB Flash, embedded GPU, ~10-100 MHz / kB RAM / MB Flash, simple accelerators < 1W, ~
Multiple watts, ~ 100cc, ~ 100 gm; carried, or plugged in; Linux 10 cc, ~ 10 gm; wearable, battery or harvested; RTOS
Off-loading to Cloud Higher-end IoT Devices Ultra Resource Constrained IoT Devices
31
Another Enabler: The “Maker” Culture
• What are the right platform abstractions to get robust and secure design?
32
Hartmann @ UCB (http://iot.stanford.edu/workshop14/SITP-8-11-14-Hartmann.pdf)
Desktop Fabrication
33
Modular & Open Hardware,
Rapid Fabrication Services
34
http://www.sunstone.com https://www.ponoko.com
Course Content & Logistics
Foundational Issues in Embedded Computing
• Connectivity
• Power/Energy
• Intelligence
• Security
• Privacy
• Safety
• Human-coupling
36
Experience with Various Tools and Technologies
37
Syllabus
Module Topic
1 Embedded Hardware
2 Organizing Software
3 Scheduling Computation
5 Embedded Communication
6 Time Synchronization
7 Localization
9 Emerging Topics
38
Course Components
Individual (≤4)
Assignments Concepts, Programming, Literature/Web
40%
Individual or teams of up to 3
Project Analysis, Design, Experiment… 60%
(Report Website + Video Demo/Talk)
39
Grading Algorithm
• Some components of the course will be graded on a numerical scale while others
directly on a letter grade scale (A+=4.3, A=4, A-=3.7, … D-=0.7, F=0)
• Expectation for letter grade:
‣ A+/A/A- = correct / high-quality; B+/B/B- = some- aws / acceptable; C+/C/C- =
signi cant- aws / below-average-quality; D+/D/C- = mostly-incorrect / unacceptable-
quality; F = did not make a serious attempt
• Numerical scores will be mapped to letter grade as follows
‣ Scale to 100
‣ If median<80, normalize so that highest=100 and median=80
‣ Mapping: scores ≥95 = A, ≥90=A-; ≥85=B+, ≥80=B, and so on.
• Course grade
‣ Compute weighted course score on scale of 4
‣ Convert to letter grade using mid-points between adjacent letter grades as thresholds
‣ A+=(4,4.3], A=[3.85,4], A-=[3.5,3.85), etc.
‣ thresholds may be selective nudged lower at instructor’s discretion to account for
unusual clustering
• S grade means letter grade of B or better [UCLA rules]
• Historical: Median/Mean course grade between B+ and A-
40
fi
fl
fl
Course Project
• Dig deep into a focus area on your own as lectures would provide a “broad” coverage
• Aim for something concrete and tangible, even if minor
‣ Simulation, analysis, software/hardware design, tools, application...
‣ Literature surveys not acceptable
• Project topics
‣ Some topics will be provided as exemplars
‣ Discuss project ideas with me
‣ While project may be motivated by your prior research or work, it must be a distinct topic and
e ort whose output you must be willing to publicly disseminate
- you may not reuse work already being done or planned for a thesis or another project
- you may not collaborate with other researchers in your group
‣ Topics will have to be approved by me and I reserve the right to veto any project proposal
• While teams are allowed, it is with the understanding that if a partner drops the course
then the remaining member(s) would need to nish the project, and other than giving
extra time the instructor cannot help
• What should be your goal?
‣ Something useful or cool -risky ideas leading to negative results are ne
‣ The key is to keep the project simple, and focused
‣ Aim for high quality!
41
ff
fi
fi
Thinking about Project Ideas: Heilmeier Catechism
• What are you trying to do? Articulate your objectives using absolutely no jargon.
• How is it done today, and what are the limits of current practice?
• What is new in your approach and why do you think it will be successful?
• Who cares? If you are successful, what difference will it make?
• What are the risks?
• How much will it cost?
• How long will it take?
• What are the mid-term and nal “exams” to check for success?
42
fi
ff
Project Timeline
• Week 2-3: Mandatory initial discussion with instructor about project ideas [2%]
• Document and summarize meeting via a direct non-anonymous message on Piazza to
instructor
• Week 3-4: Mandatory second discussion with instructor about project ideas 3%]
• Document and summarize meeting via a direct non-anonymous message on Piazza to
instructor
• Week 5: Initial project repo and website ready on GitHub [5%]
• Submit project title, team information, GitHub repo URL, and GitHub website URL via web form
• Website must have initial sections for goals, speci c aims,
• Week 7: Midterm checkpoint [20%]
• 5-min max in-class presentation [80%]
• Website updated and also add initial text for data, tools, methods, and results [20%]
• Finals Week: Submission [70%]
• 15 min max Zoom presentation plus any demo [80%]
• Website nalized [20%]
• Grading will consider
• problem and approach: di culty (relative to team size), novelty
• execution: architecture, analysis, evaluation, e ort, elegance
• presentation: quality, organization, discussion
43
fi
ffi
ff
fi
More Project Guidelines
• The project should re ect a serious e ort to go beyond the course material
‣ Obtain additional sources from the net, journals, or books.
• All prior work, published or not, public domain or proprietary, should be fully credited
‣ "my o cemate, Joe Schmo, says ...", "This section of code is modi ed from XXX gotten from
YYY” etc.
• Do not build software or hardware from scratch
‣ Your project will not be evaluated on the basis of how much e ort you put into it, but rather on
how e ective your work is.
‣ Go to the net or commercial software and nd something to build on.
• Learn to use the relevant tools and languages
‣ At least to the level of pro ciency required to make your point
‣ Get the compiler, simulator, design environment, and install it
• If you are already engaged in relevant work, leverage it.
• You may work in groups of up to 3
‣ I will expect the ambitious-ness of the project to be proportional to the group size
‣ I think optimal group size is 2
• You need to deal with inter-personal issues in the group yourself
‣ Learning how to work in a team is important professionally
• Project report must describe what each team member did
‣ Part of the score will depend on team e ort and part on individual e ort
44
Source: Prof. Lee @ Berkeley, Prof. Kastner @ UCSD
ffi
ff
fl
fi
ff
ff
fi
ff
fi
ff
Course on the Web
• What is BruinLearn?
‣ UCLA’s on-line platform for courses
• We will not use BruinLearn as it doesn’t t well for the needs of this course.
‣ However, I have posted an announcement there with links to class resources
45
fi
Course on the Web
46
fi
fi
fi
ff
No Textbook!
Computers
• You need to have access to a computer (ideally a laptop) where you have
administrator privileges in order to install software.
• The computer must have at least one and ideally two USB 3.0 USB
ports (either built-in or via adapters) and suitable adapters/cables/hub to
allow you to connect to hardware devices with micro-USB ports.
• While we will try to provide instructions for all the three major OSs (Linux, Mac
OS X, and Windows), please note that some of the tools are much better
supported or easier to install under Unix-like OSs (Linux, Mac OS X).
‣ No ChromeBooks - get a real computer :-)
‣ If you are on Windows then it may become necessary to run a Linux VM (using
VirtualBox or VMWare ) or Container (Docker) con gured to access the USB
ports and with the laptop provisioned with plenty of RAM (16GB or more)
‣ Windows now has a Linux subsystem, which might work as well
‣ If on a Mac, it is strongly recommended to install the Homebrew package
manager
48
fi
Smartphones
• In order to run certain applications that interact with hardware via Bluetooth
Low Energy (BLE) as well as for use in your project, you would bene t from
having an Android or iOS smartphone with Bluetooth Low Energy (BLE).
‣ Most phones from recent years will have BLE, but please double check,
particularly if you've an Android smartphone with an old version of the OS
49
fi
Hardware Platforms for Coursework
Embedded
Gateway
Device
Embedded
Device
Wearable
Device
Implantable
Device
Mobile PC 50
Arduino Nano 33 BLE Sense
• Alternatives that are based on the same mbed OS based software stack
‣ Arduino Nano RP2040 Connect
- RP2040 processor (dual Cortex-M0+)
- Bluetooth and WiFi
- IMU, Microphone, Temperature
‣ Seeed Studio XIAO nRF52840 Sense or, Seeed Studio XIAO RP2040
- need further vetting…
52
Hardware Platforms for Coursework
• And you may need a gateway device that you can program: iOS or Android
Smartphone, or a computer with Bluetooth (BLE), WiFI, and USB
Embedded
Gateway
Device
Embedded
Device
Wearable
Device
Implantable
Device
Mobile PC 53
Cheating & Plagiarism
54
ffi
fi
ff
Post any more questions on Piazza!!!
55