The microcontroller used on the Preon32 radio module has a large number of interfaces. These can be used to control both sensors and actuators with different protocols. VIRTENIO offers a VariSen sensor module for the Preon32 Shuttle, which has been developed to fit the radio module and contains a large number of sensors for different measured variables.

In this example for the PreonVM, a digital sensor for acceleration (ADXL345) is operated at the SPI. The sensor has a ChipSelect cable to switch it on. The driver allows a configuration, so that in this example a continuous acquisition of the acceleration is set. In the course of the program, acceleration in a time interval of 1000ms in 3-axes (X, Y, Z) is recorded and output as sensor values.

Copy to Clipboard