miércoles, 5 de enero de 2011

Vector control




English
As we have said many times, our short-term goal is to make a rocket capable of reaching space (minimum 100 km), but thinking long term, this rocket will not just be to reach space but also we want to control the path in order to accurately place in orbit the wiki-sats as well as we can, so Roberto is responsible for the future manufacture and test of the definitive vector control rocket. The vector control of our satellite is based on 4 small copper tubes with a very small diameter, with a valve controlled by a servo in turn controlled by a satellite that will go in the rocket, the theoretical performance is simple, our wiki-sats are fitted with accelerometers, they look at the attitude of the rocket and corrected according to a prescribed path, if necessary, by air pressure expulsion (generated by the combustion of rocket) for the tubes may change as well in all three axes (pitch , Roll and yaw). In practice it is not as simple as it is not only the production itself with the servo valves and tubes (and in itself complicated by the small scale) but also have to find the appropriate control algorithms (a followed by mathematical formulas for how much you have to open a valve or another to make a turn more or less closed or faster). What you can see in the video are the tests that have been made of the vector control system to see if the valves closed withstand the pressure and also see if the system works.


Castellano
Como ya hemos repetido numerosas veces, nuestro objetivo a corto plazo es hacer un cohete capaz de llegar al espació (mínimo 100 km), pero pensando en largo plazo, este cohete no solo tendrá que llegar al espacio sino que además querremos controlar la trayectoria de este a fin de colocar con la mayor precisión los wiki-satélites en sus óptimas órbitas, por eso Roberto es el encargado de fabricar y probar el futuro control vectorial del cohete definitivo. El control vectorial de nuestro satélite se basa en 4 pequeños tubitos de cobre de un diámetro muy pequeño, con unas válvulas controladas por unos servos a su vez controladas por uno de los satélites que irá en el cohete, el funcionamiento teórico es simple, nuestros wiki-sats estan dotados de acelerómetros, estos miran la actitud del cohete y la corrigen según una trayectoria estipulada si es necesario mediante la expusión de aire a presión (generado por la combustión del cohete) por los tubitos pudiendo cambiar así en los tres ejes (cabeceo, alabeo y guiñada). En la práctica no es tan simple pues no es solo la fabricación en si de los servos con las válvulas y los tubitos (ya de por si complicado debido a su reducida escala) sinó que también se tienen que encontrar los algoritmos de control idoneos (un seguido de formulas matemáticas para saber cuanto se tiene que abrir una válvula o otra para hacer un giro más o menos cerrado o rápido). Lo que podeis ver en el vídeo son las pruebas que se le han practicado al sistema de control vectorial para ver si las válvulas aguantan cerradas la presión y para ver también si el sistema funciona.

lunes, 3 de enero de 2011

Launch campaign, first launch

English
In our wiki-space campaign we have decided the first launch date, this is the next January 28th. For this launch the following objectives:

    1. Launch a stratospheric balloon with our launch ramp and the system arrives at least 30 km.
    2. At 30 km high, launch a rocket stage with a monitoring system.
    3. At 2 km to open a parachute.
    4. See the results, analyze and report.

Then you can see the code that we will introduce the AWIP to the igniter is turned on at 30 km and the parachute at 2 km. This has been done by Juan Martínez and Joshua Tristancho and reviewed by Victor Kravchenko.



Castellano
En nuestra wiki-campaña espacial nos hemos propuesto la primera fecha de lanzamiento, esta es el 28 de enero. Para este lanzamiento los objetivos son los siguientes:
  1. Lanzar nuestro globo estratosferico con nuestra rampa le lanzamiento y que llegue a un mínimo de 30 km.
  2. A 30 km lanzar la etapa del cohete con un sistema de seguimiento.
  3. A 2 km que se abra un paracaídas.
  4. Ver los resultados, analizarlos y reportarlos.
Seguidamente podes ver el código que le vamos a introducir a la AWIP para que que el igniter se encienda a 30 km y el paracaídas a 2 km. Este ha sido hecho por Juan Martínez y Joshua Tristancho y revisado por Victor Kravchenko.


Code (codigo):


