Table of Contents
|
The Firmware section contains finished and working documents pertaining to the detailed design of the Health and Status firmware to be delivered to AMSAT alongside the Maximum Power Point Tracker for potential use in the Fox-2 satellite. The MPPT Health and Status firmware is part of a secondary mission, and is not required for the operation of the Maxium Power Point Tracker.
The purpose of the MPPT Heath and Status firmware is to provide up-to-date information concerning the status of the satellite, such as solar panel voltages, solar panel temperatures, and system current. The information collected by the MPPT Health and Status firmware is requested by the primary microcontroller of the satellite, referred to as the Internal Housekeeping Unit (IHU), and is eventually transmitted to Earth.
Firmware Goals
The MPPT Health and Status firmware has two primary functions:
- Measure analog inputs using an analog to digital converter (ADC)
- Report measurements to the Internal Housekeeping Unit upon request
The MPPT Health and Status firmware also has one secondary function:
- Take measures to protect firmware integrity from random memory errors due to radiation events
A primary goal of the MPPT Health and Status firmware is to remain as hardware-independent as possible, so that it may be easily ported to alternate microcontrollers if necessary. This might be necessary should the selected microcontroller perform poorly in radiation testing (outside the scope of this project), or more functionality is required at a later point.
Another goal of the MPPT Health and Status firmware is to remain as modular as possible, so that major software functionality may be changed with minimal effects on other portions of the firmware.
Microcontroller
The microprocessor selected to run the MPPT Health and Status firmware is the Texas Instruments MSP430FR5739 mixed signal microprocessor. The MSP430FR5739 is currently the highest-end microprocessor in TI’s MSP430 FRAM series, boasting ultra-low power and radiation-resistant ferroelectric memory (FRAM).
The MSP430FR5739 has many useful features relevant to the MPPT Health and Status firmware. Some of the features the MSP430FR5739 has to offer are:
- 16-Bit RISC Architecture
- 16KB FRAM Nonvolatile Memory
- Built in Error Coding and Correction (ECC)
- 81.4 µA/MHz active current consumption
- 14-Channel 10-Bit Analog-to-Digital Converter (ADC) with Internal Reference
- eUSCI with support for UART, I2C, and SPI
- 16-Bit Hardware Cyclic Redundancy Checker (CRC)
- 32-Bit Hardware Multiplier (MPY)
- Memory Protection Unit (MPU)
Until the MPPT PCB is fabricated and populated, the MPPT Health and Status firmware is being developed on the MSP430-EXP430FR5739 Experimenter Board.
Firmware Structure
Every major software function, particularly those requiring a hardware interface, is separated into an independent block, referred to as a "module". This modular structure allows individual modules to be changed or replaced with minimal effect on the rest of the firmware. Information may be passed between the modules only within the main file.
Every module is separated into three portions:
- Interface – Refers to the interface between main and the module. Main may only call a function within a module’s Interface, access to the Library or Target-Specific functions is forbidden. The file containing the module interface, as well as the functions included, has a _INT suffix.
- Library functions – Functions necessary to carry out the operation of the module, but do not need to be visible to Main, and contain no hardware dependence. The file containing the library functions, as well as the functions included, has a _LIB suffix.
- Target-Specific functions – Functions and interrupt service routines that are microcontroller (target)-specific in nature. For example, the I¬2C Slave module’s target-specific functions may involve direct access to the microcontroller’s communications peripheral. For a module with a purely software implementation (no hardware dependence), the Target-Specific functions block may be excluded. The file containing the target-specific functions, as well as the functions included, has a _TGT suffix.
Main Files
main.c
- Description: Handles system startup and module processing.
- Link: main.c
build.h
- Description: Contains code-wide build information. Information contained in build.h is used to determine which target-specific sections of code should be compiled.
- Link: build.h
datatypes.h
- Description: Contains code-wide data type declarations.
- Link: datatypes.h
macros.h
- Description: Contains code-wide macro functions.
- Link: macros.h
Modules
I2C Slave Module (Communications)
- Theory of Operations: (Not yet available)
- Code: modules/I2C_Slave
- Test Plan: (Not yet available)
10-bit ADC Module (Communications)
- Theory of Operations: (Not yet available)
- Code: modules/ADC10
- Test Plan: (Not yet available)
Reference Documents
Home | Planning & Execution | Detailed Design | Build, Test, Document | Photo Gallery