A multifunctional and modular Firmware for Multitech's mDot based on ARM mBed provides a widerange of functionality for several Sensors such as MAX44009, BME280, MPU9250, SI1143 and uBlox. It allows you to quickly build a Sensornode that measures specific data with its sensors and sends it via LoRaWAN.

Dependencies:   mDot_LoRa_Sensornode_Flowmeter_impl mbed-rtos mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers MPU9250GyroscopeMessage.h Source File

MPU9250GyroscopeMessage.h

Go to the documentation of this file.
00001 /**
00002  * @file MPU9250GyroscopeMessage.h
00003  *
00004  * @author Adrian
00005  * @date 01.06.2016
00006  *
00007  */
00008 
00009 #ifndef MPU9250GYROSCOPEMESSAGE_H_
00010 #define MPU9250GYROSCOPEMESSAGE_H_
00011 #include <stdio.h>
00012 #include <string>
00013 #include <vector>
00014 #include "SensorMessage.h "
00015 
00016 class MPU9250GyroscopeMessage: public SensorMessage {
00017 public:
00018     MPU9250GyroscopeMessage();
00019     virtual ~MPU9250GyroscopeMessage();
00020 
00021     /**
00022      * Sets the x-axis gyroscope value of the MPU9250GyroscopeMessage
00023      * @param xGyro x-axis Gyroscope value to be stored
00024      */
00025     void setXGyro(float xGyro);
00026 
00027     /**
00028      * Sets the y-axis gyroscope value of the MPU9250GyroscopeMessage
00029      * @param yGyro y-axis Gyroscope value to be stored
00030      */
00031     void setYGyro(float yGyro);
00032 
00033     /**
00034      * Sets the z-axis gyroscope value of the MPU9250GyroscopeMessage
00035      * @param zGyro z-axis Gyroscope value to be stored
00036      */
00037     void setZGyro(float zGyro);
00038 
00039 
00040     /**
00041      * Gets the x-axis gyroscope value from the MPU9250GyroscopeMessage
00042      * @return
00043      */
00044     float getXGyro();
00045 
00046     /**
00047      * Gets the y-axis gyroscope value from the MPU9250GyroscopeMessage
00048      * @return
00049      */
00050     float getYGyro();
00051 
00052     /**
00053      * Gets the z-axis gyroscope value from the MPU9250GyroscopeMessage
00054      * @return
00055      */
00056     float getZGyro();
00057 
00058     /**
00059      * Gets a small LoRaMessage Type Formated String from the  MPU9250GyroscopeMessage.
00060      * This String can later be used for transportation via LoRa
00061      * @return
00062      */
00063     virtual char* getLoRaMessageString();
00064 
00065 private:
00066     std::string loraMessage;
00067     std::vector<std::string> loraMessageId;
00068 
00069     float xGyro;
00070     float yGyro;
00071     float zGyro;
00072 
00073 };
00074 
00075 
00076 #endif /* MPU9250GYROSCOPEMESSAGE_H_ */