The 2017 Edition of Princeton Satellite Systems’ MATLAB Toolboxes is Now Available!

Version 2017.1 of Princeton Satellite Systems MATLAB toolbox suite is now available! Over 60 new functions were added and updates to dozens of existing functions were made to improve their performance and expand their applications.

In the Aircraft Control Toolbox we added an inlet loss function to compute losses due to shockwaves. Our Unscented Kalman Filter algorithm was updated.

We expanded our support for heliocentric missions. This includes functions to compute solar eclipses in heliocentric orbits, heliocentric sphere of influence, heliocentric trajectory plotting and thermal models for heliocentric spacecraft.

Several new component models were added for use with the CAD modeling functions. These included a liquid apogee Engine, curved tubes and triangular trusses.

We have added all new star identification functions. These are based on a pyramid star identification algorithm using four stars for a definitive match during lost-in-sky conditions. The algorithm provides reliable star identification with almost any star catalog and in any orientation. We have updated image processing algorithms for star centroid determination.

New attitude determination demos and algorithms were added for mixtures of different sensors, such as sun measurements, earth chords and magnetic field measurements. You can compare the performance of extended and Unscented Kalman Filters. A new second order guidance law was added for planetary and lunar landing that provides a simple and effective algorithm for landers.

Contact Princeton Satellite Systems or your distributor for more information!

NEA Scout Toolbox

Near-Earth Asteroid Scout, or NEA Scout is a exciting new NASA mission to map an asteroid and achieve several technological firsts, including being the first CubeSat to reach an asteroid and demonstrate CubeSat technologies in deep space. http://www.nasa.gov/content/nea-scout

NEAScoutCAD

NEA Scout will perform a survey of an asteroid using a CubeSat and solar sail propulsion and gather a wide range of scientific data. NEA Scout will be launched on the first Space Launch System (SLS) launch.

NASA asked Princeton Satellite Systems to develop custom MATLAB software based on the Princeton Satellite Systems Spacecraft Control Toolbox and Solar Sail Module to assist with this mission. We just delivered our first software release to NASA!

The NEA Scout module provides MATLAB scripts that simulate the spacecraft. One, TrajectorySimulation, simulates just the trajectory. It includes a solar sail force model and uses the JPL Ephemerides to compute the gravitational forces on the sail. In addition it can use a 150 x 150 Lunar Gravity model during lunar flybys. It also simulates the orbit dynamics of the target asteroid.

AttitudeSimulation expands on this script. It adds attitude, power and thermal dynamics to the model. A full Attitude Control System (ACS) is included. This ACS uses reaction wheels and optionally cold gas thrusters for control. Momentum unloading can be done with the thrusters our using NASA’s Active Mass Translation (AMT) system that moves one part of the CubeSat relative to the other to adjust the center-of-mass so that it aligns with the system center-of-pressure or adds a slight offset to unload momentum. The control system reads command lists that allows the ACS to perform attitude maneuvers, do orbit changes with thrusters and for the user to change parameters during simulations. It adds the rotational dynamics of the asteroid.

The dynamics of the AMT can be modeled either with a lag on the position or a full multi-body model. Dynamics of the reaction wheels, including a friction model, are included in the simulation. The following are a few figures from a typical simulation.

The first figure shows reaction wheel torques during attitude maneuvers. The ACS uses quaternions as its attitude reference. You can mix reaction wheels and thrusters or use either by themselves for attitude control.

RWATorque

This GUI shows the current command and allows you to control the simulation.

CommandGUI

The Figure GUI lists all figures generated by the simulation. It makes it easy to find plots when you have many, as you do in the attitude simulation.

figui

The Telemetry GUI gives you telemetry from the ACS system. You can easily add more data to the telemetry GUI which can have multiple pages.

Telemetry

This figure shows solar sail pointing during simulations.

SailPlot

The following figure shows the spacecraft with its solar sail deployed. This is built in the CAD script using the  Spacecraft Control Toolbox CAD functions. The sail is 83 meters square.

NEAScoutCADWithSail

The sail is huge but the core spacecraft would sit comfortably on your desk.

If you want more information about our products or our customization services you can email us directly by clicking  Mission Simulation Tools.

SolidWorks Interface in SCT 2015.1

Version 2015.1 will have a new DXF file format exporter to export CAD models built in the Spacecraft Control Toolbox into SolidWorks. The following figure shows the Lunar Lander model in the Spacecraft Control Toolbox CAD window.

LunarLander

Exporting requires just two lines of code:

g = BuildCADModel( 'get model' );
ExportDXF(g,'LunarLander');

Rodger Stephens of Prism Engineering provided SolidWorks models from the DXF file. The file opened in SolidWorks with 7 parts creating an assembly called LunarLander-1.

SolidWorks1

Each part contains planes, sketches, and surfaces.

SolidWorks2

