Giter Club home page Giter Club logo

wistrio_rak5205's Introduction

rak5205Demos

Introduction

This repository contains simple examples on how to program the STM32L151CB-A processor implemented on the Rak5205 Wis-Trio LoRa board. This board contains a RAK811 LoRa module with the processor and an SX1276 LoRa transceiver. The programs in this repository were written to explore the Wis-Trio board during beta testing. They use peripherals either implemented on the processor chip itself or on the Rak5205 board. All programs have been developed with STM32CubeMX which generates the peripheral initialization code. This code is included into Eclipse with the Ac6STM32 plugin. STM32CubeMX generated code for the ST HAL (Hardware Abstraction Layer) library whose functions are subsequently used in the programs. Once the program has been successfully built it is flashed into the Rak811 processor using an ST-Link V2 debugging probe. In circuit debugging is accomplished using this probe with the help of openocd and gdb. All this can be done from within the Eclipse IDE.

The Blink Demo (RAK5205Blink)

The Rak5205 Wis-Trio board has 2 user programmable LEDs connected to the GPIO port PA12 (LED1) and PB4 (LED2) The Blink program uses a 2 bit binary counter to drive those LEDs. The HAL_Delay function determines the frequency of blinking.

The Timer (Rak5205Timer)

This program also uses the LEDs on the WisTrio board but here the blinking frequency is determined by 2 hardware timers. When the first timer expires it triggers an interrupt at a frequency of 1 Hz. In the callback routine associated with this interrupt the state of the first LED is toggled and the second LED switched on. Then a second 200 ms timer is started and the interrupt generated by this timer will switch the second LED off again.

The board ID (RAK5205BoardID)

Each STM32L151CB-A processor has a unique identifier which is used as device EUI when registering the device with The Things Network (TTN). RAK5205BoardID reads the ID registers and constructs the device EUI as needed by TTN. The ID is printed to the serial port where it can be picked up with a serial terminal emulator like minicom or gtkterm.

GPS (RAK5205GPS)

The Rak5205 WisTrio uses Quectel L76 GNSS module as a GPS receiver. This module is interfaced to the Rak811 processor through its UART3. Quectel L76 sends GPS information in form of NMEA sentences. The program reads and prints these sentences which are in ASCII format. It then interprets each of the sentences and saves the results in dedicated data structures.

GPS with Parser (RAK5205_GPSParse)

The program is based on RAK5205GPS and reads out the Quectel L76 module the same way. However, this program copies each NMEA sentence into a line buffer and parses it, filling C structures. you can switch on "debugging" in which case the parsed information is printed in a humanly readable format,

I2C Scanner (RAK5025_I2CScanner)

The Wis-Trio Rak5205 has a MEMS digital motion sensor and a BME608 barometric presssure sensor on board. These chips are interfaced to the Rak811 chip through I2C. In order to scan the I2C bus for I2C slaves connected I wrote a simple I2C scanner. These program tries to acces an I2C slave on each of the possible I2C addresses and print the address on which it gets an answer.

The LIS3-DH MEMS motion scanner (Rak5205Lis3d)

In this program I try to read the LIS3-DH chip and print motion information. This needs some polishing.

The Real Time Clock (Rak5205RTC)

A demo program for the RTC. At the start of the program the user is asked to enter the current date and time (no line editing yet!). These data are sent to the RTC to set up date and time. In the main loop the RTC is read out every 5 s and date and time are printed.

wistrio_rak5205's People

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.