Changeset 657 in Sophya


Ignore:
Timestamp:
Nov 25, 1999, 4:58:46 PM (26 years ago)
Author:
ansari
Message:

4 bit pour bolo on-of/bolo transmis

Location:
trunk/Poubelle/archediab.old
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/Poubelle/archediab.old/SimulMission/simulmission.c

    r647 r657  
    99#include "choix_acquisition.h"
    1010#include "archeops.h"
     11#include "arcunit.h"
    1112#include "choix_param.h"
    1213#include "structure.h"
     
    683684// microvolts -> codage
    684685
     686
    685687def_gains
     688
    686689#define         gainbrut(aa)    ((char)(((aa).mot1&0x1f)))             
    687690#define         gain(aa)        gains_reels[gainbrut(aa)]               
    688 #define codsignal(muv) muv/1.e5 * (65536.*gain(simReglage.bolo[i]))
     691#define         codsignal(muv) (muv/1.e5 * (65536.*gain(simReglage.bolo[i])))
    689692
    690693void PerformScan()
     
    829832  }
    830833       
    831   for(i=5;i<nb_bolo_util;i++)   
     834  for(i=5;i<parametr.nb_bolo;i++)       
    832835    for (j=0; j<nb_per_block*2; j++) {
    833836      blk->data_bolo[i][j] = 0;
     
    844847  SimBlocBolo(tt);
    845848  blk = (block_type_bolo*) &(tt->vi.btt);
    846   for(i=0;i<nb_bolo_util;i++) {
     849  for(i=0;i<parametr.nb_bolo;i++) {
    847850    compress_7_2((unsigned long*)blk->data_bolo[i],(unsigned long*)blk2.data_bolo[i],nb_per_block*2,1);
    848851  }
  • trunk/Poubelle/archediab.old/archediab.sources/c/acquisition_archeops.c

    r652 r657  
    317317jc=0;for(j=0;j<nb_max_bolo;j++)  // jc = bolo_comprime  //   j=bolo normal
    318318                {
    319                 if( (parametr.bolo[j].bolo_code_util==bolo_normal_transmis) &&  (jc<parametr.nb_bolo)  )
     319                if( (parametr.bolo[j].bolo_code_util&bolo_transmis_comprime) &&  (jc<parametr.nb_bolo)  )
    320320                        {
    321321                        decompress_7_2((long *)blk->data_bolo[jc],blk2->data_bolo[j],nb_per_block*2);
  • trunk/Poubelle/archediab.old/archediab.sources/c/arcunit.c

    r652 r657  
    133133for(j=0;(j<nb_max_bolo) && (k<4);j++)
    134134        {
    135         if(param_pt->bolo[j].bolo_code_util==bolo_thermo_simplifie)
     135        if(param_pt->bolo[j].bolo_code_util&bolo_thermo_simplifie)
    136136                {
    137137                if(k==indice_tempe)
     
    159159for(j=0;(j<nb_max_bolo) && (k<4);j++)
    160160        {
    161         if(param_pt->bolo[j].bolo_code_util==bolo_thermo_simplifie)
     161        if(param_pt->bolo[j].bolo_code_util&bolo_thermo_simplifie)
    162162                {
    163163                if(k==indice_tempe)
  • trunk/Poubelle/archediab.old/archediab.sources/c/compress.c

    r637 r657  
    1 #include <manip.h>
     1#include "manip.h"
    22#include "compress.h"
    33
    44
    55/*******************************************************************************************/
    6 /****************                                                                                                               ****************/
    7 /****************                                       compress_3                                                      ****************/
    8 /****************                                                                                                               ****************/
    9 /*******************************************************************************************/
    10 
    11 void  com_3(long val,long* in,long*out,int n,int pasin);
    12 
    13 
    14 #define kmax_   15              /*  valeur maximum de l'exposant        */
    15 #define kmak_   0xf             /*      masque pour l'exposant          */
    16 #define emak_   0x7             /*      masque pour l'ecart             */             
    17 #define sgbi_   0x4             /*      bit de signe de l'ecart         */
    18 #define sign_   0xfffffff8      /*      masque de signe de l'ecart      */
    19 
    20 /*  compress un tableau in de n*9 points disposé avec un pas pasin              */
     6/****************                                                               ************/
     7/****************                                       compress_3              ************/
     8/****************                                                               ************/
     9/*******************************************************************************************/
     10
     11static int filtre[16]={0xfffffff,0xffffffe,0xffffffc,0xffffff8,
     12                0xffffff0,0xfffffe0,0xfffffc0,0xfffff80,
     13                0xfffff00,0xffffe00,0xffffc00,0xffff800,
     14                0xffff000,0xfffe000,0xfffc000,0xfff8000};
     15int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
     16                0x00000008,0x00000010,0x00000020,0x00000040,
     17                0x00000080,0x00000100,0x00000200,0x00000400,
     18                0x00000800,0x00001000,0x00002000,0x00004000};
     19
     20
     21void  com_3(unsigned long val,unsigned long* in,unsigned long*out,int n,int pasin);
     22
     23#define data_mask       0xffff  /* masque pour les données en entree    */
     24#define ecart_(i,n,val)         (( (in[(i*9+n)*pasin]&data_mask) | ecart_bit )-val);
     25
     26#define ecart_mask              0x7     /*      masque pour l'ecart             */             
     27
     28
     29
     30/*  compress un tableau in de n*9 points disposé avec un pas pasin      */
    2131/*  les data compressées sont ecrites dans le tableau out de n points   */
    22 /*  la valeur val est la valeur de reference du point origine                   */
    23 
    24 
    25 /*  comprime    9*n points  : 1er point dans 1er mot, tous les ecarts dans les n mots suivants          */
    26 /*      9*n     ==>     n+1         pour  72 points :   9 mots                  */
    27 
    28 void compress_3_1(long* in,long*out,int n,int pasin)
    29 {
    30 long val;
     32/*  la valeur val est la valeur de reference du point origine           */
     33
     34
     35/*  comprime    9*n points  : 1er point dans 1er mot                    */
     36/*                            tous les ecarts dans les n mots suivants  */
     37/*      9*n     ==>     n+1         pour  72 points :   9 mots          */
     38
     39void compress_3_1(unsigned long* in,unsigned long*out,int n,int pasin)
     40{
     41unsigned long val;
    3142val=in[0]; out[0]=val;
    3243com_3(val,in,out+1,n/9,pasin);
     
    3546
    3647
    37 void  com_3(long val,long* in,long*out,int n,int pasin)
    38 {
    39 int filtre[16]={0xffffffff,0xfffffffe,0xfffffffc,0xfffffff8,
    40                                 0xfffffff0,0xffffffe0,0xffffffc0,0xffffff80,
    41                                 0xffffff00,0xfffffe00,0xfffffc00,0xfffff800,
    42                                 0xfffff000,0xffffe000,0xffffc000,0xffff8000};
    43 int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
    44                                 0x00000008,0x00000010,0x00000020,0x00000040,
    45                                 0x00000080,0x00000100,0x00000200,0x00000400,
    46                                 0x00000800,0x00001000,0x00002000,0x00004000};
    47 
    48 long val1;
    49 long ec1,ec2,ec3,ec4,ec5,ec6,ec7,ec8,ec9;
    50 int i,k,k1;long q;
     48
     49void  com_3(unsigned long val,unsigned long* in,unsigned long*out,int n,int pasin)
     50{
     51unsigned long val1;
     52unsigned long ec1,ec2,ec3,ec4,ec5,ec6,ec7,ec8,ec9;
     53int i,k,k1;unsigned long q;
    5154
    5255
     
    5558        k=0;q=3;        /* 3 bit = 7 = +-3      */
    5659
    57         ec1=in[i*9*pasin]-val;
     60        ec1=ecart_(i,0,val);
    5861        shif(ec1,k,q);
    59         val1=val + arrondi(ec1,k);
     62        val1=new_val(val,ec1,k);
    6063       
    6164        k1=k;
    62         ec2=in[(i*9+1)*pasin]-val1;
     65        ec2=ecart_(i,1,val1);
    6366        shif(ec2,k,q);
    6467       
    65         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k);}
    66         val1+= arrondi(ec2,k);
    67 
    68         ec3=in[(i*9+2)*pasin]-val1;
     68        if(k>k1)        {k1=k;val1=new_val(val,ec1,k);}
     69        val1=new_val(val1,ec2,k);
     70
     71        ec3=ecart_(i,2,val1);
    6972        shif(ec3,k,q);
    7073
    71         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k);}
    72         val1+= arrondi(ec3,k);         
    73 
    74         ec4=in[(i*9+3)*pasin]-val1;
     74        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k))&data_mask;}
     75        val1=new_val(val1,ec3,k);
     76
     77        ec4=ecart_(i,3,val1);
    7578        shif(ec4,k,q);
    7679
    77         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k);}
    78         val1+= arrondi(ec4,k);         
    79 
    80         ec5=in[(i*9+4)*pasin]-val1;
     80        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k))&data_mask;}
     81        val1=new_val(val1,ec4,k);
     82
     83        ec5=ecart_(i,4,val1);
    8184        shif(ec5,k,q);
    8285
    83         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k) + arrondi(ec4,k);}
    84         val1+= arrondi(ec5,k);         
    85        
    86         ec6=in[(i*9+5)*pasin]-val1;
     86        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
     87                                + arrondi(ec4,k))&data_mask;}
     88        val1=new_val(val1,ec5,k);
     89       
     90        ec6=ecart_(i,5,val1);
    8791        shif(ec6,k,q);
    8892
    89         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
    90                                          + arrondi(ec4,k) + arrondi(ec5,k);}
    91         val1+= arrondi(ec6,k);         
    92        
    93         ec7=in[(i*9+6)*pasin]-val1;
     93        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
     94                                        + arrondi(ec4,k) + arrondi(ec5,k))&data_mask;}
     95        val1=new_val(val1,ec6,k);
     96       
     97        ec7=ecart_(i,6,val1);
    9498        shif(ec7,k,q);
    9599
    96         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k)
    97                                 + arrondi(ec3,k) + arrondi(ec4,k) + arrondi(ec5,k) + arrondi(ec6,k);}
    98         val1+= arrondi(ec7,k);         
    99        
    100         ec8=in[(i*9+7)*pasin]-val1;
     100        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k)
     101                                + arrondi(ec3,k) + arrondi(ec4,k) + arrondi(ec5,k) + arrondi(ec6,k))&data_mask;}
     102        val1=new_val(val1,ec7,k);
     103       
     104        ec8=ecart_(i,7,val1);
    101105        shif(ec8,k,q);
    102106
    103         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
    104                                          + arrondi(ec4,k) + arrondi(ec5,k) + arrondi(ec6,k) + arrondi(ec7,k);}
    105         val1+= arrondi(ec8,k);         
    106        
    107         ec9=in[(i*9+8)*pasin]-val1;
     107        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
     108                                         + arrondi(ec4,k) + arrondi(ec5,k) + arrondi(ec6,k) + arrondi(ec7,k))&data_mask;}
     109        val1=new_val(val1,ec8,k);
     110       
     111        ec9=ecart_(i,8,val1);
    108112        shif(ec9,k,q);
    109113       
     
    120124        ec9 =  arrondi(ec9,k) >> k;
    121125
    122         out[i]= ((ec1&emak_)<<29) | ((ec2&emak_)<<26) | ((ec3&emak_)<<23)
    123                                 | ((ec4&emak_)<<20) | ((ec5&emak_)<<17) | ((ec6&emak_)<<14)
    124                                 | ((ec7&emak_)<<11)  | ((ec8&emak_)<<8) | ((ec9&emak_)<<5) | k ;
     126        out[i]= ((ec1&ecart_mask)<<29) | ((ec2&ecart_mask)<<26) | ((ec3&ecart_mask)<<23)
     127                | ((ec4&ecart_mask)<<20) | ((ec5&ecart_mask)<<17) | ((ec6&ecart_mask)<<14)
     128                | ((ec7&ecart_mask)<<11)  | ((ec8&ecart_mask)<<8) | ((ec9&ecart_mask)<<5) | k ;
    125129
    126130
    127131/*      if(i<30)  printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);*/
    128132
    129         val+= ( (ec1 + ec2 + ec3 + ec4 + ec5 + ec6 + ec7 + ec8 + ec9 ) << k );
     133        val=(val + ( (ec1 + ec2 + ec3 + ec4 + ec5 + ec6 + ec7 + ec8 + ec9 ) << k )) & data_mask;
    130134        }
    131135}
     
    139143/*******************************************************************************************/
    140144
    141 void  com_4(long val,long* in,long*out,int n,int pasin);
    142 void  com_4_paire(long val1,long val2,long* in,long*out,int n,int pasin);
    143 
    144 
    145 #undef kmax_
    146 #undef  kmak_
    147 #undef  emak_           
    148 #undef  sgbi_
    149 #undef  sign_
    150 
    151 
    152 #define kmax_   15              /*  valeur maximum de l'exposant        */
    153 #define kmak_   0xf             /*      masque pour l'exposant          */
    154 #define emak_   0xf             /*      masque pour l'ecart             */             
    155 #define sgbi_   0x8             /*      bit de signe de l'ecart         */
    156 #define sign_   0xfffffff0      /*      masque de signe de l'ecart      */
     145void  com_4(unsigned long val,unsigned long* in,unsigned long*out,int n,int pasin);
     146void  com_4_paire(unsigned long val1,unsigned long val2,unsigned long* in,unsigned long*out,int n,int pasin);
     147
     148
     149#undef  ecart_mask             
     150#define ecart_mask      0xf             /*      masque pour l'ecart             */             
     151
     152#undef  data_mask
     153#define data_mask       0xffff  /* masque pour les données en entree    */
     154#undef  ecart_
     155#define ecart_(i,n,val)         (( (in[(i*7+n)*pasin]&data_mask) | ecart_bit )-val);
     156
    157157
    158158/*  compress un tableau in de n*7 points disposé avec un pas pasin      */
     
    165165/*      7*n + 2 ==>     n+1          ==>   pour  72 points :   11 mots                          */
    166166
    167 void compress_4_1(long* in,long*out,int n,int pasin)
    168 {
    169 long val1,val2;
     167void compress_4_1(unsigned long* in,unsigned long*out,int n,int pasin)
     168{
     169unsigned long val1,val2;
    170170val1=in[0];val2=in[1];
    171171*out=( (val1<<16) & 0xffff0000 )        |       ( ( val2 ) & 0xffff ) ;
     
    176176
    177177
    178 void  com_4(long val,long* in,long*out,int n,int pasin)
    179 {
    180 int filtre[16]={0xffffffff,0xfffffffe,0xfffffffc,0xfffffff8,
    181                                 0xfffffff0,0xffffffe0,0xffffffc0,0xffffff80,
    182                                 0xffffff00,0xfffffe00,0xfffffc00,0xfffff800,
    183                                 0xfffff000,0xffffe000,0xffffc000,0xffff8000};
    184 int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
    185                                 0x00000008,0x00000010,0x00000020,0x00000040,
    186                                 0x00000080,0x00000100,0x00000200,0x00000400,
    187                                 0x00000800,0x00001000,0x00002000,0x00004000};
    188 
    189 long val1;
    190 long ec1,ec2,ec3,ec4,ec5,ec6,ec7;
    191 int i,k,k1;long q;
     178void  com_4(unsigned long val,unsigned long* in,unsigned long*out,int n,int pasin)
     179{
     180unsigned long val1;
     181unsigned long ec1,ec2,ec3,ec4,ec5,ec6,ec7;
     182int i,k,k1;unsigned long q;
    192183
    193184
     
    196187        k=0;q=7;        /* 4 bit = 15 = +-7     */
    197188
    198         ec1=in[i*7*pasin]-val;
     189        ec1=ecart_(i,0,val);
    199190        shif(ec1,k,q);
    200         val1=val + arrondi(ec1,k);
     191        val1=new_val(val,ec1,k);
    201192       
    202193        k1=k;
    203         ec2=in[(i*7+1)*pasin]-val1;
     194        ec2=ecart_(i,1,val1);
    204195        shif(ec2,k,q);
    205196       
    206         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k);}
    207         val1+= arrondi(ec2,k);
    208 
    209         ec3=in[(i*7+2)*pasin]-val1;
     197        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k))&data_mask;}
     198        val1=new_val(val1,ec2,k);
     199
     200        ec3=ecart_(i,2,val1);
    210201        shif(ec3,k,q);
    211202
    212         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k);}
    213         val1+= arrondi(ec3,k);         
    214 
    215         ec4=in[(i*7+3)*pasin]-val1;
     203        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k))&data_mask;}
     204        val1=new_val(val1,ec3,k);
     205
     206        ec4=ecart_(i,3,val1);
    216207        shif(ec4,k,q);
    217208
    218         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k);}
    219         val1+= arrondi(ec4,k);         
    220 
    221         ec5=in[(i*7+4)*pasin]-val1;
     209        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k))&data_mask;}
     210        val1=new_val(val1,ec4,k);
     211
     212        ec5=ecart_(i,4,val1);
    222213        shif(ec5,k,q);
    223214
    224         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k) + arrondi(ec4,k);}
    225         val1+= arrondi(ec5,k);         
    226        
    227         ec6=in[(i*7+5)*pasin]-val1;
     215        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k) + arrondi(ec4,k))&data_mask;}
     216        val1=new_val(val1,ec5,k);
     217       
     218        ec6=ecart_(i,5,val1);
    228219        shif(ec6,k,q);
    229220
    230         if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
    231                                          + arrondi(ec4,k) + arrondi(ec5,k);}
    232         val1+= arrondi(ec6,k);         
    233        
    234         ec7=in[(i*7+6)*pasin]-val1;
     221        if(k>k1)        {k1=k;val1=(val + arrondi(ec1,k) + arrondi(ec2,k) + arrondi(ec3,k)
     222                                         + arrondi(ec4,k) + arrondi(ec5,k))&data_mask;}
     223        val1=new_val(val1,ec6,k);
     224       
     225        ec7=ecart_(i,6,val1);
    235226        shif(ec7,k,q);
    236227       
     
    245236        ec7 =  arrondi(ec7,k) >> k;
    246237
    247         out[i]= ((ec1&emak_)<<28) | ((ec2&emak_)<<24) | ((ec3&emak_)<<20)
    248                                 | ((ec4&emak_)<<16) | ((ec5&emak_)<<12) | ((ec6&emak_)<<8) | ((ec7&emak_)<<4) | k ;
     238        out[i]= ((ec1&ecart_mask)<<28) | ((ec2&ecart_mask)<<24) | ((ec3&ecart_mask)<<20)
     239                                | ((ec4&ecart_mask)<<16) | ((ec5&ecart_mask)<<12) | ((ec6&ecart_mask)<<8) | ((ec7&ecart_mask)<<4) | k ;
    249240
    250241
    251242/*      if(i<30)  printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);*/
    252243
    253         val+= ( (ec1 + ec2 + ec3 + ec4 + ec5 + ec6 + ec7 ) << k );
     244        val=(val+ ( (ec1 + ec2 + ec3 + ec4 + ec5 + ec6 + ec7 ) << k ))&data_mask;
    254245        }
    255246}
     
    264255/*      7*n+2   ==>     n+2                     ==>  pour 72 points :           12 mots                                                         */
    265256
    266 void compress_4_2(long* in,long*out,int n,int pasin)
    267 {
    268 long val1,val2;
    269 val1=in[0];             val2=in[1];
     257#undef  data_mask
     258#define data_mask       0x1fffff        /* masque pour les données en entree 21 bit     */
     259#undef  ecart_
     260#define ecart_(i,n,val)         (( (in[(i*7+n)*pasin]&data_mask) | ecart_bit )-val);
     261
     262void compress_4_2(unsigned long* in,unsigned long*out,int n,int pasin)
     263{
     264unsigned long val1,val2;
     265val1=in[0]&data_mask;           val2=in[1]&data_mask;
    270266out[0]=val1;    out[1]=val2;
    271267com_4_paire(val1,val2,in+2,out+2,n/7,pasin);
     
    273269
    274270
    275 void  com_4_paire(long val1,long val2,long* in,long*out,int n,int pasin)
    276 {
    277 int filtre[16]={0xffffffff,0xfffffffe,0xfffffffc,0xfffffff8,
    278                                 0xfffffff0,0xffffffe0,0xffffffc0,0xffffff80,
    279                                 0xffffff00,0xfffffe00,0xfffffc00,0xfffff800,
    280                                 0xfffff000,0xffffe000,0xffffc000,0xffff8000};
    281 int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
    282                                 0x00000008,0x00000010,0x00000020,0x00000040,
    283                                 0x00000080,0x00000100,0x00000200,0x00000400,
    284                                 0x00000800,0x00001000,0x00002000,0x00004000};
    285 
    286 long val1p,val2p;
    287 long ec1,ec2,ec3,ec4,ec5,ec6,ec7;
    288 int i,k,k1;long q;
     271void  com_4_paire(unsigned long val1,unsigned long val2,unsigned long* in,unsigned long*out,int n,int pasin)
     272{
     273unsigned long val1p,val2p;
     274unsigned long ec1,ec2,ec3,ec4,ec5,ec6,ec7;
     275int i,k,k1;unsigned long q;
    289276
    290277
     
    293280        k=0;q=7;        /* 4 bit = 15 = +-7     */
    294281
    295         ec1=in[i*7*pasin]-val1;
     282        ec1=ecart_(i,0,val1);
    296283        shif(ec1,k,q);
    297284       
    298         ec2=in[(i*7+1)*pasin]-val2;
     285        ec2=ecart_(i,1,val2);
    299286        shif(ec2,k,q);
    300287       
    301288        k1=k;
    302         val1p=val1 + arrondi(ec1,k);
    303 
    304 
    305         ec3=in[(i*7+2)*pasin]-val1p;
     289        val1p=new_val(val1,ec1,k);
     290
     291
     292        ec3=ecart_(i,2,val1p);
    306293        shif(ec3,k,q);
    307294
    308         val2p=val2 + arrondi(ec2,k);
    309 
    310         ec4=in[(i*7+3)*pasin]-val2p;
     295        val2p=new_val(val2,ec2,k);
     296
     297        ec4=ecart_(i,3,val2p);
    311298        shif(ec4,k,q);
    312299
    313         if(k>k1)        {k1=k;val1p=val1 + arrondi(ec1,k);val2p = val2 + arrondi(ec2,k);}
    314        
    315         val1p+= arrondi(ec3,k);         
    316 
    317         ec5=in[(i*7+4)*pasin]-val1p;
     300        if(k>k1)        {k1=k;val1p=new_val(val1,ec1,k);val2p=new_val(val2,ec2,k);}
     301       
     302        val1p=new_val(val1p,ec3,k);             
     303
     304        ec5=ecart_(i,4,val1p);
    318305        shif(ec5,k,q);
    319306
    320307        if(k>k1)        {       k1=k;
    321                                 val1p=val1 + arrondi(ec1,k) + arrondi(ec3,k);
    322                                 val2p=val2 + arrondi(ec2,k);
     308                                val1p=(val1 + arrondi(ec1,k) + arrondi(ec3,k))&data_mask;
     309                                val2p=(val2 + arrondi(ec2,k))&data_mask;
    323310                                }
    324         val2p+= arrondi(ec4,k);         
    325        
    326         ec6=in[(i*7+5)*pasin]-val2p;
     311        val2p=new_val(val2p,ec4,k);             
     312       
     313        ec6=ecart_(i,5,val2p);
    327314        shif(ec6,k,q);
    328315
    329316        if(k>k1)        {       k1=k;
    330                                 val1p=val1 + arrondi(ec1,k) + arrondi(ec3,k);
    331                                 val2p=val2 + arrondi(ec2,k) + arrondi(ec4,k);
     317                                val1p=(val1 + arrondi(ec1,k) + arrondi(ec3,k))&data_mask;
     318                                val2p=(val2 + arrondi(ec2,k) + arrondi(ec4,k))&data_mask;
    332319                                }
    333         val1p+= arrondi(ec5,k);         
    334        
    335         ec7=in[(i*7+6)*pasin]-val1p;
     320        val1p=new_val(val1p,ec5,k);             
     321       
     322        ec7=ecart_(i,6,val1p);
    336323        shif(ec7,k,q);
    337324       
     
    346333        ec7 =  arrondi(ec7,k) >> k;
    347334
    348         out[i]= ((ec1&emak_)<<28) | ((ec2&emak_)<<24) | ((ec3&emak_)<<20)
    349                                 | ((ec4&emak_)<<16) | ((ec5&emak_)<<12) | ((ec6&emak_)<<8) | ((ec7&emak_)<<4) | k ;
     335        out[i]= ((ec1&ecart_mask)<<28) | ((ec2&ecart_mask)<<24) | ((ec3&ecart_mask)<<20)
     336                                | ((ec4&ecart_mask)<<16) | ((ec5&ecart_mask)<<12) | ((ec6&ecart_mask)<<8) | ((ec7&ecart_mask)<<4) | k ;
    350337
    351338
    352339/*      if(i<30)  printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);*/
    353340
    354         val1p = val1 + ( (ec1 + ec3 + ec5 + ec7 ) << k );
    355         val1= val2 + ( (ec2 + ec4       + ec6 ) << k );
     341        val1p = (val1 + ( (ec1 + ec3 + ec5 + ec7 ) << k ))&data_mask;
     342        val1= (val2 + ( (ec2 + ec4      + ec6 ) << k ))&data_mask;
    356343        val2 = val1p;
    357344        }
     
    368355/*******************************************************************************************/
    369356
    370 
    371 void  compress_7(long val,long* in,long*out,int n,int pasin);
    372 void  compress_7_paire(long val1,long val2,long* in,long*out,int n,int pasin);
    373 
    374 
    375 #undef kmax_
    376 #undef  kmak_
    377 #undef  emak_           
    378 #undef  sgbi_
    379 #undef  sign_
    380 
    381 
    382 
    383 #define kmax_   15              /*  valeur maximum de l'exposant        */
    384 #define kmak_   0xf             /*      masque pour l'exposant          */
    385 #define emak_   0x7f            /*      masque pour l'ecart             */             
    386 #define sgbi_   0x40            /*      bit de signe de l'ecart         */
    387 #define sign_   0xffffff80      /*      masque de signe de l'ecart      */
    388 
    389 
    390 /*  comprime    4*n points  : 1er point dans 1er mot, tous les ecarts dans les n mots suivants          */
     357/*******************************************************************************************/
     358
     359/*  compresse en 7 bit mais par paire (pour data provenant de la detection synchrone      */
     360
     361/* ne prend que les 21 bit de poid faible dans le mot en entree                 */
     362/*  comprime    4*n points  : 1er et 2eme point dans 1er mot (16 bit chacun),  suite dans n mots                */
     363/*              différences entre valeures paires  et entre valeures impaires uniquement                        */
    391364/*      4*n     ==>     n+1     */
    392365
    393 void compress_7_1(long* in,long*out,int n,int pasin)
    394 {
    395 long val;
    396 val=*in;
    397 *out=val;
    398 compress_7(val,in,out+1,n/4,pasin);
    399 }
    400 
    401 
    402 
    403 /*  compress un tableau in de n*4 points disposé avec un pas pasin      */
    404 /*  les data compressées sont ecrites dans le tableau out de n points   */
    405 /*  la valeur val est la valeur de reference du point origine   */
    406 
    407 void  compress_7(long val,long* in,long*out,int n,int pasin)
    408 {
    409 int filtre[16]={0xffffffff,0xfffffffe,0xfffffffc,0xfffffff8,
    410                                 0xfffffff0,0xffffffe0,0xffffffc0,0xffffff80,
    411                                 0xffffff00,0xfffffe00,0xfffffc00,0xfffff800,
    412                                 0xfffff000,0xffffe000,0xffffc000,0xffff8000};
    413 int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
    414                                 0x00000008,0x00000010,0x00000020,0x00000040,
    415                                 0x00000080,0x00000100,0x00000200,0x00000400,
    416                                 0x00000800,0x00001000,0x00002000,0x00004000};
    417 
    418 long val1;
    419 long ec1,ec2,ec3,ec4;
    420 int i,k,k1;long q;
     366
     367
     368void  compress_7_paire(unsigned long val1,unsigned long val2,unsigned long* in,unsigned long*out,int n,int pasin);
     369
     370#undef  data_mask
     371#define data_mask       0x1fffff        /* masque pour les données en entree 21 bit     */
     372#undef  ecart_mask             
     373#define ecart_mask              0x7f            /*      masque pour l'ecart 7 bits              */             
     374
     375#undef   ecart_
     376#define ecart_(i,n,val)         (( (in[(i*4+n)*pasin]&data_mask) | ecart_bit )-val);
     377
     378
     379void compress_7_2(unsigned long* in,unsigned long*out,int n,int pasin)
     380{
     381unsigned long val1,val2;
     382val1=in[0]&0x1fffe0;val2=in[pasin]&0x1fffe0;
     383*out=( (val1<<11) & 0xffff0000 )        |       ( (val2 >> 5) & 0xffff ) ;
     384
     385/*printf("in[0]=%x  val1=%x        in[1]=%x   val2=%x  \n",in[0],val1,in[1],val2);
     386printf("in[2]=%x    in[3]=%x   \n",in[2],in[3]);*/
     387compress_7_paire(val1,val2,in,out+1,n/4,pasin);
     388}
     389
     390
     391void  compress_7_paire(unsigned long val1,unsigned long val2,unsigned long* in,unsigned long*out,int n,int pasin)
     392{
     393
     394unsigned long val1p,val2p;
     395unsigned long ec1,ec2,ec3,ec4;
     396int i,k;unsigned long q;
    421397
    422398
     
    425401        k=0;q=63;               /* 7 bit ->  127  ->   +-63     */
    426402
    427         ec1=in[i*4*pasin]-val;
    428         shif(ec1,k,q);
    429         val1=val + arrondi(ec1,k);
    430        
    431         k1=k;
    432         ec2=in[(i*4+1)*pasin]-val1;
    433         shif(ec2,k,q);
    434        
    435 /*      if(k>k1)        {k1=k;val1=val + arrondi(ec1,k);}       */
    436         val1+= arrondi(ec2,k);
    437 
    438         ec3=in[(i*4+2)*pasin]-val1;
    439         shif(ec3,k,q);
    440 
    441 /*      if(k>k1)        {k1=k;val1=val + arrondi(ec1,k) + arrondi(ec2,k);}      */
    442         val1+= arrondi(ec3,k);         
    443 
    444         ec4=in[(i*4+3)*pasin]-val1;
    445         shif(ec4,k,q);
    446        
    447 /*printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);   */
    448 
     403        ec1=ecart_(i,0,val1);   shif(ec1,k,q); 
     404       
     405        ec2=ecart_(i,1,val2);   shif(ec2,k,q);
     406        val1p =new_val(val1,ec1,k);
     407
     408        ec3=ecart_(i,2,val1p);  shif(ec3,k,q);
     409        val2p=new_val(val2,ec2,k);
     410
     411        ec4=ecart_(i,3,val2p);  shif(ec4,k,q);
     412       
    449413        ec1 =  arrondi(ec1,k) >> k;
    450414        ec2 =  arrondi(ec2,k) >> k;
     
    452416        ec4 =  arrondi(ec4,k) >> k;
    453417
    454         out[i]= ((ec1&emak_)<<25) | ((ec2&emak_)<<18) | ((ec3&emak_)<<11) | ((ec4&emak_)<<4) | k ;
    455 
    456 /*      if(i<30)  printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);   */
    457 
    458         val+= ( (ec1 + ec2 + ec3 + ec4 ) << k );
     418        out[i]= ((ec1&ecart_mask)<<25) | ((ec2&ecart_mask)<<18) | ((ec3&ecart_mask)<<11) | ((ec4&ecart_mask)<<4) | k ;
     419
     420        /*if(i<5)  printf("i=%d  k=%d  ec= %x %x %x %x  out=%x \n",i,k,ec1,ec2,ec3,ec4,out[i]); */
     421
     422        val1=(val1+ ( (ec1 + ec3 ) << k ))&data_mask;
     423        val2=(val2+ ( (ec2 + ec4 ) << k ))&data_mask;
    459424        }
    460425}
    461426
    462427
    463 /*******************************************************************************************/
    464 
    465 /*  compresse en 7 bit mais par paire (pour data provenant de la detection synchrone      */
    466 
    467 /* ne prend que les 21 bit de poid faible dans le mot en entree                 */
    468 /*  comprime    4*n points  : 1er et 2eme point dans 1er mot (16 bit chacun),  suite dans n mots                */
    469 /*              différences entre valeures paires  et entre valeures impaires uniquement                        */
    470 /*      4*n     ==>     n+1     */
    471 
    472 #define  point_in(i,pasin,n)  (in[(i*4+n)*pasin]&0x1fffff)
    473 
    474 
    475 void compress_7_2(long* in,long*out,int n,int pasin)
    476 {
    477 long val1,val2;
    478 val1=in[0]&0x1fffe0;val2=in[1]&0x1fffe0;
    479 *out=( (val1<<11) & 0xffff0000 )        |       ( (val2 >> 5) & 0xffff ) ;
    480 
    481 /*printf("in[0]=%x  val1=%x   //    in[1]=%x   val2=%x  \n",in[0],val1,in[1],val2);
    482 printf("in[2]=%x    in[3]=%x   \n",in[2],in[3]);*/
    483 compress_7_paire(val1,val2,in,out+1,n/4,pasin);
    484 }
    485 
    486 
    487 void  compress_7_paire(long val1,long val2,long* in,long*out,int n,int pasin)
    488 {
    489 int filtre[16]={0xffffffff,0xfffffffe,0xfffffffc,0xfffffff8,
    490                                 0xfffffff0,0xffffffe0,0xffffffc0,0xffffff80,
    491                                 0xffffff00,0xfffffe00,0xfffffc00,0xfffff800,
    492                                 0xfffff000,0xffffe000,0xffffc000,0xffff8000};
    493 int test[16]=  {0x00000000,0x00000001,0x00000002,0x00000004,
    494                                 0x00000008,0x00000010,0x00000020,0x00000040,
    495                                 0x00000080,0x00000100,0x00000200,0x00000400,
    496                                 0x00000800,0x00001000,0x00002000,0x00004000};
    497 
    498 long val1p,val2p;
    499 long ec1,ec2,ec3,ec4;
    500 int i,k;long q;
    501 
    502 
    503 for(i=0;i<n;i++)
    504         {
    505         k=0;q=63;               /* 7 bit ->  127  ->   +-63     */
    506 
    507         ec1=point_in(i,pasin,0)-val1;
    508         shif(ec1,k,q);
    509        
    510        
    511         ec2=point_in(i,pasin,1)-val2;
    512         shif(ec2,k,q);
    513                
    514         val1p =val1 + arrondi(ec1,k);
    515 
    516         ec3=point_in(i,pasin,2)-val1p;
    517         shif(ec3,k,q);
    518 
    519         val2p=val2+ arrondi(ec2,k);
    520 
    521         ec4=point_in(i,pasin,3)-val2p;
    522         shif(ec4,k,q);
    523        
    524 /*printf("i=%d  k=%d  ec= %d %d %d \n",i,k,ec1,ec2,ec3,out[(i+8)/7]);   */
    525 
    526         ec1 =  arrondi(ec1,k) >> k;
    527         ec2 =  arrondi(ec2,k) >> k;
    528         ec3 =  arrondi(ec3,k) >> k;
    529         ec4 =  arrondi(ec4,k) >> k;
    530 
    531         out[i]= ((ec1&emak_)<<25) | ((ec2&emak_)<<18) | ((ec3&emak_)<<11) | ((ec4&emak_)<<4) | k ;
    532 
    533 /*      if(i<5)  printf("i=%d  k=%d  ec= %x %x %x %x  out=%x \n",i,k,ec1,ec2,ec3,ec4,out[i]);*/
    534 
    535         val1+= ( (ec1 + ec3 ) << k );
    536         val2+= ( (ec2 + ec4 ) << k );
    537         }
    538 }
    539 
    540 
    541 
    542 
     428
     429
  • trunk/Poubelle/archediab.old/archediab.sources/c/decompress.c

    r637 r657  
    99//*******************************************************************************************
    1010
     11#define ecart_mask              0x7     /*      masque pour l'ecart             */             
     12
    1113void  decom_3(long val,long* in,long*out,int n);
    1214
    13 #define kmax_   15              /*  valeur maximum de l'exposant        */
    14 #define kmak_   0xf             /*      masque pour l'exposant          */
    15 #define emak_   0x7             /*      masque pour l'ecart             */             
     15#define k_mask  0xf             /*      masque pour l'exposant          */
    1616#define sgbi_   0x4             /*      bit de signe de l'ecart         */
    1717#define sign_   0xfffffff8      /*      masque de signe de l'ecart      */
     
    4343        {
    4444        R=in[i];
    45         k=R&kmak_;
     45        k=R&k_mask;
    4646        recup(ec1,29,k);
    4747        recup(ec2,26,k);
     
    7777void  decom_4_paire(long val1,long val2,long* in,long*out,int n);
    7878
    79 #undef kmax_
    80 #undef  kmak_
    81 #undef  emak_           
     79#undef  ecart_mask             
     80#define ecart_mask      0xf             /*      masque pour l'ecart             */             
    8281#undef  sgbi_
    8382#undef  sign_
     
    8584
    8685
    87 #define kmax_   15              /*  valeur maximum de l'exposant        */
    88 #define kmak_   0xf             /*      masque pour l'exposant          */
    89 #define emak_   0xf             /*      masque pour l'ecart             */             
     86#define k_mask  0xf             /*      masque pour l'exposant          */
    9087#define sgbi_   0x8             /*      bit de signe de l'ecart         */
    9188#define sign_   0xfffffff0      /*      masque de signe de l'ecart      */
     
    118115        {
    119116        R=in[i];
    120         k=R&kmak_;
     117        k=R&k_mask;
    121118        recup(ec1,28,k);
    122119        recup(ec2,24,k);
     
    165162        {
    166163        R=in[i];
    167         k=R&kmak_;
     164        k=R&k_mask;
    168165        recup(ec1,28,k);
    169166        recup(ec2,24,k);
     
    195192//*******************************************************************************************
    196193
    197 
    198 #undef kmax_
    199 #undef  kmak_
    200 #undef  emak_           
    201194#undef  sgbi_
    202195#undef  sign_
    203196
    204197
    205 
    206 #define kmax_   15              /*  valeur maximum de l'exposant        */
    207 #define kmak_   0xf             /*      masque pour l'exposant          */
    208 #define emak_   0x7f            /*      masque pour l'ecart             */             
     198#undef  ecart_mask             
     199#define ecart_mask              0x7f            /*      masque pour l'ecart 7 bits              */             
    209200#define sgbi_   0x40            /*      bit de signe de l'ecart         */
    210201#define sign_   0xffffff80      /*      masque de signe de l'ecart      */
     
    239230        {
    240231        R=in[i];
    241         k=R&kmak_;
     232        k=R&k_mask;
    242233        recup(ec1,25,k);
    243234        recup(ec2,18,k);
     
    282273        {
    283274        R=in[i];
    284         k=R&kmak_;
     275        k=R&k_mask;
    285276        recup(ec1,25,k);
    286277        recup(ec2,18,k);
     
    293284        val2+=ec4;      out[4*i+3]=val2;         
    294285
    295 /*if(i<5)  printf("in=%x  i=%d  k=%d  ec= %x %x %x %x  \n",R,i,k,ec1,ec2,ec3,ec4);      */
    296 
    297         }
    298 }
    299 
    300 
     286/*if(i<5)  printf("in=%x  i=%d  k=%d  ec= %x %x %x %x  \n",R,i,k,ec1,ec2,ec3,ec4);*/   
     287
     288        }
     289}
     290
     291
  • trunk/Poubelle/archediab.old/archediab.sources/c/diabolo.c

    r656 r657  
    9292#endif
    9393
     94
    9495#ifdef _archeops
    9596//nouveauD(fenetre_vitesse_block,config_transputer_id,"config_transputer",exec_config_transputer);
     
    117118                        printf(" capa=%g ",capa(j+1));
    118119                        printf(" boloutil = %d  bolonom = %s  \n",parametr.bolo[j].bolo_code_util,parametr.nom_coef[parametr.bolo[j].numero_nom_coef].bolo_nom);
    119                         if( parametr.bolo[j].bolo_code_util==bolo_normal_transmis)              parametr.nb_bolo++;
     120                        if( parametr.bolo[j].bolo_code_util&bolo_transmis_comprime)             parametr.nb_bolo++;
    120121                        if(parametr.bolo[j].bolo_code_util)
    121122                                {
  • trunk/Poubelle/archediab.old/archediab.sources/c/dilution.c

    r651 r657  
    235235for(j=0;(j<nb_max_bolo) && (k<4);j++)
    236236        {
    237         if(parametr.bolo[j].bolo_code_util==bolo_thermo_simplifie)
     237        if(parametr.bolo[j].bolo_code_util&bolo_thermo_simplifie)
    238238                {
    239239                I = 1e-3 * (double)dac_V(gg->reglage.bolo[j]) * 2441. / parametr.bolo[j].bolo_capa;     //      I en µA
  • trunk/Poubelle/archediab.old/archediab.sources/h/compress.h

    r637 r657  
    1717/*      pour    n = 72    en sortie     19 mots = 76 octets             */
    1818
    19 void compress_7_1(long* in,long*out,int n,int pasin);
     19void compress_7_1(unsigned long* in,unsigned long*out,int n,int pasin);
    2020void decompress_7_1(long* in,long*out,int n);
    2121
     
    2929/*      pour    n = 72    en sortie     11 mots = 44 octets             */
    3030
    31 void compress_4_1(long* in,long*out,int n,int pasin);
     31void compress_4_1(unsigned long* in,unsigned long*out,int n,int pasin);
    3232void decompress_4_1(long* in,long*out,int n);
    3333
     
    4242
    4343
    44 void compress_3_1(long* in,long*out,int n,int pasin);
     44void compress_3_1(unsigned long* in,unsigned long*out,int n,int pasin);
    4545void decompress_3_1(long* in,long*out,int n);
    4646
     
    6363
    6464
    65 void compress_7_2(long* in,long*out,int n,int pasin);
     65void compress_7_2(unsigned long* in,unsigned long*out,int n,int pasin);
    6666void decompress_7_2(long* in,long*out,int n);
    6767
     
    7878
    7979
    80 void compress_4_2(long* in,long*out,int n,int pasin);
     80void compress_4_2(unsigned long* in,unsigned long*out,int n,int pasin);
    8181void decompress_4_2(long* in,long*out,int n);
    8282
     
    8989/************************************************************************/
    9090
    91 /*Les valeures de la table d'entree sont consideres comme toujopurs positives   */
    92 /* les ecarts sont calculés signés sur 32 bit avant d'etre tronconnés           */
     91/*      tous les nombres sont des entiers unsigned long pour compress                           */
     92/*Les valeures de la table d'entree sont consideres comme toujours positives et sur 21 bits     */
     93/*  les valeurs de reference pour le calcul des ecarts sont augmentees de ecart_bit=0x10000000  */
     94/*      LES ECARTS SONT DES ENTIERS POSITIFS (ecart_bit +  valeur courante - valeur precedente) */
    9395
    94 #define shif(ec,k,q)    {while(ec>q)if(k<kmax_){k++;q<<=1;}else ec=q;while(ec<-q)if(k<kmax_){k++;q<<=1;}else ec=-q;}
    95 #define recup(ec,sss,k) {ec=((R>>sss)&emak_);if(ec & sgbi_ ) ec|= sign_ ; ec<<=k;}
    96 #define arrondi(ec,k)   ((ec &  filtre[k]) +( (ec & test[k]) <<1 ) )   
     96/*  pour tous les compresseurs  */
     97#define kmax_   15              /*  valeur maximum de l'exposant        */
     98#define ecart_bit       0x10000000
     99#define shif(ec,k,q)    {while(ec>(q|ecart_bit))if(k<kmax_){k++;q<<=1;}else ec=(q|ecart_bit);while(ec<ecart_bit-q)if(k<kmax_){k++;q<<=1;}else ec=ecart_bit-q;}
     100#define arrondi(ec,k)   ((ec &  filtre[k]) +( (ec & test[k]) <<1 ) ) /* resultat sur 28 bit  */
     101#define new_val(val,ec,k)       ((val + arrondi(ec,k))&data_mask);
    97102
     103/* pour les decompresseurs      */
     104#define recup(ec,sss,k) {ec=((R>>sss)&ecart_mask);if(ec & sgbi_ ) ec|= sign_ ; ec<<=k;}
     105
  • trunk/Poubelle/archediab.old/archeops.c

    r652 r657  
    1 
    21
    32#include "manip.h"     
    4 
    53#include "archeops.h"
    64
    7 
    8 
    95/* sauve vol trapani 2eme config de vol   */
    106
    11 
    12 
    137/**********  coefficients  pour  les  mesures  bolo    **********************************/
    14 
    158/*                         toutes les puissances en pW                                  */
    16 
    179/*      -1-     loi de reponse thermique des bolos  avec R en ohms et T en Kelvin               */
    18 
    1910/*                                                                                      */
    20 
    2111/*      T =  coef2  *   (   ln (  R / coef1) **  ( -1 / coef0 )                             */
    22 
    2312/*                                                                                      */
    24 
    2513/*      -2-     fuite thermique du bolo   coef 3,4                                              */
    26 
    2714/*                                                                                      */
    28 
    2915/*      Ptot =  coef3  *  ( (10*Tb) ** coef4    -    (10*Tcryo)  **  coef4 )                */
    30 
    3116/*                                                                                      */
    32 
    3317/*      -3-     calcul empirique de Pciel et de  tau      coef  5,6                             */
    34 
    3518/*                                                                                      */
    36 
    3719/*      Pciel   =       coef5   - Pelec         coef5= I * Ai (tables xavier)                       */
    38 
    3920/*      tau     =       - ln ( 1 +  Pciel / coef6 )     coef6= I * Bi (tables xavier)                   */
    40 
    4121/*                                                                                                                          */
    42 
    4322/* Pour les thermometres 1 à 4 (germanium et carbone Allan-Bradley)                         */
    44 
    4523/* les coefficients sont utilisés differemment, ils permettent de convertir                 */
    46 
    4724/* R vers T             ( c(6) est un offset sur la mesure de R par rapport  aux mesures 4 fils)*/
    48 
    4925/*   llR= log(log(R - c(6))-c(0))                                                                               */
    50 
    5126/*    T = exp(c(1) + c(2)* llR + c(3)* llR* llR + c(4)* llR* llR* llR +                 */
    52 
    5327/*            c(5)* llR* llR* llR* llR)                                                 */
    54 
    5528/*                                                                                                                              */
    56 
    5729/*      version vol Trapani                                                                                                     */
    58 
    5930/*      on corrige le biais de temperature coef2=1.1 old,  coef3=old/1.1^coef4              */
    60 
    6131/*                                                                                                                              */
    62 
    6332/*                                                                                                                              */
    64 
    6533/*                                                                                                                              */
    66 
    6734/*                                                                                                                              */
    68 
    6935/*                                                                                                                              */
    70 
    7136/****************************************************************************************/
    7237
    7338
    74 
    75 
    76 
    7739/**************************************************************************************/
    78 
    7940/*                                                                                    */
    80 
    8141/*   pour les MLPA      :  gain = 100   diviseur = 101  ou  330                       */
    82 
    8342/*   pour les bebodiff  :  gain = diviseur = 100Kohm / R preampli                     */
    84 
    8543/*   pour les bebodiff  :  la capa est corrigee d'un facteur 0.868                    */
    86 
    8744/*   pour les cartes modifiees : mettre diviseur=0                                    */
    88 
    8945/*                         et capa = la resistance de chage en Megohm                 */
    90 
    9146/*                                                                                    */
    92 
    9347/**************************************************************************************/
    9448
    9549
    96 
    97 
    98 
    9950/*  numero_nom,  on/off  ,  0 = MLPA       , N° bolo , gain_pa  , capa*1000 , diviseur , coef*10000 */
    100 
    10151/*       ,  0 ou 1  ,  2..8 = BEBO    ,  hard   ,           ,  4700     ,  333     ,            */
    102 
    10352/*                     10 = Bediff    ,         ,           ,                                   */
    10453
    105 
    106 
    10754/* pour les bediff (code 10)  le n° de bolo est  N° de bebo*8  +  numero dans la bebo           */
    108 
    10955/*  soit :  1 2 3 4 5 6  ..  9 10 11 12 13 14 .. 17 18 19 20 21 22 .. etc                       */
    11056
    11157
    112 
    113 
    114 
    11558/*debut_param*/
    116 
    11759/*----------------------------------  fenetre :  -----------------------------------*/
    11860
    119 
    120 
    12161/* ------------------------ configuration de vol 5 juillet 99-----------------------------*/
    122 
    12362/* ---------------------- modifié les indices de bolo  le 15 septembre 1999-------------------*/
    124 
    125 param_bolo  parametr={29,24,36,88,18,
    126 
    127 
     63/*  contient au debut :  numero_version,n_max_bolo,n_per_block,n_max_mes_per,nb_bolo    */
     64
     65
     66param_bolo  parametr={29,36,36,88,0,
     67
     68/*  dans l'ordre :                                              */
     69/* 1-   numero des caracteristiques du bolo                     */
     70/* 2-   transmission du bolo  (normal = 7)  (non transmis =  5) (thermo = 9)    */
     71/* 3-   10 = bebo  differentielle                               */
     72/* 4-   numero de la voie de commande (8*n°bebo + N° dans la bebo)      */
     73/* 5-   gain du preamplificateur                                */
     74/* 6-   capacite de modulation (en fF)                          */
     75/* 7-   diviseur pour la modulation                             */
    12876
    12977{
    130 
    131 { 11    , 2,10, 1 , 200, 22000  ,  200 },       /*      0       */
    132 
    133 {  9    , 1,10, 2 , 200, 22000  ,  200 },
    134 
    135 {  8    , 1,10, 3 , 200, 22000  ,  200 },
    136 
    137 { 14    , 2,10, 4 , 200, 22000  ,  200 },
    138 
    139 
    140 
    141 {  5    , 1,10, 5 ,1000,  4700  , 1000 },       /*      4       */
    142 
    143 {  0    , 2,10, 6 ,1000,  4700  , 1000 },
    144 
    145 { 10    , 1,10, 9 ,1000,  4700  , 1000 },
    146 
    147 {  0    , 2,10,10, 1000,  4700  , 1000 },
    148 
    149 
    150 
    151 {  2    , 1,10,11, 1000,  4700  , 1000 },       /*      8       */
    152 
    153 {  4    , 1,10,12, 1000,  4700  , 1000 },
    154 
    155 {  7    , 2,10,13, 1000,  4700  , 1000 },
    156 
    157 {  1    , 1,10,14, 1000,  4700  , 1000 },
    158 
    159 
    160 
    161 { 13    , 1,10,17, 1000,  4700  , 1000 },       /*      12      */
    162 
    163 {  3    , 1,10,18, 1000,  4700  , 1000 },
    164 
     78{ 11    , 5,10, 1 , 200, 22000  ,  200 },       /*      0       */
     79{  9    , 7,10, 2 , 200, 22000  ,  200 },
     80{  8    , 7,10, 3 , 200, 22000  ,  200 },
     81{ 14    , 5,10, 4 , 200, 22000  ,  200 },
     82
     83{  5    , 7,10, 5 ,1000,  4700  , 1000 },       /*      4       */
     84{  0    , 5,10, 6 ,1000,  4700  , 1000 },
     85{ 10    , 7,10, 9 ,1000,  4700  , 1000 },
     86{  0    , 5,10,10, 1000,  4700  , 1000 },
     87
     88{  2    , 7,10,11, 1000,  4700  , 1000 },       /*      8       */
     89{  4    , 7,10,12, 1000,  4700  , 1000 },
     90{  7    , 5,10,13, 1000,  4700  , 1000 },
     91{  1    , 7,10,14, 1000,  4700  , 1000 },
     92
     93{ 13    , 7,10,17, 1000,  4700  , 1000 },       /*      12      */
     94{  3    , 7,10,18, 1000,  4700  , 1000 },
    16595{ 12            , 1,10,19, 1000,  4700  , 1000 },
    166 
    167 {  6    , 1,10,20, 1000,  4700  , 1000 },
    168 
    169 
    170 
    171 { 15    , 1,10,21,  200, 22000  ,  200 },       /*      16      */
    172 
    173 { 16    , 1,10,22,  200, 22000  ,  200 },
    174 
    175 { 17    , 1,10,25,  500, 22000  ,  500 },
    176 
    177 { 18    , 2,10,26,  500, 22000  ,  500 },
    178 
    179 
    180 
    181 { 20    , 3,10,27, 1000, 22000  ,    0 },       /*      20      */
    182 
    183 { 21    , 3,10,28, 1000,  1000  ,    0 },
    184 
    185 { 22    , 3,10,29, 1000,  1000  ,    0 },
    186 
    187 { 23    , 3,10,30, 1000,  1000  ,    0 },
    188 
    189 
    190 
    191 { 0     , 3,10,30, 1000,  1000  ,    0 },       /*      24      */
    192 
    193 { 0     , 3,10,30, 1000,  1000  ,    0 },
    194 
    195 { 0     , 3,10,30, 1000,  1000  ,    0 },
    196 
    197 { 0     , 3,10,30, 1000,  1000  ,    0 },
    198 
    199 
    200 
    201 { 0     , 3,10,30, 1000,  1000  ,    0 },       /*      28      */
    202 
    203 { 0     , 3,10,30, 1000,  1000  ,    0 },
    204 
    205 { 0     , 3,10,30, 1000,  1000  ,    0 },
    206 
    207 { 0     , 3,10,30, 1000,  1000  ,    0 },
    208 
    209 
    210 
    211 { 0     , 3,10,30, 1000,  1000  ,    0 },       /*      32      */
    212 
    213 { 0     , 3,10,30, 1000,  1000  ,    0 },
    214 
    215 { 0     , 3,10,30, 1000,  1000  ,    0 },
    216 
    217 { 0     , 3,10,30, 1000,  1000  ,    0 },
    218 
    219 
     96{  6    , 7,10,20, 1000,  4700  , 1000 },
     97
     98{ 15    , 7,10,21,  200, 22000  ,  200 },       /*      16      */
     99{ 16    , 7,10,22,  200, 22000  ,  200 },
     100{ 17    , 7,10,25,  500, 22000  ,  500 },
     101{ 18    , 5,10,26,  500, 22000  ,  500 },
     102
     103{ 20    , 9,10,27, 1000, 22000  ,    0 },       /*      20      */
     104{ 21    , 9,10,28, 1000,  1000  ,    0 },
     105{ 22    , 9,10,29, 1000,  1000  ,    0 },
     106{ 23    , 9,10,30, 1000,  1000  ,    0 },
     107
     108{ 0     , 0,10,30, 1000,  1000  ,    0 },       /*      24      */
     109{ 0     , 0,10,30, 1000,  1000  ,    0 },
     110{ 0     , 0,10,30, 1000,  1000  ,    0 },
     111{ 0     , 0,10,30, 1000,  1000  ,    0 },
     112
     113{ 0     , 0,10,30, 1000,  1000  ,    0 },       /*      28      */
     114{ 0     , 0,10,30, 1000,  1000  ,    0 },
     115{ 0     , 0,10,30, 1000,  1000  ,    0 },
     116{ 0     , 0,10,30, 1000,  1000  ,    0 },
     117
     118{ 0     , 0,10,30, 1000,  1000  ,    0 },       /*      32      */
     119{ 0     , 0,10,30, 1000,  1000  ,    0 },
     120{ 0     , 0,10,30, 1000,  1000  ,    0 },
     121{ 0     , 0,10,30, 1000,  1000  ,    0 },
    220122
    221123},
    222 
    223124{
    224 
    225125{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },                      /*      0       */
    226 
    227126{ "ch1-bolo1"  , { 5000  ,  600000 , 154000,  63039, 25000, 0, 0}  },           /*      1       */     
    228 
    229127{ "ch1-bolo2"  , { 5000  ,  600000 , 154000,  47279, 25000, 0, 0}  },
    230 
    231128{ "ch1-bolo3"  , { 5000  ,  600000 , 154000,  51219, 25000, 0, 0}  },
    232 
    233129{ "ch2-bolo4"  , { 5000  ,  600000 , 154000,  70919, 25000, 0, 0}  },
    234 
    235130{ "ch2-bolo5"  , { 5000  ,  600000 , 154000,  78799, 25000, 0, 0}  },   
    236 
    237131{ "ch3-bolo6"  , { 5000  ,  600000 , 154000,  86678, 25000, 0, 0}  },
    238132
    239 
    240 
    241133{ "Dum100mK1"  , { 5000  ,  588000 , 125000,  0,0,0,0} },                               /*      7       */
    242 
    243134{ "Dum100mK2"  , { 5000  ,  588000 , 125000,  0,0,0,0} },
    244 
    245135/*{ "Dum100mK3"  , { 5000  , 1361800 , 125000,  0,0,0,0} },             */
    246 
    247136{ "Dum100mK4"  , { 5000  , 1361800 , 125000,  0,0,0,0} },                           /* 9 */
    248 
    249137/*{ "Dum100mK5"  , { 5000  , 1361800 , 125000,  0,0,0,0} },             */
    250 
    251138{ "Dum100mK6"  , { 5000  , 1361800 , 125000,  0,0,0,0} },               
    252139
    253 
    254 
    255140{ "Lou100mK1"  , { 5000  , 5680000 , 560000,  0,0,0,0} },                   /* 11 */
    256 
    257141{ "Lou100mK2"  , { 5000  , 5680000 , 560000,  0,0,0,0} },
    258 
    259142{ "Lou100mK3"  , { 5000  , 5680000 , 560000,  0,0,0,0} },
    260 
    261143{ "Lou100mK4"  , { 5000  , 5680000 , 560000,  0,0,0,0} },
    262144
    263 
    264 
    265145{ "Lou1.6K5 "  , { 5000  ,  0 , 0,   0,0,0,0} },                                                /*      15      */
    266 
    267146{ "Lou1.6K6 "  , { 5000  ,  0 , 0,   0,0,0,0} }, 
    268 
    269147{ "Lou10K7  "  , { 5000  ,  0 , 0,   0,0,0,0} }, 
    270 
    271148{ "Lou10K8  "  , { 5000  ,  0 , 0,   0,0,0,0} },
    272149
    273 
    274 
    275150{ "R10MOhm  "  , { 5000  ,  0 , 0,   0,0,0,0} },                                                        /*      19      */
    276151
    277 
    278 
    279152/* La germanium doit toujours etre en premier par rapport aux autres thermos absolus */
    280 
    281153{ "germanium"  , {     0 ,  30719 ,   -910 , -16389 , 2927 ,   0,      0} }, /* 20      */
    282 
    283154{ "therm_4k"   , { 45000 ,  28907 , -16028 ,  -1327 , 1472 , 872,  52500} },
    284 
    285155{ "therm_1.6k" , { 45000 ,  28907 , -16028 ,  -1327 , 1472 , 872, 566700} },
    286 
    287156{ "therm_10k"  , { 45000 ,  28907 , -16028 ,  -1327 , 1472 , 872, 138100} },
    288157
    289 
    290 
    291158{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },                      /*      24      */
    292 
    293159{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    294 
    295160{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    296 
    297161{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    298162
    299 
    300 
    301163{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },                      /*      28      */
    302 
    303164{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    304 
    305165{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    306 
    307166{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    308167
    309 
    310 
    311168{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },                      /*      32      */
    312 
    313169{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    314 
    315170{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    316 
    317171{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    318172
    319 
    320 
    321173{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },                      /*      36      */
    322 
    323174{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    324 
    325175{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    326 
    327176{ "Niente   "    , { 5000  ,  0 , 0,   0,0,0,0} },
    328177
    329 
    330 
    331178}
    332179
    333 
    334 
    335180};
    336 
    337181/*fin_param*/
    338182
    339 
    340 
    341183/* Definition Mai-Juin 1999
    342 
    343184{
    344 
    345185{ "v1-bedif1"  , 1,10,1 ,  200, 22000   ,  200,  { 5000  , 123100 , 334200,0,0,0,0} },         
    346 
    347186{ "v1-bedif2"  , 1,10,2 ,  200, 22000   ,  200,  {  500  , 136180 ,   9010,0,0,0,0} },
    348 
    349187{ "v1-bedif3"  , 1,10,3 ,  200, 22000   ,  200,  {  500  , 136180 ,   9010,0,0,0,0} },
    350 
    351188{ "v1-bedif4"  , 1,10,4 ,  200, 22000   ,  200,  { 5000  , 123100 , 334200,0,0,0,0} },
    352 
    353189{ "v1-bedif5"  , 1,10,5 , 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    354 
    355190{ "v1-bedif6"  , 1,10,6 , 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    356191
    357 
    358 
    359192{ "v1-bedif7"  , 1,10,9 , 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    360 
    361193{ "v1-bedif8"  , 1,10,10, 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    362 
    363194{ "v1-bedif9"  , 1,10,11, 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    364 
    365195{ "v1-bedif10" , 1,10,12, 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    366 
    367196{ "v1-bedif11" , 1,10,13, 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    368 
    369197{ "v1-bedif12" , 1,10,14, 1000, 4700    , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    370198
    371 
    372 
    373199{ "v1-bedif13"  , 1,10,17, 1000, 100000 , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    374 
    375200{ "v1-bedif14"  , 1,10,18, 1000, 470000 , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    376 
    377201{ "bedif15"     , 1,10,19, 1000, 470000 , 1000,  {  500  ,  58800 ,  12500,0,0,0,0} },
    378 
    379202{ "bedif16"     , 1,10,20, 1000,2200000 , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    380 
    381203{ "bedif17"     , 1,10,21, 1000, 4700   , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    382 
    383204{ "bedif18"     , 1,10,22, 1000, 4700   , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    384205
    385 
    386 
    387206{ "v1-bedif19"  , 2,10,25, 1000, 4700   , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    388 
    389207{ "v1-bedif20"  , 2,10,26, 1000, 4700   , 1000,  { 5000  , 123100 , 334200,0,0,0,0} },
    390 
    391208{ "germanium"   , 3,10,27, 1000, 22000  ,    0,  { 3500  ,  17100 , 646500,0,0,0,0} },
    392 
    393209{ "therm_4k"    , 3,10,28, 1000, 1000   ,    0,  {12000  ,1804000 ,  72800,0,0,0,0} },
    394 
    395210{ "therm_1.6k"  , 3,10,29, 1000, 1000   ,    0,  {12000  ,1804000 ,  72800,0,0,0,0} },
    396 
    397211{ "therm_10k"   , 3,10,30, 1000, 1000   ,    0,  {12000  ,1804000 ,  72800,0,0,0,0} },
    398212
    399 
    400 
    401213}*/
    402214
    403 
    404 
    405215/* bolos campagne 1998-1999     */
    406 
    407216/*
    408 
    409217reg_NbSi.J, 1, 0, 1, 100, 4.7, 333,     .5                      ,519.6  , 8.286
    410 
    411218v1-231...L, 1, 0, 2, 100, 4.7, 333, .5   , 1.7   , 32.41 , 0.333 , 10  , 20.30  ,  11.41               
    412 
    413219v1-232...N, 1, 0, 3, 100, 4.7, 333,             
    414 
    415220v1-237...E, 1, 0, 4, 100, 4.7, 333,
    416221
    417 
    418 
    419222reg_JamieO, 1, 0, 5, 100, 4.7, 101,
    420223
    421 
    422 
    423224V2-NbSi..H, 1, 0, 6, 100, 4.7, 101, .5   ,433.8  , 9.25
    424 
    425225V2-230...B, 1, 0, 7, 100, 4.7, 333, .5   , 8.26  , 26.61 , 5.10  ,  7  , 9.354   ,  1.026
    426 
    427226V2-205...Q, 1, 0, 8, 100, 4.7, 333,     .518 , 81    , 25.2
    428 
    429227V2-208...P, 1, 0, 9, 100, 4.7, 333, .5   , 12.31 , 33.42 , 0.627 , 6.5 , 8.113   ,  2.958
    430228
    431 
    432 
    433229*/
    434 
    435230/*bolos campagne 1997-1998      */
    436 
    437231/*
    438232
    439 
    440 
    441233v1-208...J, 1, 0, 1, 100, 4.7, 333, .5   , 12.31 , 33.42               
    442 
    443234v1-232...L, 1, 0, 2, 100, 4.7, 333,             
    444 
    445235v1-205...N, 1, 0, 3, 100, 4.7, 333,     .518 , 81    , 25.2     
    446 
    447236v1-NbSi..E, 1, 0, 4, 100, 4.7, 333,     .5                      ,519.6  , 8.286
    448 
    449237Jamie....O, 1, 0, 5, 100, 4.7, 101,
    450 
    451238V2-NbSi..H, 1, 0, 6, 100, 4.7, 101, .5   ,433.8  , 9.25
    452 
    453239V2-224...B, 1, 0, 7, 100, 4.7, 333, .5   ,3.43   , 26.6
    454 
    455240V2-230...Q, 1, 0, 8, 100, 4.7, 333, .5   , 8.26  , 26.61
    456 
    457241V2-231...P, 1, 0, 9, 100, 4.7, 333, .5   , 1.7   , 32.41
    458242
    459 
    460 
    461243*/
    462244
    463245
    464 
    465 
    466 
    467246int mode_transmission_telemesure[nb_modes_telemesure][nb_type_blocks]= {
    468247
    469 
    470 
    471248/* enregisteur de bord flash :  plafond standard nominal        */
    472 
    473249/* 0*/  { 0,10,15,50, 10,50, 0, 0, 0, 1, 0, 0, 1, 0, 1,2500, 0, 0, 0, 0},
    474250
    475 
    476 
    477251/* 1*/  { 0,10,10, 1, 10, 3, 0, 0, 0, 1, 0, 0, 1, 0, 4,2500, 0, 0, 0, 0},
    478252
    479 
    480 
    481253/* 2*/  { 0,10,05,01, 10,06, 0, 0, 0, 1, 0, 0, 1, 0, 2,2500, 0, 0, 0, 0},
    482254
    483 
    484 
    485255/* 3*/  { 0,10, 1,25, 10, 2, 0, 0, 0, 0, 0, 0, 1, 0, 0,2500, 0, 0, 0, 0},
    486256
    487 
    488 
    489257/* 4*/  { 0,10,15,50, 10,25, 0, 0, 1, 0, 0, 0, 0, 0, 0,2500, 0, 0, 0, 0},
    490258
    491 
    492 
    493259/* 5*/  { 0,10,15,50, 10,25, 0, 0, 0, 0, 1, 0, 0, 0, 0,2500, 0, 0, 0, 0},
    494260
    495 
    496 
    497261/* 6*/  { 0,10,15,50, 10,50, 0, 0, 0, 1, 0, 0, 1, 0, 2,2500, 0, 0, 0, 0},
    498262
    499 
    500 
    501263/* 7*/  { 0,10,15,50,100,50, 1, 1, 0, 1, 0, 0, 1, 0, 1,2500, 0, 0, 0, 0},
    502264
    503 
    504 
    505265/* 8*/  { 0,10,15,50,100,50, 1, 1, 1, 0, 0, 0, 0, 0, 0,2500, 0, 0, 0, 0},
    506266
    507 
    508 
    509267/* 9*/  { 0,10, 1, 1,100, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0,2500, 0, 0, 0, 0}
    510268
    511 
    512 
    513269 };
    514270
    515271
    516272
    517 
    518 
    519 
    520 
    521273int mode_transmission_flash[nb_modes_flash][nb_type_blocks]= {
    522274
    523275
    524 
    525 
    526 
    527276/* enregisteur de bord flash : nominal  */
    528 
    529277/* 0*/  { 0,50,15,25, 10,25, 0, 0, 0, 1, 0, 0, 1, 0, 1,2500, 0, 0, 0, 0} ,
    530278
    531 
    532 
    533279/* enregisteur de bord flash : minimum  */
    534 
    535280/* 1*/  { 0,50,50,50,50,100, 0, 0, 0, 0, 0, 0, 0, 0, 0,2500, 0, 0, 0, 0} ,
    536281
    537 
    538 
    539282/* enregisteur de bord flash :  rien    */
    540 
    541283/* 2*/  { 0, 0, 0, 0,  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,   0, 0, 0, 0, 0} };
    542284
     
    544286
    545287
    546 
    547 
    548 
    549 
    550 
    551288/*debut_nom_reglage*/
    552 
    553289/* 0->1 - demarrage par defaut - Nominal*/
    554 
    555290/* 1->2 - idem*/
    556 
    557291/* 2->3 - faible courant*/
    558 
    559292/* 3->4 - fort courant*/
    560 
    561293/* 4->5 - non fffdéfini*/
    562 
    563294/* 5->6 - non défini*/
    564 
    565295/* 6->7 - non défini*/
    566 
    567296/* 7->8 - non défini*/
    568 
    569297/*fin_nom_reglage*/
    570298
     
    600328
    601329
    602 
    603 
    604 
    605 
    606 
    607 
    608 
    609 
    610 
    611 
    612 
    613 
    614 
    615 
    616 
    617 
    618 
    619 
    620 
    621 
    622 
    623 
    624 
    625 
    626 
    627 
    628 
    629 
    630 
    631 
    632 
    633 
    634 
    635330reglage_bolo  reglage_standard[8]={{
    636331
    637332
    638 
    639 
    640 
    641333/*debut reglage 0 */
    642 
    643334#ifdef programme
    644 
    645335{32,76,8,1},{
    646 
    647336{20,0}
    648 
    649337,{1311522837,256000}
    650 
    651338,{1048576021,256004}
    652 
    653 ,{20,0}
    654 
     339,{20,0}
    655340,{1048576021,256001}
    656 
    657 ,{20,0}
    658 
     341,{20,0}
    659342,{262144021,128003}
    660 
    661 ,{20,0}
    662 
    663 ,{262144021,128001}
    664 
    665 ,{262144021,128001}
    666 
    667 ,{20,0}
    668 
     343,{20,0}
     344,{262144021,128001}
     345,{262144021,128001}
     346,{20,0}
    669347,{1048576021,256257}
    670 
    671348,{1048576021,256003}
    672 
    673 ,{262144021,128001}
    674 
     349,{262144021,128001}
    675350,{262144789,128001}
    676 
    677 ,{262144021,128001}
    678 
     351,{262144021,128001}
    679352,{100663317,256002}
    680 
    681353,{100716053,155650}
    682 
    683354,{1048576277,256003}
    684 
    685 ,{20,0}
    686 
     355,{20,0}
    687356,{1024021,0}
    688 
    689357,{262165,0}
    690 
    691 ,{65557,0}
    692 
     358,{65557,0}
    693359,{1024020,0}
    694 
    695 },{
    696 
     360},{
    697361{1,21,16,4}
    698 
    699362,{1,21,13,4}
    700 
    701363,{1,21,20,4}
    702 
    703364,{1,21,20,4}
    704 
    705365,{0,21,0,4}
    706 
    707366,{0,21,0,4}
    708 
    709 },{
    710 
     367},{
    711368{3,1,21,24,21,24,0}
    712 
    713 ,{0,1,9,1,0,0,0}
    714 
    715 ,{0,1,9,1,0,0,0}
    716 
     369,{0,1,9,1,0,0,0}
     370,{0,1,9,1,0,0,0}
    717371,{6,1,9,34,30,0,65326}
    718 
    719372},{5,3,129,108,0,126,104,88}
    720 
    721373#else
    722 
    723374{1,8,76,32},{
    724 
    725375{20,0}
    726 
    727376,{1311522837,256000}
    728 
    729377,{1048576021,256004}
    730 
    731 ,{20,0}
    732 
     378,{20,0}
    733379,{1048576021,256001}
    734 
    735 ,{20,0}
    736 
     380,{20,0}
    737381,{262144021,128003}
    738 
    739 ,{20,0}
    740 
    741 ,{262144021,128001}
    742 
    743 ,{262144021,128001}
    744 
    745 ,{20,0}
    746 
     382,{20,0}
     383,{262144021,128001}
     384,{262144021,128001}
     385,{20,0}
    747386,{1048576021,256257}
    748 
    749387,{1048576021,256003}
    750 
    751 ,{262144021,128001}
    752 
     388,{262144021,128001}
    753389,{262144789,128001}
    754 
    755 ,{262144021,128001}
    756 
     390,{262144021,128001}
    757391,{100663317,256002}
    758 
    759392,{100716053,155650}
    760 
    761393,{1048576277,256003}
    762 
    763 ,{20,0}
    764 
     394,{20,0}
    765395,{1024021,0}
    766 
    767396,{262165,0}
    768 
    769 ,{65557,0}
    770 
     397,{65557,0}
    771398,{1024020,0}
    772 
    773 },{
    774 
     399},{
    775400{4,16,21,1}
    776 
    777401,{4,13,21,1}
    778 
    779402,{4,20,21,1}
    780 
    781403,{4,20,21,1}
    782 
    783404,{4,0,21,0}
    784 
    785405,{4,0,21,0}
    786 
    787 },{
    788 
     406},{
    789407{24,21,1,3,0,24,21}
    790 
    791 ,{1,9,1,0,0,0,0}
    792 
    793 ,{1,9,1,0,0,0,0}
    794 
     408,{1,9,1,0,0,0,0}
     409,{1,9,1,0,0,0,0}
    795410,{34,9,1,6,65326,0,30}
    796 
    797411},{108,129,3,5,88,104,126,0}
    798 
    799412#endif
    800 
    801413/*fin_reglage*/
    802414
    803415
    804 
    805 
    806 
    807 },{
    808 
    809 
     416},{
    810417
    811418/*debut reglage 1 */
    812 
    813419#ifdef programme
    814 
    815420{32,76,8,1},{
    816 
    817421{20,0}
    818 
    819422,{1311522837,256000}
    820 
    821423,{1048576021,256004}
    822 
    823 ,{20,0}
    824 
     424,{20,0}
    825425,{1048576021,256001}
    826 
    827 ,{20,0}
    828 
     426,{20,0}
    829427,{262144021,128003}
    830 
    831 ,{20,0}
    832 
    833 ,{262144021,128001}
    834 
    835 ,{262144021,128001}
    836 
    837 ,{20,0}
    838 
     428,{20,0}
     429,{262144021,128001}
     430,{262144021,128001}
     431,{20,0}
    839432,{1048576021,256257}
    840 
    841433,{1048576021,256003}
    842 
    843 ,{262144021,128001}
    844 
     434,{262144021,128001}
    845435,{262144789,128001}
    846 
    847 ,{262144021,128001}
    848 
     436,{262144021,128001}
    849437,{100663317,256002}
    850 
    851438,{100716053,155650}
    852 
    853439,{1048576277,256003}
    854 
    855 ,{20,0}
    856 
     440,{20,0}
    857441,{1024021,0}
    858 
    859442,{262165,0}
    860 
    861 ,{65557,0}
    862 
     443,{65557,0}
    863444,{1024020,0}
    864 
    865 },{
    866 
     445},{
    867446{1,21,16,4}
    868 
    869447,{1,21,13,4}
    870 
    871448,{1,21,20,4}
    872 
    873449,{1,21,20,4}
    874 
    875450,{0,21,0,4}
    876 
    877451,{0,21,0,4}
    878 
    879 },{
    880 
     452},{
    881453{3,1,21,24,21,24,0}
    882 
    883 ,{0,1,9,1,0,0,0}
    884 
    885 ,{0,1,9,1,0,0,0}
    886 
     454,{0,1,9,1,0,0,0}
     455,{0,1,9,1,0,0,0}
    887456,{6,1,9,34,30,0,65326}
    888 
    889457},{5,3,129,108,0,126,104,88}
    890 
    891458#else
    892 
    893459{1,8,76,32},{
    894 
    895460{20,0}
    896 
    897461,{1311522837,256000}
    898 
    899462,{1048576021,256004}
    900 
    901 ,{20,0}
    902 
     463,{20,0}
    903464,{1048576021,256001}
    904 
    905 ,{20,0}
    906 
     465,{20,0}
    907466,{262144021,128003}
    908 
    909 ,{20,0}
    910 
    911 ,{262144021,128001}
    912 
    913 ,{262144021,128001}
    914 
    915 ,{20,0}
    916 
     467,{20,0}
     468,{262144021,128001}
     469,{262144021,128001}
     470,{20,0}
    917471,{1048576021,256257}
    918 
    919472,{1048576021,256003}
    920 
    921 ,{262144021,128001}
    922 
     473,{262144021,128001}
    923474,{262144789,128001}
    924 
    925 ,{262144021,128001}
    926 
     475,{262144021,128001}
    927476,{100663317,256002}
    928 
    929477,{100716053,155650}
    930 
    931478,{1048576277,256003}
    932 
    933 ,{20,0}
    934 
     479,{20,0}
    935480,{1024021,0}
    936 
    937481,{262165,0}
    938 
    939 ,{65557,0}
    940 
     482,{65557,0}
    941483,{1024020,0}
    942 
    943 },{
    944 
     484},{
    945485{4,16,21,1}
    946 
    947486,{4,13,21,1}
    948 
    949487,{4,20,21,1}
    950 
    951488,{4,20,21,1}
    952 
    953489,{4,0,21,0}
    954 
    955490,{4,0,21,0}
    956 
    957 },{
    958 
     491},{
    959492{24,21,1,3,0,24,21}
    960 
    961 ,{1,9,1,0,0,0,0}
    962 
    963 ,{1,9,1,0,0,0,0}
    964 
     493,{1,9,1,0,0,0,0}
     494,{1,9,1,0,0,0,0}
    965495,{34,9,1,6,65326,0,30}
    966 
    967496},{108,129,3,5,88,104,126,0}
    968 
    969497#endif
    970 
    971498/*fin_reglage*/
    972499
    973 
    974 
    975 },{
    976 
    977 
     500},{
    978501
    979502/*debut reglage 2 */
    980 
    981503#ifdef programme
    982 
    983504{32,76,8,1},{
    984 
    985505{20,0}
    986 
    987506,{100721941,256000}
    988 
    989507,{1048607509,256004}
    990 
    991 ,{20,0}
    992 
     508,{20,0}
    993509,{1048586773,256003}
    994 
    995 ,{20,0}
    996 
     510,{20,0}
    997511,{50335509,128001}
    998 
    999 ,{20,0}
    1000 
     512,{20,0}
    1001513,{50331669,128001}
    1002 
    1003514,{50336789,128001}
    1004 
    1005 ,{20,0}
    1006 
     515,{20,0}
    1007516,{1048622101,256259}
    1008 
    1009517,{1048635413,256003}
    1010 
    1011518,{50331669,128001}
    1012 
    1013519,{50352661,128001}
    1014 
    1015520,{50337813,128001}
    1016 
    1017521,{100665109,256002}
    1018 
    1019522,{100664597,155650}
    1020 
    1021523,{1048600341,256003}
    1022 
    1023 ,{20,0}
    1024 
     524,{20,0}
    1025525,{1024021,0}
    1026 
    1027 ,{65557,0}
    1028 
    1029 ,{65557,0}
    1030 
     526,{65557,0}
     527,{65557,0}
    1031528,{262165,0}
    1032 
    1033 },{
    1034 
     529},{
    1035530{1,21,11,4}
    1036 
    1037531,{1,21,13,4}
    1038 
    1039532,{1,21,20,4}
    1040 
    1041533,{1,21,20,4}
    1042 
    1043534,{0,20,0,1}
    1044 
    1045535,{0,20,0,1}
    1046 
    1047 },{
    1048 
     536},{
    1049537{3,1,21,24,21,24,0}
    1050 
    1051 ,{0,1,9,1,0,0,0}
    1052 
    1053 ,{0,1,9,1,0,0,0}
    1054 
     538,{0,1,9,1,0,0,0}
     539,{0,1,9,1,0,0,0}
    1055540,{6,17,0,34,30,0,65386}
    1056 
    1057541},{5,3,129,108,0,126,104,88}
    1058 
    1059542#else
    1060 
    1061543{1,8,76,32},{
    1062 
    1063544{20,0}
    1064 
    1065545,{100721941,256000}
    1066 
    1067546,{1048607509,256004}
    1068 
    1069 ,{20,0}
    1070 
     547,{20,0}
    1071548,{1048586773,256003}
    1072 
    1073 ,{20,0}
    1074 
     549,{20,0}
    1075550,{50335509,128001}
    1076 
    1077 ,{20,0}
    1078 
     551,{20,0}
    1079552,{50331669,128001}
    1080 
    1081553,{50336789,128001}
    1082 
    1083 ,{20,0}
    1084 
     554,{20,0}
    1085555,{1048622101,256259}
    1086 
    1087556,{1048635413,256003}
    1088 
    1089557,{50331669,128001}
    1090 
    1091558,{50352661,128001}
    1092 
    1093559,{50337813,128001}
    1094 
    1095560,{100665109,256002}
    1096 
    1097561,{100664597,155650}
    1098 
    1099562,{1048600341,256003}
    1100 
    1101 ,{20,0}
    1102 
     563,{20,0}
    1103564,{1024021,0}
    1104 
    1105 ,{65557,0}
    1106 
    1107 ,{65557,0}
    1108 
     565,{65557,0}
     566,{65557,0}
    1109567,{262165,0}
    1110 
    1111 },{
    1112 
     568},{
    1113569{4,11,21,1}
    1114 
    1115570,{4,13,21,1}
    1116 
    1117571,{4,20,21,1}
    1118 
    1119572,{4,20,21,1}
    1120 
    1121573,{1,0,20,0}
    1122 
    1123574,{1,0,20,0}
    1124 
    1125 },{
    1126 
     575},{
    1127576{24,21,1,3,0,24,21}
    1128 
    1129 ,{1,9,1,0,0,0,0}
    1130 
    1131 ,{1,9,1,0,0,0,0}
    1132 
     577,{1,9,1,0,0,0,0}
     578,{1,9,1,0,0,0,0}
    1133579,{34,0,17,6,65386,0,30}
    1134 
    1135580},{108,129,3,5,88,104,126,0}
    1136 
    1137581#endif
    1138 
    1139582/*fin_reglage*/
    1140583
    1141 
    1142 
    1143 },{
    1144 
    1145 
     584},{
    1146585
    1147586/*debut reglage 3 */
    1148 
    1149587#ifdef programme
    1150 
    1151588{32,76,8,1},{
    1152 
    1153589{20,0}
    1154 
    1155590,{100721941,256000}
    1156 
    1157591,{1048607509,256004}
    1158 
    1159 ,{20,0}
    1160 
     592,{20,0}
    1161593,{1048586773,256003}
    1162 
    1163 ,{20,0}
    1164 
     594,{20,0}
    1165595,{524291861,128001}
    1166 
    1167 ,{20,0}
    1168 
     596,{20,0}
    1169597,{524288021,128001}
    1170 
    1171598,{524293141,128001}
    1172 
    1173 ,{20,0}
    1174 
     599,{20,0}
    1175600,{1048622101,256259}
    1176 
    1177601,{1048635413,256003}
    1178 
    1179602,{524288021,128001}
    1180 
    1181603,{524309013,128001}
    1182 
    1183604,{524294165,128001}
    1184 
    1185605,{100665109,256002}
    1186 
    1187606,{100664597,155650}
    1188 
    1189607,{1048600341,256003}
    1190 
    1191 ,{20,0}
    1192 
     608,{20,0}
    1193609,{1024021,0}
    1194 
    1195 ,{65557,0}
    1196 
    1197 ,{65557,0}
    1198 
    1199 ,{65557,0}
    1200 
    1201 },{
    1202 
     610,{65557,0}
     611,{65557,0}
     612,{65557,0}
     613},{
    1203614{1,21,18,4}
    1204 
    1205615,{1,21,13,4}
    1206 
    1207616,{1,21,20,4}
    1208 
    1209617,{1,21,20,4}
    1210 
    1211618,{0,20,0,1}
    1212 
    1213619,{0,20,0,1}
    1214 
    1215 },{
    1216 
     620},{
    1217621{3,1,21,24,21,24,0}
    1218 
    1219 ,{0,1,9,1,0,0,0}
    1220 
    1221 ,{0,1,9,1,0,0,0}
    1222 
     622,{0,1,9,1,0,0,0}
     623,{0,1,9,1,0,0,0}
    1223624,{6,17,0,34,30,0,65386}
    1224 
    1225625},{5,3,129,108,0,126,104,88}
    1226 
    1227626#else
    1228 
    1229627{1,8,76,32},{
    1230 
    1231628{20,0}
    1232 
    1233629,{100721941,256000}
    1234 
    1235630,{1048607509,256004}
    1236 
    1237 ,{20,0}
    1238 
     631,{20,0}
    1239632,{1048586773,256003}
    1240 
    1241 ,{20,0}
    1242 
     633,{20,0}
    1243634,{524291861,128001}
    1244 
    1245 ,{20,0}
    1246 
     635,{20,0}
    1247636,{524288021,128001}
    1248 
    1249637,{524293141,128001}
    1250 
    1251 ,{20,0}
    1252 
     638,{20,0}
    1253639,{1048622101,256259}
    1254 
    1255640,{1048635413,256003}
    1256 
    1257641,{524288021,128001}
    1258 
    1259642,{524309013,128001}
    1260 
    1261643,{524294165,128001}
    1262 
    1263644,{100665109,256002}
    1264 
    1265645,{100664597,155650}
    1266 
    1267646,{1048600341,256003}
    1268 
    1269 ,{20,0}
    1270 
     647,{20,0}
    1271648,{1024021,0}
    1272 
    1273 ,{65557,0}
    1274 
    1275 ,{65557,0}
    1276 
    1277 ,{65557,0}
    1278 
    1279 },{
    1280 
     649,{65557,0}
     650,{65557,0}
     651,{65557,0}
     652},{
    1281653{4,18,21,1}
    1282 
    1283654,{4,13,21,1}
    1284 
    1285655,{4,20,21,1}
    1286 
    1287656,{4,20,21,1}
    1288 
    1289657,{1,0,20,0}
    1290 
    1291658,{1,0,20,0}
    1292 
    1293 },{
    1294 
     659},{
    1295660{24,21,1,3,0,24,21}
    1296 
    1297 ,{1,9,1,0,0,0,0}
    1298 
    1299 ,{1,9,1,0,0,0,0}
    1300 
     661,{1,9,1,0,0,0,0}
     662,{1,9,1,0,0,0,0}
    1301663,{34,0,17,6,65386,0,30}
    1302 
    1303664},{108,129,3,5,88,104,126,0}
    1304 
    1305665#endif
    1306 
    1307666/*fin_reglage*/
    1308667
    1309 
    1310 
    1311 },{
    1312 
    1313 
     668},{
    1314669
    1315670/*debut reglage 4 */
    1316 
    1317671#ifdef programme
    1318 
    1319672{39,62,9,1},{
    1320 
    1321673{20,0}
    1322 
    1323674,{-100659180,229382}
    1324 
    1325675,{-100659436,294918}
    1326 
    1327 ,{20,0}
    1328 
     676,{20,0}
    1329677,{-100663276,221189}
    1330 
    1331678,{-100663276,5}
    1332 
    1333679,{-100659436,245762}
    1334 
    1335680,{-100663276,5}
    1336 
    1337681,{-100658154,245761}
    1338 
    1339682,{-100658156,253954}
    1340 
    1341 ,{20,0}
    1342 
     683,{20,0}
    1343684,{-100663276,204805}
    1344 
    1345685,{-100663276,16389}
    1346 
    1347686,{-100656874,1}
    1348 
    1349687,{-100656874,16385}
    1350 
    1351688,{-100663276,3}
    1352 
    1353689,{-100506347,6}
    1354 
    1355690,{-100509675,6}
    1356 
    1357691,{-100372972,6}
    1358 
    1359692,{2097174,0}
    1360 
    1361693,{1024022,0}
    1362 
    1363694,{16406,0}
    1364 
    1365695,{4117,0}
    1366 
    1367696,{262164,0}
    1368 
    1369 },{
    1370 
     697},{
    1371698{2,22,24,1}
    1372 
    1373699,{1,20,24,4}
    1374 
    1375700,{0,20,24,4}
    1376 
    1377701,{0,20,24,3}
    1378 
    1379702,{0,20,24,4}
    1380 
    1381703,{0,20,24,4}
    1382 
    1383 },{
    1384 
     704},{
    1385705{0,1,9,1,0,0,0}
    1386 
    1387 ,{0,1,9,1,0,0,0}
    1388 
    1389 ,{0,1,9,1,0,0,0}
    1390 
    1391 ,{0,1,9,1,0,0,0}
    1392 
     706,{0,1,9,1,0,0,0}
     707,{0,1,9,1,0,0,0}
     708,{0,1,9,1,0,0,0}
    1393709},{2,3,129,108,2,126,104,88}
    1394 
    1395710#else
    1396 
    1397711{1,9,62,39},{
    1398 
    1399712{20,0}
    1400 
    1401713,{-100659180,229382}
    1402 
    1403714,{-100659436,294918}
    1404 
    1405 ,{20,0}
    1406 
     715,{20,0}
    1407716,{-100663276,221189}
    1408 
    1409717,{-100663276,5}
    1410 
    1411718,{-100659436,245762}
    1412 
    1413719,{-100663276,5}
    1414 
    1415720,{-100658154,245761}
    1416 
    1417721,{-100658156,253954}
    1418 
    1419 ,{20,0}
    1420 
     722,{20,0}
    1421723,{-100663276,204805}
    1422 
    1423724,{-100663276,16389}
    1424 
    1425725,{-100656874,1}
    1426 
    1427726,{-100656874,16385}
    1428 
    1429727,{-100663276,3}
    1430 
    1431728,{-100506347,6}
    1432 
    1433729,{-100509675,6}
    1434 
    1435730,{-100372972,6}
    1436 
    1437731,{2097174,0}
    1438 
    1439732,{1024022,0}
    1440 
    1441733,{16406,0}
    1442 
    1443734,{4117,0}
    1444 
    1445735,{262164,0}
    1446 
    1447 },{
    1448 
     736},{
    1449737{1,24,22,2}
    1450 
    1451738,{4,24,20,1}
    1452 
    1453739,{4,24,20,0}
    1454 
    1455740,{3,24,20,0}
    1456 
    1457741,{4,24,20,0}
    1458 
    1459742,{4,24,20,0}
    1460 
    1461 },{
    1462 
     743},{
    1463744{1,9,1,0,0,0,0}
    1464 
    1465 ,{1,9,1,0,0,0,0}
    1466 
    1467 ,{1,9,1,0,0,0,0}
    1468 
    1469 ,{1,9,1,0,0,0,0}
    1470 
     745,{1,9,1,0,0,0,0}
     746,{1,9,1,0,0,0,0}
     747,{1,9,1,0,0,0,0}
    1471748},{108,129,3,2,88,104,126,2}
    1472 
    1473749#endif
    1474 
    1475750/*fin_reglage*/
    1476751
    1477 
    1478 
    1479 },{
    1480 
    1481 
     752},{
    1482753
    1483754/*debut reglage 5 */
    1484 
    1485755#ifdef programme
    1486 
    1487756{39,68,9,1},{
    1488 
    1489757{20,0}
    1490 
    1491758,{1048982293,229382}
    1492 
    1493759,{1049128469,253958}
    1494 
    1495 ,{20,0}
    1496 
     760,{20,0}
    1497761,{1048966677,245765}
    1498 
    1499 ,{20,0}
    1500 
     762,{20,0}
    1501763,{262157846,245762}
    1502 
    1503764,{1048919829,5}
    1504 
    1505765,{262156054,245761}
    1506 
    1507766,{262154006,253954}
    1508 
    1509 ,{20,0}
    1510 
     767,{20,0}
    1511768,{1049123349,229381}
    1512 
    1513769,{1049157141,237573}
    1514 
    1515770,{262154262,1}
    1516 
    1517771,{262158614,16385}
    1518 
    1519772,{262149654,3}
    1520 
    1521773,{262750740,237572}
    1522 
    1523774,{262606612,122884}
    1524 
    1525775,{-1174095083,139270}
    1526 
    1527 ,{20,0}
    1528 
     776,{20,0}
    1529777,{16406,0}
    1530 
    1531778,{16406,0}
    1532 
    1533779,{4117,0}
    1534 
    1535780,{262164,0}
    1536 
    1537 },{
    1538 
     781},{
    1539782{1,22,16,1}
    1540 
    1541783,{1,22,16,4}
    1542 
    1543784,{1,22,16,4}
    1544 
    1545785,{1,20,16,3}
    1546 
    1547786,{1,21,20,4}
    1548 
    1549787,{1,21,20,4}
    1550 
    1551 },{
    1552 
     788},{
    1553789{0,1,9,1,0,0,0}
    1554 
    1555 ,{0,1,9,1,0,0,0}
    1556 
    1557 ,{0,1,9,1,0,0,0}
    1558 
    1559 ,{0,1,9,1,0,0,0}
    1560 
     790,{0,1,9,1,0,0,0}
     791,{0,1,9,1,0,0,0}
     792,{0,1,9,1,0,0,0}
    1561793},{2,3,129,108,3,126,104,88}
    1562 
    1563794#else
    1564 
    1565795{1,9,68,39},{
    1566 
    1567796{20,0}
    1568 
    1569797,{1048982293,229382}
    1570 
    1571798,{1049128469,253958}
    1572 
    1573 ,{20,0}
    1574 
     799,{20,0}
    1575800,{1048966677,245765}
    1576 
    1577 ,{20,0}
    1578 
     801,{20,0}
    1579802,{262157846,245762}
    1580 
    1581803,{1048919829,5}
    1582 
    1583804,{262156054,245761}
    1584 
    1585805,{262154006,253954}
    1586 
    1587 ,{20,0}
    1588 
     806,{20,0}
    1589807,{1049123349,229381}
    1590 
    1591808,{1049157141,237573}
    1592 
    1593809,{262154262,1}
    1594 
    1595810,{262158614,16385}
    1596 
    1597811,{262149654,3}
    1598 
    1599812,{262750740,237572}
    1600 
    1601813,{262606612,122884}
    1602 
    1603814,{-1174095083,139270}
    1604 
    1605 ,{20,0}
    1606 
     815,{20,0}
    1607816,{16406,0}
    1608 
    1609817,{16406,0}
    1610 
    1611818,{4117,0}
    1612 
    1613819,{262164,0}
    1614 
    1615 },{
    1616 
     820},{
    1617821{1,16,22,1}
    1618 
    1619822,{4,16,22,1}
    1620 
    1621823,{4,16,22,1}
    1622 
    1623824,{3,16,20,1}
    1624 
    1625825,{4,20,21,1}
    1626 
    1627826,{4,20,21,1}
    1628 
    1629 },{
    1630 
     827},{
    1631828{1,9,1,0,0,0,0}
    1632 
    1633 ,{1,9,1,0,0,0,0}
    1634 
    1635 ,{1,9,1,0,0,0,0}
    1636 
    1637 ,{1,9,1,0,0,0,0}
    1638 
     829,{1,9,1,0,0,0,0}
     830,{1,9,1,0,0,0,0}
     831,{1,9,1,0,0,0,0}
    1639832},{108,129,3,2,88,104,126,3}
    1640 
    1641833#endif
    1642 
    1643834/*fin_reglage*/
    1644835
    1645 
    1646 
    1647 },{
    1648 
    1649 
     836},{
    1650837
    1651838/*debut reglage 6 */
    1652 
    1653839#ifdef programme
    1654 
    1655840{197,191,175,185},{
    1656 
    1657841{0,0}
    1658 
    1659 ,{0,0}
    1660 
    1661 ,{0,0}
    1662 
    1663 ,{0,0}
    1664 
    1665 ,{0,0}
    1666 
    1667 ,{0,0}
    1668 
    1669 ,{0,0}
    1670 
    1671 ,{0,0}
    1672 
    1673 ,{0,0}
    1674 
    1675 ,{0,0}
    1676 
    1677 ,{0,0}
    1678 
    1679 ,{0,0}
    1680 
    1681 ,{0,0}
    1682 
    1683 ,{0,0}
    1684 
    1685 ,{0,0}
    1686 
    1687 ,{0,0}
    1688 
    1689 ,{0,0}
    1690 
    1691 ,{0,0}
    1692 
    1693 ,{0,0}
    1694 
    1695 ,{0,0}
    1696 
    1697 ,{0,0}
    1698 
    1699 ,{0,0}
    1700 
    1701 ,{0,0}
    1702 
    1703 ,{0,0}
    1704 
    1705 },{
    1706 
     842,{0,0}
     843,{0,0}
     844,{0,0}
     845,{0,0}
     846,{0,0}
     847,{0,0}
     848,{0,0}
     849,{0,0}
     850,{0,0}
     851,{0,0}
     852,{0,0}
     853,{0,0}
     854,{0,0}
     855,{0,0}
     856,{0,0}
     857,{0,0}
     858,{0,0}
     859,{0,0}
     860,{0,0}
     861,{0,0}
     862,{0,0}
     863,{0,0}
     864,{0,0}
     865},{
    1707866{106,98,93,71}
    1708 
    1709867,{66,74,87,66}
    1710 
    1711868,{48,46,38,33}
    1712 
    1713869,{40,41,33,26}
    1714 
    1715870,{25,29,40,57}
    1716 
    1717871,{63,62,71,80}
    1718 
    1719 },{
    1720 
     872},{
    1721873{83,79,75,75,92,112,31100}
    1722 
    1723874,{125,126,117,113,107,94,20315}
    1724 
    1725875,{108,116,122,124,117,120,32117}
    1726 
    1727876,{110,99,94,98,107,93,17217}
    1728 
    1729877},{88,82,94,108,111,126,104,88}
    1730 
    1731878#else
    1732 
    1733879{185,175,191,197},{
    1734 
    1735880{0,0}
    1736 
    1737 ,{0,0}
    1738 
    1739 ,{0,0}
    1740 
    1741 ,{0,0}
    1742 
    1743 ,{0,0}
    1744 
    1745 ,{0,0}
    1746 
    1747 ,{0,0}
    1748 
    1749 ,{0,0}
    1750 
    1751 ,{0,0}
    1752 
    1753 ,{0,0}
    1754 
    1755 ,{0,0}
    1756 
    1757 ,{0,0}
    1758 
    1759 ,{0,0}
    1760 
    1761 ,{0,0}
    1762 
    1763 ,{0,0}
    1764 
    1765 ,{0,0}
    1766 
    1767 ,{0,0}
    1768 
    1769 ,{0,0}
    1770 
    1771 ,{0,0}
    1772 
    1773 ,{0,0}
    1774 
    1775 ,{0,0}
    1776 
    1777 ,{0,0}
    1778 
    1779 ,{0,0}
    1780 
    1781 ,{0,0}
    1782 
    1783 },{
    1784 
     881,{0,0}
     882,{0,0}
     883,{0,0}
     884,{0,0}
     885,{0,0}
     886,{0,0}
     887,{0,0}
     888,{0,0}
     889,{0,0}
     890,{0,0}
     891,{0,0}
     892,{0,0}
     893,{0,0}
     894,{0,0}
     895,{0,0}
     896,{0,0}
     897,{0,0}
     898,{0,0}
     899,{0,0}
     900,{0,0}
     901,{0,0}
     902,{0,0}
     903,{0,0}
     904},{
    1785905{71,93,98,106}
    1786 
    1787906,{66,87,74,66}
    1788 
    1789907,{33,38,46,48}
    1790 
    1791908,{26,33,41,40}
    1792 
    1793909,{57,40,29,25}
    1794 
    1795910,{80,71,62,63}
    1796 
    1797 },{
    1798 
     911},{
    1799912{75,75,79,83,31100,112,92}
    1800 
    1801913,{113,117,126,125,20315,94,107}
    1802 
    1803914,{124,122,116,108,32117,120,117}
    1804 
    1805915,{98,94,99,110,17217,93,107}
    1806 
    1807916},{108,94,82,88,88,104,126,111}
    1808 
    1809917#endif
    1810 
    1811918/*fin_reglage*/
    1812919
    1813 
    1814 
    1815 },{
    1816 
    1817 
     920},{
    1818921
    1819922/*debut reglage 7 */
    1820 
    1821923#ifdef programme
    1822 
    1823924{197,191,175,185},{
    1824 
    1825925{0,0}
    1826 
    1827 ,{0,0}
    1828 
    1829 ,{0,0}
    1830 
    1831 ,{0,0}
    1832 
    1833 ,{0,0}
    1834 
    1835 ,{0,0}
    1836 
    1837 ,{0,0}
    1838 
    1839 ,{0,0}
    1840 
    1841 ,{0,0}
    1842 
    1843 ,{0,0}
    1844 
    1845 ,{0,0}
    1846 
    1847 ,{0,0}
    1848 
    1849 ,{0,0}
    1850 
    1851 ,{0,0}
    1852 
    1853 ,{0,0}
    1854 
    1855 ,{0,0}
    1856 
    1857 ,{0,0}
    1858 
    1859 ,{0,0}
    1860 
    1861 ,{0,0}
    1862 
    1863 ,{0,0}
    1864 
    1865 ,{0,0}
    1866 
    1867 ,{0,0}
    1868 
    1869 ,{0,0}
    1870 
    1871 ,{0,0}
    1872 
    1873 },{
    1874 
     926,{0,0}
     927,{0,0}
     928,{0,0}
     929,{0,0}
     930,{0,0}
     931,{0,0}
     932,{0,0}
     933,{0,0}
     934,{0,0}
     935,{0,0}
     936,{0,0}
     937,{0,0}
     938,{0,0}
     939,{0,0}
     940,{0,0}
     941,{0,0}
     942,{0,0}
     943,{0,0}
     944,{0,0}
     945,{0,0}
     946,{0,0}
     947,{0,0}
     948,{0,0}
     949},{
    1875950{106,98,93,71}
    1876 
    1877951,{66,74,87,66}
    1878 
    1879952,{48,46,38,33}
    1880 
    1881953,{40,41,33,26}
    1882 
    1883954,{25,29,40,57}
    1884 
    1885955,{63,62,71,80}
    1886 
    1887 },{
    1888 
     956},{
    1889957{83,79,75,75,92,112,31100}
    1890 
    1891958,{125,126,117,113,107,94,20315}
    1892 
    1893959,{108,116,122,124,117,120,32117}
    1894 
    1895960,{110,99,94,98,107,93,17217}
    1896 
    1897961},{88,82,94,108,111,126,104,88}
    1898 
    1899962#else
    1900 
    1901963{185,175,191,197},{
    1902 
    1903964{0,0}
    1904 
    1905 ,{0,0}
    1906 
    1907 ,{0,0}
    1908 
    1909 ,{0,0}
    1910 
    1911 ,{0,0}
    1912 
    1913 ,{0,0}
    1914 
    1915 ,{0,0}
    1916 
    1917 ,{0,0}
    1918 
    1919 ,{0,0}
    1920 
    1921 ,{0,0}
    1922 
    1923 ,{0,0}
    1924 
    1925 ,{0,0}
    1926 
    1927 ,{0,0}
    1928 
    1929 ,{0,0}
    1930 
    1931 ,{0,0}
    1932 
    1933 ,{0,0}
    1934 
    1935 ,{0,0}
    1936 
    1937 ,{0,0}
    1938 
    1939 ,{0,0}
    1940 
    1941 ,{0,0}
    1942 
    1943 ,{0,0}
    1944 
    1945 ,{0,0}
    1946 
    1947 ,{0,0}
    1948 
    1949 ,{0,0}
    1950 
    1951 },{
    1952 
     965,{0,0}
     966,{0,0}
     967,{0,0}
     968,{0,0}
     969,{0,0}
     970,{0,0}
     971,{0,0}
     972,{0,0}
     973,{0,0}
     974,{0,0}
     975,{0,0}
     976,{0,0}
     977,{0,0}
     978,{0,0}
     979,{0,0}
     980,{0,0}
     981,{0,0}
     982,{0,0}
     983,{0,0}
     984,{0,0}
     985,{0,0}
     986,{0,0}
     987,{0,0}
     988},{
    1953989{71,93,98,106}
    1954 
    1955990,{66,87,74,66}
    1956 
    1957991,{33,38,46,48}
    1958 
    1959992,{26,33,41,40}
    1960 
    1961993,{57,40,29,25}
    1962 
    1963994,{80,71,62,63}
    1964 
    1965 },{
    1966 
     995},{
    1967996{75,75,79,83,31100,112,92}
    1968 
    1969997,{113,117,126,125,20315,94,107}
    1970 
    1971998,{124,122,116,108,32117,120,117}
    1972 
    1973999,{98,94,99,110,17217,93,107}
    1974 
    19751000},{108,94,82,88,88,104,126,111}
    1976 
    19771001#endif
    1978 
    19791002/*fin_reglage*/
    19801003
    1981 
    1982 
    19831004} };
    19841005
     
    19861007
    19871008
    1988 
    1989 
    1990 
    1991 
    1992 
    19931009int     calcul_somme_block(block_type_modele* blk,int longueur)
    1994 
    19951010{
    1996 
    19971011int i,so=0;;
    1998 
    19991012for(i=0;i<(longueur/4-4);i++)  so^=(int)blk->mot[i];
    2000 
    20011013/* somme sur tous les mots internes     : on exclus le dbut, les codes et la fin        */
    2002 
    20031014return((so^(so>>16))&0xffff);
    2004 
    20051015}
    20061016
     
    20081018
    20091019
    2010 
    2011 
    2012 
    2013 
    2014 
    20151020void  valide_block(block_type_modele* blk,int type,int block_num)
    2016 
    20171021{
    2018 
    20191022int somme,longueur;
    2020 
    20211023def_long_block
    2022 
    20231024longueur=long_block[type];
    2024 
    20251025/*printf("valide block adresse %x  type %d  numblock %d  longueur=%d \n" */
    2026 
    20271026/*              ,(unsigned)blk,type,block_num,longueur);*/
    2028 
    20291027blk->debut              =       debut_block_mesure;
    2030 
    20311028somme=0;blk->code1              =       (((long)longueur)<<16)  |       somme;
    2032 
    20331029blk->code2              =       (((long)block_num) & 0xffffff ) | ( (((long)type)<<24)&0xff000000 );
    20341030
    2035 
    2036 
    20371031blk->mot[longueur/4-4]  =       fin_block_mesure;
    20381032
    2039 
    2040 
    20411033#if defined(_ECC_LIB_H_)
    2042 
    20431034{
    2044 
    20451035int place_ecc;
    2046 
    20471036place_ecc=(longueur-4-ECC_SIZE-SIZE_HEAD-((longueur-4-SIZE_HEAD)/ECC_TOTAL)*ECC_SIZE)/4;
    2048 
    20491037SetEcc( blk, (unsigned char *) &(blk->mot[place_ecc] ) ) ;
    2050 
    20511038}
    2052 
    20531039#endif
    20541040
    2055 
    2056 
    20571041somme=calcul_somme_block(blk,longueur);
    2058 
    20591042blk->code1              =       (((long)longueur)<<16)  |       somme;
    2060 
    20611043/* l'ecc est faux car on a change la somme: mettre la somme a zero avant de tester ecc  */
    2062 
    20631044}
    20641045
    2065 
    2066 
    20671046/* Quand on est sur une machine swappee, on ne cherche pas a verifier */
    2068 
    20691047/* le checksum, puisqu'on a modifie les blocs, sans swapper par exemple */
    2070 
    20711048/* les chars des noms de bolometres et des chaines GPS... */
    2072 
    20731049#ifdef __alpha
    2074 
    20751050#define SWAP
    2076 
    20771051#endif
    2078 
    20791052#if defined(Linux)  || defined(linux)
    2080 
    20811053#define SWAP
    2082 
    20831054#endif
    20841055
    20851056
    20861057
    2087 
    2088 
    2089 
    2090 
    20911058int  verifie_block(block_type_modele* blk)
    2092 
    20931059{
    2094 
    20951060int type,lg,som;
    2096 
    20971061def_long_block
    2098 
    20991062if(blk->debut != debut_block_mesure)                                    return(block_debut_erreur);
    2100 
    21011063type=type_block(blk);           if( (type<0) ||(type>=nb_type_blocks) ) return(block_type_inconnu);     
    2102 
    21031064lg=longueur_block(blk);         if( lg != long_block[type] )            return(block_longueur_erreur); 
    2104 
    21051065if( blk->mot[(lg/4)-4]  !=      fin_block_mesure)                       return(block_fin_erreur);       
    2106 
    21071066#ifndef SWAP
    2108 
    21091067som=calcul_somme_block(blk,lg); if( som!= somme_block(blk))             return(block_somme_erreur);
    2110 
    21111068#endif
    2112 
    21131069return(block_correct);
    2114 
    21151070}
    21161071
    21171072
    2118 
    2119 
    2120 
    21211073int  verifie_block_printf(block_type_modele* blk)
    2122 
    21231074{
    2124 
    21251075int type,lg,som;
    2126 
    21271076def_long_block
    2128 
    21291077def_nom_block
    2130 
    21311078if(blk->debut != debut_block_mesure)
    2132 
    21331079        {
    2134 
    21351080        printf(" erreur dans le code debut de block      \n");
    2136 
    21371081        return(block_debut_erreur);
    2138 
    21391082        }       
    21401083
    2141 
    2142 
    21431084type=type_block(blk);
    2144 
    21451085if( (type<0) || (type>nb_type_blocks) )
    2146 
    21471086        {
    2148 
    21491087        printf(" block de type %d  inconnu\n",type);
    2150 
    21511088        return(block_type_inconnu);
    2152 
    21531089        }
    21541090
    2155 
    2156 
    21571091lg=longueur_block(blk);
    2158 
    21591092if( lg!=long_block[type] )     
    2160 
    21611093        {
    2162 
    21631094        printf(" block type %s  erreur de longueur (nominal=%d , dans le block=%d \n"
    2164 
    21651095                        ,nom_block[type],long_block[type],lg);
    2166 
    21671096        return(block_longueur_erreur);
    2168 
    21691097        }
    21701098
    2171 
    2172 
    21731099som=calcul_somme_block(blk,lg);
    2174 
    21751100if( som!=somme_block(blk) )     
    2176 
    21771101        {
    2178 
    21791102        printf(" block type %s   :  erreur de somme (calculee=%d , dans le block=%d \n"
    2180 
    21811103                        ,nom_block[type],som,somme_block(blk) );
    2182 
    21831104        return(block_somme_erreur);
    2184 
    21851105        }
    2186 
    21871106       
    2188 
    21891107if(blk->mot[(lg/4)-4]   != fin_block_mesure)   
    2190 
    21911108        {
    2192 
    21931109        printf(" block type %s  erreur de code fin de block : trouve %x au lieu de %x \n"
    2194 
    21951110                        ,nom_block[type],(int)blk->mot[(lg/4)-4],fin_block_mesure);
    2196 
    21971111        return(block_fin_erreur);
    2198 
    21991112        }
    22001113
    2201 
    2202 
    22031114return(block_correct);
    2204 
    22051115}
    22061116
     
    22091119
    22101120
    2211 
    2212 
    2213 
    2214 
    2215 
    2216 
  • trunk/Poubelle/archediab.old/archeops.h

    r652 r657  
    297297       
    298298/* code_util des bolos  */
    299 enum{bolo_hors_service,bolo_normal_transmis,bolo_normal_non_transmis,bolo_thermo_simplifie};
     299
     300/*      bit 0   ->      bolo en service (fenetre ouverte sur le mac)                            */
     301/*      bit 1   ->      bolo transmis dans les donnees comprimees:  block_type_bolo_comprime    */
     302/*      bit 2   ->      courbe 1 periode transmise dans les     block_type_une_periode          */
     303/*      bit 3   ->      carte modofiées bebo pour       thermometre                             */
     304
     305#define         bolo_en_service                 1
     306#define         bolo_transmis_comprime          2
     307#define         bolo_transmis_un_per            4
     308#define         bolo_thermo_simplifie           8
     309
     310/*enum{bolo_hors_service,bolo_normal_transmis,bolo_normal_une_per,bolo_normal_non_transmis,bolo_thermo_simplifie};*/
    300311
    301312       
     
    706717
    707718/*  ---------------------   structures N° 12 :  data bolo apres compression sur 7 bit    ------ */
    708 /*  --   longueur variable car nb_max_bolo est remplacé par  parametr.nb_bolo apres calcul   ------ */
     719/*  ------------------------------------------------------------------------------------------- */
     720/*  --   longueur variable car nb_max_bolo est remplacé par  parametr.nb_bolo apres calcul  --- */
    709721/*  --     ATTENTION   l'ECC  calcule  est donc faux  !!!!!!                             ------ */
    710722/*  ------------------------------------------------------------------------------------------- */
Note: See TracChangeset for help on using the changeset viewer.