Skip to content

Plan the Capstone and Use the Resource Map

Companion videos

Watch on YouTube (opens in a new tab)

Videos by Thai Embedded Systems Association (TESA) · The whole series in the playlist AIoT Foundation

Course 1 · Module 8 Suggested time: flexible — 2–4 hours recommended + continuing the Capstone on your own Format: combining the skills of M01–M07 into a mini-project + using the resource map / online portals

Lab · Capstone brief · Course package map · ← Table of Contents · ← M07

Note: which firmware the code in this lesson is written for (checked on 2026-09-26)

The C code in this lesson calls the API of the TESAIoT Bitstream firmware, called “TESA Firmware SDK” in the original, which is published as a ready-made HEX file (tesaiot-bitstream-<version>.hex) alongside Bitstream Studio in the TESAIoT_Hackathon lab pack. The source code of this firmware is not yet public. Functions such as cm55_*, sensor_*, led_controller_*, cm33_mqtt_* and cm55_ble_* therefore have no header you can open or build yourself. Read the snippets as concepts and a calling order. The calls to FreeRTOS and the Infineon PDL (such as xTaskCreate, vTaskDelay, Cy_GPIO_*) are ordinary public APIs.

The Capstone uses APIs from all of Modules 3–7. See the checked equivalents in the open SDK in each lesson’s note, and in the summary table on the course page

The ble-flet host is not yet published — the TESAIoT_Hackathon README (commit f5f09a6) states that python-app/, ble-react/ and ble-flet/ belong to the maintainers and are not in the public repo. Use the backup path the lesson already suggests: a general GATT explorer such as nRF Connect, LightBlue, or AIROC™ Bluetooth® Connect


By the end of this lesson you should be able to:

  1. Use the M01–M07 exercise set as the foundation, then combine it into a demonstrable system
  2. Deliver work against the Capstone’s pass criteria (build/flash, RTOS, sensor, MQTT or BLE)
  3. Use the course’s resource / API map to find functions and examples on your own
  4. Deliver the Capstone project with a README others can reproduce
  5. Use online learning resources (the Developer Hub, the Marketplace, Hackathon) to support the demonstration

Each module’s exercise is part of the whole course’s practice set — M08 is the layer that combines and delivers.

Document Use when
Table of Contents The whole course’s index
Course package map A module map + online portals + an API index
TESAIoT Developer Hub Code examples + API Reference
Bitstream Studio Host / Digital Twin / broker tools
TESAIoT_Hackathon HEX, Flasher, VSIX, web-app/, ble-flet/
M05 · M06 · M07 Sensor + MQTT + BLE for the Capstone

Module Lab What you get once passed
M01 The domain ↔ SDK layer map Can choose a domain/layer before writing code
M02 Create / Build / Flash / Debug A project running on the board
M03 GPIO + UART + peripherals The real Driver API on hardware
M04 Multi-task + queue / mutex Basic FreeRTOS
M05 Sensor + filter + window Data ready for AI / a twin
M06 Wi‑Fi + MQTT pub/sub Connected to the cloud / a broker
M07 A BLE peripheral / scan + host Connected locally / to a phone / desktop
M08 The Capstone mini-project A combined system, demonstrable and reproducible

Key phrase The Capstone is about choosing and connecting pieces you already have — not writing everything from scratch.


Use this section to plan your work and check before submitting.

Block Focus
Before starting the Capstone Check the main labs M02–M07 already meet their minimum bar
Hour 1 Write the task architecture + choose sensors / connectivity
Hours 2–3 Combine the code on the board + test MQTT and/or BLE
Hour 4 / continuing on your own The README, demo evidence, wrapping up
  • A board + a USB cable + working Wi‑Fi
  • A designated broker (LAN / Studio / public per your policy) — if using MQTT
  • A phone or PC that can scan BLE — if using BLE
  • Bitstream Studio, or the VSIX from Hackathon
  • HEX / Flasher from Hackathon, if using the ready-made pack
  • Do not commit a Wi‑Fi / broker password in files submitted publicly
Criterion Required
Builds + flashes, following your own README Yes
≥ 2 FreeRTOS tasks Yes
A sensor path + LED/UART indication Yes
Connectivity — MQTT or BLE (at least one path), with a command received or a link confirmed Yes
No secrets embedded in submitted public files Yes

Extension work (optional): using both MQTT and BLE, a threshold alert, a mutex on a shared bus, a queue/topic ready for a Digital Twin, demo quality.

Full detail in the lab and capstone-brief.md


