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
2017.01.16 Embedded system
Search
blue chen
January 16, 2017
Technology
0
88
2017.01.16 Embedded system
blue chen
January 16, 2017
Tweet
Share
More Decks by blue chen
See All by blue chen
RelaJet Caption
iamblue
0
100
The future of hearing device - 聽覺領域新的機會及挑戰
iamblue
2
240
20180918-Digitime 導入MCU設計 催熟智慧語音辨識應用市場
iamblue
0
210
Pixnet hackthon - workshop
iamblue
0
98
AI 人工智慧學校分享
iamblue
0
380
Javascript -Full stack 物聯網開發
iamblue
0
120
MCS Lite 私有雲物聯網開發
iamblue
0
290
Blockchain for IoT 應用
iamblue
1
210
microlattice.js ( World of tech 2016 )
iamblue
1
280
Other Decks in Technology
See All in Technology
Model Mondays S2E02: Model Context Protocol
nitya
0
190
ユーザーのプロフィールデータを活用した推薦精度向上の取り組み
yudai00
0
490
Oracle Audit Vault and Database Firewall 20 概要
oracle4engineer
PRO
3
1.6k
【TiDB GAME DAY 2025】Shadowverse: Worlds Beyond にみる TiDB 活用術
cygames
0
880
ハノーバーメッセ2025座談会.pdf
iotcomjpadmin
0
150
本部長の代わりに提案書レビュー! KDDI営業が毎日使うAIエージェント「A-BOSS」開発秘話
minorun365
PRO
14
2.3k
Amplifyとゼロからはじめた AIコーディング 成果と展望
mkdev10
1
360
新卒3年目の後悔〜機械学習モデルジョブの運用を頑張った話〜
kameitomohiro
0
390
A2Aのクライアントを自作する
rynsuke
1
150
プロダクトエンジニアリング組織への歩み、その現在地 / Our journey to becoming a product engineering organization
hiro_torii
0
110
Amazon Bedrockで実現する 新たな学習体験
kzkmaeda
1
400
登壇ネタの見つけ方 / How to find talk topics
pinkumohikan
3
290
Featured
See All Featured
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
8
660
Testing 201, or: Great Expectations
jmmastey
42
7.5k
The Language of Interfaces
destraynor
158
25k
The Invisible Side of Design
smashingmag
299
51k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Documentation Writing (for coders)
carmenintech
71
4.9k
How to Think Like a Performance Engineer
csswizardry
24
1.7k
Practical Orchestrator
shlominoach
188
11k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.3k
A Tale of Four Properties
chriscoyier
160
23k
Done Done
chrislema
184
16k
Become a Pro
speakerdeck
PRO
28
5.4k
Transcript
Blue
None
None
None
None
IT# Hardware# device## # # # # 近年年來來應⽤用. 服務 .
價值在 這裡發光發熱
IT# Hardware# device## # # # # Javascript# 近年年來來應⽤用. 服務
. 價值在 這裡發光發熱
全端物聯聯網開發 Javascript (Node.js) 不在僅是跑在 server 上 希望他可以跑在你我周遭的任何事物上 javascript 現在可以來來做 native
phone app, native desktop app, browser app, server … etc (投資報酬率較⼤大的選擇)
LinkIt™ Smart 7688 與 Node.js 的邂逅
> npm install express …. ran out of memory …
npm install 耗⽤用極⼤大 memory npm install ⼤大約基礎會耗掉接近 60 mb 的 memory
> opkg install node …. no space … 硬碟只有 16
MB, 只剩 4 mb 可⽤用空間 nodejs 在各平台⼤大約基礎會耗掉 6~8 mb 的 space
• MT7688 • 128MB DDR2 • 32MB Flash • Chip
Antenna (default) • IPEX Ext Antenna • microSD • USB Host • JTAG LinkIt Smart 7688
• MT7688 + ATmega32U4 • 128MB DDR2 • 32MB Flash
• Chip Antenna (default) • IPEX Ext Antenna • microSD • USB Host • JTAG LinkIt Smart 7688 Duo
MT7688& ATMega32U4+ Sensor USB device LinkIt Smart 7688 Duo MT7688&
Sensor USB device LinkIt Smart 7688
MPU ( Microproccess Unit) MCU (MIcrocontroller Unit) 1. ⼯工作時脈幾百MHz 2.
MB 等級的 RAM 3. 含有 MMU 可以跑完整的 Linux 1. ⼯工作時脈 100MHz 以下 2. KB 等級的 RAM 3. Real-time OS : freeRTOS …etc
MT7688& ATMega32U4+ Sensor USB device LinkIt Smart 7688 Duo MT7688&
Sensor USB device LinkIt Smart 7688 MPU, 邏輯端運算 MCU, Real-time control
先從⼀一般基本跑得動 Node.js (javascript) 情境來來談 Nodejs OS Applicaton 想像⼀一下各位現有的 server 如何跑
Node.js(javascript) ? 規格 架構 Linux, openWRT…etc 硬碟⾄至少要 1X mb, RAM 建議⾄至少要 64 mb
MT7688& ATMega32U4+ Sensor USB device LinkIt Smart 7688 Duo MT7688&
Sensor USB device LinkIt Smart 7688 MPU, 邏輯端運算 MCU, Real-time control Node.js 跑在這
關於開發版的外型
總結硬體介⾯面上 7688 擁有三個領域的玩法 USB device Sensor Wifi, OS driver/pkg
Node.js需要有其他的軟體架構擴充 對嵌入式開發板⽽而⾔言 1.PWM, GPIO, I2C …. etc ( libmraa )
2.跟 MCU 端溝通 ( node-serialport, firmata ) 3.USB device ( node-hid )
NodeJS ( v0.12.7 ) node-serialport node-hid Firmata, cylonJS Your application
OpenWRT OS (Wifi, driver) (MCU 溝通) (MCU 溝通) mraa (USB)
7688 OpenWRT OS 完全開源 1. OpenWRT 創始⼈人之⼀一親⾃自操⼑刀使⽤用最新 15.05 架構製作 2.
全部開源在 github 上 3. Upgrade all lib/pkg version
OpenWRT 重點玩法 1. full stack wifi: AP mode, Station mode
2. wifi Router/gateway 玩法 3. 超級豐富的 package, driver community
1. full stack wifi: AP mode, Station mode 2. wifi
Router/gateway 玩法 3. 超級豐富的 package, driver community OpenWRT 重點玩法
7688 Duo 外網網路路孔 外部網路路(有線網路路) <-> 7688 Duo <-> 家⽤用裝置
1. full stack wifi: AP mode, Station mode 2. wifi
Router/gateway 玩法 3. 超級豐富的 package, driver community OpenWRT 重點玩法
OpenWRT package management > opkg update > opkg install 套件名
我們提供 opkg 清單: http://mirror2.openwrt.org/mt7688_v0.9/packages/
ruby, python, nodejs, lua, perl, php, erlang, javm, opencv, ffmpeg,
bluez … 找不到? 來來 contribute 吧!
Demo (mjpg-streamer)
Demo (CD-player) opkg update opkg install kmod-scsi-cdrom opkg install kmod-scsi-core
opkg install kmod-scsi-generic opkg install kmod-fs-isofs
NodeJS ( v0.10.27 ) node-serialport node-hid Firmata, cylonJS Your application
OpenWRT OS (Wifi, driver) (MCU 溝通) (MCU 溝通) mraa (USB)
USB device Sensor Wifi, OS driver/pkg 全部交給 OpenWRT mraa, node-serialport,
firmata node-hid
Demo (keyboard)
USB device Sensor Wifi, OS driver/pkg 全部交給 OpenWRT mraa, node-serialport,
firmata node-hid
MT7688& ATMega32U4+ Sensor ( mcu, mpu溝通) USB device LinkIt Smart
7688 Duo MT7688& Sensor ( libmraa ) USB device LinkIt Smart 7688
如何讓兩兩個晶片溝通? Duo 上玩 Arduino Sensor
node-serialport 接收對話 Firmata 把每個通道都打通 Digital 0~13 PWM i2C Arduino sensor
MT7688& ATMega32U4+ Linkit Smart 7688 Duo 相同的 baudrate下
MPU Atmega32U4 Application 101010000000 node-serialport framework Digital 0~13 PWM i2C
Arduino sensor Firmata 把每個通道都打通 LinkIt Smart 7688 Duo 相同的 baudrate下
Framework 的選擇
firmata 的效能及市場性問題 Duo 上玩 Arduino Sensor
firmata 的效能及市場性的問題 Firmata is not a good pattern MPU Atmega32U4
Application 101010000000 node-serialport framework Digital 0~13 PWM i2C Arduino sensor Firmata 把每個通道都打通 LinkIt Smart 7688 Duo 相同的 baudrate下
Firmata is not a good pattern MPU Atmega32U4 Application 101010000000
node-serialport framework Digital 0~13 PWM i2C Arduino sensor Firmata 把每個通道都打通 LinkIt Smart 7688 Duo 相同的 baudrate下 1 且所有運算都在 MPU 端 很多 sensor 只有 C 不提供 JS parser 2 firmata 的效能及市場性的問題
None
挑戰⼆二如何讓兩兩個晶片溝通 ? firmata ? Firmata is not a good pattern
MPU Atmega32U4 Application node-serialport framework Digital 0~13 PWM i2C Arduino sensor LinkIt Smart 7688 Duo 相同的 baudrate下 運算在 MCU 端處理理好
挑戰⼆二如何讓兩兩個晶片溝通 ? firmata ? Firmata is not a good pattern
MPU Atmega32U4 Application 這是 blue 的指紋 node-serialport framework Digital 0~13 PWM i2C Arduino sensor LinkIt Smart 7688 Duo 相同的 baudrate下 運算在 MCU 端處理理好
讓兩兩顆晶片各司其職
Demo (指紋辨識機)
USB device Sensor Wifi, OS driver/pkg 全部交給 OpenWRT mraa, node-serialport,
firmata node-hid (指紋辨識機) (web cam, CD-player) (keyboard)
mcs.mediatek.com labs.mediatek.com
mcs.mediatek.com
/PEFKTປᆜTVQQPSU 48)8ປಆῘჷ -FWFSBHFBMM"SEVJOPTFOTPS 䌉ࡄ֥≐ڛ↩ⅴ⇼ ൲ᾁӑьၒ ಸၞΆೆਈ㸗ᾲ؍
Make it big with something small
感謝所有參參與 LinkIt smart 7688 專案的所有同仁