Giter VIP home page Giter VIP logo

grs's Introduction

FloripaSat

The Floripa-Sat project consists of an initiative of UFSC researchers and students for the development of a complete space mission. Design and implementation of a complete CubeSat Mission. Oficial website: www.floripasat.ufsc.br

Repository for the firmware source code of the project.
Full documentation at: https://drive.google.com/drive/folders/0B_6IdQdAvIZWfjV5N0RIZ1NmRkpIMmZZOUZ3cXFCRUctVWl3VV8teHJSQmJKM0ZnSXhYalU

1. System Overview

The FloripaSat project consists of a 1U cubesat and groundstation containing the following modules:

1 - OBDH and TT&C PCB [UFSC]
2 - EPS PCB [UFSC]
3 - Payload 1 [TODO: ??]
4 - Payload 2 [TODO: ??]
5 - Payload 3 [TODO: ??]
6 - Antenna Module [Gomspace]
7 - Solar Panels Module [Gomspace]
8 - Mechanical structure (1U Cubesat) [TODO: ??]
9 - Groundstation Hardware and Software [UFSC]

This software repository contains the full source code of items 1, 2 and 9, with details regarding the interface with modules 3, 4 and 5.

TODO: Itens 6 and 7 have any connection/comunication with other modules with any impact in software? (besides RF / power)

2. Code Structure, Toolchain and Guidelines

2.1 Code Structure

This software repository is organized with the following structure:

.  
|--- eps - Firmware for the EPS PCB (1 MSP430 MCU)  
|     |-- [eps_main]     Part# MSP430F249MPMEP  
│     |-- batmon         Part# **TODO** ??  
|  
|  
|--- obdh_ttc - Firmware for the OBDH and TT&C PCB (2x MSP430 MCUs, 2x Radios)  
│      |--- [obdh_ttc_main]    Part# MSP430F6659IPZR  
│      |--- [beacon]           Part# MSP430F6659IPZR  
│      |--- radio_tx           Part# **TODO** ??  
│      |--- radio_rx           Part# **TODO** ??  
|  
|--- docs - Low level software guides and references (full project docs @GoogleDrive). Ie. tips&tricks about code dev. unrelated to the overall project documentation.   
|  
|--- tests - Testing software and code samples  
|  
|--- groundstation - PC Software for the groundstation.   
|  
|--- README.md - (this doc)   

