Prototype. Test. Repeat.
At first, our satellite was nothing but words and sketches. They grew into diagrams and calculations. Now, with less than two years until launch, we need to build working prototypes, test them thoroughly and learn from their failures to finally build a reliable satellite.
Our main problem is: Most of us students working at MOVE-II are mechanical engineers but virtually all subsystems of the satellite are electronic devices. With our expertise in electrical engineering being so humble we decided to use premade devices for most of our satellite’s subsystems.
- EPS, the electrical power generation and distribution system, is bought from ClydeSpace.
- CDH, the command and data handling system, is bought from a commercial supplier.
- COM, the communication system, is developed by Rolf-Dieter Klein.
But still there are quite a few systems that we have to build by ourselves.
- ADCS, the attitude determination and control system.
- PL, our Payload consisting of quadruple-junction solar cells provided by Azur Space.
- and lots and lots of test equipment!
One of these pieces of test equipment is the magnetic field simulator that shall aid the development of the detumbling and attitude control algorithms of the ADCS. We want it to simulate a magnetic field in x, y, and z direction so we can mimic a complete orbit. This field is created by three pairs of magnetic coils. The satellite sits in between these coils on an air bearing and tries to use its torquers to control its attitude. The magnetic coils of the test stand are driven by a set of motor drivers connected to a computer which can command the desired magnetic field strength in real-time.
So we needed a board that can control the current of three pairs of coils and receive commands from a computer. We figured that we could use a motor driver IC for supplying a current to the coils and a microcontroller for controlling the motor drivers and communication to the computer. Our first attempt at designing a microcontroller board is shown below in the image on the left.
Later on, we realized that a similar board was already available from ST Micro. So much effort and then you find it was useless right from the start! It is important to adapt and not stick with old designs in these moments so we switched to the STM32F4 Discovery board and started with designing the power stage. From our first calculations we estimated that our magnetic coils had to be driven with a maximum current of 6 A so we selected the Texas Instruments DRV8432 H-bridge driver. It is made for DC or stepper motors. Essentially, the electrical component of a motor is just an array of coils so it is handy for us to simply use a motor driver rather than designing a power stage by ourselves.
There were quite a few sub circuits to be designed like the FTDI chip for communicating via USB, the low pass filters at the output pins of the drivers, the voltage regulators, the hall-effect current measurement chips, and some LEDs. They are not covered here but the final design is available for download at the bottom of this article.
To the left, there is the microcontroller board and the FTDI chip and voltage regulators underneath it. Further to the right there are the motor drivers and the current measurement chips with a large heatsink on top. At the far right, the inductors and capacitors for filtering the driver output are located. The wires to the coils and three 48V power supplies can be inserted into the screw terminals.
The first revision of that board was manufactured in our small workshop but its quality was too poor to get it to work reliably. At least we could start the software development. A few months later we incorporated some changes and had our second revision manufactured at a professional board manufacturer. Soldering the components on this board was a lot easier than with the first revision. After one evening of soldering and two of reworking the board was performing correctly.
We only needed a current control algorithm so we could use some rather inefficient but very easy way of programming: Simulink with the Waijung blockset. You create your algorithm using blocks, click the ‘Build Model’ button and it will translate the Simulink model to C code, compile that code for the target microcontroller and upload it. This approach is well suited for rapid prototyping and can easily be adopted by students who do not know how to write C code.
The current regulation is accurate to 0.01 A and now we are waiting for the completion of our attitude control test stand to begin using it for magnetic field simulation.
There were quite a few lessons we learned from this project for further electronic development
- Adapt your design to new solutions and components as soon as you get to know about them. Do not justify sticking to some old concept just because you already spent a lot of time on it.
- Make notes about errors right when you find them. We did not do so and had to work around a faulty trace at the FTDI chip in both revisions.
- Use enlarged pads. Especially with chips, this makes examining the solder joints a lot easier.
The Design Files of the test bench board and the Simulink models to program them are available for download.