The Spacecraft Control Toolbox has always had DXF import capability but now it can export in a format that is supported by most CAD packages. This will speed the process of going from conceptual designs in the Spacecraft Control Toolbox to detailed designs in SolidWorks and other CAD packages.

Heading to the Moon

We have transitioned our lunar lander work from the Spacecraft Control Toolbox to VisualCommander. Here is a simulation of the lander heading to the moon on the elliptical transfer orbit designed in our Landing on the Moon blog post.

Lunar Transfer

The model was discussed in our Moon Lander Design blog post. We exported it from the Spacecraft Control Toolbox as a Wavefront obj file. The textures were applied by Amazing3D Graphics. Amazing 3D Graphics builds very high quality models with low polygon counts that are ideal for simulation and games.

The attitude control system is our Precision ACS system. In the next few weeks we’ll be adding software to perform mid-course corrections, lunar orbit insertion and lunar landing. Say tuned!

Why Use Princeton Satellite Systems’ MATLAB Toolboxes?

Almost all aerospace organizations have extensive libraries of software for simulation, design and analysis. Why then should they use our MATLAB toolboxes?

I’ve been working in the aerospace business since 1979. My experience includes:

  1. The Space Shuttle Orbiter Dynamics Analysis
  2. The GPS IIR control system design
  3. The Inmarsat 3 control system design
  4. The GGS Polar Platform control system design
  5. The Mars Observer delta-V control system
  6. The Indostar-1 control system
  7. The ATDRS momentum management system
  8. The PRISMA formation flying safe mode guidance

Continue reading

Brand New Free SCT Textbook Companion App for MATLAB

We are happy to announce the release of our free Textbook Companion App for MATLAB (2012b or later).  Based on four Chapter 2 walk through tutorials, the goal is to design a geostationary spacecraft, maintaining an exact orbital position, delivering a -126 dB in the Ku band, and 7 year lifetime.

app_cover

The GUI allows us to look at the results of various gravity models, summing various types of disturbances caused by the sun-angle, a basic geo-synchronous orbit simulation, and then a full simulation that incorporates the orbit, disturbances, and Control and Link parameters. app_results

The app is available on the textbook support page: http://support.psatellite.com/sct/theory_textbook.php.

 

Move it or lose it!

Space is silent. No air, no sound. This must have seemed strange on February 10, 2009, when the satellites “Kosmos-2251” and “Iridium 33” collided, shattering the spacecraft into more than 2,000 pieces of debris. Now, each of these pieces presents a new risk of collision to our satellites in low Earth orbit.

An example collision avoidance scenario between two close-orbiting satellites.

An example collision avoidance scenario between two close-orbiting satellites.

The potential to collide with other satellites or debris is a real and growing concern. As a result, collision detection and avoidance are becoming a critical aspect of satellite operations.

We have worked on new collision avoidance algorithms and strategies for several different projects, including the Prisma formation flying mission which was launched in 2010.

Some of our work in this area was just published in the Journal of Aerospace Information Systems. The paper is “Avoidance Maneuver Planning Incorporating Station-Keeping Constraints and Automatic Relaxation”. You can find it here: http://arc.aiaa.org/toc/jais/10/6

The paper discusses different ways to model the time-varying avoidance region that represents the predicted path of another satellite, and methods for computing minimum-fuel maneuvers that satisfy both the avoidance constraints and station-keeping constraints for the mission. The details may be complex, but the message is simple: “Move it or lose it!”

Installing Eclipse Communications Framework on Indigo

I was researching for an XMPP Eclipse plug-in that I can reuse from one of our RCP application. From my past experience of working with Jabber, I knew there are several XMPP libraries available. http://www.igniterealtime.org/projects/smack/ seemed like a good choice. It has good API and examples. But what I really wanted was an Eclipse plug-in that I can just drop in and reuse as is. Eclipse has plug-ins for just about anything. So there must be one for this too.

That’s when I came as Eclipse Communications Framework.

It seemed like it probably has what I needed at the moment.

Eclipse, especially RCP development, is a maze. That universe is not easy to navigate unless you know something about source bundles and are comfortable with navigating the source bundles.  ECF is no exception. The last modification date on documentation for ECF says: “UNDER CONSTRUCTION 6/17/07”. Not very encouraging.

The first thing is to install ECF onto my Indigo installation. I am sure the steps are similar for later versions too but you have to find that one by yourself and let me know…

Like most plug-ins either you can install it using a zip bundle or from Help—>Install New Software… I generally prefer the later approach.

Install ECF

Follow the usual steps on installation. It will ask you to restart your Eclipse.

Once your Eclipse comes back again. Window–>Open Perspective->Other…, you should see Communications perspective listed there.

You should see two new items on your toolbar, they look like this:

ecf_toolbar

One of them let’s you connect to various IM providers.

ECF comes with several views that you can also open from the usual, Window->Show View->Other..

ECF_views

They are pretty self-explanatory. The one that is of interest to me is the Contacts view.ECF_chatView