The master branch contains the most up to date and stable software version for the project. Experimental development MUST be done in separated branches and later merged into the master tree (when the development is done and tested). Since each feature should be developed in an individual branch, with a specific and atomic scope, after completed the branch should be deleted. (it's not expected to have ongoing development, regarding multiple features, in a specific branch).

Each item [enclosed in brackes] in the above structure consists of the full firmware source for a single MCU/IC device. All dependencies must be included within and the folder MUST be self suficient for generating a full build for the target device (ie. .bin to be flashed into the hardware). -- even if apart from the rest of this repository.

Each device folder should already contain the additional config files for its specific build system. Ie. MSP430 sources are built with TI's Code Composer Studio, so the folder is already a CCSv6 project folder. The developer can open or import it directly into its own CCSv6 install and edit from its own interface. Unrelated files generated by the tool should be included in the .gitignore file (ie. debug symbols, temporary .hex files, and so).

Although batmon, radio_tx and radio_rx do have internal firmwares, they code is programmed at runtime by other modules. That's why their respective folders only contains configuration instructions and are not bold (whitout a proper source/build config)

.

TODO: Code build is still FAILING! Independent code/modules are merged into master but aren't yet fully integrated.

###2.2 Toolchain

2.2.1 - EPS_MAIN, OBDH_TTC_MAIN, BEACON

The EPS_MAIN, OBDH_TTC_MAIN and BEACON software modules will run on MSP430 devices and are compiled using TI's Code Composer Studio v6 (6.1.2.00015)

Installation Guide for Linux Platform: http://processors.wiki.ti.com/index.php/Linux_Host_Support_CCSv6

Ubuntu 15.10 installation guide:

  • Resolve Dependencies
sudo apt-get update
sudo apt-get install libc6:i386 libx11-6:i386 libasound2:i386 libatk1.0-0:i386 libcairo2:i386 libcups2:i386 libdbus-glib-1-2:i386 libgconf-2-4:i386 libgdk-pixbuf2.0-0:i386 libgtk-3-0 libice6:i386 libncurses5:i386 libsm6:i386 liborbit2:i386 libudev1:i386 libusb-0.1-4:i386 libstdc++6:i386 libxt6:i386 libxtst6:i386 libgnomeui-0:i386 libusb-1.0-0-dev:i386 libcanberra-gtk-module:i386 gtk2-engines-murrine:i386 unzip

If you will be using Grace, also install these:

sudo apt-get install libnss3:i386 libnss3-1d:i386 libnss3-nssdb:i386

Manually download libgcrypt11:i386 and install it: https://launchpad.net/ubuntu/+archive/primary/+files/libgcrypt11_1.5.3-2ubuntu4.2_i386.deb

sudo dpkg -i libgcrypt11_1.5.3-2ubuntu4.2_i386.deb
  • Install CCS
./ccs_setup_6.x.x.xxxxx.bin (replace the x.x.xxxxx with the version number of your installer executable).
  • Install Drivers Go to the /ccsv6/install_scripts folder
sudo ./install_drivers.sh

2.2.2 - RADIO, BATMON

The BATMON and RADIO modules firmware are fully programmed at runtime by obdh_ttc_main and eps_main, so there is not related toolchain to build and program their firmware offline.

3. Use Cases

This section describes the operating scenarios of the satellite, which the software should cover.

3.1 - Normal operation

3.1.1 - Payloads OFF

3.1.1.1 - With groundstation contact

3.1.1.2 - Without groundstation contact

3.1.2 - Payloads ON

3.1.2.1 - With groundstation contact

3.1.2.2 - Without groundstation contact

3.2 - Power Saving mode

3.3 - Hibernating

When hibernating all the components and operations are completely shutdown, except for the ones absolutely mandatory for the cubesat to receive a command from the groundstation and perform some subset of its core functionality (including to restore to normal operation).

Even radio transmission is shutdown in this module, although the TTC will still listen for radio RX and a wake up commands.

3.3.1 - Due internal failure

If a critical failure leads to a state that prevents the the cubesat to perform the other states it will go into this state to preseve the maximum ammount of power and with minimal components enabled (to reduce interference from a damaged module which may be affecting critical systems).

3.3.1 - Due ground command

This mode is mandatory due ITU regulation, in which an external entity (with proper approval / justification) must be able to shutdown the satellite if, for instance, it starts do interfere or polute the RF spectrum in a non planned/approved way (ie. due internal failure).

3.2 - Complete shutdown

No eletronic element is powered up and batteries are completely discharged. Antenna may be open or closed.

4 - Data format

Considerations:

  • Since the maximum packet length transmitted by the radio consists of 150 bytes, this length was used as upper cap to avoid packet fragmentation in the lower communication layer.


          OSI MODEL                 DESCRIPTION                                                 PACKET STRUCTURE 
       EQUIVALENT LAYER                                                                                          
      .--------------.  |  .----------------------------. |  .----------------.-------------.--------.-------------.-----------.--------------.
      |    OSI 7     |  |  | Floripasat Dataframe (FDF) | |  | Start Of Frame | Destination | Source |   Content   | Signature | End Of Frame |
      |              |  |  |----------------------------| |  |----------------|-------------|--------|-------------|-----------|--------------|
      |              |  |  | Short name                 | |  | SOF            | TO          | FROM   | DATA        | CRC       | EOF          |
      | Application  |  |  | Size (Bytes)               | |  | 1 Byte         | 1 Byte      | 1 Byte | 1 to 90     | 1 Byte    | 1 Byte       |
      |              |  |  | Numeric Value (if static)  | |  | 0x7B           |             |        | Bytes       |           | 0x7D         |
      |              |  |  | ASCII Representation       | |  | {              |             |        |             |           | }            |
      '--------------'  |  '----------------------------' |  '----------------'-------------'--------'-------------'-----------'--------------'
                        |                                 |
      ---------------------------------------------------------------------------------------------------------|------------------------------>
                        |                                 |                                                    v
      .--------------.  |  .---------------------------.  |  .------.-------------.---------.------------.-------------.-------------.------.
      |   OSI 3-6    |  |  |       AX.25 (v2.0)        |  |  | Flag | Destination | Source  |  Protocol  | Information | Frame-check | Flag |
      |              |  |  |---------------------------|  |  |      |   Address   | Address | Identifier |    Field    |  Sequence   |      |
      | Network      |  |  | Size (Bytes)              |  |  |------|-------------|---------|------------|-------------|-------------|------|
      | Transport    |  |  |                           |  |  | 1 B  | 7 B         | 7 B     | 1 B        | 6 to 95 B   | 2 B         | 1 B  |
      | Session      |  |  |                           |  |  |      |             |         |            |             |             |      |
      | Presentation |  |  |                           |  |  |      |             |         |            |             |             |      |
      '--------------'  |  '---------------------------'  |  '------'-------------'---------'------------'-------------'-------------'------'
                        |                                 |
      ------------------------------------------------------------------------------------------------------------------|--------------------->
                        |                                 |                                                             v
      .--------------.  |  .---------------------------.  |   .------------.------------.------------.---------.---------------.------------.
      |    OSI 2     |  |  |       CC1125 packet       |  |   |  Preamble  |   Sync     |   Length   | Address |     Data      |   CRC16    |
      |              |  |  |---------------------------|  |   |            |    word    |   Field    |  field  |     Field     |            |
      | Data Link    |  |  | Userguide pg 45           |  |   |------------|------------|------------|---------|---------------|------------|
      |              |  |  |                           |  |   | n x 1B     | max 4 B    | 1 B        | 1 B     | 25 to 114 B   | 2 B        |
      |              |  |  |                           |  |   |            |            |            |         |               |            |
      |              |  |  |                           |  |   |            |            |            |         |               |            |
      '--------------'  |  '---------------------------'  |   '------------'------------'------------'---------'---------------'------------'
                        |                                 |
      ---------------------------------------------------------------------------------------------------------------------------------------->
                        |                                 |
      .--------------.  |  .---------------------------.  |   .-----------------------------------------------------------------------------.
      |    OSI 1     |  |  | Frequency: 437.5 Mhz      |  |   |                                                                             |
      |              |  |  | Modulation: 2GFSK         |  |   |                                                                             |
      | Physical     |  |  |                           |  |   |                                RF Spectrum                                  |
      |              |  |  |                           |  |   |                                                                             |
      |              |  |  |                           |  |   |                                                                             |
      |              |  |  |                           |  |   |                                                                             |
      '--------------'  |  '---------------------------'  |   '-----------------------------------------------------------------------------'
                        |                                 |
                        v                                 v

References

Markdown Syntax - https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet Markdown Editor - https://remarkableapp.github.io/ Git GUI Client - http://www.gitkraken.com/

grs's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

grs's Issues

Build project from source Ubuntu 19.04

I'm trying to build the project from source running the command make -j4 as the documentation says, but I keep getting the following error:

mkdir -p build make BUILD_DIR=/home/kig/Documents/projects/grs/build -C libs make[1]: Entering directory '/home/kig/Documents/projects/grs/libs' make[1]: '/home/kig/Documents/projects/grs/build/libngham.a' is up to date. make[1]: Leaving directory '/home/kig/Documents/projects/grs/libs' make BUILD_DIR=/home/kig/Documents/projects/grs/build -C src make[1]: Entering directory '/home/kig/Documents/projects/grs/src' g++ pkg-config --cflags --libs gtkmm-3.0-std=c++14 -I../ -c main.cpp -o /home/kig/Documents/projects/grs/build/main.o g++pkg-config --cflags --libs gtkmm-3.0-std=c++14 -I../ -c aux.cpp -o /home/kig/Documents/projects/grs/build/aux.o /bin/sh: 1: pkg-config: not found g++pkg-config --cflags --libs gtkmm-3.0-std=c++14 -I../ -c fsat-grs.cpp -o /home/kig/Documents/projects/grs/build/fsat-grs.o /bin/sh: 1: pkg-config: not found g++pkg-config --cflags --libs gtkmm-3.0` -std=c++14 -I../ -c protocol_statistic.cpp -o /home/kig/Documents/projects/grs/build/protocol_statistic.o
/bin/sh: 1: pkg-config: not found
/bin/sh: 1: pkg-config: not found
In file included from aux.cpp:38:
aux.hpp:42:10: fatal error: gtkmm.h: No such file or directory
#include <gtkmm.h>
^~~~~~~~~
compilation terminated.
make[1]: *** [Makefile:19: /home/kig/Documents/projects/grs/build/aux.o] Error 1
make[1]: *** Waiting for unfinished jobs....
main.cpp:38:10: fatal error: gtkmm.h: No such file or directory
#include <gtkmm.h>
^~~~~~~~~
compilation terminated.

make[1]: *** [Makefile:16: /home/kig/Documents/projects/grs/build/main.o] Error 1
In file included from protocol_statistic.cpp:38:
protocol_statistic.h:42:10: fatal error: gtkmm.h: No such file or directory
#include <gtkmm.h>
^~~~~~~~~
compilation terminated.
make[1]: *** [Makefile:31: /home/kig/Documents/projects/grs/build/protocol_statistic.o] Error 1
In file included from fsat-grs.cpp:45:
fsat-grs.h:39:10: fatal error: gtkmm.h: No such file or directory
#include <gtkmm.h>
^~~~~~~~~
compilation terminated.
make[1]: *** [Makefile:22: /home/kig/Documents/projects/grs/build/fsat-grs.o] Error 1
make[1]: Leaving directory '/home/kig/Documents/projects/grs/src'
make: *** [Makefile:15: all] Error 2
`
I'm not really familiar with c++ and I'm probably missing something. Any help would be appreciated!

Initialization of Reed-Solomon decoder

I am looking to add a decoder for FloripaSat-1 to gr-satellites. I am following ngham as a reference to decode the NGHam protocol, but I can't get Reed-Solomon decoding working with some packets transmitted by the satellite.

I have done more investigation and I have seen that in the grs code the Reed-Solomon decoder variables are not initialized properly (see the line below).

void ngham_init_arrays()

I can't even understand why this isn't segfaulting, since variables such as alpha_to are dereferenced during decode_rs_char().

Uplink with a transceiver.

Hi, I was looking the software for floripasat and I only see the uplink option with a SDR device...

There is any way to use a normal ham radio equipment? with a hamlib TX/Freq control?

Thanks!

Application not running on Ubuntu 16.04

After installation, the application does not start from the launcher.
When running from the terminal, the following error is shown:

floripasat-grs: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.22' not found (required by floripasat-grs)

Add Signal tab content

Add signal configuration, audio player and recorder to signal tab right bar (groupbox).

Sample Audio Files?

Could you please make available sample audio files for us to test the beacon & telemetry packet decoders?

Thank you and best wishes for success with your satellite!

-Scott, K4KDR

Edit GUI README.md

Add content to the file, explaining about how to create and edit GUI, how to create .py from .ui.

"Request Data" tab: "Check All" and "Uncheck All" buttons are not working

When clicked, these buttons return, respectively, the following errors:

Traceback (most recent call last): File "grs/src/tabRequest.py", line 165, in checkAll checkboxes = gb[1][0].findChildren(QtGui.QCheckBox) TypeError: 'module' object has no attribute '__getitem__'

Traceback (most recent call last): File "grs/src/tabRequest.py", line 172, in uncheckAll checkboxes = gb[1][0].findChildren(QtGui.QCheckBox) TypeError: 'module' object has no attribute '__getitem__'

Delete "gui/qt/__init__.pyc" file

Delete "gui/qt/__init__.pyc" file at branch "dev".

This file was not deleted before adding *.pyc extension to the .gitignore file. After running the program, the file is modified and the user cannot switch the branch without make a commit with this file.

GNU Radio 3.7 or 3.8?

Would you please let us know what version of GNU Radio should be on the system running this application?

Thank you in advance!

-Scott, K4KDR

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.