Micro:bit board: an introduction
Micro:bit board: an introduction
The objective of this post is to introduce the micro:bit board, a very easy to use ARM-based development board.
(more…)
View On WordPress
seen from Australia
seen from United Kingdom
seen from Italy

seen from United Kingdom
seen from Lithuania
seen from United States
seen from United States
seen from Rwanda

seen from United Kingdom
seen from United Arab Emirates

seen from Canada
seen from Yemen
seen from United States
seen from United States

seen from United States

seen from Malaysia
seen from United States
seen from Argentina

seen from United States
seen from Türkiye
Micro:bit board: an introduction
Micro:bit board: an introduction
The objective of this post is to introduce the micro:bit board, a very easy to use ARM-based development board.
(more…)
View On WordPress
#Nordic #nRF51 Module #Raytac #MDBT40 & MDBT40-P reflow reference(在 Raytac Corporation)
The BBC micro:bit has been made possible by a pioneering partnership between 29 partners including ARM, Barclays, BBC, element14, Freescale, Lancaster University, Microsoft, Nordic Semiconductor, Samsung, ScienceScope, Technology Will Save Us and the Wellcome Trust
Les enfants Anglais vont être initiés à la programmation. Je pense que c’est vraiment une idée géniale et le kit semble super sympa.
English:
The English childrens will be introduced to programming. I think this is a great idea and the kit looks really nice.
Mobilian released 2nd version of Cortex-M production board.
- Erase/Program Cortex-M processors (NORDIC nRF51, nRF52 ...)
- It takes 3 seconds to program one device
- Support max 8-ports.
- Customize Status LED, Power Switch, Functional button(Power, Program)
You can see more detail at http://www.mobilian.biz/#/app/product/jig
nRF51822 based BLE beacon: basics of beacon
IoT, Bluetooth, BLE, Nordic, nRF51, nRF52, nRF5x, WiFi, TI, CC3200, CCS, Solution, Mobilian, Firmware, Atmel, Software
nRF51, nRF52 / Cortex-M Production board 2.0 is now released.
Only 3 seconds can make your device ready!!!
Premières cartes nRF51 pour réseau BLE
Et voici une de mes premières cartes. Il manque encore quelques composants mais la partie Bluetooth est opérationnelle. Je l’ai conçue avec l’aide d’un ami pour aller plus vite, merci à toi si tu lis ça.
Quelques nombres :
20 ms de “ping” (aller + retour) entre 2 cartes connectées directement en Bluetooth. Donc un saut radio fait 10 ms (en fait c’est probablement 7.5 ms ce qui est ma période de connexion mais je n’ai pas assez de précision pour la mesure), c’est la limite du nrf51 donc je suis content car mon algorithme de réseau est rapide.
2 à 3 s c’est le temps pour établir une connexion. Donc un arbre de profondeur 20 va mettre 1 minute à se construire totalement. En prenant une valeur défensive de 10 m par saut, cela fait déjà un belle couverture de 200 m. Il faut donc compter 400 ms de ping avec le bout de l’arbre.
1 chance sur 18 446 744 073 709 551 615 : c’est un entier de 64 bits qui sert de réponse à un challenge basé sur AES pour s’authentifier donc ça devrait pas mal ralentir les personnes mal intentionnées.
10.5 à 16 Ko / s : c’est le débit maximum qu’une branche de l’arbre peut canaliser. C’est aussi pour cela que mon algorithme autorise plusieurs racines. C’est à la racine que le besoin de débit est maximum et en avoir plusieurs permet d’additionner les débits.
English:
And here's one of my first cards. It still lacks some components but Bluetooth is operational. I designed it with the help of a friend to go faster, thank you to you if you're reading this.
A few numbers:
20ms "ping" (go + return) between 2 cards directly connected by Bluetooth. So a radio hop is 10 ms (in fact it is probably 7.5 ms which is my connection period but I do not have enough measurement precision) It’is the limit of nrf51 so I am happy because my network algorithm is fast.
2 to 3 s is the time to establish a connection. So a deep shaft 20 will put 1 minute to build completely. Taking a defensive value of 10 m a jump, it's a beautiful cover of 200 m. We must therefore rely 400ms ping with the end of the tree.
1 chance in 18 446 744 073 709 551 615 : it is a 64-bit integer that serves as a response to a challenge based on AES to authenticate. So bad people should be slow down.
10.5 to 16 Kb / s is the maximum throughput that a branch of the tree can handle. This is also why my algorithm allows multiple roots. It is at the root that the need of speed is highest. So i can speed up with multiple roots that can combine their flows.
nRF51: STLink on MAC OS X
ครั้งที่แล้วได้ลองโปรแกรมผ่าน JLink แล้วคราวนี้มาลองโปรแกรมผ่าน STLink บ้าง
STLink นี้เป็น JTAG ที่เรามักจะเจอได้บ่อยๆในบอร์ด Discovery ของ STM32 ไม่ว่าจะเป็น STM32F0-Discovery, STM32F4-Discovery ซึ่งเป็นบอร์ดราคาประหยัดและหาได้ง่าย โดยบอร์ดเหล่านี้ เราสามารถที่ดึง Jumper เพื่อตัดการเชื่อมต่อระหว่าง STLink ออกจาก Target Processor ได้ ซึ่งตรงนี้ทางผู้ผลิต ทำมาไว้เพื่อที่จะทำให้เรานำ STLink ที่มีอยู่ไปต่อใช้งานกับบอร์ดอื่น
ด้วยความที่ STLink (ส่วนใหญ่ในปัจจุบันเป็น STLinkV2) จะรองรับ SWD ซึ่งเป็นการเชื่อมต่อแบบเดียวกันกับที่ nRF51 ใช้อีกทั้งยังมีระดับแรงดันใกล้เคียงกัน เราจึงสามารถที่จะนำเอา STLink ที่อยู่บนบอร์ด Discovery ไปใช้ต่อกับ nRF51 ได้เช่นกัน
ในครั้งนี้ผมจะยกตัวอย่างการไปเชื่อมกับโมดูล nRF51822 ของบริษัท XUNTONG ขนาดก็ประมาณ 1.8x2.6 cm (ตัวนี้มีที่ใส่แบตเตอรี่ด้วย)
ก็ทำการต่อสาย GND, SWCLK, SWDIO ระหว่างบอร์ด STM32 กับ nRF51 ได้เลย (ในภาย จะต่อ VCC 3 Volt จาก STM32 ไปใช้ด้วย) แล้วทำการ ดึง Jumper 2 ตัวออก (CN2 จะเขียนกำกับว่า STLink / Discovery)
จากนั้นก็เรียกโปรแกรมมาใช้งาน
OpenOCD
โปรแกรมสำหรับติดต่อผ่าน STLink ที่น่าจะใช้สะดวกสุดสำหรับ OS X (รวมทั้ง Linux) ก็คงจะเป็น OpenOCD ซึ่งใน Version ปัจจุบัน มีการทำ config และ script สำหรับ ติดต่อ nRF51 ผ่าน STLink มาไว้แล้วด้วย การติดตั้งก็ผ่าน Homebrew ได้เลย
brew install open-ocd
จากนั้นก็เรียกโปรแกรม
openocd -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl
ถ้าโปรแกรมทำงานได้ตามปกติ โปรแกรมจะเปิด TCP Port ไว้ 3 Port คือ 3333, 4444, 6666 สำหรับ GDB, Telnet, Tcl ตามลำดับ ให้ทำการใช้โปรแกรม telnet เชื่อมต่อเข้าไป
telnet localhost 4444
ในบางครั้ง เราอาจจะเห็นหน้าจอแสดง Polling target nrf51.cpu failed อันอาจจะเกิดจากตัว nRF51 ทำงานต่อเนื่องอยู่จนไม่สามารถคุยกับ SWD ได้ ให้พิมพ์คำสั่ง halt ก่อน เพื่อสั่งให้ nRF51 หยุดทำงาน
จากนั้นเราสามารถที่จะสั่งโปรแกรมไฟล์ลงใน nRF51 ได้ด้วยคำสั่ง flash
flash write_image erase FILE.hex
ซึ่งสามารถเขียนไฟล์ที่เป็น .hex ได้เลย (การระบุ path ของไฟล์ให้ระบุเต็มๆหรือ อ้างอิงกับ folder ที่รับโปรแกรม OpenOCD) โดยไม่จำเป็นต้องระบุตำแหน่งหน่วยความจำที่จะเขียน การลบและเขียนจะใช้เวลาอยู่พอสมควร หลังจากเขียนเสร็จ ก็สั่ง reset เพื่อให้ nRF51 ทำงานตามโปรแกรมได้เลย
ในภาพข้างบน จะเป็นการเขียน SoftDevice ซึ่งเป็น .hex หลังจากที่เขียน SoftDevice แล้ว เราสามารถที่จะสั่งเขียนตัวโปรแกรมของเราตามลงไปได้เลย ตัว script จะลบตำแหน่งที่จะเขียนและเขียนลงไปในตำแหน่งที่ถูกระบุไว้ใน .hex ให้เอง