CUBEX

A CubeSat Exemplar for Teaching Software Architecture Principles

CUBEX is an exemplar project designed to teach software architecture principles to master's level university students. It bridges the gap between theoretical concepts and practical application, especially within complex domains like software for aerospace systems.

CUBEX utilizes JPL's F' (F Prime) flight software framework within the context of a simulated CubeSat mission focused on orientation monitoring. Students are tasked with developing key flight software components, specifically an Inertial Measurement Unit (IMU) driver and a Payload processing component, while adhering to specified mission requirements. Through this process, students gain practical experience with core software architecture principles, including component-based design, interface definition, telemetry and event handling, and system integration.

CUBEX is presented as a readily available and reusable educational artifact designed to facilitate the teaching of contemporary software architecture principles.

To experiment with CUBEX without deploying to hardware, we provide a VirtualBox image containing all required software. (see instructions) For an overview, see the CUBEX ECSA25 Video walkthrough:



Exercise

CubeSat Mission Overview

Mission Objective

The upcoming CubeSat mission is focused on studying and monitoring the satellite's orientation and movement in space. This will be accomplished through real-time data acquisition from an onboard accelerometer. The CubeSat will continuously track its acceleration in three dimensions (X, Y, Z) to understand its orientation, identify dominant movement axis, and ensure proper operation during its mission.

System Overview

The CubeSat will utilize the FPrime flight software framework to manage its subsystems. The Payload component is central to this mission, handling data from the accelerometer and providing critical telemetry and event data. It also manages onboard indicators (LEDs) to signify the CubeSat's operational state and orientation.

Key Functionalities

  1. Accelerometer Data Acquisition: The Payload component reads acceleration data in the X, Y, and Z axis. This data is used to compute the average acceleration of the last second and determine the dominant movement axis.
  2. Orientation Detection: The system identifies the dominant axis of acceleration and uses this information to assess the CubeSat's orientation in space. A green LED indicates when the Z-axis is dominant, signaling the CubeSat's correct orientation.
  3. Real-Time Feedback: LED indicators provide real-time feedback on the CubeSat's operational status and orientation. The system toggles LEDs based on the state of the CubeSat, ensuring that the system status is always visible.
  4. Event Logging: Changes in the CubeSat's dominant axis are logged as events, allowing mission controllers to track orientation changes over time.

Software Requirements

Requirements are named as Module - Component - Requirement Number.

Based on those goal functionalities the requirements that you will have to accomplise are:

IMU Component

Requirement ID Description
Components-IMU-1 The Components::Imu component shall power on from the beginning.
Components-IMU-2 The Components::Imu component shall communicate with the MPU6050 over I2C.
Components-IMU-3 The Components::Imu component shall produce telemetry and events for the MPU's I2C status.
Components-IMU-4 The Components::Imu component shall produce telemetry of accelerometer data at 100Hz.
Components-IMU-5 The Components::Imu component shall transmit data to other components from output port.

Payload Component

Requirement ID Description
Components-Payload-1 The Components::Payload shall read and store acceleration data from IMU component for the X, Y, and Z axis and produce telemetry.
Components-Payload-2 The Components::Imu component shall be able to produce telemetry and events for the MPU's I2C status.
Components-Payload-3 The Components::Payload shall determine the dominant axis of acceleration based on the computed average values and emit an event.
Components-Payload-4 The Components::Payload shall support the command StartPayload to turn the payload on or off.
Components-Payload-5 The Components::Payload shall toggle the green LED on when the Z-axis is the dominant axis and off otherwise.
Components-Payload-6 The red LED shall start blinking based on the sampling of the accelerometer sensor, when Payload is ON else it remains OFF.
Components-Payload-7 The blue LED shall stay ON when Payload is ON, else it shall stay OFF.

Tutorials

It's recommended to complete the official fprime tutorials before starting:


Tips