Need Go to
Browse online examples TESAIoT Developer Hub — Example Explorer + API Reference
Peripheral function names M03 cheatsheet
FreeRTOS patterns M04 cheatsheet
Sensors / windows / fusion M05 cheatsheet
MQTT / Wi‑Fi triggers M06 cheatsheet
A BLE peripheral / scan M07 cheatsheet
The chip architecture / SDK layers M01
The toolchain M02
led_controller_* / cm55_button_* / sensor_*_*
xTaskCreate / vTaskDelay / xQueue* / xSemaphore*
cm55_trigger_connect / cm55_trigger_mqtt_* / bs_mqtt_telem_encode_json_*
cm55_trigger_ble_periph_* / cm55_ble_request_scan_* / cm55_ble_ipc_set_event_handler

3.3 Capstone data-flow (reference architecture)

Section titled “3.3 Capstone data-flow (reference architecture)”
[sensor_*_read task] --samples--> [filter / window]
│ │
│ ▼
│ [decision / event]
│ │ │
▼ ▼ ▼
[UART / LED] [MQTT publish] [BLE notify / host]
▲ ▲
└── [MQTT and/or BLE command path]

An example delay inside a task (from M04/M05):

TickType_t last = xTaskGetTickCount();
for (;;) {
/* read → filter → maybe publish */
vTaskDelayUntil(&last, pdMS_TO_TICKS(200));
}

An example MQTT command once Wi‑Fi is ready (from M06):

(void)cm55_trigger_mqtt_connect();
/* wait until cm55_get_mqtt_status reports CONNECTED */

An example reading BLE peripheral status (from M07):

ipc_ble_periph_status_t ble;
if (cm55_ble_periph_status_get_sync(&ble, 5000U)) {
/* stack_ready / connection_id / tx_notify_enabled */
}

The combined sheet: course-package.md


Example source Role in M08
The projects you built in M02–M07 The Capstone’s codebase
Developer Hub Pull examples for GPIO / Sensors / System / Integrations
TESAIoT_Hackathon Ready-made HEX, web-app/, ble-flet/ for live evidence
Infineon CE (extra) Compare against the vendor’s approach — does not replace the TESA Driver API

A small Environmental / Activity monitor

Must have at least:

  1. A sensor path — periodic reads + a filter or window (M05)
  2. Local indication — an LED and/or UART (M03)
  3. RTOS — ≥ 2 tasks + a queue or mutex when needed (M04)
  4. Connectivity — at least one path:
    • MQTT publish + subscribe to a command (M06), or
    • A BLE peripheral a host can connect to + a confirmed link/command (M07)

Extra options:

  • Use both MQTT and BLE
  • An event/alert when a threshold is exceeded
  • A to_twin structure (a separate queue or topic) for connecting a Digital Twin
  • Demonstrate on Bitstream Studio, the Hackathon dashboard, or ble-flet/

