Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CAN bus emulation with FreeRTOS and Qt
Search
Andrei Mukamolau
August 25, 2023
Programming
290
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
CAN bus emulation with FreeRTOS and Qt
Deck from Tallinn DevClub meetup
Andrei Mukamolau
August 25, 2023
Other Decks in Programming
See All in Programming
為什麼你並不需要ViewModel / No, you don't need a ViewModel
lovee
1
490
属人化した知識を、 AIが辿れる地図にする
pkshadeck
PRO
1
170
20260722_microCMSで考える、AI時代のコンテンツ運用設計
yosh1
0
400
ソフトウェアエンジニアにとっての生成AI - 特性を知って使い倒す / generative ai for software enginner
kishida
2
340
【やさしく解説 設計編・中級 #4】ルールの寿命と、システムの年輪
panda728
PRO
2
180
VibeCodingからAgenticWorkflowへ
starfish719
0
450
AWS CDK を「作」ってみた 〜フルスクラッチで見えた CDK の裏側〜 / aws-cdk-from-scratch
gotok365
3
2.8k
ルールを書いて終わらせないハーネスエンジニアリング
yug1224
4
1.9k
【やさしく解説 設計編・中級 #6】良いアーキテクチャとは ~ 一本の登り道の、行き先 ~
panda728
PRO
0
210
GDG Korea Android: 2026 I/O Extended ~ What's new in Android development tools
pluu
0
220
JAWS-UG横浜 #102 AWSサ終供養LT会 成仏できない AWS サービスたち 〜本日、三体供養します〜
maroon1st
0
360
Claude CodeとAgentCore Gatewayを繋ぐ際の認証認可 / Authentication and authorization when connecting Claude Code with AgentCore Gateway
har1101
2
270
Featured
See All Featured
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
650
Art, The Web, and Tiny UX
lynnandtonic
304
22k
So, you think you're a good person
axbom
PRO
2
2.1k
Leo the Paperboy
mayatellez
8
2.1k
Paper Plane (Part 1)
katiecoart
PRO
1
10k
It's Worth the Effort
3n
188
29k
Product Roadmaps are Hard
iamctodd
55
12k
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
430
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
940
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.7k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
1
390
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
460
Transcript
CAN bus emulation with FreeRTOS and Qt Andrei Mukamolau, Dmitriy
Stupak
Contents 1. Why 2. Prerequisites 3. FreeRTOS app 4. Qt
app 5. Demo
Who we are • Automotive software development company • Develop
and design apps • HMI • Android Automotive • Connected cars
Problem • App testing requires real data from the vehicle
• It can be only obtained from the vehicle • We don’t often have needed vehicle available • Testing becomes expensive
Solution • Cheap CAN bus stand for development • Close
to real life technologies • Test apps without vehicle
Hardware used in cars • Sensors • ECUs • Instrument
cluster • Infotainment • CAN bus
CAN bus • Controlled Area Network • 2-way short range
communication • Used in automotive and industrial apps • Simple at first glance • Fast • Robust
Software used in cars • Embedded soft for sensors •
RTOS for ECUs • Embedded Linux for infotainment and instrument cluster • Android Automotive for infotainment
Software used in cars • Embedded soft for sensors •
RTOS for ECUs • Embedded Linux for infotainment and instrument cluster • Android Automotive for infotainment
RTOS • Real Time Operating System • Scheduler runs tasks
for a fixed amount of time • May not have all the features of standard OSes • Critical for safety-related systems
RTOSes • QNX • VxWorks • FreeRTOS
Software used in cars • Embedded soft for sensors •
RTOS for ECUs • Embedded Linux for infotainment and instrument cluster • Android Automotive for infotainment
Embedded Linux • Regular Linux kernel, tuned for specific hardware
• UI can be done in any way • Most popular is Qt
Tech stack • Arduino Uno with FreeRTOS app • Raspberry
Pi with Qt app
FreeRTOS app
Hardware • Arduino Uno • CAN bus shield • Buttons
• Wires • 10 kOhm resistor
Software • PlatformIO • C++ (Arduino) • FreeRTOS
Advantages • Arduino is cheap • Highly configurable • Can
be extended and ported easily • FreeRTOS is flexible enough • Can be used backwards
Problems • Arduino Uno is not so powerful • FreeRTOS
eats up memory if you’re not careful • Jitter
Qt app
What’s Qt • Cross-platform framework • Written in C++ •
Signals and slots • Double licensing • Its own IDE - Qt Creator
Technologies/Tools
Qt Creator
Qt Creator - design editor
Connect can or vcan • Guide • Connect physical CAN
HAT • Install the necessary modules • Set up it with commands • Install can-utils • Turn on the interface • Send frames with can-utils The same for vcan but without physical part
Cross-platform application Windows 10 Raspberry OS macOS
Hiccups • C++ errors are obscure • CAN loopback didn’t
work • Qt libs on Raspberry are not available by default • Qt versions mismatch Win/Mac Qt 6.4.3 Raspberry OS 5.15.5
Demo app workflow • Click on the button on Arduino
• Build CAN signal and send to Raspberry Pi via CAN wires • Receive CAN frame and process it • Visualize it in Qt application
Demo
Q&A
Thanks!