Artemis Teensy Flight Software
The software on the Teensy in the Artemis cubesat.
Artemis::Devices::Magnetometer Class Reference

The satellite's magnetometer. More...

#include <artemis_devices.h>

Classes

struct  magbeacon
 The structure of a magnetometer beacon. More...
 

Public Member Functions

bool setup (void)
 Sets up the satellite's magnetometer. More...
 
bool read (uint32_t uptime)
 Reads the satellite's magnetometer. More...
 

Public Attributes

Adafruit_LIS3MDL * magnetometer = new Adafruit_LIS3MDL()
 The core sensor object. More...
 

Detailed Description

The satellite's magnetometer.

Member Function Documentation

◆ read()

bool Artemis::Devices::Magnetometer::read ( uint32_t  uptime)

Reads the satellite's magnetometer.

This method of the Magnetometer class reads the magnetometer's values, stores it in a magbeacon, and transmits that beacon to the ground.

Parameters
uptimeThe time, in milliseconds, since the Teensy has been powered on.
Returns
true The magnetometer has been successfully read and a packet carrying the reading has been queued for transmission.
false The magnetometer could not be read or hasn't been set up.

◆ setup()

bool Artemis::Devices::Magnetometer::setup ( void  )

Sets up the satellite's magnetometer.

This method of the Magnetometer class sets up the I2C connection to the satellite's magnetometer and applies settings to it.

Returns
true The magnetometer has been successfully set up.
false The I2C connection to the magnetometer failed to start.

Member Data Documentation

◆ magnetometer

Adafruit_LIS3MDL* Artemis::Devices::Magnetometer::magnetometer = new Adafruit_LIS3MDL()

The core sensor object.

The Magnetometer class is a wrapper around the Adafruit LIS3MDL magnetometer object.


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