Changeset 649 in Sophya for trunk/Poubelle/archediab.old/archediab.sources/c/acquisition_general.c
- Timestamp:
- Nov 25, 1999, 2:56:34 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Poubelle/archediab.old/archediab.sources/c/acquisition_general.c
r643 r649 14 14 #include "compress.h" 15 15 #include "controle.h" 16 #include "simulmission.h" 16 17 17 18 … … 41 42 static int count_moy_err=0; 42 43 int err; 44 static bilan_err=0; 43 45 44 46 if (item!=tache_de_fond) return; … … 56 58 */ 57 59 58 if( count-- < 0 )60 //if( count-- < 0 ) 59 61 { 60 62 count=3; 61 ecritD(fenetre_controle,con_ retard1,"%d",tt->nb_lec_fofo_ext);62 tt-> nb_lec_fofo_ext=0;63 ecritD(fenetre_controle,con_fifo,tt->val_con_fifo/2); 64 tt->val_con_fifo=0; 63 65 } 64 66 65 67 66 68 err=test_erreur(); //______________ test des erreurs _______________________________ 69 70 if(err) bilan_err+=10*err; 71 72 // Pour la simulation, rempli les buffers avec les donnees simulees 73 74 if (tt->PCI_actif==3) SimulMissionReadLoop(); 67 75 68 76 69 77 //_____________________ lit la table télémesure ______________________________________ 70 78 71 79 if(bilan_err>100) bilan_err=100; 80 if(bilan_err>50) bilan_err-=20; 81 if(bilan_err>10) bilan_err-=5; 82 if(bilan_err>0) bilan_err--; 83 if(bilan_err) ecritD(fenetre_controle,con_erreur,20+bilan_err*10); 84 else ecritD(fenetre_controle,con_erreur,0); 72 85 73 86 q=(longueur_table_tm+tt->tm.pos_ecrit-tt->tm.pos_lit)%longueur_table_tm; 87 88 ecritD(fenetre_controle,con_pile,(1000*((longueur_table_tm+tt->tm.pos_ecrit-tt->tm.pos_lit)%longueur_table_tm))/longueur_table_tm); 89 ecritD(fenetre_controle,con_donnee,tt->val_con_donnee); 74 90 75 91 while(q) 76 92 { 77 ecritD(fenetre_controle,con_ retard2,"%d",(longueur_table_tm+tt->tm.pos_ecrit-tt->tm.pos_lit)%longueur_table_tm);78 93 ecritD(fenetre_controle,con_pile,(1000*((longueur_table_tm+tt->tm.pos_ecrit-tt->tm.pos_lit)%longueur_table_tm))/longueur_table_tm); 94 // printf(" pile = %d \n",(1000*((longueur_table_tm+tt->tm.pos_ecrit-tt->tm.pos_lit)%longueur_table_tm))/longueur_table_tm); 79 95 //***************************************************************************************** 80 96 // *** … … 109 125 { 110 126 case ouverture : gg->flag_tc_reduite=litD(fen,e_tc_reduite,0); 111 if( tt->PCI_actif==1) reset_carte;127 if(acquisition_PCI) reset_carte; 112 128 ecritD(fen,e_tache_inter,0); // arreter les interruptions 113 129 reset_epld(); … … 161 177 break; 162 178 163 case e_vanne : { 164 long ll=(long)(&(gg->reglage.dilu.vanne))-(long)(&(gg->reglage.dilu)); 179 case e_vanne : 180 { 181 long ll=(long)(&(gg->reglage.dilu.vanne))-(long)(&(gg->reglage.dilu)); 165 182 int a=(int) valeur; 183 if(a==vanne_ouvre) 184 if(alerte(2,"voulez-vous vraiment ouvrir la vanne ??")!=1) break; 166 185 emission_tc_reduite(tc2_auto_dilu,ll,a); 167 186 } … … 189 208 case e_tache_inter : calfreq(0); // command ou arrete le flag epld sortie data 190 209 if(TTm) stoptimer(TTm); 191 if( tt->PCI_actif==1) reset_carte;210 if(acquisition_PCI) reset_carte; 192 211 tt->vi.a=0; 193 212 if(valeur)
Note:
See TracChangeset
for help on using the changeset viewer.