Subversion Repositories shark

Rev

Rev 1655 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1655 giacomo 1
/*
2
 * Project: S.Ha.R.K.
3
 *
4
 * Coordinators:
5
 *   Giorgio Buttazzo    <giorgio@sssup.it>
6
 *   Paolo Gai           <pj@gandalf.sssup.it>
7
 *
8
 * Authors     :
9
 *   Giacomo Guidi       <giacomo@gandalf.sssup.it>
10
 *
11
 * ReTiS Lab (Scuola Superiore S.Anna - Pisa - Italy)
12
 *
13
 * http://www.sssup.it
14
 * http://retis.sssup.it
15
 * http://shark.sssup.it
16
 */
17
 
18
#include "kernel/kern.h"
19
 
20
#include "drivers/shark_keyb26.h"
21
#include "rtdac4.h"
22
 
23
int main(int argc, char **argv)
24
{
25
 
26
  char ch,buf_char[4];
27
  short buf_short[2];
28
  long prescaler;
29
 
30
  RTDAC4_open();
31
 
32
  RTDAC4_read_states(buf_char);
33
 
34
  buf_short[0] = 0;
35
  buf_short[1] = 0;
36
 
37
  RTDAC4_set_motor(buf_short);
38
 
39
  /* Reset encoders */
40
  RTDAC4_ioctl(1, 0);
41
 
42
  prescaler = 0;
43
 
44
  /* Set prescaler */
45
  RTDAC4_ioctl(2, prescaler);
46
 
47
  ch = keyb_getch(BLOCK);
48
 
49
  sys_end();
50
 
51
  return 0;
52
 
53
}