/[PAMELA software]/yoda/techmodel/forroutines/calorimeter/fillin.c
ViewVC logotype

Annotation of /yoda/techmodel/forroutines/calorimeter/fillin.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2.2 - (hide annotations) (download)
Fri Dec 3 22:08:10 2004 UTC (20 years ago) by kusanagi
Branch: MAIN
Changes since 2.1: +1 -1 lines
File MIME type: text/plain
*** empty log message ***

1 kusanagi 2.1 /***************************************************************
2     *
3     * change the buffer from bytes to words to read the calorimeter
4     *
5     ***************************************************************/
6     /*
7     * include needed system headers
8     */
9     #include <stdio.h> /* include standard i/o library */
10     #include <stdlib.h> /* include standard library */
11     #include <string.h> /* include string library */
12     #include <unistd.h> /* include unix standard library */
13     #include <sys/types.h> /* */
14     #include <sys/stat.h> /* */
15     #include <fcntl.h> /* */
16     #include <errno.h> /* error simbol definitions */
17     #include <time.h> /* system time definitions */
18     #include <math.h> /* math library */
19    
20     void fillin_(int *m, int *lunga, int *lleng, int *lung, int *pari, short int *vect, char *vecta)
21     {
22     int i;
23     char tempv[*lung];
24     char tempv2[*lung];
25 kusanagi 2.2 memcpy(&tempv, &*vecta+*m-1, *lung-*m+1);
26 kusanagi 2.1 for (i = 1; i < *lung-1; i=i+2){
27     tempv2[i-1]=tempv[i];
28     tempv2[i]=tempv[i-1];
29     };
30     memcpy(&*vect, &tempv2, (*lunga-*lleng)*2);
31     }
32    
33    
34    
35    
36    
37    
38    
39    
40    
41    

  ViewVC Help
Powered by ViewVC 1.1.23