Project

General

Profile

Revision d7c3c222

IDd7c3c222b98353458e9c1e5353c8a4c76f847dc9
Parent 2237e1f0
Child a69f6363, 6350051e, 04270a10

Added by Thomas Mullins about 11 years ago

Encoders node now actually reads from hardware

This compiles but hasn't been tested on the Scout yet.

View differences:

scout/encoders/src/encoders.h
29 29
 * 
30 30
 * @author Colony Project, CMU Robotics Club
31 31
 * @author Alex Zirbel
32
 * @author Tom Mullins
32 33
 **/
33 34

  
34 35
#ifndef _ENCODERS_H_
35 36
#define _ENCODERS_H_
36 37

  
38
#include <fstream>
37 39
#include "encoders/query_encoders.h"
38 40

  
41
class Encoder
42
{
43
    public:
44
        Encoder(int n);
45
        int get_ticks();
46
    private:
47
        std::fstream fticks; /**< The file in sysfs containing tick count */
48
};
49

  
39 50
/** @brief Initialize the encoders module and driver **/
40 51
int main(int argc, char **argv);
41 52

  

Also available in: Unified diff