Programming language for satellites?

Click For Summary
C, C++, and Ada are the primary programming languages used in satellite systems, with C++ being favored for its safety features despite not being a low-level language. Ada was designed for aerospace applications but has not gained widespread adoption due to a shortage of skilled programmers and support tools. While C is less preferred due to its lack of type safety, it is still utilized in real-time operating systems (RTOS) alongside assembly language. MATLAB/Simulink is often used for spacecraft simulation and guidance, navigation, and control (GNC) design, generating C/C++ code for onboard processors. The Pumpkin Cubesat kit primarily uses the C programming language for its Salvo RTOS.
Biosyn
Messages
114
Reaction score
0
Hello,

What programming languages are used in the majority of satellites? I was thinking it would be C,C++, and Ada because these languages are close to the processor. I'm sure ASM is also used too.
Am I correct? I don't think any satellite uses Java but I could be wrong.
 
Physics news on Phys.org
Biosyn said:
Hello,

What programming languages are used in the majority of satellites? I was thinking it would be C,C++, and Ada because these languages are close to the processor. I'm sure ASM is also used too.
Am I correct? I don't think any satellite uses Java but I could be wrong.
Ada was developed precisely for applications such as this, but it never quite took hold. The biggest problems are lack of good Ada programmers and lack of good support tools. The language of choice nowadays is C++, sans some keywords that are either verboten or whose usage is very restricted (register, volatile, mutable, new, delete, catch, and throw). Closeness to the processor is not a factor. Neither Ada nor C++ is a close to the metal language. The primary reason for choosing Ada and C++ is safety. C isn't used all that much because C is not type safe. It's not a safe language, period. The burden of safety lies solely with the programmer rather than being built into the language.

Under the hood, the RTOS may well have good amounts of C and assembly in it. But I don't think you're asking about the RTOS. You're asking about the software used to operate and control the spacecraft .
 
Although C/C++ are usually used for RTOS but the development (at least the type of dev that a non-software engineer likes) for these systems is done in MATLAB/Simulink. MATLAB has tools for computing euler angles and quaternion math easily which is used extensively in spacecraft simulation and GNC design.

Most Aero's are more interested in the physics than the details of the language, which is why MATLAB/Simulink are preferred over C. They do generate C/C++ code for the processors used on board.
 
I actually designed a satellite as part of a team for my design project. We used STK software. I am not sure what language it had under the hood though.

If you mean the actual language inside the satellite well I have no idea. It would be whatever is the simplest and least complicated. There are also strict guidelines (due to the orbit mechanics) on how much data can actually be sent to the satellite and what ground-stations actually receive. I remember X band was touted a lot and some other band which I forgot.
 
Thanks for the responses!

What programming language is used for the Pumpkin Cubesat kit?
Is it C programming language? I believe that's what the Salvo RTOS is programmed in.
 
Biosyn said:
Thanks for the responses!

What programming language is used for the Pumpkin Cubesat kit?
Is it C programming language? I believe that's what the Salvo RTOS is programmed in.

Yes, it's C. More info here.
 
Due to the constant never ending supply of "cool stuff" happening in Aerospace these days I'm creating this thread to consolidate posts every time something new comes along. Please feel free to add random information if its relevant. So to start things off here is the SpaceX Dragon launch coming up shortly, I'll be following up afterwards to see how it all goes. :smile: https://blogs.nasa.gov/spacex/

Similar threads

Replies
86
Views
2K
Replies
11
Views
558
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 0 ·
Replies
0
Views
1K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 102 ·
4
Replies
102
Views
2K
  • · Replies 23 ·
Replies
23
Views
7K
  • · Replies 9 ·
Replies
9
Views
2K
  • · Replies 38 ·
2
Replies
38
Views
2K