Demo Accelerometer Stream

Stream accelerometer data

API Features Demonstrated

Platforms

This app works on:

Requirements and Prerequisites

This app requires a ZentriOS device, such as an AMW106 Moray evaluation board, connected to an ST LIS3DH three axes linear accelerometer, such as supplied with the ASG001 Zentri Backpack.

Description

This app streams accelerometer data to a webapp accessible via WLAN.

The webapp graphs the accelerometer data.

Instructions for Use

Open a ZentriOS serial terminal to the device. See Getting Started, Opening a ZentriOS Terminal.

This app assumes your ZentriOS device is set up with the credentials to join your local network. If you have not already set up network credentials, on the ZentriOS terminal, run the commands:

network_up -s
save

See the Wi-Fi Command API documentation for network_up and save.

Build, download and run the app.

Connect a WLAN client (smartphone/PC/tablet) to the same network as the ZentriOS device.

Open a web browser and go to http://acc_demo

The browser displays a graph of accelerometer values that change as you move the ZentriOS device.

Source

See:

See also: