Index: tag/rc_1/MORARD_Jordan/main.c
===================================================================
--- tag/rc_1/MORARD_Jordan/main.c	(nonexistent)
+++ tag/rc_1/MORARD_Jordan/main.c	(revision 424)
@@ -0,0 +1,400 @@
+#include "trame.h"
+#include<math.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <strings.h>
+
+
+#define PI 3.14
+#define Rayon_Terre 6370
+
+
+typedef struct {
+    float latitude;
+    float longitude;
+}position;
+
+typedef struct {
+    position rpos;
+    float VitesseMax;
+    }zone;
+
+//Trames de tests à modifier si nécessaire.
+char * trames[]=  {"$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C",
+                    "$GPGSV,3,3,10,22,39,053,50,28,15,320,*7E",
+                    "$GPRMC,141914.00,A,4545.6424,N,00306.6036,E,0.4,99.4,010206,,*0C",
+                    "$GPGLL,4545.6424,N,00306.6036,E,141914.00,A*0E",
+                    "$GPGGA,141914.00,4545.0000,N,00306.6036,E,1,05,3.4,499.3,M,,M,,*7D",
+                    "$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39",
+                    "$GPVTG,99.4,T,,M,0.4,N,0.7,K*57",
+                    "$GPZDA,141914.00,01,02,2006,00,00*69",
+                    0};
+
+position pos,pos1,pos2,pos3;
+
+//déclaration et initialisation de la distance
+float distance = 0.0;
+
+float calcul_distance(position *p1,position *p2)
+{
+    float D;
+    D = sqrt(pow((p2->latitude-p1->latitude)*PI*Rayon_Terre/180.0,2)+pow(((p2->longitude-p1->longitude)*(cos(((p2->latitude+p1->latitude)/2.0)*PI/180.0)*PI*Rayon_Terre/180.0)),2));        //formule calcul d'une distance sur une sphere, voir internet
+
+    return D;
+}
+
+
+float latitude(char *ch)
+{
+    float res, res1, res2, res3;
+
+    res1 = decode_nombre(ch,17,2);      //retrouver les degrés en sexagesimal dans la trame
+    res2 = decode_nombre(ch,19,2);      //retrouver les minutes en sexagesimal dans la trame
+    res3 = decode_nombre(ch,22,4);      //retrouver les secondes en sexagesimal dans la trame
+
+    res = res1 + (res2 + res3/10000)/60;    //conversion sexagesimal à degrés
+
+    if(ch[27]=='S')     //identifier si la latitude est nord ou sud
+    {
+        res = -res;
+    }
+
+    return res;
+}
+
+float longitude(char *ch)       //meme principe que la fonction latitude
+{
+    float res, res1, res2, res3;
+
+    res1 = decode_nombre(ch,29,3);
+    res2 = decode_nombre(ch,32,2);
+    res3 = decode_nombre(ch,35,4);
+
+    res = res1 + (res2 + res3/10000)/60;
+
+    if(ch[40]=='W')     //identifier si la latitude est ouest ou est
+    {
+        res = -res;
+    }
+
+    return res;
+}
+
+//Fonction à modifier !!!!!
+void traitement(char * trame)
+{
+    static int cpt = 0;
+    cpt++;
+    if(trame_cmp(trame,"GPGGA")==1)     //verifier si la trame GPS contient le caractere "GPGGA"
+    {
+        printf ("> %s\n",trame);
+        printf("\n> %s \n\n ",trame);
+    }
+}
+
+//description de toutes les zones
+zone zones[]= {
+    {{44.7887762, -3.012}, 50},
+    {{45.752610, 3.465067}, 60},
+    {{45.75080886, 3.11006165}, 70},
+    {{45.752910, 3.110067}, 80},
+    {{46.753910, 4.618967}, 90},
+};
+
+int distance_a_la_proche_zone(position p, zone r[],int nb_zones, float *d)
+{
+    int i,j;
+    float reference;
+
+    reference = calcul_distance(&p,&r[0].rpos);     //creation reference sur la premiere zone  du tableau pour commnencer la boucle
+    for(i=0; i<nb_zones; i++)
+    {
+        *d=calcul_distance(&p,&r[i].rpos);
+        if(*d<=reference)
+        {
+            j=i;                //changement de l'indice de la zone la plus proche
+            reference=*d;       //changement de la reference en distance de la zone la plus proche
+        }
+    }
+
+    return j;
+
+}
+
+int trame_cmp(char * trame,char * type)
+{
+    int i;
+    int retour=1;
+    for(i=0;i<4;i++)
+    {
+        if(trame[i+1]!=type[i])
+        {
+            retour=0;
+        }
+    }
+    return retour;
+}
+
+
+int decode_int(char c)
+{
+    int nb;
+
+    nb = c-48;
+
+    if((nb<0)||(nb>9))
+    {
+        return -1;
+    }
+    else
+    {
+        return nb;
+    }
+
+}
+
+
+int test_decode_int()
+{
+
+    if (decode_int('0')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('1')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('2')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('3')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('4')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('5')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('6')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('7')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('8')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+    if (decode_int('9')!=0)
+    {
+        printf("erreur unitaire de decode_int");
+        exit(-1);
+    }
+
+    return 1;
+}
+
+int decode_nombre(char *ch,int i, int n)
+{
+    int j;
+    int res=0;
+    for(j=i;j<i+n;j++)
+        res=(res*10)+decode_int(ch[j]);
+    return res;
+}
+
+int test_decode_nombre()
+{
+    int retour = 1;
+    if (decode_nombre("758961",2,0)!=75)
+    {
+        printf("Erreur test unitaire nombre \n");
+        retour = 0;
+    }
+    if (decode_nombre("758961",5,0)!=75896)
+    {
+        printf("Erreur test unitaire nombre \n");
+        retour = 0;
+    }
+
+}
+
+
+decode_trame(char *ch, position *p)     //executer directement les deux fonctions pour retrouver la longitude et la latitude
+{
+    p->latitude = latitude(ch);
+    p->longitude = longitude(ch);
+}
+
+float calcul_vitesse(position p1,position p2)
+{
+    float V;
+    V = calcul_distance(&p1,&p2)*3600;      //calcul de la vitesse avec la fonction calcul_distance entre 2 points séparés d'une seconde
+
+    return V;
+}
+
+
+
+//Ajouter vos tests unitaires dans cette fonction.
+void tests_unitaires(void)
+{
+    //test basique pour verifier bon fonctionnement du processeur
+    if (5!=5){
+        printf ("Erreur Test unitaire basique.\n");
+        exit(-1);
+    }
+
+    //4 tests pour la fonction trame_cmp pour bien avoir "GPGGA" en début de chaine
+    if (trame_cmp("$GPGGA suite chaine","GPGGA")!=1){
+        printf ("Erreur Test unitaire trame_cmp 1.\n");
+        exit(-1);
+    }
+    if (trame_cmp("$GPRMC suite chaine","GPGGA")!=0){
+        printf ("Erreur Test unitaire trame_cmp 2.\n");
+        exit(-1);
+    }
+    if (trame_cmp("$GPRMC... ", "GPRMC" )!=1){
+        printf ("Erreur Test unitaire trame_cmp 3.\n");
+        exit(-1);
+    }
+    if (trame_cmp("$APRMC...", "GPGGA")!=0){
+        printf ("Erreur Test unitaire trame_cmp 4.\n");
+        exit(-1);
+    }
+
+    //test decode_int
+    if(decode_int('5')!=5){
+        printf ("Erreur Test unitaire decode int.\n");
+        exit(-1);
+    }
+
+    //test decode_nombre
+    if(decode_nombre("7558",0,2)!=75){
+        printf ("Erreur Test unitaire decode nombre.\n");
+        exit(-1);
+    }
+
+    //test fonction latitude pour savoir si elle est bien précise à 10e-6 près, deux floattants ne peuvent pas être comparés directement
+    if(fabs(fabs(latitude("$GPGGA,141914.00,4545.0000,N,00306.6036,E,1,05,3.4,499.3,M,,M,,*7D"))-45.75) > 10-6){
+        printf ("Erreur Test unitaire latitude.\n");
+        exit(-1);
+    }
+    //test fonction longitude pour savoir si elle est bien précise à 10e-6 près, deux floattants ne peuvent pas être comparés directement
+    if(fabs(fabs(longitude("$GPGGA,141914.00,4545.0000,N,00306.6036,E,1,05,3.4,499.3,M,,M,,*7D"))-3.11006) > 10-6){
+        printf ("Erreur Test unitaire longitude.\n");
+        exit(-1);
+    }
+
+    //test decode_trame qui renvoie la latitude et la longitude, précision a 10e-6 près commme au dessus
+    decode_trame("$GPGGA,141914.00,4645.5624,N,00306.0000,E,1,05,3.4,499.3,M,,M,,*7D",&pos);
+    if(fabs(fabs(pos.latitude)-46.759373 >10-6)){
+        printf ("Erreur Test unitaire coordonnees 1.\n");
+        exit(-1);
+    }
+    if(fabs(fabs(pos.longitude)-3.100000 >10-6)){
+        printf ("Erreur Test unitaire coordonnees 2.\n");
+        exit(-1);
+    }
+
+    //declaration coordonnées de 3 villes pour les tests de calcul_distance
+    //Paris
+    pos1.latitude = 48.8588897;
+    pos1.longitude = 2.320041;
+
+    //Lyon
+    pos2.latitude = 45.7578137;
+    pos2.longitude = 4.8320114;
+
+    //Clermont-Ferrand
+    pos3.latitude = 45.777222;
+    pos3.longitude = 3.087025;
+
+    //test calcul_distance entre Paris et Lyon, voir si distance est dans l'intervalle que donne des infos sur internet
+    if((calcul_distance(&pos1,&pos2)>393) & (calcul_distance(&pos1,&pos2)<394))
+        {
+        printf("La distance Paris - Lyon est juste \n");
+        }
+    else{
+        printf ("Erreur Test unitaire calcul distance 1.\n");
+        exit(-1);
+    }
+    //test calcul_distance entre Lyon et Clermont-ferrand, voir si distance est dans l'intervalle que donne des infos sur internet
+    if((calcul_distance(&pos1,&pos3)>340) & (calcul_distance(&pos1,&pos3)<355))
+        {
+        printf("La distance Paris - Clermont est juste \n ");
+        }
+    else
+    {
+        printf ("Erreur Test unitaire calcul distance 2.\n");
+        exit(-1);
+    }
+
+    //declaration 2 points à latitude et longitude proche pour simuler une différence de position sur 1 seconde
+    position pos4;
+    pos4.latitude = 45.752911;
+    pos4.longitude = 3.110066;
+
+    position pos5;
+    pos5.latitude = 45.75298;
+    pos5.longitude = 3.11007;
+
+    //la vitesse est un floattant donc vérification de la précision de la mesure à 10e-2 près
+    if((calcul_vitesse(pos4,pos5)-27.51)<10-1){
+       printf (" Test unitaire calcul vitesse juste ! \n");
+    }
+    else {
+        printf ("Erreur Test unitaire calcul vitesse.\n");
+        exit(-1);
+    }
+
+    int nombre_zone = 5;
+
+    //test fonction distance_a_la_proche_zone avec l'indice de la zone la plus proche dans le test, la zone 3 correspond a la 4eme zone du tableau zones[]
+    if(distance_a_la_proche_zone(pos4,zones,nombre_zone,&distance)!=3){
+        printf ("Erreur Test unitaire calcul distance_a_la_proche_zone.\n");
+        exit(-1);
+    }
+}
+
+
+
+// Ne pas modifier cette fonction
+int main(int argc,char ** argv)
+{
+
+    tests_unitaires();
+
+    // Affichage des trames definies dans la table trames.
+    printf ("Trames de tests tableau trames:\n");
+    int i=0;
+    while (trames[i])
+        traitement(trames[i++]);
+
+    if (!trame_init())
+        exit(-1);
+    // Affichage des trames du fichier gps.log
+    char *trame;
+    printf ("Trames de tests du fichier gps.log\n");
+    while  ((trame = trame_suivante()))
+        traitement(trame);
+
+    return 0;
+}
Index: tag/rc_1/MORARD_Jordan/gps.log
===================================================================
--- tag/rc_1/MORARD_Jordan/gps.log	(nonexistent)
+++ tag/rc_1/MORARD_Jordan/gps.log	(revision 424)
@@ -0,0 +1,111 @@
+$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C
+$GPGSV,3,3,10,22,39,053,50,28,15,320,*7E
+$GPRMC,141914.00,A,4545.6424,N,00306.6036,E,0.4,99.4,010206,,*0C
+$GPGLL,4545.6424,N,00306.6036,E,141914.00,A*0E
+$GPGGA,141914.00,4545.0000,N,00306.6036,E,1,05,3.4,499.3,M,,M,,*79
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,99.4,T,,M,0.4,N,0.7,K*57
+$GPZDA,141914.00,01,02,2006,00,00*69
+$GPGSV,3,1,10,01,13,142,46,03,48,144,47,11,41,277,,14,27,104,42*75
+$GPGSV,3,2,10,15,03,077,,18,04,041,41,19,85,271,,20,08,214,*7F
+$GPGSV,3,3,10,22,39,053,48,28,15,320,*77
+$GPRMC,141915.00,A,4545.6423,N,00306.6039,E,0.6,110.2,010206,,*31
+$GPGLL,4545.6423,N,00306.6039,E,141915.00,A*07
+$GPGGA,141915.00,4545.0242,N,00306.6039,E,1,05,3.4,499.5,M,,M,,*75
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,110.2,T,,M,0.6,N,1.2,K*67
+$GPZDA,141915.00,01,02,2006,00,00*68
+$GPGSV,3,1,10,01,13,142,45,03,48,144,47,11,41,277,,14,27,104,41*75
+$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C
+$GPGSV,3,3,10,22,39,053,49,28,15,320,*76
+$GPRMC,141916.00,A,4545.6422,N,00306.6037,E,0.1,211.1,010206,,*3B
+$GPGLL,4545.6422,N,00306.6037,E,141916.00,A*0B
+$GPGGA,141916.00,4545.0484,N,00306.6037,E,1,05,3.4,500.0,M,,M,,*70
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,211.1,T,,M,0.1,N,0.2,K*60
+$GPZDA,141916.00,01,02,2006,00,00*6B
+$GPGSV,3,1,10,01,13,142,45,03,48,144,48,11,41,277,,14,27,104,43*78
+$GPGSV,3,2,10,15,03,077,,18,04,041,44,19,85,271,,20,08,214,*7A
+$GPGSV,3,3,10,22,39,053,48,28,15,320,*77
+$GPRMC,141917.00,A,4545.6422,N,00306.6039,E,0.3,122.3,010206,,*37
+$GPGLL,4545.6422,N,00306.6039,E,141917.00,A*04
+$GPGGA,141917.00,4545.0726,N,00306.6039,E,1,05,3.4,499.6,M,,M,,*73
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,122.3,T,,M,0.3,N,0.5,K*64
+$GPZDA,141917.00,01,02,2006,00,00*6A
+$GPGSV,3,1,10,01,13,142,45,03,48,144,46,11,41,277,,14,27,104,41*74
+$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C
+$GPGSV,3,3,10,22,39,053,48,28,15,320,*77
+$GPRMC,141918.00,A,4545.6421,N,00306.6034,E,0.5,252.2,010206,,*35
+$GPGLL,4545.6421,N,00306.6034,E,141918.00,A*05
+$GPGGA,141918.00,4545.0968,N,00306.6034,E,1,05,3.4,498.8,M,,M,,*7A
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,252.2,T,,M,0.5,N,1.0,K*63
+$GPZDA,141918.00,01,02,2006,00,00*65
+$GPGSV,3,1,10,01,13,142,45,03,48,144,48,11,41,277,,14,27,104,42*79
+$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C
+$GPGSV,3,3,10,22,38,053,49,28,15,320,*77
+$GPRMC,141919.00,A,4545.6420,N,00306.6040,E,0.6,95.2,010206,,*0C
+$GPGLL,4545.6420,N,00306.6040,E,141919.00,A*06
+$GPGGA,141919.00,4545.1210,N,00306.6040,E,1,05,3.4,500.2,M,,M,,*77
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,95.2,T,,M,0.6,N,1.2,K*5B
+$GPZDA,141919.00,01,02,2006,00,00*64
+$GPGSV,3,1,10,01,13,142,46,03,48,144,49,11,41,277,,14,27,104,42*7B
+$GPGSV,3,2,10,15,03,077,,18,04,041,43,19,85,271,,20,08,214,*7D
+$GPGSV,3,3,10,22,38,053,49,28,15,320,*77
+$GPRMC,141920.00,A,4545.6419,N,00306.6039,E,0.2,133.1,010206,,*38
+$GPGLL,4545.6419,N,00306.6039,E,141920.00,A*08
+$GPGGA,141920.00,4545.1410,N,00306.6039,E,1,05,3.4,500.0,M,,M,,*77
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,133.1,T,,M,0.2,N,0.4,K*66
+$GPZDA,141920.00,01,02,2006,00,00*6E
+$GPGSV,3,1,10,01,13,142,45,03,48,144,46,11,41,277,,14,27,104,43*76
+$GPGSV,3,2,10,15,03,077,,18,04,041,41,19,85,271,,20,08,214,*7F
+$GPGSV,3,3,10,22,38,053,50,28,15,320,*7F
+$GPRMC,141921.00,A,4545.6419,N,00306.6043,E,0.6,103.1,010206,,*33
+$GPGLL,4545.6419,N,00306.6043,E,141921.00,A*04
+$GPGGA,141921.00,4545.1610,N,00306.6043,E,1,05,3.4,499.8,M,,M,,*70
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,103.1,T,,M,0.6,N,1.1,K*65
+$GPZDA,141921.00,01,02,2006,00,00*6F
+$GPGSV,3,1,10,01,13,142,46,03,48,144,48,11,41,277,,14,27,104,42*7A
+$GPGSV,3,2,10,15,03,077,,18,04,041,42,19,85,271,,20,08,214,*7C
+$GPGSV,3,3,10,22,38,053,48,28,15,320,*76
+$GPRMC,141922.00,A,4545.6418,N,00306.6046,E,0.7,96.9,010206,,*00
+$GPGLL,4545.6418,N,00306.6046,E,141922.00,A*03
+$GPGGA,141922.00,4545.1810,N,00306.6046,E,1,05,3.4,500.6,M,,M,,*77
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,96.9,T,,M,0.7,N,1.3,K*53
+$GPZDA,141922.00,01,02,2006,00,00*6C
+$GPGSV,3,1,10,01,13,142,47,03,48,144,46,11,41,277,,14,27,104,43*74
+$GPGSV,3,2,10,15,03,077,,18,04,041,43,19,85,271,,20,08,214,*7D
+$GPGSV,3,3,10,22,38,053,48,28,15,320,*76
+$GPRMC,141923.00,A,4545.6417,N,00306.6046,E,0.3,113.6,010206,,*39
+$GPGLL,4545.6417,N,00306.6046,E,141923.00,A*0D
+$GPGGA,141923.00,4545.2010,N,00306.6046,E,1,05,3.4,500.6,M,,M,,*7D
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,113.6,T,,M,0.3,N,0.7,K*61
+$GPZDA,141923.00,01,02,2006,00,00*6D
+$GPGSV,3,1,10,01,13,142,45,03,48,144,47,11,41,277,,14,27,104,41*75
+$GPGSV,3,2,10,15,03,077,,18,04,041,43,19,85,271,,20,08,214,*7D
+$GPGSV,3,3,10,22,38,053,49,28,15,320,*77
+$GPRMC,141924.00,A,4545.6416,N,00306.6044,E,0.2,197.7,010206,,*31
+$GPGLL,4545.6416,N,00306.6044,E,141924.00,A*09
+$GPGGA,141924.00,4545.2210,N,00306.6044,E,1,05,3.4,500.5,M,,M,,*79
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,197.7,T,,M,0.2,N,0.4,K*6E
+$GPZDA,141924.00,01,02,2006,00,00*6A
+$GPGSV,3,1,10,01,13,142,45,03,48,144,47,11,41,277,,14,27,104,40*74
+$GPGSV,3,2,10,15,03,077,,18,04,041,43,19,85,271,,20,08,214,*7D
+$GPGSV,3,3,10,22,38,053,49,28,15,320,*77
+$GPRMC,141925.00,A,4545.6415,N,00306.6046,E,0.2,130.8,010206,,*33
+$GPGLL,4545.6415,N,00306.6046,E,141925.00,A*09
+$GPGGA,141925.00,4545.2410,N,00306.6046,E,1,05,3.4,501.4,M,,M,,*7C
+$GPGSA,A,3,,03,,22,14,,01,,18,,,,3.9,3.4,1.9*39
+$GPVTG,130.8,T,,M,0.2,N,0.5,K*6D
+$GPZDA,141925.00,01,02,2006,00,00*6B
+$GPGSV,3,1,10,01,13,142,45,03,48,144,47,11,41,277,,14,27,104,40*74
+$GPGSV,3,2,10,15,03,077,,18,04,041,41,19,85,271,,20,08,214,*7F
+$GPGSV,3,3,10,22,38,053,47,28,15,320,*79
+$GPRMC,141926.°E,0.2,260.8,010206,,*34
Index: tag/rc_1/MORARD_Jordan/trame.c
===================================================================
--- tag/rc_1/MORARD_Jordan/trame.c	(nonexistent)
+++ tag/rc_1/MORARD_Jordan/trame.c	(revision 424)
@@ -0,0 +1,28 @@
+/* Fichier trames.c - Gestion et decodage des trames */
+/* Ce fichier sera fourni */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include "trame.h"
+
+#define FICHIER_TRAMES "gps.log"  /* Par exemple */
+
+#define MAX_FRAME_LENGTH 80
+
+static char trame_buf[MAX_FRAME_LENGTH];
+static FILE *trame_fic;
+
+int trame_init(void)
+{
+    trame_fic = fopen(FICHIER_TRAMES, "r");
+    if (trame_fic)
+        return 1;
+
+    fprintf(stderr, "Impossible d'ouvrir le fichier %s\n", FICHIER_TRAMES);
+    return 0;
+}
+
+char *trame_suivante(void)
+{
+  return fgets(trame_buf, MAX_FRAME_LENGTH-1, trame_fic);
+}
Index: tag/rc_1/MORARD_Jordan/sp4a.cbp
===================================================================
--- tag/rc_1/MORARD_Jordan/sp4a.cbp	(nonexistent)
+++ tag/rc_1/MORARD_Jordan/sp4a.cbp	(revision 424)
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
+<CodeBlocks_project_file>
+	<FileVersion major="1" minor="6" />
+	<Project>
+		<Option title="sp4a" />
+		<Option pch_mode="2" />
+		<Option compiler="gcc" />
+		<Build>
+			<Target title="Debug">
+				<Option output="sp4a" prefix_auto="1" extension_auto="1" />
+				<Option object_output=".\debug" />
+				<Option type="1" />
+				<Option compiler="gcc" />
+				<Compiler>
+					<Add option="-g" />
+				</Compiler>
+			</Target>
+		</Build>
+		<Compiler>
+			<Add option="-Wall" />
+		</Compiler>
+		<Unit filename="gps.log" />
+		<Unit filename="main.c">
+			<Option compilerVar="CC" />
+		</Unit>
+		<Unit filename="trame.c">
+			<Option compilerVar="CC" />
+		</Unit>
+		<Unit filename="trame.h" />
+		<Extensions>
+			<code_completion />
+			<envvars />
+			<debugger />
+			<lib_finder disable_auto="1" />
+		</Extensions>
+	</Project>
+</CodeBlocks_project_file>
Index: tag/rc_1/MORARD_Jordan/trame.h
===================================================================
--- tag/rc_1/MORARD_Jordan/trame.h	(nonexistent)
+++ tag/rc_1/MORARD_Jordan/trame.h	(revision 424)
@@ -0,0 +1,3 @@
+
+int trame_init(void);
+char * trame_suivante(void);