#include <Wire.h>
#include <SoftwareSerial.h>
#include <EEPROM.h>
#include <math.h>
#define IGNITION_ALTITUDE 30000 // Above this altitude in meters the igniter is activated
#define PARACHUTE_ALTITUDE 2000 // Below this altitude in meters the parachute is deployed
#define SAFETY_ALTITUDE 3000 // Safety altitude above wich the parachute can be deployed
#define APOGEE_ADDR 0 // Apogee EEPROM Address
#define IGNITION_PIN 12 // Ouput pin number to activate the igniter 5V
#define PARACHUTE_PIN 10 // Ouput pin number to activate the parachute 5V
#define GPSRX_PIN 11 // Input pin for GPS Rx serial port
#define GPSTX_PIN 13 // Output pin for GPS Tx serial port
//#include "itg3200.h" // GYRO ITG-3200
#define GyroID B1101001
//Register 22 - FS_SEL, DLPF_CFG
#define R22 0x16
#define R22INIT B00011011
//Register 62 - Power Management
#define R62 0x3e
#define R62INIT B00000001
//Registers 27 to 34 - Sensor Registers
#define TempH 0x1b
#define TempL 0x1c
#define GyroXH 0x1d
#define GyroXL 0x1e
#define GyroYH 0x1f
#define GyroYL 0x20
#define GyroZH 0x21
#define GyroZL 0x22
//#include "lis331hh.h" Accelerometer LIS331HH
#define AccID 0x18
//Register CTRL_REG0 - Power management and conf
#define RCTR0 0x20
#define RCTR0INIT B00100111
//Sensor Registers
#define AccXH 0x29
#define AccXL 0x28
#define AccYH 0x2B
#define AccYL 0x2A
#define AccZH 0x2D
#define AccZL 0x2C
#define AccStat 0x27
void i2cSetRegister(int device, int address, int value)
{
  Wire.beginTransmission(device);
  Wire.send(address);
  Wire.send(value);
  Wire.endTransmission();
}
byte i2cGetRegister(int device, int address)
{
  Wire.beginTransmission(device);
  Wire.send(address);
  Wire.endTransmission();
  Wire.requestFrom(device, 1);
  if(Wire.available())
  return Wire.receive();
  return B00000000;
}
int i2cGetValue(int device, int addressH, int addressL)
{
  return i2cGetRegister(device, addressH) * 256 + i2cGetRegister(device, addressL);
}
// Globals
SoftwareSerial GPS = SoftwareSerial(GPSRX_PIN,GPSTX_PIN);
int addr;
int val; // Last byte read from GPS
float alt; // Last altitude read from GPS
float apogee; // Highest altitude read from GPS. This variable is mirrored in EEPROM.
byte k[]={0,0,0,0,0,0,0,0,0,0,0,0,0}; // Read buffer for GPS input
float EEPROMGetFloat(int addr)
{
  float num;
  ((byte*)&num)[0]=EEPROM.read(addr++);
  ((byte*)&num)[1]=EEPROM.read(addr++);
  ((byte*)&num)[2]=EEPROM.read(addr++);
  ((byte*)&num)[3]=EEPROM.read(addr++);
  return num;
}
void EEPROMSetFloat(int addr, float num)
{
  EEPROM.write(addr++,((byte*)&num)[0]);
  EEPROM.write(addr++,((byte*)&num)[1]);
  EEPROM.write(addr++,((byte*)&num)[2]);
  EEPROM.write(addr++,((byte*)&num)[3]);
}
byte Next()
{
  // BYTE, BIN, OCT, HEX, 1 = number of decimals
  val=byte(GPS.read());
  Serial.print(val,BYTE); // For debbuging purpose only
  return val;
}
int ReadParam(byte chr=',')
{
  int i=0;
  while(true)
    if(i>=sizeof(k))
      return -1; // Buffer overrun
    else if((k[i]=Next())==chr)
      return i; // Read 'i' bytes
    else
      i++;
}
void setup ()
{
  pinMode(IGNITION_PIN,OUTPUT);
  digitalWrite(IGNITION_PIN,LOW);
  pinMode(PARACHUTE_PIN,OUTPUT);
  digitalWrite(PARACHUTE_PIN,LOW);
  GPS.begin(4800);
  Serial.begin(4800);
 
  // EEPROM dumping
  /*
  for(addr=0;addr<512;addr++)
  {
    if (!(addr%16)){Serial.println();Serial.print(addr/1000.0f,3);Serial.print(": ");}
    Serial.print(EEPROM.read(addr)/1000.0f,3);Serial.print(" ");
    //EEPROM.write(addr,0); // WARNING: This line will erase all the EEPROM memory
  }
  Serial.println();
  */
 
  addr=0;
  val=0;
  alt=0;
  apogee=EEPROMGetFloat(APOGEE_ADDR);
  Wire.begin();
  // Hyperterminal at 57600 and Arduino at 115200 bauds
  //Serial.begin(115200);
  // Accelerometer LIS331HH setup
  i2cSetRegister(AccID, RCTR0, RCTR0INIT);
  // Gyro ITG-3200 setup
  i2cSetRegister(GyroID, R62, R62INIT);
  i2cSetRegister(GyroID, R22, R22INIT);
  // Hardware-on-the-loop config
  //i=0;
}
void loop()
{
  int i;
  if(Next()=='$')if(Next()=='G')if(Next()=='P')if(Next()=='G')if(Next()=='G')if(Next()=='A')if(Next()==',')
  {
    if(ReadParam()>=0)      // Time in UTC of position
    if(ReadParam()>=0)      // Latitude of position
    if(ReadParam()>=0)      // Latitude N or S
    if(ReadParam()>=0)      // Longitude of position
    if(ReadParam()>=0)      // Longitude E or W
    if(ReadParam()>=0)      // GPS quality                            (0=fix not available, 1=Non-differential GPS fix available, 2=Differential GPS (WAAS) fix available, 6=Estimated)
    if(ReadParam()>=0)      // Number of satellites                   (00 to 12)
    if(ReadParam()>=0)      // Horizontal dilution of precision       (0.5 to 99.9)
    if(ReadParam()>0)       // Antenna altitude above mean sea level  (-9999.9 to 99999.9)
    {
      alt=atof((char*)&k[0]);
      if(ReadParam()>=0)    // Units of antenna altitude, meters      M
      if(ReadParam()>=0)    // Height of geoid above ellipsoid        (-999.9 to 9999.9)
      if(ReadParam()>=0)    // Units of geoid height, meters          M
      if(ReadParam()>=0)    // Age of differential GPS data, seconds  Null
      if(ReadParam('*')>=0) // Differential reference station ID      Null
      if(ReadParam(10)>0)   // Checksum                               *HH
      {
        if(alt>apogee)
        {
          apogee=alt;
          EEPROMSetFloat(APOGEE_ADDR,alt);
        }
        if(alt>IGNITION_ALTITUDE)digitalWrite(IGNITION_PIN,HIGH);
        if(alt<PARACHUTE_ALTITUDE)if(apogee>SAFETY_ALTITUDE)digitalWrite(PARACHUTE_PIN,HIGH);
      }
    }
  }
}