When you click on the “Connect to IM Provider” either on the main toolbar or the view toolbar, it will bring up the following provider selection dialog:

ECF_chat_providers

I have only tried XMPP. It will bring up this:

ECF_IMProviders

Enter your credentials and it will bring up your contacts.  The UI is self-explanatory.

Now I need to figure out how to use this plug-in from my RCP application but that should be simple. That’s for another post.

ECF also talks about this really cool feature called DocShare that I want to explore some day to see if I can use it to share our custom views across multiple users.

 

 

Visual Commander satellite training demo

Visual Command is a revolutionary Mac OS X application for data acquisition, hardware control, simulation and visualization. VisualCommander provides a flexible, open environment that allows you to integrate all of your software tools and heritage code into one easy-to-use environment.

Check out this video about using Visual Commander for training satellite operators. This was the original goal of the Air Force SBIR that led to the development of VisualCommander.

If you have any questions please contact us!

Confession: I don’t use Subversion.

The software developers at Princeton Satellite Systems use Subversion to manage revision control.  Usually, we don’t use branches.  We work locally and commit changes to the trunk when we feel that we’ve finished a chunk of code, and we haven’t broken anything.   I had no problem with this until …

About two years ago I ran into a merge conflict  / reversion problem while trying to use Subversion branches in the way that they are intended to be used. I don’t remember the details, but I do remember that the process of fixing things was painful and time consuming.  I never again tried to use an svn branch; I worked locally.   I also wondered if there were a better way.

Google advised me that lots of people had problems with merging and branching while using svn.  And reverting to earlier versions was non-intuitive.  In fact if I remember correctly (and I may not), you can’t really revert in svn.  Rather you merge in a previous version of your work.  So your history becomes <old working version> –> <new broken version> –> <old working version>.   I may be entirely wrong about all that; I really don’t remember very well.

Other people with the same complaints said that they switched to Git, or Mercurial, or Bazaar.   I took a look at all three, and decided to try Git.  The reasons:

  1. Git can be used to manage a Subversion repository
  2. Git can be used off-line for most tasks.
  3. People report that merging goes smoothly
  4. People report that reverting is trivial
  5. People report that branching is trivial

After a period of learning, I learned that all of the above are accurate.  I now rarely do anything directly in svn.   And then later Apple integrated Git into Xcode (although I never use that integration feature) which made me feel a little better about choosing Git over Mercurial or Bazaar.   I now use branches liberally, every day, to try out ideas.  I create branches and destroy branches with abandon, and when I’m ready I merge my work into the “main branch”.  Git keeps all of the things I tried (until I’m ready to ditch them), and I can switch between them instantly and effortlessly.  If I want to see how the application behaved three revisions ago, that’s also effortless and instantaneous, as is returning to my current working state.

I chose not to tell my colleagues about this subterfuge.  The reasons:

  1. Git is not so easy to learn if you are starting from a knowledge svn.  For some reason, the Git developers chose to use the same words (like “checkout”) to mean things that are entirely different from what they mean in svn.  (What’s up with that?)
  2. There’s no reason that anyone has to change a workflow that works for them, especially if there’s a learning curve to endure.
  3. Git is structured very differently than svn.  My brain revolted for a while.
  4. It took me a while to get comfortable with Git, and even now I’m get a little nervous at times.  But then again, I’m nervous at times using Subversion.

I am now a gitophile.  The main advantages from my point of view are:

  1. A copy of the entire repository is kept on your local machine.  (In fact, strictly speaking you don’t need a central repository.)  So you don’t have to be online to use Git (except to push your changes to a central repository if you have one).   
  2. Creating and destroying branches is fast and easy.
  3. Reverting to any previous rev is fast and easy
  4. Revisions can be assigned names at any time, so I don’t need to hunt for revision numbers.
  5. Merging branches seems to work quite smoothly.
  6. Setting up Git locally is a breeze, so it’s easy to use anywhere you want to manage a changing document… for example that novel you are writing about a fictional small engineering company.

Things about Git that I’m not crazy about:

  1. If you get a conflict while updating, it’s not as easy to choose “theirs” as it is with svn.
  2. There are one or two operations whose locations or syntax don’t make sense to me.  The developers could have chosen more wisely.
  3. Git has some tools that are dangerous in that it is possible to screw up and lose data and/or history.  I suppose that’s true of any revision management system.
  4. There is one feature that I call a bug that seems to involve a time-out.  It comes up only in very specific circumstances, but I’ve hit it a couple of times.

I also use Git for some other special activities.   Since I have a desktop and a laptop, I have the issue of being able to start work on one machine and then continue on the other.  There are a number of ways to solve the “sync” problem, including using Subversion to hold intermediate work.  My solution was to set up a Git repository on a local server we have in house (very easy to do) which I use to sync work between the two computers.  When I’m ready, I can then I can update the company’s master Subversion repository from either machine.   I did a similar thing when a colleague and I were the only two contributors  to a small specialized project.