Hardware Block Schema
Hardware is built around the STM32F103 microcontroller. CPU timing is derived from an 8MHz crystal; it provides a clock stable enough for an on-chip USB interface to function correctly. An auxiliary low-speed precision 32.768kHz crystal is used for real-time clock (RTC), which is also included in the microcontroller.
Bluetooth modem is implemented by a pre-built commercial module. The first prototype uses OEMSPA310 from connectBlue, later the BTM431 from Laird will be used. The BTM431 has the advantage of lower power consumption and smaller size. These modules implement complete Bluetooth stack beginning with built-in ceramic antenna, and ending with a UART interface. Both modules are controlled via AT-style modem commands (albeit different between the types).
All power is normally delivered from Li-On battery, type Nokia BL-4C. The battery is charged form a Micro-USB connector via a charging controller MCP73831. The whole device runs at 3.3V, which is generated by a low-drop regulator LD59015C33R from a battery voltage. Current battery voltage is monitored by an A/D converter in the microcontroller, so the remaining battery charge can be computed and displayed on screen.
The display is implemented by GDE021A1, a small 3” electrophoretic display with the resolution 172x72 pixels. Communication with the display is via simple SPI-like interface. The display requires a charge pump with a coil and MOSFET.
Besides the display, the rest of human interface comprises of at least three buttons, three LEDs, and a vibrating motor(s) to give tactile notifications.
Software Block Schema
Software is organized in three layers. At the bottom there is a hardware access library from STM. The middle layer is composed mainly of the FreeRTOS operating system and a graphics drawing library u8g, both open-source. FreeRTOS is a simple multi-tasking operating system with pre-emptive scheduling, and with support for simple inter-task communication primitives such as queues and semaphores. The u8g is a drawing library: it is used to draw text and graphics such as lines and circles into a frame-buffer. The frame-buffer is then transmitted to the display.
The top software layer are tasks. The main tasks include a “Bluetooth Modem” task which communicates with a smartphone via Bluetooth, a “Battery” task that monitors battery charge using A/D converter, and a “Display Drawing” task that refreshes the display. Other tasks may be added as needed.
Is possible to add LoraWAN to this device? For example mesh communication emergency?
(like gotenna.com or other)