Microbit 硬件架構介紹
文章來至http://tech.microbit.org/hardware/
這篇內容為近期整理介紹,我們盡可能維持正確性,若有發現錯誤,請參考 GitHub here上的數據為左證參考
概述
- Overview 概述
- Getting Started With the micro:bit Hardware 如何開始使用microbit
- Hardware Description 硬件構造及零件說明
- nRF51 Application Processor 藍芽主要IC
- Bluetooth Wireless Communication 藍芽通訊描述
- Low Level Radio Communications 無線通信描述(同樣用2.4Ghz , 但不是用藍芽通訊協議)
- Buttons 按鍵
- Display 顯示屏
- Accelerometer 重力傳感器
- Magnetometer 磁力傳感器
- Temperature Sensing 溫度感測
- General Purpose Input/Output Pins 數字輸入出
- Power Supply 電力供應
- Interface 接口IC 說明
- USB Communications USB 通訊
- Debugging 除錯
- Mechanical 機構
- Links 相關連結
如何開始使用microbit 硬件
Microbit 硬件設計是根據ARM mbed技術所開發的應用IC及相干周邊功能所設計出來的! 另外有一顆接口IC 用來處理USB 接口及拖拉式核心軟件更新法.這接口IC 並未用來鏈接任何周邊.
兩部分關鍵信息可以一窺Microbit 的內部設計:
- 線路圖(schematics), 可以看到主要零件的鏈接方式及設計.
- 參考設計及相關模塊數據(reference design), 這部分的數據可以幫助進一步了解Microbit 的設計及變動性
.
硬件相關說明
nRF51 應用處理器IC
nRF51 應用處理器IC是讓使用者作主要程控的處理器,完整的程序包含了用戶客制及中介層(runtime) 及藍芽協議層(Stack),(譯者注:瀏覽器編譯環境會在用戶程序寫完同時,將這三部分整合完成) 一旦用戶將完整程序(HEX 文件)放在USB 閃存根目錄上,處理器便會直接執行程序代碼。使用者也可對連接在這處理器上的GPIO去做控制. 也可透過 2.4GHz 無線去做相關周邊的控制.
項目 |
說明 |
Model |
|
Core variant |
|
Flash ROM |
256KB |
RAM |
16KB |
Speed |
16MHz |
Debug |
SWD, jlink/OB |
More Info |
藍芽通訊
板子上2.4G無線相關設計提供了對手機平板的藍芽通訊功能
項目 |
說明 |
Stack |
Bluetooth 4.1 with Bluetooth low energy |
Band |
2.4GHz ISM (Industrial, Scientific and Medical) 2.4GHz..2.41GHz |
Channels |
50 2MHz channels, only 40 used (0 to 39), 3 advertising channels (37,38,39) |
Sensitivity |
-93dBm in Bluetooth low energy mode |
Tx Power |
-20dBM to 4dBm in 4 dB steps |
Role |
|
Congestion avoidance |
Adaptive Frequency Hopping |
Profiles |
|
More Info |
無線通信
板子上2.4G無線相關設計提供另外的無線通信協議(Nordic Gazell),這通訊協議已經在不同的程序語言環境可以直接使用,並且可以在多個microbit 裝置中互相傳遞並且群組化(group code ).
項目 |
說明 |
Protocol |
|
Freq band |
2.4GHz |
Channel rate |
1Mbps or 2Mbps |
Encryption |
None |
Channels |
101 (0..100) |
Group codes |
255 |
Tx power |
Eight user configurable settings from 0(-30dbm) to 7 (+4dbm) |
Payload size |
32 (standard) 255 (if reconfigured) |
More Info |
按鍵
Microbit 正面有兩個按鈕,背面有一個。背面的按鍵連接至KL26 接口IC及 nRF51 處理器做系統重制用(reset)
正面的按鍵A 、 B 是可以由使用者去做程控包括了短壓、長壓或是A、B同時按,按鍵A、B 均連接至金手指(edge connector)上的GPIO ,加上電路設計可以做logic 0 或 1值的操作.
項目 |
說明 |
Type |
2 tactile user buttons, 1 tactile system button |
Debounce |
(A & B) software debounced, 54ms period |
Pullup |
(A & B) external 4K7, (System) 10K |
顯示
在板子上有5x5 數組LEDs.做為顯示屏,microbit 是以3x9 數組電路去控制它.並用很高的速度去刷新它。以下暫不翻譯但保留( LED matrix is also used to sense ambient light, by repeatedly switching some of the LED drive pins into inputs and sampling the voltage decay time, which is roughly proportional to ambient light levels.)
項目 |
說明 |
Type |
minature surface mount red LED |
Physical structure |
5x5 matrix |
Electrical structure |
3x9 |
Intensity control |
10 steps |
Intensity range |
TBC |
Sensing |
ambient light estimation via software algorithm |
Sensing Range |
TBC, 10 levels from off to full on |
Colour sensitivity |
red centric, red is 700nm |
重力傳感器(加速度傳感器)
重力傳感器是經由I2C 跟處理器連結,並提供了三軸的感應數據並包含了手勢感測的算法 (like : fall detection, logo-up, logo-down, shake)
項目 |
說明 |
Model |
|
Features |
3 axis, 2/4/8g ranges |
Resolution |
10 bits (0..1023) |
Max output data rate |
800Hz |
On board gestures |
‘freefall’ |
Other gestures |
Other gestures are implemented by software algorithms in the runtime. |
磁力傳感器
磁力傳感器也是透過I2C 跟處理器連結,提供了磁力感測數值,並提供指南針功能, (The compass must be calibrated before use, and the calibration process is automatically initiated by the runtime software – 譯者對這段有些疑慮,暫不翻譯)
項目 |
說明 |
Model |
|
Max update rate |
80Hz |
Full Scale range |
1000uT |
Sensitivity |
0.10uT |
溫度感測
nRF51 處理器提供了板子上的實時溫度感測(Run time ambient temperature sensing ).
項目 |
說明 |
Type |
on-core nRF51 |
Sensing range |
-25C .. 75C |
Resolution |
0.25C steps |
Accuracy |
+/-4C (uncalibrated) |
More Info |
數字輸入輸出(GPIO)
金手指 (edge connector) 上有許多 GPIO 。處理器上有許多的多任務訊號針腳(pin define) ,有些已經設定成GPIO 功能連接至金手指,如何進一步使用這些針腳請參閱 (nRF51 data sheet)
項目 |
說明 |
Rings |
3 large IO rings and two large power rings, 4mm plug and crocodile clip compatible |
GPIO features |
19 assignable GPIO pins |
|
2 are assigned to the on board I2C interface |
|
6 are used for display or light sensing feature |
|
2 are used for on board button detection |
|
1 is reserved for an accessibility interface |
|
19 may be assigned as digital input or digital output |
|
19 may be assigned for up to 3 simultaneous PWM channels |
|
19 may be assigned for 1 serial transmit and 1 serial receive channel |
|
6 may be assigned as analog input pins |
|
3 may be assigned to an optional SPI communications interface |
|
3 may be assigned for up to 3 simultaneous touch sensing inputs |
ADC resolution |
10 bit (0..1023) |
Edge Connector |
|
Pitch |
1.27mm, 80 way double sided. |
Pads |
5 pads, with 4mm holes |
More Info |
電力供應
給microbit的電力,主要是由接口IC透過USB 提供,亦可由電池盒連接器提供,在金手指上亦有電力供應的功能,需要熟悉電路設計的人操作.
項目 |
說明 |
Operating range |
1.8V .. 3.6V |
USB current |
120mA max |
Onboard Peripherals budget |
30mA |
Battery connector |
JST X2B-PH-SM4-TB |
Battery current |
TBC |
Max current provided via edge connector |
90mA |
More Info |
界面
這接口IC提供USB鏈接功能、拖拉式程序刷新(drag and drop flash program)及跟主計算機做序列通訊(serial communication) .
項目 |
說明 |
Model |
|
Core variant: |
|
Flash ROM |
32KB |
RAM |
4KB |
Speed |
16MHz |
Debug capabilities |
SWD |
More Info |
USB通訊
主要意思跟上一段雷同,不做翻譯但保留原文(The micro:bit has an on board USB communications stack, that is built into the firmware of the interface chip. This stack provides the ability to drag and drop files onto the MICROBIT drive in order to load code into the application processor. It also allows serial data to be streamed to and from the micro:bit application processor over USB to an external host computer, and supports the CMSIS-DAP protocol for host debugging of application programs.)
項目 |
說明 |
Connector |
USB micro, MOLEX_47346-0001 |
USB version |
1.1 Full Speed device |
Speed |
12Mbit/sec |
USB classes supported |
|
|
|
More Info |
除錯
譯者尚未做過這段的實務操作所以暫不翻譯先保留原文(The interface processor can be used with special host tools to debug code that is running on the application processor. It connects to the application processor via 4 signal wires. The KL26 interface processor code can also be debuged via it’s integral SWD software debug interface, for example to load initial bootloader code into this processor at manufacturing time, or to recover a lost bootloader.)
項目 |
說明 |
Protocol |
CMSIS-DAP |
Options |
JLink/OB (via different firmware) |
More Info |
機構
我們有提供2D 跟3D CAD 圖文件,這些資料可以用來提供microbit 營銷及項目資料甚至3D printing 的生產制造的圖文件數據.
項目 |
說明 |
Dimensions |
5cm(w) 4cm(h) |
Weight |
5g |
相關連結
Freescale KL26 reference manual
Freescale MMA8652 accelerometer datasheet