狠狠撸

狠狠撸Share a Scribd company logo
2015 JSDC Build Anything with JavaScript
JavaScript 速度 x 100 倍
JavaScript 速度破表
JavaScript 速度破表
JavaScript 速度破表
JavaScript 統治了 Web 平台
JavaScript 跑到後端
JavaScript 跑到後端
Raspberry Pi @@
NodeJS 跑到 Raspberry Pi
NodeJS 跑到 Raspberry Pi
Arduino 串接感測器,收集資料上雲端
Internet of Things ( IoT )
能否放到 Arduino 裡面呢?
Internet of Things ( IoT )
Flash Memory 32KB
SRAM 2KB
EEPROM 1KB
Clock Speed 16 MHz
能否放到 Arduino 裡面呢?
能否放到 Arduino 裡面呢?
Arduino Yun (雲)
Arduino Yun (雲)
另一種選擇... Arduino Firmata
設定指定腳位的功能Arduino Firmata
Byte Array 0xF4 0x0D 0x01
0x91 0x10 0x00Byte Array
設定13腳輸出Arduino Firmata
F4
0D
03
91
1000
2015 JSDC Build Anything with JavaScript
目前支援的程式語言Arduino Firmata
2015 JSDC Build Anything with JavaScript
用 Webduino 玩轉 Arduino
- Open Source
- MIT License
- 運行環境
- Browser
- NodeJS
- 通訊方式
- USB / WiFi
- 支援Blockly開發工具
- JS Code generator
NodeJS
Arduino Firmata
Chrome + ChromeApp + Serial Port
Arduino Firmata
Webduino
Blockly
Blockly → JS → Browser / NodeJS
Arduino Firmata
Blockly → JS → Browser / NodeJS
Arduino Firmata
Blockly → JS → Browser / NodeJS
// require('webduino-blockly');
var dht;
boardReady('3qad', function (board) {
dht = getDht(board, 11);
dht.read(function(evt){
window.alert(dht.temperature);
}, 1000);
});
Arduino Firmata
更小更便宜?
行動
電源
更小更便宜?
行動
電源
ESP8266 誕生 !
ESP8266 Features
● 802.11 b/g/n protocol
● Wi-Fi Direct (P2P), soft-AP
● Integrated TCP/IP protocol stack
● +19.5dBm output power in 802.11b mode
● Integrated temperature sensor
● Power down leakage current of < 10uA
● SDIO 2.0, SPI, UART
● STBC, 1×1 MIMO, 2×1 MIMO
● …
直接用 HTML控制 LED
<wa-led id='led' pin='10' state='off'>
</wa-led>
直接用 HTML控制 LED
<wa-led id='led' pin='10' state='on'>
</wa-led>
WebComponents → WS/MQTT → Firmata
<web-arduino id='board' >
<wa-dht id='dht' pin='10'></wa-dht>
</web-arduino>
dht.read( function (evt) {
var show =
"<br>溫度:" + evt.temperature + " ℃
<br> 溼度:" + evt.humidity + " %";
}
, 1000);
WebComponents → WS/MQTT → Firmata
<web-arduino id='board' >
<wa-ultrasonic id='snd' trig='11'
echo='11'></wa-ultrasonic>
</web-arduino>
snd.ping(
function (cm) {
var show = "距離:" + cm + "公分";
}
, 1000);
感测资料可以先经由搁笔2处理再上云端
HTML JS CSS
http
tcp/ip
websocket
mqtt
mqtt
Arduino Firmata
傳輸架構
溫濕度結合 Google Chart 即时显示
Webduino 馬克一號韌體升級啦~
Ver 1.0 Ver 1.5
Webduino 馬克一號 ver 1.5
Webduino 馬克一號 Ver 1.0
Arduino
ESP8266
Webduino 馬克一號 Ver 1.5
Arduino
ESP8266
天上飞的词
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
地上跑的词
地上跑的词
2015 JSDC Build Anything with JavaScript
遙控車的控制方式 - 前輪
遙控車的控制方式 - 後輪
連接小威開發板
轉接訊號線
焊接控制線
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
Web 的威力
Webduino 馬克一號 Ver 1.5
Arduino
ESP8266
其實應該是這樣
Arduino
ESP8266
JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
视频遥控车
相關資源
● UV4L WebRTC
● tracking.js
● raspi-webRTC
● 用JavaScript實現人臉追蹤
電源開關
充電孔
升壓板
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
2015 JSDC Build Anything with JavaScript
前進
前進停止 後退停止
後退
超简单实现叁轴控制
Web 的威力
F4
04
0B
00
F7
自訂命令
自己感測器元件自己包
10月底前釋出
Arduino Firmware
webduino

More Related Content

2015 JSDC Build Anything with JavaScript