miércoles, 15 de diciembre de 2010

balloon + Launching-ramp = Aerial launching ramp


English
Today we tested our skill and strength "building" our revolutionary aerial launch ramp. By now you know that this is based on a PVC pipe attached "curiously". Tree month ago we did a test and the memory I had was a superhuman effort to get the PVC pipe into the nozzle of the balloon through the shims (the Chinese). She feels that with a new balloon is no such effort. The trick is without doubt the timing and the steps are:
  1. First of all be careful with the balloon (the part that is not the nozzle) is very delicate and can seriously compromise the properties of this (it can reach an altitude exploit unintended).
  2. Having taken all precautions, enter 4 shims from the nozzle 2 to 2.
  3. Begin to enter the PVC pipe through the nozzle.
  4. As the mouthpiece widens go separating 4 shims.
  5. Enter fifth shoehorn (it was necessary, because the diameter of the tube, we complicated the operation if not we used).
  6. Pull down (the two people to do so) slowly but steadily (to prevent sidewall).
  7. Once all the nozzle of the balloon, remove shims one by one looking at the mouthpiece is as straight as possible.


Castellano
Hoy hemos puesto nuestra habilidad y fuerza a prueba "construyendo" nuestra revolucionaria rampa de lanzamiento aerea. A esta altura ya sabeis que esta se basa en un tubo de PVC acoplado de una forma muy "curiosa". Hicimos una prueba hace 3 meses y el recuerdo que tenia era de un esfuerzo sobrehumano para entrar el tubo de PVC dentro de la boquilla del globo mediante los calzadores (de los chinos). Pues se ve que con un globo nuevo el esfuerzo no es tal. El truco es sin duda la sincronización y los pasos son los siguientes:
  1. Antes de nada tener mucho cuidado con el globo (la parte que no es la boquilla) es muy delicado y podemos comprometer seriamente las propiedades de este (este puede llegar a explotar a una altitud no deseada)
  2. Una vez tomadas todas las precauciones, introducir 4 calzadores por la boquilla 2 a 2.
  3. Empezar a entrar el tubo de PVC por la boquilla.
  4. A medida que se ensancha la boquilla ir separando los 4 calzadores.
  5. Introducir un quinto calzador (era necesario, pues por el diametro del tubo, se nos complicaba la operación si no lo utilizabamos).
  6. Tirar hacia abajo (las dos personas que lo hagan) poco a poco pero sin parar (para evitar que se salga)
  7. Una vez introducida toda la boquilla del globo,  retirar uno a uno los calzadores mirando de que la boquilla quede lo más recta posible.



    domingo, 12 de diciembre de 2010

    Monegros launch test




    English
    In our plan, the first step was the validation of our Stage2 on the ground, this means, throw our stage from the ground with all the limitations we have to attest that our Stage2 will be desired. So we decided to head towards the desert of Monegros (Zaragoza) to test our stage safely. 

    Test: Ground test of our stage, see the behavior, analyze the launch and see what can be improved. 

    Test results: We prepared a check list, but we failed a component that is not critical, we have to weld a mass and gas welder that we had, do not work (we think due the cold), this mass function is used to make our called "payload" formed by the GPS and our board AWIP to do a tracking of the stage, this was a secondary test for as we say before, our main objective in this test is to see the behavior of the stage. This is the first test (we have many miles) and arrive to the conclusion that if I was going well but that we did not, would launch the Stage2 also. So we skip the steps related to the recording of tracking and proceed to the following, we put Roberto and me each with cameras to capture the moment (a reasonable long distance) and Joshua do all pre-launch preparations. When is about to launch, the stage reached three meters making loops and drops to ten feet from where we launched, "a disaster? Was it expected? 

    Test conclusions: This test gives us a starting point, therefore, is not a disaster, says that we have much work ahead, lower weight and overall structure of payload and improve system reliability (chance is not an option)


    Castellano
    Dentro de nuestro plan, el primer paso era la validación de nuestra segunda etapa en tierra, esto quiere decir, lanzar nuestra etapa desde el suelo con todas las limitaciones que tenemos para dar fe de que nuestra segunda etapa hará lo deseado. Así pues nos decidimos a ir dirección al desierto de los Monegros (Zaragoza) para probar con seguridad nuestra etapa.

    Test: Prueba en suelo de nuestra etapa, ver el comportamiento, analizar el lanzamiento y ver que se puede mejorar.

    Resultados del test: Nos preparamos una check list, pero nos falla un componente que no es crítico, tenemos que soldar una masa y el soldador de gas que llevamos no funciona (creemos que por el frío), esta masa sirve para hacer que funcione nuestra supuesta "carga de pago" formada por el GPS y nuestra placa AWIP para poder hacer un tracking de la etapa, esto era una prueba secundaria pues como decimos antes, nuestro objetivo principal en este test es ver el comportamiento de la etapa. Esta es la primera prueba (hemos hecho muchos quilometros) y ya llegamos a la conclusion que si iba bien pero que si no iba, lanzariamos igualmente la segunda etapa. Así pues nos saltamos los pasos relacionados a la grabación del tracking y pasamos a los siguientes, nos colocamos Roberto y yo con sendas cámaras para inmortalizar el momento (a una distancia siempre prudencial) y Joshua hace todos los preparativos pre-lanzamiento. Cuando esta a punto lanza, la etapa llega a unos tres metros haciendo loopings y cae a tres metros de donde lo hemos lanzado, ¿un desastre? ¿era lo esperado?

    Conclusiones del test: Este test nos da un punto de salida, por lo tanto, no es un desastre, nos dice que tenemos mucho trabajo por delante, rebajar pesos de estructura y sobretodo de carga de pago y mejorar la fiabilidad del sistema (el azar no es una opción)

    jueves, 9 de diciembre de 2010

    Check list (Fire box)

    English
    Material:
    • Stage2.
    • Tube-Launch ramp.
    • Fire Box.
    • Tester.
    • Adhesive tape.
    • Gas solder.
    • Welder tin.
    • Cameras.
    Check list:
    • welded to the secondary mass.
    • Check for igniter continuity.
    • Pass the Fire Box wire (disconected from the Fire Box) from the "cobered" hole to the stage2 exit.
    • Connect the Fire Box wire with the igniter wire.
    • Connect the Fire Box wire with the tracking sistem.
    • Slowly entering into the tube-launch ramp recovering the wire excess.
    • Wear hearing protection.
    • Turn on all the cameras that we carry. 
    • Check that all of the Fire Box switches are OFF. 
    • Connect the cable to the Fire Box. 
    • Point the tube-launching ramp into the sky. 
    • Pass the Power switch of the Fire Box from OFF to ON. 
    • Wait for the line, you have to switch the GPS READY LED. 
    • Once aligned, to signal "ready to launch" to mate (by phone [missed call] if no visual contact or by signs if there is in visual field). 
    • Pass the RECORD switch from OFF to ON, then the Ignition from OFF to START.


    Castellano
    Material:
    • Segunda etapa.
    • Tubo-rampa de lanzamiento.
    • Fire Box.
    • Tester.
    • Cinta adhesiva.
    • Protección auditiva.
    • Soldador de gas.
    • Estaño para soldar.
    • Camaras.

    Check list:
    • Soldar la masa secundaria.
    • Mirar si el igniter tiene continuidad.
    • Pasar el cable de la Fire Box (desconectado de la Fire Box) del extromo "tapado" con el agujerito al extremo de salida del cohete.
    • Conectar el cable de la Fire Box con el cable del igniter.
    • Conectar el cable de la Fire Box con el sistema de tracking.
    • Entrar lentamente el cohete dentro del tubo-rampa de lanzamiento recuperando el sobrante de cable.
    • Colocarse los protectores auditivos.
    • Encender todas las camaras que llevemos.
    • Comprobar que todos los switchs de la Fire Box están en OFF.
    • Conectar el cable con la Fire Box.
    • Apuntar el tubo-rampa de lanzamiento hacia el cielo.
    • Pasar el switch de Power de la Fire Box de OFF a ON.
    • Esperar a que alinee, se tiene que encender el led de GPS READY.
    • Una vez alineado dar la señal de "a punto para lanzar" al compañero (mediante telefono [llamada perdida] si no hay contacto visual o mediante señas si hay campo visual).
    • Pasar el switch RECORD de OFF a ON, seguidamente del de IGNITION de OFF a START.

    martes, 30 de noviembre de 2010

    Stage2 third burn



    English
    Following the validation of the stage2 we got to the third version of it. In this third prototype we decided to move to higher and place the savage amount of 7 grains (1 plant with its encapsulation of cardboard and its nozzle and 6 around without encapsulation or nozzle) with this configuration we reach the maximum capacity of the can. At first it wanted to put 8 grains (1 in the center and 7 around) but it was impossible to enter and so we opted for the 7-grain configuration. These 7 grains are not subject to the anothers and the can only be diposit a little resin on the bottom to support the central grain. Only the central grain is expected to igniter and the other 6 are switched to heat, pressure and fire to detach it. The can is coated with epoxy resin in order to support higher temperatures. 

    Test: The test is still the same, turn on the stage and see how it reacts. 

    Test result: The igniter works and lights up the stage this, but exploits a few moments of ignition by blowing up the grains that were not subject these to not be exposed to any pressure, which burned paper. 

    Test conclusions: very important to hold ALL the grains so that if there is an explosion (as in our case) they do not go flying around.


    Castellano
    Siguiendo con la validacion de la segunda etapa llegamos a la tercera versión de la misma. En este tercer prototipo decidimos pasar a mayores y colocar la bárbara cantidad de 7 granos (1 central con su encapsulado de cartón y su tobera y 6 a su alrededor sin encapsulado ni tobera) con esta configuración llegamos a la capacidad máxima de la lata. En un principio se querian poner 8 granos (1 en el centro y 7 al rededor) pero fué imposible hacer que entraran y por eso se optó por la configuración de 7 granos. Estos 7 granos no estan sujetos entre si y la lata, solo se diposita un poquito de resina en el fondo para soportar el grano central. Solo el grano central tiene igniter y se espera que los otros 6 se enciendan con el calor, presión y fuego que desprenda este. La lata está recubierta de resina epoxy a fin de que soporte más altas temperaturas.

    Test: El test sigue siendo el mismo, encender la etapa y ver como reacciona.

    Resultado del test: El igniter funciona y enciende la etapa, esta, pero, explota a pocos instantes de la ignición haciendo volar por los aires los granos que no estaban sujetos, estos al no estar expuestos a presión alguna, se queman cual hoja de papel.


    Conclusiones del test: muy importante sujetar TODOS los granos a fin de que si hay una explosión (como ha sido nuestro caso) estos no salgan volando por allí.

    Stage2 fifth burn



    English
    And with this we reach the fifth prototype of the Stage2 and come full of "improvements" (If we use the slang of the Formula 1 can say that for this prototype comes new developments). If recapitulate and reminisced about the rights and wrongs of the other prototypes we have our fifth stage, it consists of an insulating coating of epoxy resin on the inside of the can so that it could withstand the high temperatures generated, in this case we use a configuration central grain surrounded by five others naked grains, in this prototype beans that go around are covered with a layer of resin with fiber, so we contain grains and further protect the can (our weak link) is due to the augment in grain volume so we could not six grains and in the last two prototypes, we have also smoothed the crust of central grain board to laces and entry though pimples. 

    Test: More of the same, see the behavior of the can (and grains) in ignition. 

    Test result: The igniter fails, and we have many faults, then decided to ignite "manually" via a wick. This goes on and we see a perfect "wake", the can hold the entire process. At the end we see that the nozzle is clear because the resin that hold it has been burned. 

    Test conclusions: The test is a success (except that the igniter does not burn the grain), the can (remember, our weak link) hold for the first time a configuration of more than 1 grain. But here, even to amateurs, we are perfectionists and we see that the wake takes "jolts" due to the grains do not burn in unison, this certainly derive a serious departure from the stage if we would launch it. Our next step should be to think of a way to ensure that light up all at the same instant.

    Castellano
    Y con esta llegamos al quinto prototipo de segunda etapa y viene cargadita de "mejoras" (Si utilizamos el argot de la Formula 1 podriamos decir que para este prototipo nos llegan nuevas evoluciones). Si recapitulamos y rememoramos los errores y aciertos de los otros prototipos tenemos nuestra quinta etapa, esta consta de un recubrimiento aislante de resina epoxy por el interior de la lata para que esta soporte las altas temperaturas que se generan, en este caso utilizamos una configuración de grano central rodeado de otros cinco, en este prototipo los granos que van alrededor estan recubiertos por una capa de resina con fibra, de esta manera contenemos los granos y protegemos aún más la lata (nuestro eslabón débil) es debido a este augmento en el volumen de los granos por lo que no hemos podido seis granos como en las dos últimos prototipos, además hemos limado la corteza de cartón del grano central para poder encagar y hacer entrar bien todos los granos.

    Test: Más de lo mismo, ver el comportamiento de la lata (y los granos) en ignición.

    Resultado del test: El igniter falla, ya llevamos diversos fallos, entonces se decide a igniciar "manualmente" mediante una mecha. Este se enciende y vemos una perfecta "estela", la lata aguanta todo el proceso. Al final vemos que la tobera se desprende debido a que se ha quemado la resina que lo sujeta.


    Conclusiones del test: El test és un éxito (salvo por que el igniter no enciende el grano), la lata (recordamos, nuestro eslabón débil) aguanta por primera vez una configuración de más de 1 grano. Pero aquí, aún que amateurs, somos perfeccionistas y vemos en el test que la estela da "bandazos" debidos a que los granos no se queman al unísono, esto derivaria seguramente en una seria desviación de la etapa si la lanzaramos. Nuestro siguiente paso deberia ser pensar en alguna manera de asegurarnos que se enciendan todos al mismo instante.