Piece Location
Table of Contents The course page
Lessons M01–M08 mNN-<slug>/l01-<slug>/README.md
Labs mNN-<slug>/l02-lab/README.md
Cheatsheets / worksheets mNN-<slug>/l01-<slug>/resources/*
The combined map course-package.md
Portal URL
Code examples / API https://dev.tesaiot.dev/
VS Code host / twin https://marketplace.visualstudio.com/items?itemName=TERNIONDEV.bitstream-studio
Lab pack HEX/VSIX/web/BLE https://github.com/drsanti/TESAIoT_Hackathon

After finishing Course 1, you should be able to explain:

  1. How the TESA Firmware SDK lays out the HAL/Driver/Utility/Application layers
  2. How ModusToolbox™ + VS Code are used to build, debug, and flash
  3. How GPIO / peripherals, FreeRTOS, sensor prep, MQTT and BLE connect together into an edge product
  4. How the host (Bitstream Studio / Hackathon BLE) and the lab pack help you test

Next path (outside Course 1): the Digital Twin / Product Design course — using the stream and structure prepared in the Capstone as input.

  1. Do the Capstone: Lab
  2. Fill in capstone-brief.md
  3. Keep the resource map: course-package.md
  4. Go back and review any module that isn’t solid yet, through the TOC

  1. Course 1 TOC
  2. TESAIoT Developer Hub
  3. Bitstream Studio
  4. TESAIoT_Hackathon
  5. M01 · M02 · M03 · M04 · M05 · M06 · M07
  6. MQTT Essentials · Bluetooth LE overview (Bluetooth SIG)
  7. PSOC™ Edge E84

Three short questions in quiz.yaml, one per objective of this lesson. Try answering them yourself first, then compare with the answer key and explanations in the file.

Continue hands-on at Capstone lab: a mini-project

Lab · Capstone brief · Course package map · ← Table of Contents

Try the real thing on the TESAIoT Dev Kit: open examples on the Developer Hub to read the code, download it, or flash ready-made firmware.

  • EP07 — SensorHub Final — a course-closing project: a dashboard combining all 4 sensors (DPS368, SHT4x, BMI270, BMM350) + a stereo PDM microphone on a single screen
  • EP07 — Final WiFi Manager — combines scan + profile + connect + auto-retry + a ping watchdog into a complete WiFi manager, with a state machine on screen and auto-connect from a saved profile

Review questions

Answer on your own first, then open the answer.

  1. ข้อใดเป็นเกณฑ์ผ่านขั้นต่ำของ Capstone (เลือกได้หลายข้อ) (Objective 1)

    1. ไม่ฝัง secret ในไฟล์ส่งสาธารณะ
    2. มีอย่างน้อย 2 FreeRTOS tasks
    3. MQTT หรือ BLE อย่างน้อยหนึ่งเส้น พร้อมรับคำสั่งหรือยืนยันลิงก์
    4. ใช้ทั้ง MQTT และ BLE พร้อมกัน
    Show answer

    Answer: A. ไม่ฝัง secret ในไฟล์ส่งสาธารณะ · B. มีอย่างน้อย 2 FreeRTOS tasks · C. MQTT หรือ BLE อย่างน้อยหนึ่งเส้น พร้อมรับคำสั่งหรือยืนยันลิงก์

    ตาราง Minimum pass criteria ในหัวข้อ 2.3: การใช้ทั้ง MQTT และ BLE เป็นงานต่อยอด ไม่ใช่เกณฑ์ขั้นต่ำ

  2. ต้องการชื่อฟังก์ชัน peripheral ตารางในหัวข้อ 3.1 ให้เปิดที่ใดก่อน (Objective 2)

    1. ชีตของโมดูล 7 (ble-connectivity.md)
    2. บทเรียนโมดูล 1
    3. บทเรียนโมดูล 2 (toolchain)
    4. ชีตของโมดูล 3 (peripheral-api-map.md)
    Show answer

    Answer: D. ชีตของโมดูล 3 (peripheral-api-map.md)

    หัวข้อ 3.1 Where to look first: ชื่อฟังก์ชัน peripheral อยู่ใน M03 cheatsheet

  3. สถานการณ์สาธิต “Command” หมายถึงข้อใด (Objective 3)

    1. build และ flash ใหม่ให้สำเร็จ
    2. ส่งคำสั่งจาก PC หรือโทรศัพท์ (MQTT topic หรือ BLE write) แล้วอุปกรณ์ตอบสนอง
    3. ค่าเซ็นเซอร์ไหลและ LED/UART ทำงานปกติ
    4. เปลี่ยนอุณหภูมิหรือขยับบอร์ดแล้วค่าเปลี่ยน
    Show answer

    Answer: B. ส่งคำสั่งจาก PC หรือโทรศัพท์ (MQTT topic หรือ BLE write) แล้วอุปกรณ์ตอบสนอง

    Demo scenarios ในแล็บ Capstone: Normal, Stimulus และ Command ต่างกันที่แหล่งของการเปลี่ยนแปลง

Cite this lesson

If you teach from this lesson or reuse it in slides or documents, credit it with the text below. If you changed it, add (adapted) after the title.

"Plan the Capstone and Use the Resource Map" from TESA Open Knowledge by the Thai Embedded Systems Association (TESA), https://github.com/tesaiot/tesa-qualification-program, licensed under CC BY-NC 4.0

Thai attribution: "วางแผน Capstone และใช้แผนที่เอกสาร" จาก TESA Open Knowledge โดยสมาคมสมองกลฝังตัวไทย (Thai Embedded Systems Association: TESA) https://github.com/tesaiot/tesa-qualification-program สัญญาอนุญาต CC BY-NC 4.0

Lesson link: https://tesaiot.github.io/tesa-qualification-program/en/courses/firmware-sdk-edge-ai/m08-capstone/l01-capstone-and-resources/

This lesson adapts the source below; keep its credit too.
https://github.com/drsanti/TESAIoT-Courses/blob/287c21814ba8c75f693136616dcd270349a15966/C1/M08/README.md · Original content by Asst. Prof. Dr. Santi Nuratch (ผศ.ดร.สันติ นุราช), KMUTT. Course 1 (C1/) of drsanti/TESAIoT-Courses. TESA funded the work and holds the rights; published here under CC BY-NC 4.0. The upstream repository carries no licence file. Text kept faithful; structure, front matter, quizzes and notes added by TESA Open Knowledge.

Full guide: how to cite TESA

TESA Open Knowledge · © 2026 สมาคมสมองกลฝังตัวไทย (TESA) · CC BY-NC 4.0

Content is licensed CC BY-NC 4.0. Reuse it non-commercially and credit the Thai Embedded Systems Association (TESA) every time. · How to cite TESA