JM9 XRCU Board 0.1.1
Libraries API Reference
Loading...
Searching...
No Matches
Heading_sensor Class Referenceabstract

Interface of sensors that can find heading. More...

#include <Heading_sensor.h>

Inheritance diagram for Heading_sensor:
Supported_sensor Supported_module General_compass Mpu_6050_dmp Hmc5883l Qmc5883l

Public Member Functions

virtual bool reset_heading ()=0
 Takes the current heading of compass as zero.
 
virtual uint16_t get_heading ()=0
 Gets the heading of compass in degrees.
 

Protected Member Functions

 Heading_sensor ()
 Creates a Heading_sensor object.
 
- Protected Member Functions inherited from Supported_sensor
 Supported_sensor ()
 Creates an object of a supported sensor.
 
- Protected Member Functions inherited from Supported_module
 Supported_module ()
 Creates an object of a supported module.
 

Detailed Description

Interface of sensors that can find heading.

The API of sensors that can find heading.

Author
YH Choi @ JM9

Constructor & Destructor Documentation

◆ Heading_sensor()

Heading_sensor::Heading_sensor ( )
inlineprotected

Creates a Heading_sensor object.

This constructor is private to prevent direct instantiation.

Member Function Documentation

◆ get_heading()

virtual uint16_t Heading_sensor::get_heading ( )
pure virtual

Gets the heading of compass in degrees.

Returns
the heading of compass in degrees [ 0 : 359 ]

Implemented in General_compass, and Mpu_6050_dmp.

◆ reset_heading()

virtual bool Heading_sensor::reset_heading ( )
pure virtual

Takes the current heading of compass as zero.

Returns
true if compass heading is resetted, false otherwise.

Implemented in General_compass, and Mpu_6050_dmp.


The documentation for this class was generated from the following file: