BayBladeカウンター製作

この記事は、mbed Advent Calendar2016 19日目の記事です。

子供の好きな遊びで、BayBladeというコマ回しみたいな遊びがあります。
今回は、それに使う点数カウンターをmbedで作ってみました。
BayBladeというコマは、3層構造になっており、激しくぶつかり合うとバラバラになります。
コマが最後まで回っていたら1点。バラバラにさせた方が2点入るらしいです。
それをシリコンラボのWG3800とGG3700上に実装してみました。

Hardware

  • STK-GG3700
  • STK-WG3800

Drivers

  • LCD Driver EFM32_segmentLCD
  • mbed OS
  • Note : segmentLCDのドライバで、segmentlcd.cの418行目にあるLOW_ENERGY_LOW_FREQUENCYの定義が見つからなかったので、32768を直接指定しています。

Specification

  • PB0 is single count up.
  • PB1 is double count up.
  • LED0 is toggled with PB0, LED1 is toggled with PB1.
  • Ring display and Text Message are based on thread each other.

Image

Here is thread diagram. /media/uploads/ura_pooh/thread.png

Video

Here is short movie for the application image.

Play

Playing Picture /media/uploads/ura_pooh/img_3649.jpg

My Memo

Regarding the "Signal" of OS resource, it takes a time to work correctly.

Import programBayBladeScoreCounter

Original


Please log in to post comments.