FACT++  1.0
main ( int  argc,
char **  argv 
)

Definition at line 21 of file test_server_ccpc.c.

References dis_add_cmnd, dis_add_service, dis_start_serving, i, ids, registers, set_register(), and sprintf().

24 {
25  int i;
26  char aux[80];
27 
28  for(i = 0; i< 10; i++)
29  {
30  sprintf(aux,"Register%03d",i);
31  ids[i] = dis_add_service( aux, "I", &registers[i], sizeof(int),
32  (void *)0, 0 );
33  }
34 
35  dis_add_cmnd("SET_REGISTER","I:2",set_register, 0);
36 
37  dis_start_serving( "TEST_REGISTERS" );
38 
39  while(1)
40  {
41  pause();
42  }
43 }
int ids[10]
int i
Definition: db_dim_client.c:21
void set_register(int *tag, int *data, int *size)
#define dis_add_cmnd
Definition: dis.h:13
#define dis_start_serving
Definition: dis.h:8
#define dis_add_service
Definition: dis.h:12
int registers[10]
sprintf(name1,"NewService%d", i)

+ Here is the call graph for this function: