Se ha denunciado esta presentación.
Utilizamos tu perfil de LinkedIn y tus datos de actividad para personalizar los anuncios y mostrarte publicidad más relevante. Puedes cambiar tus preferencias de publicidad en cualquier momento.

YP in space2018_bcn_all_slides_lab_sesssions_x2

614 visualizaciones

Publicado el

Lab Sessions of the IEEE Young Professionals in Space boot camp - UPCBarcelonaTech July 2018

Publicado en: Educación
  • Inicia sesión para ver los comentarios

  • Sé el primero en recomendar esto

YP in space2018_bcn_all_slides_lab_sesssions_x2

  1. 1. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 1 IEEE Young Professionals in Space P1. Introduction and Orbits P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 2 • Objetives of this lab lesson:  “to visually understand satellite orbits” – Physical meaning of the Keplerian orbital parameters – Visualization of ideal orbits with “CubeSat Sim” – Understand the Two‐Line Elements (TLE) – Visualization of real orbits with “Orbitron”
  2. 2. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 3 3 The six orbital Keplerian parameters completely define the shape and  orientation of the orbit, and the position of the secondary body at t=0:  ∙  longitude of the ascending node on the equatorial plane (Ω)  ∙  inclination of the orbital plane with respect to the equatorial plane (Ψ) ∙ argument of the perigee at the ascending node (ϒ) ∙ semi‐major axis of the ellipse (a) ∙ orbit eccentricity (e)  ∙ time of passage at the perigee (tp). Basic theory: Keplerian Parameters P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 4 Software Tool: CUBESAT_SIM • Tool specially designed for YPinSpace 2018 to help to  understand all the basic  satellite concepts. • Developed by the students of Advanced Engineering Project 3Cat‐NXT (fall 2017  and spring 2018 semesters). • Based on some functions of  the Princeton Satellite Toolbox and UPC codes.
  3. 3. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 5 Installing the CUBESAT_SIM… Execute this file. An  installation window will  appear.  You may:  • Accept the conditions • Add the application path  • Generate a desktop  shortcut Follow the steps until the  installation is completed. Advice for the user: Be patient.  This software works correctly but it  may take a few seconds before the  simulations are completed. Do not click  the “Load and Run” button many times  or you will collapse the app.  Software Tool: CUBESAT_SIM P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 6 Initial  parameters Profile menu: allows the user to  upload and save  simulation profiles Load and Run button: click  here to run the simulation Simulations  pop‐up menu CUBESAT_SIM
  4. 4. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 7 1. Spacecraft Definition: it appears an image  of the number of units CubeSat introduced.  1U 12U 3U CUBESAT_SIM P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 8 2. Orbit Animation: 3D representation of the Earth and the satellite  orbiting around it.  Possibility to choose the FOV width and orientation (Nadir, Zenith and  Limb pointing).  Keplerian parameters, FOV angle and  orientation of the Pitch required By clicking on this buttons, the  user can see how the orbit  changes CUBESAT_SIM
  5. 5. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 9 Semi‐major axis: 7100 km Eccentricity: 0 Inclination: 98 Longitude of the A.N: 0 Argument of the Perigee: 0 Time of the Ascending Node: 6AM Pitch: Zenith Semi‐major axis: 7100 km Eccentricity: 0 Inclination: 98 Longitude of the A.N: 90 Argument of the Perigee: 0 Time of the Ascending Node: 6AM Pitch: Zenith CUBESAT_SIM: impact of the longitude of the ascending node P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 10 Semi‐major axis: 7100 km Eccentricity: 0.01 Inclination: 45º Longitude of the A.N: 90º Argument of the Perigee: 0º Time of the Ascending Node: 12PM Pitch: Nadir Semi‐major axis: 7100 km Eccentricity: 0.05 Inclination: 45º Longitude of the A.N: ‐90º Argument of the Perigee: 0º Time of the Ascending Node: 6PM Pitch: Limb CUBESAT_SIM: combined impact of several parameters
  6. 6. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 Semi‐major axis: 10000 km Eccentricity: 0.01 Inclination: 98º Longitude of the A.N: 0º Argument of the Perigee: 0º Time of the Ascending Node: 6AM Pitch: Nadir Semi‐major axis: 15000 km Eccentricity: 0.2 Inclination: 98º Longitude of the A.N: 90º Argument of the Perigee: 0º Time of the Ascending Node: 12PM Pitch: Nadir CUBESAT_SIM: combined impact of several parameters P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 12 3. Ground track: it generates a Lat/Lon map where the sub‐satellite point  can be tracked.  Keplerian parameters and the number of orbits are needed. Semi‐major axis: 7100 km Eccentricity: 0.2 Inclination: 98 Longitude of the A.N: 90 Argument of the Perigee: 0 Time of the Ascending Node: 6AM Number of orbits: 10 CUBESAT_SIM satellite ground‐tracks
  7. 7. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 13 Semi‐major axis: 7100 km Eccentricity: 0 Inclination: 30º Longitude of the A.N: 90º Argument of the Perigee: 0º Time of the Ascending Node: 6AM Number of orbits: 5 Semi‐major axis: 7100 km Eccentricity: 0 Inclination: 45º Longitude of the A.N: ‐90º Argument of the Perigee: 0º Time of the Ascending Node: 6AM Number of orbits: 5 CUBESAT_SIM satellite ground‐tracks P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 14 4. Contact with the Ground Station:  ● Lat/Lon map where the contact with the Ground Station is represented.  ● Amount of time the satellite is in contact with the GS. Keplerian parameters, the number of orbits, and location of Ground Station  are needed. CUBESAT_SIM contacts with ground station
  8. 8. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 15 Semi‐major axis: 7100 km Eccentricity: 0 Inclination: 98 Longitude of the A.N: 0 Argument of the Perigee: 0 Time of the Ascending Node: 6AM  Number of orbits: 10 Ground Station: (41.39, 2.154) @ Barcelona CUBESAT_SIM contacts: polar LEO & mid‐latitude ground station P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 16 Semi‐major axis: 8000 km Eccentricity: 0 Inclination: 45 Longitude of the A.N: ‐90 Argument of the Perigee: 0  Time of the Ascending Node: 6 am  Number of orbits: 5 Ground Station: (41.39, 2.154) CUBESAT_SIM contacts: low inclination LEO & mid‐latitude ground station
  9. 9. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 17 Semi‐major axis: 7500 km Eccentricity: 0 Inclination: 30 Longitude of the A.N: 0 Argument of the Perigee: 0 Time of the Ascending Node: 6 am  Number of orbits: 8 Ground Station: (1.345, 103.85) CUBESAT_SIM contacts: low inclination LEO & equatorial ground station P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 18 Semi‐major axis: 6900 km Eccentricity: 0 Inclination: 90 Longitude of the A.N: ‐50 Argument of the Perigee: 0 Time of the Ascending Node: 6 am  Number of orbits: 4 Ground Station: (1.93, ‐78.52) CUBESAT_SIM contacts: polar LEO & equatorial ground station
  10. 10. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 19 5. Power System: representation of the evolution of the generated power during  the orbitat of the CubeSat. Number of CubeSat units required. Battery charge decreases when satellite enters in eclipse region as it cannot re‐charge them with the solar cells until it is out from there. CUBESAT_SIM: power budget (complements P5) Number of CubeSats units: 3 Semi-major axis: 6600 km Eccentricity: 0.2 Inclination: 0º Longitude of the A.N: 0º Argument of the Perigee: 0º Time of the Ascending Node: 0AM Number of orbits: 2 Percentage of SC: 0.05 P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 20 Basic Theory: the Two‐Line Elements (TLE) The TLE is a data format encoding a list of orbital elements of an Earth‐ orbiting object for a given point in time.  At a particular time, each satellite has a particular TLE. As an example, let’s study the TLE of Molniya 3‐50, a HEO. As we can see, there are three lines that gives us different information.
  11. 11. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 21 To work more comfortable,  we can add a new line in  order to make the study easier. It is better to count numbers, than to count zeros. The first line, called title line, defines the name of the satellite. The following  one (LINE 1), has this format: Basic Theory: the Two‐Line Elements (TLE) P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 22 • Satellite number (columns 03‐07; NORAD number) is a sequential 5‐digit  number assigned by USSPACECOM to all Earth orbiting satellite in order of  identification.  • TLEs have to be updated to predict precisely the position and velocity of a  particular satellite. As TLE get older, accuracy degrades.  • Epoch indicates when the TLEs have been updated.  • In the case above: April 21st, 2018 at 6:54:59. Basic Theory: the Two‐Line Elements (TLE)
  12. 12. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 23 We must pay attention to columns 19 to 32 (18111,2881902), where: ∙ 18 corresponds to 2018 (column 19‐20) ∙ 111 means the 111st day of the year (column 21‐32) ∙ .2881902 is the fractional day from midnight. We must multiply per  24 to extract the hours, remove them, multiply per 60 to get the  minutes, etc (column 21‐32)  And LINE 2 has the following format: The content of this line shows us the six orbital parameters, like the  inclination in degrees, the right ascension of the ascending node also in  degrees, the eccentricity, the argument of the perigee, among others. Basic Theory: the Two‐Line Elements (TLE) P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 24 1. Overview of Orbitron capabilities (can be downloaded from http://www.stoff.pl/). 2. Update TLEs (if not updated in the last 24 h) 3. Study case 1: • Go to Celestrak web site, open the web site and save 3Cat‐2 TLEs: https://www.celestrak.com/cgi‐bin/TLE.pl?CATNR=41732 as 3CAT2.TLE  • Open 3CAT2.TLE • Analyze its orbital parameters (INFO SAT/ORB): • Which type of orbit it is? LEO/MEO/GEO/HEO? • Which is the eccentricity? • Which is the perigee/apogee? • Which is the orbital period? • Which is the separation between consecutive ground tracks? • Run a simulation and comment what happens to the relative position of the Sun  wrt the satellite. Software Tool: ORBITRON
  13. 13. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 25 What type of orbit it is? Please comment which implications this has in the termal and power design of the satellite. • Contact time with a ground station: • In LOCATION, select or create a ground station in Barcelona 2.1835 E, 41.3901 N,  height 0.0 m • In CONFIG EVENTS select satellite elevation equal to 0 , 5 , 10  , 20  . For each  elevation, calculate in EVENTS the upcoming passes, when they will take place,  at which will be the maximum elevation, and which will be the minimum range. Note: you can also use the following web tool:   http://www.n2yo.com/passes/?s=41732#  that allows to compute as well the duration of the pass, and show it on a map. • How many passes exist per day? How many are ascending? How many are  descending? How many are useful? Software Tool: ORBITRON THE FOLLOWING USE CASES CAN BE ANALYZED AS HOMEWORK P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 26 4. Study case 2: • Open GEO.TLE and select HISPASAT 1D satellite • Analyze its orbital parameters (INFO SAT/ORB): o Which type of orbit is it? LEO/MEO/GEO/HEO? o Which is the eccentricity? o Which is the perigee/apogee? o Which is the orbital period? o Which is the separation between consecutive ground tracks? • Run a simulation and comment what happens to the relative position of the Sun  wrt the satellite. o What type of orbit is it? Please comment which implications this has in the  thermal and power design of the satellite. • Contact time with a ground station: o In LOCATION, select or create a ground station in Barcelona 2.1835E, 41.3901N, height 0.0 m o In CONFIG EVENTS select satellite elevation equal to 0. Calculate in EVENTS the  upcoming passes, when they will take place, which will be the maximum  elevation, and which will be the minimum range. What has happened?
  14. 14. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 27 o How long are the contacts? o Note: you can also use the following web tool:  http://www.n2yo.com/?s=27528 o Why the satellite is not really “still” as seen from the Earth? • Open the GEO.TLE file and modify it by increasing the orbit inclination by 5 as  follows (for example): HISPASAT 1D              1 27528U 02044A   18176.72469785 ‐.00000223  00000‐0  00000+0 0  9992 2 27528   0.0196 357.6175 0003414  81.4485  65.6126  1.00271077 57731 HISPASAT 1D 1 27528U 02044A   18176.72469785 ‐.00000223  00000‐0  00000+0 0  9992 2 27528   5.0196 357.6175 0003414  81.4485  65.6126  1.00271077 57736 o Do not forget to change accordingly the CHECKSUM, otherwise the satellite  will be ignored • Run the orbit again and see the ground track. What has happened? From the  satellite operator point of view, which actions will have to be undertaken? • Open GEO.TLE and select HISPASAT 1C, 1D and 1E satellites. What are their  orbital positions, and why? P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 28 5. Study case 3: • Open GPS‐OPS.TLE and select the first GPS satellite in the list. • Analyze its orbital parameters (INFO SAT/ORB): o Which type of orbit it is? LEO/MEO/GEO/HEO? o Which is the eccentricity? o Which is the perigee/apogee? o Which is the orbital period? o Which is the separation between consecutive ground tracks? o Now, select ALL GPS satellites in the list, and in the “radar screen”  (polar plot), count how many satellites are in view for all elevation  angles larger than 15, 30, 45, and 60. Note: each circle is a 15 step, and the outer circle represents the horizon.  Please explain the rationale of the numbers you are getting.
  15. 15. P1. Introduction and Orbits IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 29 6. Study case 4: • Open MOLNIYA.TLE and select MOLNIYA 3‐50 satellite (look for active Molniya satellites in http://www.n2yo.com/database/?q=molniya#results) • Analyze its orbital parameters (INFO SAT/ORB): o Which type of orbit it is? LEO/MEO/GEO/HEO? o Which is the eccentricity? o Which is the perigee/apogee? o Which is the orbital period? o Which is the separation between consecutive ground tracks? o Run a simulation and comment what happens to the relative position of the  Sun wrt the satellite. o What type of orbit it is? What are the implications in the thermal and power  design of the satellite? o Contact time with a ground station:  In LOCATION, select or create a ground station in Moskva (Moscow) 37.6300 E,  55.7525 N, height 150.0 m In CONFIG EVENTS select satellite elevation equal to 5. Calculate in EVENTS  the upcoming passes, when they will take place, at which will be the maximum  elevation, and which will be the minimum range. What has happened? How  long are the contacts?
  16. 16. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 IEEE Young Professionals in Space P2. Space Environment and Thermal Control P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 2 • Objectives of this lab session:  “to conduct the thermal design of a CubeSat” – Understand the Radiation in the Space Environment and how  it affects the Satellite Subsystems – Understanding heat modeling • Black‐body and Sun radiation – How to design satellites that • Avoid extreme temperatures • Avoid large temperature changes • Allow heat exchange
  17. 17. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 3 Basic Theory: Thermal Control ● Control of spacecraft equipment and structure temperatures:  ○ Electronic equipment operational temperature range ○ Thermal distortions and mechanical stress ● Typically, spacecraft temperature range must be between 0C and 50C, as  most of the components used in spacecraft equipment were originally  designed for terrestrial use. ● Some components can withstand larger temperature excursions, but  batteries have more stringent requirements (i.e. T > ~ 2‐4C) ● Heat: generated inside the spacecraft  collected from the environment (Sun & Earth) P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 4 A spacecraft can interact with its  environment by radiation, which  is characterized by:  • Direct solar radiation • Albedo radiation  • Planetary radiation • Radiation from the spacecraft  to deep space Thermal equilibrium: T = constant if Pabsorbed + Pinternal dissipation = Pradiated.  In practice, temperature changes slowly. ● Spacecraft’s temperature is determined by the balance between  absorbed and dissipated heat and radiated heat determines the  spacecraft temperature Basic Theory: Thermal Control
  18. 18. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 5 Basic Theory: Thermal Control • Absorptance = emittance (at a given wavelength) • Radiation from the Sun is absorbed at ~0.5 m • Radiation from the Earth is absorbed at ~10 m • Emission from the Spacecraft is at ~10 m   / http://www.shorstmeyer.com/msj/geo130/EnergyBal.html P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 6 SW Tool: CUBESAT_SIM 6. Isothermal Analysis:  Assumes the whole spacecraft is at the same temperature. Temperature values depend on materials covering the satellite (see table slide #5).  The user must introduce the percentage of each material, the internally dissipated  power, and the number of CubeSat units.  Please, note that:  ● The number of units, as in “1. Spacecraft definition”, is limited to 1U, 2U, 3U,  6U and 12U. ● It must be guaranteed that the sum of all the percentages of the materials is 1. 
  19. 19. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 7 6. Isothermal Analysis:  SW Tool: CUBESAT_SIM P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 8 6. Isothermal Analysis:  SW Tool: CUBESAT_SIM
  20. 20. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 9 6. Isothermal Analysis:  SW Tool: CUBESAT_SIM P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 10 6. Isothermal Analysis:  SW Tool: CUBESAT_SIM
  21. 21. P2. Space Environment and Thermal Control IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 6. Isothermal Analysis:  Now, design the materials at the surface of a 1U cubesat in a: • LEO Sun Synchronous Orbit 6 AM‐6 PM • LEO Sun Synchronous Orbit 9 AM‐9 PM • LEO Sun Synchronous Orbit 12 AM‐12 PM • GEO • HEO (Molniya orbit) So that the temperature of the CubeSat is as stable as possible and within the 0C to 50C temperature range. SW Tool: CUBESAT_SIM
  22. 22. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 1 IEEE Young Professionals in Space P3. On Board Data Handling P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 2 • Objectives of this lab session: “to understand the basic functions of the OBDH system” (and the limitations imposed by the Arduino UNO) ‐ Our OBDH system: an Arduino UNO – getting started ‐ Basic theory ‐ Sensors and variables to control ‐ Memory storage ‐ In future lab sessions the OBC will also be in charge of  controlling the ADCS, COMs etc.
  23. 23. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 3 EPS ADCS OBDH COMMS P/L GROUND SEGMENT RTL-SDR (spectrum monitoring) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 4 Getting started with Arduino Connecting it to a power supply: • Only power. Runs the program load in the previous use. • USB connector to a PC. You can change the program and load  others. Installing the IDE: • An IDE (Integrated Development Environment) is the application  you use to write your own programs, check if it is right to be  understood by the Arduino and load to your Arduino. • Download in the webpage: https://www.arduino.cc/en/Main/Software. 
  24. 24. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 5 Basic theory (i) Parts of a program: Libraries: If you will use a function that is in another file, you must  indicate to Arduino the file including this function.  You must refer to this file as you see in the following example:   #include <library.h> Variable: If you want to store a result to use it later, you need a variable.  There are many types of variables, but the main ones are: • int:  range from‐32768 to 32767 • long int: range from ‐2147483648 to 2147483647 • byte: range from ‐128 to 127 • float: range from 1.2∙10 ‐38 to 3.4∙1038 (in absolute values). To use them, you only need to specify the type (with the word key), the  name and, if you want, an initial value.  e.g.:  int pinMotor=12;  long value;   float temp; P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 6 Parts of a program: Constants: If you want to assign a name to a pin, or use a value that does  not change along the execution, you must create a constant (variable  with a fixed value.   E.g.: const pinLed=8; Setup(): This function is the first one that Arduino runs. There you define  and initialize the variables and everything you need in the program. Loop(): It is the main function in our program. ‘loop()’ is executed  continuously, when it ends it restart with the first line of code. Other functions: If you want to do some tasks in different parts of the  code, you can write them in a function, and then call the function every  time you want. Basic theory (ii)
  25. 25. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 7 Pins: To make a code that works correctly, first, you need to know how the  Arduino pins work.  There are two types of pins, digital and analog.  • Digital pins: This type of pins can be configured as an Input or as an  Output, as you need. They can only read (or write) two levels HIGH  and LOW (related to the power supply) In setup(), you must indicate the pin configuration using the function  pinMode(pinNumber, Mode). e.g.: pinMode(6,OUTPUT); //Using the pin 6 as OUTPUT pinMode(5,INPUT); //Using the pin 5 as INPUT pinMode(pinLed, OUTPUT); //In this case, we use a variable named pinLed to store the number of the pin connected to a led Basic theory (iii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 8 Pins: We can indicate to place a logical ‘0’ (0V) or ‘1’(5V), using digitalWrite(pin, value) digitalWrite(pinLed,HIGH); //Set the pinLed to HIGH (turn on the led) digitalWrite(5,LOW); //Set the pin 5 to LOW Once we have some digital pin configured as input, we can know the level using digitalRead(pin). x=digitalRead(12); //Read the level of x; Basic theory (iv)
  26. 26. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 9 Pins: • Analog pins: These pins can only be configured as input, so you can  only use them to read voltage values. Using analog pins to read, the  input signal is discretized using 10 bits, that corresponds to 210 ‐ 1=1023 levels. • To read we use analogRead(pin); e.g: y=analogRead(9) • When we read, a value from 0 to 1023 is obtained. This range is  corresponds to voltages from 0 V (0) to 5V (1023). Know this, we can  convert the digital value back to the original input voltage: e.g.: volt = analogRead(9)*5/1023; Basic theory (v) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 10 Pins: The more bits we use to discretize the signal, the closer it will look like the analog one, but samples will occupy more in the OBC memory. Basic theory (vi) http://electronicaengeneral.com/?p=679
  27. 27. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 11 Pins:  analogWrite() ? • If you would generate a signal with different levels than HIGH and LOW,  you must use:  analogWrite(pin, level); • The output range is from 0 (0V) to 255 (5V). In fact the output is not a  signal with the amplitude we want, is a signal with amplitude 5V using  Pulse‐Width Modulation (PWM). Low‐pass filtering the PWM signal (i.e.  with an RC circuit) the average value can be obtained. • A PWM is a signal that changes  the width of the pulses (see  image).  • Arduino UNO has 6 digital pins  that can work with PWM.  Basic theory (vii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 12 Sensors and variables to control (i) Sensors We will use some sensors to know the value of different variables 1. A GPS module to know the time and the position of the CanSat 2. Temperature and atmospheric pressure digital sensor (BMP280) 3. A current sensor to know the intensity generated by the solar panel  (INA‐nrhur) 4. An ADC to measure the voltage generated by the solar panel (no  sensor needed, as it is internal to Arduino)
  28. 28. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 13 GPS: How to connect it? • Today’s satellites usually use a GNSS receiver (GPS and/or Galileo) to  know its position. Alternatively, they can also internally propagate the TLEs uploaded from the ground station. • We use a software serial communication, so we need to connect correctly the sensor pins with the Arduino pins. • The connections are:  Vcc → 3,3V  GND → GND  RX → 3  TX → 4 Warning! The GPS RX Pin must be connected to the TX pin of the Arduino  and viceversa.  Follow the above image, not the one on the web (it does not work) Sensors and variables to control (ii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 14 GPS: How to connect it? • To control the sensor, we need to install the following libraries: Activate the Serial bus and begin the comunications with the Arduino: #include <SoftwareSerial.h> • Provides the functions to know the values: #include <TinyGPS++.h> • Then, create the constants and the object that corresponds to the sensor //GPS pins const int RXpin = 4; const int TXpin = 3;  // A TinyGPS++ object and serial connection to the GPS device TinyGPSPlus gps;  SoftwareSerial ss(RXPin, TXPin); • Inside the setup initialize the serial port and the ss: Serial.begin(9600);            ss.begin(9600); Sensors and variables to control (iii)
  29. 29. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 15 GPS: How to read its outputs? • Obtain the location values using the functions provided by the library, e.g.: lati = gps.location.lat();    //Read the latitude longi = gps.location.lng();   //Read the longitude alt = gps.altitude.meters();  //Read the altitude qual = gps.hdop.hdop();       //Quality of the measure hou = gps.time.hour();        //Read the hour of the clock min = gps.time.minute();      //Read the minutes of the clock sec = gps.time.second();      //Read the seconds of the clock qual = gps.hdop.hdop();       //Quality of the measure • These are the variables we want to monitor the CanSat during its flight, but this GPS provides much more information, such as the course of the object and its speed: course = gps.course.deg();    //Course of the spacecraft speed = gps.speed.knots();    //Speed course of the spacecraft in knots Sensors and variables to control (iv) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 16 Temperature and atmospheric pressure sensor (BMP280): How to connect it? • We will use the atmospheric pressure and temperature to estimate the height of the CanSat • We use the SPI bus, so we need to connect correctly the sensor pins with the Arduino pins. • The connections are:  Vcc → 5V  GND → GND  SCL →13  SDA →11  CSB →10  SDO →12 Warning! The “ground” (zero volts reference) must be the same than the GPS module to avoid “grounding” problems (i.e. the zero volt references are different, that is, there is a differential of voltaje between them) Sensors and variables to control (v)
  30. 30. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 17 Temperature and atmospheric pressure sensor (BMP280):  How to measure its outputs? • To control the sensor, we need to install the following libraries: • Activate the SPI bus and then begin the comunications with the Arduino: #include <Wire.h>                 #include <SPI.h> • The library provides the functions to read the values: #include <Adafruit_Sensor.h>      #include <Adafruit_BMP280.h> • Then, create the constants and the object that corresponds to the sensor //BMP280pins #define BMP_SCL  13; #define BMP_SDO  12; #define BMP_SDA  11;  #define BMP_CSB  10; // A BMP280 object for the sensor Adafruit_BMP280 bmp(BMP_CSB, BMP_SDA, BMP_SDO, BMP_SCL); (Remember to initialize the bmp) Sensors and variables to control (vi) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 18 Temperature and atmospheric pressure sensor (BMP280):  How to measure its outputs? • Obtain the atmospheric pressure and temperature values using the functions provided by the library: pres = bmp.readPressure();    //Read the pressure in Pa temp = bmp.readTemperature(); //Read the temperature • Doing some tests, we have observed that the temperature value was 3C higher than the real one. Check if this is the case with your sensor, and note this value in order to calibrate it later by software by subtracting it from all subsequent measurements. tempCalibrate = bmp.readTemperature()‐3; //Read the temperature Sensors and variables to control (vii)
  31. 31. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 19 Voltage: How to measure? • We will measure the voltage and current delivered by the solar panel to  estimate the generated power. • Connect the input signal to an analog pin: e.g. A5. • Read an analogue pin and convert the value in voltage value as explained in basic theory section. To do this, we use a searate function: float readVolt() { int valueV = analogRead(A5);    // Read the value in the analog pin float voldef = (valueV / 1023) * 5; // Convert the value read in the  voltage we have measured return voldef;                  // Return the voltage } Sensors and variables to control (viii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 20 Intensity: How to measure it? • Connect to an analog pin, e.g. A4. • Read an analog pin and convert the value in voltage value as explained in basic theory section. Then, we need to convert this voltage to an appropriate intensity value. To do this, we use a separate function: float readInt() { int valueI = analogRead(A4);         // Read the value in the analog pin float intdef = (valueI / 1023) * 5;  // Convert the value read in a voltage value return intdef/10;  // Return the correct intensit value (relation to measure: 0,1A/1V) } Sensors and variables to control (ix)
  32. 32. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 21 Sensors and variables to control (x) Warning! Take a look to the data sheet of the sensor (link below), measure the value of the welded resistance in the PCB (red arrow) and  estimate the maximum output voltaje, and  the discretization error introduced by the Arduino’s ADC.  Which resistance value must be used to make use of all the available ADC range? https://pdfserv.maximintegrated.com/en/ds/MAX471-MAX472.pdf P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 22 We use the Arduino UNO EEPROM memory: it is an internal memory that  is not erased even if the Arduino is turned off, but it only has 1 kB, so we  must optimize (compress) the data to be stored every time. Which measurements have to be stored? 1. Measurement counter: • It is a counter to index the measurements that are store in the  memory. • We store them completely every time. • 100 measurements (one every 3 s = 300 s = 5 min > maximum flight  dura on) → 7 bits (27 – 1 = 127 > 100) Memory storage (i)
  33. 33. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 23 Which measurements have to be stored? 2. Timer: • GMT (Greenwich Meridian Time) in seconds: First measurement: • 23:59:59 as the maximum hour → 86399 seconds → 17 bits Following measures: • Store the time difference wrt. previous timer. • T < 8 s → 3 bits. Memory storage (ii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 24 Which measurements have to be stored? 3. Latitude & 4. Longitude: • Position of the CanSat in degrees. • To be stored with 4 decimals. First measurement: • LAT:    90.0o → 900000 → 20 bits + sign bit • LON:  180.0o → 1800000 → 21 bits + sing bit Memory storage (iii)
  34. 34. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 25 Memory storage (iv) Which measurements have to be stored? 3. Latitude & 4. Longitude: Following measures: • Store the difference wrt. first value. • Both (LAT & LON) have same differential values.  • If ~9 bits +sign bit:  1 in longitude at this latitude equals to 78 Km  so this difference equals to ±78/(29‐1) km = ± 153 m  1 in latitude equals to 111 km   so this difference is ±110/(29‐1) km = ± 215 m P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 26 Memory storage (v) Which measurements have to be stored? 5. Altitude: • The GPS measures the altitude wrt. the WGS 84 ellipsoid in meters. • First measurements • Start as maximum 2km of height →2000 m →11 bits. • Following measurements • Store the difference wrt. first value. • If rocket reaches 2 km → 2000 m→ 11 bits
  35. 35. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 27 Memory storage (vi) Which measurements have to be stored? 6. Horizontal Dilution Of Precision ‐ Quality: • Measure of the quality of the measurements. • 99.9 is the worst value, position values are probably wrong.  • 1 is the optimum value, position values are accurate. • Stored completely every  me (x 10): from 10 to 999 →10 bits P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 28 Memory storage (vii) Which measurements have to be stored? 7. Temperature: • Temperature measured by BMP 280. • To be stored with only one decimal (‐10.52→‐105) • First measurement: • Start as maximum of 50C → 500C → 9 bits + sign bit • Following measurememts: • Store the difference wrt. first value. • Normally, temperature in the atmosphere decreases at a rate of  6.5C/km. → 65  C → 7 bits + sign bit.
  36. 36. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 29 Memory storage (viii) Which measurements have to be stored? 8. Pressure: • Atmospheric pressure measured by the BMP280. • Units Pa. First measurement: • Pressure at sea level is ~101325 Pa→17 bits Following measurements • Store difference wrt. first value. • Pressure at 1.5 km over the sea level are 84505 Pa. • Difference is 16820 Pa → 15 bits + sign bit P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 30 Memory storage (ix) Which measurements have to be stored? 9. Voltage: • Voltage measured at the output of the solar panel  • Store it completely every time with a precision of 2 decimal places. • Values are between 0 and 5 V. • Maximum value: 5.00 V → 500 → 9 bits.
  37. 37. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 31 Memory storage (x) Which measurements have to be stored? 10. Intensity: • Intensity at the output of the solar panel  • Store them completely every time in mA. • Values are from 0 and 100 mA. • Maximum value: 100 mA → 7 bits. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 32 Taking into account the different amount of bits, the following  memory map is obtained for the first measurement. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 Counter Timer Latitude 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 Latitude Longitude 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 long Altitude Quality Temperature 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 Temp Pressure Voltage Intensity 129 130 131 132 133 134 135 136 In total, we use 17Bytes Intensity EMPTY Memory storage (xi)
  38. 38. P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 33 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 Counter Timer Latitude Longitude Alt 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 Altitude Quality Temperature Pressure 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 Pressure Voltage Intensity EMPTY For the rest of measures we use 12 Bytes of the memory.  Memory storage (xii) P3. On Board Data Handling IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 34 • We use 17B for the first measurement. • Subsequent measurements (coding only differences): 1024‐17=1007 B left, equal 83 blocks of 12B. • Every block equals to 83 measurements  • If the CanSat flight lasts ~4 minutes (240 s), we could store data every  2.9 s before overloading the memory. • In practice, we will measure every 5 s to avoid problems with other  subsystems.  • Start storing just rocket takes off.  • Arduino can detect this moment because it can detect a difference of  pressure, related to a height change. At 10 m height the difference  equals in pressure to 133 Pa. • When program starts, we save in a variable the value of the pressure at  this moment. • Negative numbers are in two’s complement. Before storing convert them to sign + magnitude. Memory storage (xiii)
  39. 39. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 1 IEEE Young Professionals in Space P4. Attitude Determination and Control System P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 2 • Objetives of this lab lesson:  “To design a 1 axis controller based on a motor (used as a  Reaction Wheel) so that the CanSat follows a light source” ‐ Introduction ‐ Background ‐ Hardware ‐ Software • Proportional‐Integral‐Derivative (PID) Control • Control by hysteresis
  40. 40. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 3 Introduction • ADCS (Attitude Determination Control System) is the system  responsible of determining the orientation of the satellite (where it  is pointing) and modify it –if needed‐ to meet some requirements: • When it is necessary to point to a specific direction (e.g. solar  panels, antennas, cameras, for thermal control…) • First of all, it will be implemented using a closed control loop.  • Feedback (from sensors) is needed to adjust the output • The basic design is the following: Feedback allows to calculate the error as  the difference between what we want and  what we have. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 4 Introduction • First of all, attach a magnet with a bit of tape to the bottom of your CanSat estructure hanging from a wire, observe the evolution of the CanSat and answer the following questions:  What is happening?  If instead of a permanent magnet, it was an electromagnet,  what would happen?   What if the sense of the current through the electromagnet was reversed?  What if the current increases or decreases?  If there were 3 magnetorquers in 3 ortogonal directions, what could be achieved?  How to dump these oscillations?
  41. 41. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 5 Now we introduce the components to be used and the functions of the  different subsystems.   ADCS background Sensors (photoresistors) OBC (Arduino Uno) Actuator (rotor of a DC motor) Driver (transistor) Requirements ● All the system must fit inside the CanSat. ● ADCS should be powered from a single 1300 mA∙h battery. ● DC motor speed must be adjustable using a PWM signal from ARDUINO ● ADCS algorithm must be able to estimate the attitude from the readings of several photoresistors (4 analog input pins are available). P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 6 Hardware (i) • Although we need the power supply (EPS) to work, we will assume  that the battery is charged and ready to use. The EPS will be  explained in P5. • The sensors are responsible to get information on the Sun’s position.  • Since the CanSat will be hanging from the top using a wire, only 4  photoresistors separated 90 are needed. Please note that the 3D  model of the CanSat already has the holes for the photoresistors. • In order to detect the resistance change of the photoresistance a  voltage divider per photoresistor will be used. Use your skills to make  aerial connections from the photoresistors and the analog inputs of  the ARDUINO (see figure above).
  42. 42. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 7 7 • To create torque the rotor of a DC motor is used as an actuator.  • The output signal from Arduino must be adapted because it has less  power than the DC motor needs.  • A current driver is implemented with a transistor as shown: Hardware (ii) P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 8 Requirements ● The software must be able to estimate the direction of the light source (“Sun”) form the readings of the 4 sensors. ● The ADCS must orient the solar panel towards the point of highest light intensity (the “Sun”) ● The ADCS response must be as fast as possible, but stable ● Software must be compact as it has to fit with all other tasks and variables in the ARDUINO Software (i)
  43. 43. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 9 • To implement the processing part we have done 2 control systems: PID  Control by hysteresis • The two approaches fulfill the requirements but the control system by  hysteresis cannot take into account how much time the structure is in  wrong position and how fast increases or decreases the error Software (ii) P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 10 Some programming ideas… PID controller Variables declaration,  setup() and how are placed the photoresistors Software (iii)
  44. 44. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 11 • Serial.println() is only for  debugging and traceability  of the system purposes.  • The error is the difference  between value1 and  value2.  • Be careful with the error  sing, as it will depend on  how you have mounted the  motor. Some programming ideas… PID controller Proportional part Software (iv) P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 12 • Approximations of the  derivative and of the  integral terms are needed.  • Computed based on  discrete samples. Some programming ideas… PID controller Integral and Derivative parts Software (iv)
  45. 45. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 13 • Singular behaviors:  PID is used when the space‐ craft is more or less oriented  towards the light.  The motor will turn off and the  CanSat will rotate faster until it  orients towards the light (then  it starts tracking it) Some programming ideas… PID controller  Software (v) P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 14 2 different parts: • One is responsible to estimate the light’s angle of arrival.  • Algorithm to calculate the response to move the DC motor in one  speed or in other. Some programming ideas… Hysteresis control Software (v) • Initial conditions must be created  to be able to move the CanSat in  both directions.  • These initial conditions are fixed  in the setup().
  46. 46. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 15 • In this part the software  decides either to turn left or  to turn right.  • This decision depends on  which quadrant it is pointing  the light, and additionally if  it is oriented or not.  • If is oriented or not is  decided in the getAlpha()  that it is explained next. Some programming ideas… Hysteresis controller P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 16 • getAlpha() detects in which quadrant the light is pointing.  • Two photoresistors are selected, with low impedance (out voltage  of power dividers is high).  • The cases that are impossible are discarded by software. For  example, if between the 2 photoresistors with greatest values there  is a gap of 180 it is impossible to know in which quadrant is  pointing the light. Some programming ideas… Hysteresis controller
  47. 47. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 17 • A distribution of the photoresistors and how getAlpha() decides in  which quadrant the light is pointing. Some programming ideas… Hysteresis controller • The second highest value must be found following the same structure  than the highest one P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 18 This function is used in getAlpha(). It returns true if the difference between  the given variables is less than 20 (degrees):
  48. 48. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 19 • Finally we find the alpha making the average between the two results  of the polynomials which are in the same quadrant as the sun. • The same structure must be followed to complete the rest of the quadrants. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 20 • Afterwards, it is necessary to transform the digital value from the  voltage divider into degrees.  • This has been done experimentally, by trial and error measuring the  digital value from a photoresistors’ voltage divider with differents angles of light incidence.  • Then, a polynomial was used to fit the cloud of points. • Finally, as the function that relates digital value with angle can have 2  solutions, the software filters them in order to be realistic. Some programming ideas… Hysteresis controller
  49. 49. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 21 What you can expect to get… P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 22 7. Full 3D 3U CubeSat Simulation: deploys ADCS Simulator interface ● Most interesting part: the changes of state a satellite suffers during its  lifetime can be observed.  It can be emphasized depending on the type of simulation chosen.  ● It takes a while to execute all the simulation: ● From the general simulation, we obtain 16 figures.  That is the reason why they implement a figure  controller.  CUBESAT_SIM
  50. 50. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 23 Initial parameters and conditions Load and Run button Simulations pop-up menu File menu: has the same purpose as Profile Menu in CUBESAT_SIM CUBESAT_SIM P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 24 Examples of the resulting figures:  CUBESAT_SIM Sample satellite states and transitions  typically an ADCS state is activated in each one Sample ADCS states transition after deployment Try your own changing input parameters in the menu
  51. 51. P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 25 Examples of the resulting figures:  CUBESAT_SIM P4. Attitude Determination and Control System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 26 ● The code in charge of running our interface (CUBESAT_SIM) has been  designed to control all the initial parameters. So, whenever an invalid  value is introduced it appears an error dialog pointing out the mistake  and indicating which is the correct value.  ● All the windows, but the interface are closed when the “Load and Run”  button is selected, to avoid any interference between simulations.  ● When the user wants to close the interface, it appears a message to  assure the closing. CUBESAT_SIM
  52. 52. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 1 IEEE Young Professionals in Space P5. Electrical Power Supply System P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 2 • Objetives of this lab lesson:  “ to design and characterize an Electric Power Supply system” ‐ Understanding and using the different subsystems • Solar Panel • Batteries • Charge and Discharge circuit • Current sensor (MAX471) • Temperature sensor (LM35)
  53. 53. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 3 Introduction: What is an EPS? • System that supplies power to all other subsystems in the satellite. • It also provides telemetry on how much current is being consumed, voltage, temperatures etc. • Batteries must be charged properly and solar panels must be able to deliver as much power as they can. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 4 Before starting Be careful!  • Sensitive components can be harmed easily. • LiIon batteries CANNOT be charged by connecting them directly to  the power supply. There is a serious risk of explosion. Please use  the charger provided instead. If you have doubts, ask your teacher assistant! • In your toolkit box you should have a multimeter and solder tin. • It is really important to make solid welds. If not shortcircuits will be  common.
  54. 54. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 5 Solar Panel Let’s verify these values. You should have one multimeter, the Arduino, and also our current sensor MAX471 to check it. In the next slide you will see how to do it. Component Parameter Symbol Min. Typ. Max. Units Solar Panel Rated Voltage Vmpp 0 6 7 V Peak power PMAX 0 0.6 0.7 W Rated Current I Impp 0 0.1 0.03 A • We will start welding two wires to the positive and negative poles. It can be tricky, so you should try somewhere else first and then use good quantity of tin. • Here we can see some features that are a mix of tested and theoretically. What you should do is a check of each feature. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 6 • In this image we can see how to connect the solar cell and a variable resistor to drive a variable current. • If we want to measure the open circuit voltage we will just measure it connecting it in parallel (resistance removed or set to very large value) • If we want to measure the short circuit current we will connect it in serie (resistance set to minimum value). • Note: the voltage can be measured with one of the analog inputs of the Arduino • Do this test outdoors and compute the values as a function of the angle wrt to normal to the Sun. What happens? Which is the relationship between output power and angle? Solar Panel or tester
  55. 55. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 7 • These two plots show the results using the multimeter: • Left plot: Imax ~90 mA, Vmax ~6.5 V • Right plot: maximum current is obtained at very low voltages, and  maximum voltage is obtained at very low currents.  • The product P=V∙I is the power delivered by the solar cell. Maximum power is somewhere in between Solar Panel P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 8 Batteries • IMPORTANT: The charge and discharge circuit (C&D) charges the Li‐Ion  battery properly, and regulates the output at a constant voltage. • In order to extract as much power as possible at all load conditions an  MPPT is needed (Maximum Peak Power Tracker) • Try to just use the solar panel to supply the Arduino and get it works.  • It can be connected directly to Vin and any GND pin to make it work.  Component Parameter Symbol Min. Typ. Max. Units Battery Parameter Symbol Min. Typ. Max. Units Voltage V 3.6 3.7 433463.9 V Capacity of current I 1200 1300 ‐ mAh Charge time t ‐ 5 ‐ Hours
  56. 56. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 9 Charge & Discharge Circuit Component Parameter Symb ol Min. Typ. Max. Units Charge & Discharge system Input voltage Vin 4.5 ‐ 6.5 V Input current Iin 0 ‐ 1 A Battery input VBin 2.6 3.7 4.3 V Battery output VBout ‐ 4.2 ‐ V Battery current  Discharge IBout 0 3.1 3.5 A Output Voltage Vout ‐ 5.24 ‐ V Output current Iout 0 1.1 2 A • This is our main component and these are its main parameters (mostly from data sheet). • Please respect the minimum/maximum values. • Composed by an MPPT (TBC), a battery charger, and a boost converter P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 10 • Useful and very easy to use circuit. • Weld cables carefully and avoid short circuits between adjacent pads. • We can start checking if it works by connecting the input to a power supply. The output voltage can be adjusted by selecting appropriately some resistances. In our case, it should be 5 V. • Once everything is OK, we are now able to charge our batteries and make the Arduino work. Charge & Discharge Circuit
  57. 57. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 Current sensor ‐ MAX471 • We will start with our current sensor to monitor the current consumption by all circuits. In a satellite EPS there are several PoL (Points of Load) for different subsystems, and in each V, I, T are monitored. • If this resistance is replaced by a 100 K one, the real value of the data acquired must be multiplied by x50. • This image shows all connections. • In the Arduino code we should adjust the value of the scaling factor to get the correct response. With the original 2K resistor is just 1V/A but if we want to measure more precisely we need a larger resistance. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 12 Current sensor ‐ MAX471 • The red circle shows the 2K resistor. We should remove it in order to be able to put a resistor like 100K. • Circuits’ response will be x 50 times more than the original one. So in the Arduino code we will divide by 50. • What we have to do now is change this 2K resistance to put a larger one and make a better use of the Arduino’s ADC range. • Once everything is well connected we can start making our system. So we should start with the solar panel that we will see in the next slide.
  58. 58. P5. Electrical Power Supply System IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 13 LM35‐Temperature sensor • Since batteries are one of the elements with the most stringent temperature ranges, typically a temperatura sensors is located close to the batteries, and when the temperatura decreases under 3‐4C, a heater is turned on automaticlly. • Please do not exchange GND and VS, as the LM35 can get burned. • Once you have connected everything you will have to open the IDE from Arduino and manipulate the value taken in order to get an output/10 in order to get the sensors’ temperature.
  59. 59. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 1 IEEE Young Professionals in Space P6a. Telemetry, Tracking, and Command Systems P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 2 ‐ Introduction ‐ System Description ‐ Link Budget ‐ Hardware devices ‐ Hardware improvements ‐ APRS and Software *: not the right signal modulation (transceiver), and  not the full packet length (buffer limitations) • Objetives of this lab lesson:  “ to learn how to comute a link Budget and to make a  transmission using a pseudo*‐APRS system”
  60. 60. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 3 Introduction • Main objective: To establish a wireless communication between  the Cansat and the ground segment (where we will receive the  data). • The Cansat will send messages through an antenna, including  telemetry and housekeeping data, positioning  (GPS), altitude, and  other data from the sensors. • The COMs system acts as a bridge connecting to other  subsystems. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 4 Link Budget ∙ Objective: Determine the power that the transmitter needs to  transfer the desired data rate. We have to study three aspects:  ∙ Transmitter ∙ Path (distance) ∙ Receiver
  61. 61. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 5 There are some considerations about these formulas: ‐ Free‐space conditions accounts only for the distance losses between  the Tx and the Rx. ‐ It will be the best formula, but not if we test it on ground because of  reflections, diffraction losses, multipath, etc. ‐ If we want to calculate more exactly the losses in a link in which Tx and  Rx are at low‐height, in urban environments (as we are on Campus),  we can use the ITU‐R P.1411‐6 formulas. i.e: the light blue color,  shows that the 99% of the time the losses will be less than 117 dB  around 200 m. Link Budget P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 6 Hardware subsytems (i) ‐ The transmitter and the receiver that will be  used are shown on the right ‐ Operate in an UHF ISM band (433MHz).  ‐ Note: amateur satellite communications  operate in the 435‐438 MHz band ‐ Easy implementation with Arduino and Virtual Wire library. ‐ PCB antenna minimizes the space, but  efficiency is very low. ‐ We will change the antenna by a /4 monopole  to increase the range communication. Tx Rx ‐ Output power = 27dBm at 12V (less, TBD at 5 V) ‐ 3 wires male‐female needed to connect each to the Arduino UNO ‐ Maximum transmission speed of 4.8 kbps ASK  (Data rate can be reduced to increase communications range if needed).
  62. 62. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 7 • A possible connection of the TX/RX to the Arduino UNO board is  shown below.  • There are more options, we can plug the data pin to anyone of the  digital pins.  • Once all devices are connected, we can test them and compute our  own link budget. Move around on campus, and compute the  distance at which packets are lost. Hardware subsytems (ii) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 8 To improve the link budget, we need to improve the gain of the Tx and Rx  antennas.  For the transmitter we can cut the circuit  that feeds the coil (red line) and weld a  /4  wire as a monopole antenna, which is  resonant at that frequency, i.e: at 433 MHz,  we need a wire of  /4= (c/f)/4 = … For the receiver, we will also cut the circuit that feed the coil (red line) and we will weld a cable to connect a Yagi antenna (to be  built in the next lab session). Connect Yagi antenna . Coil (antenna) Hardware subsytems (iii)
  63. 63. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 9 • To  do the Arduino software to control what we are sending, we need  the Virtual Wire library, which can be installed for free from GitHub.  https://github.com/m0/Updated‐Arduino‐VirtualWire‐Library • Then, we include the library in the program window. It should appear  in the first line #include <VirtualWire.h> if it’s all correct. • Now we can use all the functions provided by the library, like the send,  the receive etc. Software (i) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 10 To test the transmitters in the ground, we used these codes Software (ii) Code for Tx Code for Rx
  64. 64. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 11 Open it in the receiver and see if  the messages are being received. Software (iii) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 12 APRS Packaging (i) APRS:Automatic Packet Reporting System  ‐ Amateur radio system used for telemetry, GPS, weather information, etc. ‐ Modulation = AFSK ‐ AX‐25 packet format We will try to pack our data in  this standard format.
  65. 65. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 13 APRS FORMAT Data type ID:  Determines the format  of the remainder of the  data in the Information  field ( 1 byte) APRS Packaging (ii) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 14 ‐ Type of reporting format that suits better for us. ‐ Begins with / or @ indicating this reporting format ‐ Time format to be used: DHM ‐> Day/Hour/Minutes. 151600z  (24h‐zulu format) ‐> Used in military and navigation to  standardize an hour Latitude and longitude Lat:  4903.50N   49degrees3minutes30secNorth From 0 to 90 degrees Lon: 07201.75W 72degrees1minute45secWest From 0 to 180 degrees ‐>Needs one more byte! APRS Packaging (iii)
  66. 66. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 15 Describes the type  of emitter (1 byte) STS shuttle  launched by  the NASA APRS Packaging (iv) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 16 APRS DATA EXTENSIONS 7 bytes. Course in degrees and speed in knots 1 knot = 1,852 km/h.  APRS COMMENTS We will include the altitude, the pressure, temperature, voltage and  current consumption, attitude data, etc. Variable size. APRS Packaging (v)
  67. 67. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 17 TTC (i) 2 packets of 27 bytes 2 different functions because if we put  together both in a function, the arrays  were wrong P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 18 TTC (ii) The GPS gives us ‐75.6657 and we want to  transmit in Degrees/minutes/hundredths  of minutes from South Maximum 27 bytes Convert a float lat to a  degrees/minute/ hundredths of minute
  68. 68. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 19 If it is 05:15:07, and we don’t put the 0, dataA would have saved 5:15:7 To indicate it is zulu time Lon from 0 to 180 format dddmm.hh Lat from 0 to 90 format ddmm.hh S from Shuttle Create an array of chars with the desired format Wait until the whole array is sent to continue (Write in a single line) TTC (iii) P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 20 Converts altitude from meters (GPS) to feet (APRS) Separate a float into a integer.  sprintf can not hold floats Course/speed  from 0‐360 in knots. 1 knot = 1,852 km/h Altitude  in feet Pressure in Pascals. More  than 32,767 = 216= 2bytes  long variable. Current intensity  less than 100 mA TTC (iv)
  69. 69. P6. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © UPC-BarcelonaTech - 2018 21 What do we send (serial monitor ‐ transmitter) and receive (serial monitor ‐ receiver) TTC (v)
  70. 70. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 1 IEEE Young Professionals in Space P6b. Ground Station Design Using the RTL-Software Defined Radio and a Yagi antenna, Decoding APRS packets P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 2 • Objetives of this lab lesson:  “ to build a Yagi antenna, to use the RTL‐SDR to “see” the signals in the frequency domain, and decode APRS packets”
  71. 71. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 3 Ground station. Using the RTL SDR Introduction Antenna Speaker RTL USB Audio PC Virtual Cable Sound Modem APRS IS 32 MAP SDR # AGW TCP/IP:8000 ZADIG P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 4 The magic size of an antena = λ/2 Negative field = all electrons to the left
  72. 72. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 5 Half wave later in time Positive field = all electrons to the right P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 6 Resonance = half wave size = λ/2  We get maximum current and maximum voltage
  73. 73. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 7 A Yagi antenna increases directivity to forward direction only The Yagi antenna theory P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 8 The Yagi for 433 MHz you are going to assemble
  74. 74. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 9 Suport beam:  Wood stick 33 cm long Section:  20 x 30 mm section Reflector:  330 mm brass rod Driven elements:  2 x 175 mm brass rod Director:  300 mm brass rod Coaxial cable:  1,5 meters of RG‐58 cable  Connector:  Solderless TV connector Materials you need P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 10 Azimutal antenna pattern of the 433 MHz Yagi Input VSWR  of the 433 MHz Yagi
  75. 75. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 11 The RTL‐2832 USB TV receiver • Plug the RTL‐2832 in a USB port: Windows installs its own divers and calls the device RTL‐2832‐U or  Bulk‐In interface. • The USB driver of RTL‐2832 must be changed with Zadig program Run Zadig and open Options Select the first option: List All Devices P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 12 • Select there the RTL‐2832  or Bulk‐In Interface • We are going to change the driver in both Bulk‐In Interface 0 and 1 • Check carefully  the selected device: it has to be the RTL2832 or Bulk‐In  Interface 0 If you are sure, click on Replace Driver
  76. 76. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 13 Look down for download section Extract and run to install Soundmodem.exe program  Download the program hs_soundmoodem19.zip: http://uz7.ho.ua/packetradio.htm Soundmodem is the program that decodes de APRS telemetry that will  inform us of the position of the beacons P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 14 Chek for A: AFSK AX‐25 1200bd 
  77. 77. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 15 Open Settings and select Devices P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 16 Select Input Device as CABLE Output (CABLE Output VB Audio Virtual) Check for AGWP Server Port 8000 + Mark Enabled
  78. 78. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 17 ‐ Run the program SDRSharp.exe (no instalation required) ‐ You can download it from the web: https://airspy.com ‐ Select Source as RTL‐SDR / USB P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 18 Open Radio section Select Frequency and Mode WFM
  79. 79. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 19 Check Correct IQ  P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 20 Start the program
  80. 80. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 21 Select Sample Rate as high as possible (see Tools) Ajust Gain between 35 dB and 40 dB as a maximum P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 22 If audio “coughes”, you will have to select a lower Sample Rate
  81. 81. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 23 Download VB Virtual Cable: https://www.vb‐audio.com/Cable/ Extract all files from the ZIP file. RUN VBCABLE_Setup.exe as Administrator then... REBOOT your PC! P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 24 Look for Windows Loudspeaker on bottom right corner of the windows screen (Right hand bottom corner) Select Sounds or Playing devices
  82. 82. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 25 Look for Loudspeaker on Player P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 26 Loudspeaker must be set as Default Play Device
  83. 83. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 27 CABLE  Input as Default Communications Device P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 28 Now, Right Click CABLE on Record devices
  84. 84. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 29 Open Properties of Cable Output  on Record Device P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 30 Tick Listen to this device on:
  85. 85. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 31 Open SDRsharp Audio section Change there Ouput Device to [MME] CABLE input (VB… P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 32 Installation of the APRSIS32  Download and extract the program from the following web site: http://aprsisce.wikidot.com/downloads
  86. 86. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 33 Run the APRSIS32 program  (no installation required) P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 34 Select Configure, then Ports, then New Port
  87. 87. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 35 New Port to be added here Type = AGW Name = Modem, then Create P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 36 Now select the Port Type as TCP/IP IP = 127.0.0.1 Port = 8000 Then OK
  88. 88. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 37 Finally Accept New Port  P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 38 You will see the Modem on the Ports list!!
  89. 89. P6b. Telemetry, Tracking and Command System IEEE Young Professionals in Space, Barcelona July 17-21 2018 - © Radio Club La Salle - 2018 39 • Please recall that our transmitter onboard the CanSat does not use neither exactly the ASPRS format (buffer size limitation), nor the ASF modulation (FSK) instead, but with the RTL you can decode ASPRS packets, ADS and  AIS, listen to the radio, and much more! • In the next two lab sessions you will integrate your CanSat, and decide the 5 finalist that will get a free launch tomorrow… • You are all welcome to come with your RTLs, ASK receivers, laptops, and  Yagi antennas to see the launch of your mates, track their telemetry… and  have fun all together! • Enjoy your introduction to the radio and to spacecraft system engineering!
  90. 90. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 IEEE Young Professionals in Space P7. Final CanSat Integration P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 2 Objectives of this lab session 1. Introduction 2. Pieces 3. Assembly 3.1 Assembling the CanSat without motor 3.2 Assembling the CanSat with motor
  91. 91. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 3 1. Introduction Every piece is introduced and it is  explained how to fit them in their place. The CanSat measures 115 mm x 65 mm.  It has to include an arduino, which will be  our main brain, one motor attached to  the center of the CanSat and all the  sensors which will be put in each own  particular place.  P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 4 1. Introduction: Before starting • This guide is used with some pieces that maybe are not the actual  ones that you have, but they are very similar.  • Pictures are shown as an illustration on how to assemble the  subsystems, but you are free to do it in a different manner.  • Besides, we recommend having a sandpaper or some kind of drill,  glue and taper, in order to make bigger holes, if needed, and fix  some parts of the CanSat.
  92. 92. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 5 1. Introduction: Assembly Tips • When you arrive at the assembling part you will see that there are 2  parts.  • We strongly recommend you be clean as you were in Part1, it will  really help. • Then add all the other components from part 2.  • Of course, read first everything to understand what you are going to  do and then you will be able to decide how do it.  • In this way you will be able to connect everything well. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 6 TIPS: We might need more GND pins. Therefore, we will take  one of this rows of sockets and weld it. You can choose  whether you want it in the upper side or the bottom side. We need to make it solid and strong. So we can use some  tape, or glue gun. If you do that your work will be really easy.  The weld has to be in all the row If you are using these wires, you will need to take into  account their longitude, since it ought to fit as precise  as possible. Besides, the plastic heads of the wires can sometimes  be annoying, since they do not allow one to adjust the  cables on the arduino. You can se other cables if it  makes you feel more comfortable. 1. Introduction: Assembly Tips
  93. 93. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 7 2. Pieces: External part Here we have the external part, one the  most important parts, as it will contain all  the structure. The blue circles indicate where the  photoresistors holes must be placed. The red rectangular is where the solar  panel will be set. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 8 2. Pieces: Circular box In the green circle we  find a little slot to  adjust the transceiver  in order to keep it fix.  The red circle is just a  hole to take a wire  until the ground to  C&D component. The blue square  shows where the C&D  will be.
  94. 94. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 9 2. Pieces: Inferior base This piece is the support of every box  in the Cansat.  Between the green lines, we will put  the box of the Arduino vertically,  oriented towards the blue draw.  In the blue draw, we will put the  circular box with the battery and the  C&D. And in the red line, we will put the  solar panel. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 10 2. Pieces: Base  This base has been made to fix the inferior one and also to take out the cable that will be the monopole antenna of the transmitter.
  95. 95. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 11 2. Pieces: Motor box • This piece is the one that will  hold the motor.  • It is quite simple because it  just fixes it in a specific hole  and avoids making contacts  with the Arduino. • You can recover it with some  tape in order to strengthen  the attachment. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 12 2. Pieces: C&D Holder This piece supports the C&D in its  specific slot.  This one has to be fixed with  superglue to get it strongly attached.  It has all the important wires that  supply all the Cansat.
  96. 96. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 13 2. Pieces: Upper base Here we can find various fundamental  holes.  The red hole is the hole for the  parachute screw. The blue hole is for the GPS antenna. The yellow hole is for the motor pole  (“reaction wheel”). P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 14 2. Pieces: Arduino box Here we have the main piece: The blue holes are used to attach the Arduino. Also in the green slot we have a rectangular hole to assemble the motor’s box. The yellow hole is for one side of the motor. If you want you can file a bit to put it more easily. The red hole is for the piece that hold the parachute. Finally, the blue sky is for the GPS’ antenna. However, it is not required.
  97. 97. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 15 3. Assembly First we need to know each piece  that will be inside: ‐ Arduino Uno ‐ Cylindrical battery ‐ Motor ‐ MAX471 (Current sensor) ‐ Solar panel ‐ C&D ‐ Transceiver ‐ GPS ‐ BMP (pressure sensor) ‐ Photoresistors Now that we know all the pieces, we will start assembling all the pieces.  P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 16 3.1. Assembly: Solar panel Weld two wires to the solar panel. Fix one male‐female wire in order to  connect the female one in their specific  pin. Sometimes, the weld is hard to fix , since  you have to use an important quantity of  tin. Hence, a piece of tape can be used  instead.
  98. 98. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 17 3.2. Assembly: BMP180  Now we are going to make a little “improvement” in order to fix the  BMP180 in its holes. Besides, we will reuse their VCC and GND to make  more welds in its points.   The last 3 pins must be connected with  wires to their correct pins. If we do not   want to create any kind of short circuit  we will put use tape.  By doing that, we will be able to put the  wires in their pins easily and without any  problem. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 18 3.3. Assembly: MAX471 After welding it, screw it in the  lateral part of the main box, so  that it will be accessible for the  wires.
  99. 99. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 19 3.4 Assembly: GPS Now is the turn of the GPS. We will put it between the micro and the  pins of the Arduino. Their connections cannot stand above of the chip.  P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 20 3.5 Assembly: Transceiver Now we will see the transceiver, which will be just under the Arduino.  Its wires must be long  enough so they can  pass touching the  wall. If they are short  enough, get right to  their points.
  100. 100. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 21 3.6. Assembling: Arduino without motor  So now we will start assembling the pieces, so that we get an idea of  the structure:  Improvement In order to connect  all the wires safely  and not to get a  really mess, you  should fix them  with some tape.  It is strongly  recommended. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 22 3.7 Assembly: Arduino + C&D  In the green circle, we can see the  MAX471 screwed to the wall. After that, we plug every wire from  the C&D in their respective pins.  It is vital to use small wires or wait  to weld before knowing which wire  you will use, since, in some cases,  you will receive a male wire, which  will allow you to use just one wire  instead of two.
  101. 101. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 23 3.8. Assembly: Arduino + Circular box This image shows how the wires  have to be connected.  We strongly recommend you  use short wires and make sure  the welds are strong enough. We repeat these tips because if  the welds are weak, the  connections are sure to get  broken. P7. Final CanSat Integration IEEE Young Professionals in Space, Barcelona July 17‐21 2018 ‐ © UPC‐BarcelonaTech ‐ 2018 24 3.9. Assembling: First step to the motor We will use the row of sockets mentioned before to  connect every component . Now we will optimize our space. In the rows of the  analog pins., we will weld one row of connectors for  the photoresistor with one side of the resistor, which  will go directly to GND, saving one wire. Everything has to be very rigid and strongly fixed.  The green circle indicates us that the resistor goes to  the photoresistor.

×