2010-12-22 21:23:10 -04:00
|
|
|
#ifndef AP_RangeFinder_MaxsonarLV_H
|
|
|
|
#define AP_RangeFinder_MaxsonarLV_H
|
|
|
|
|
|
|
|
#include "RangeFinder.h"
|
|
|
|
|
|
|
|
#define AP_RANGEFINDER_MAXSONARLV_MIN_DISTANCE 15
|
|
|
|
#define AP_RANGEFINDER_MAXSONARLV_MAX_DISTANCE 645
|
|
|
|
|
|
|
|
class AP_RangeFinder_MaxsonarLV : public RangeFinder
|
|
|
|
{
|
|
|
|
public:
|
2011-01-03 00:17:43 -04:00
|
|
|
AP_RangeFinder_MaxsonarLV();
|
2011-05-04 16:12:27 -03:00
|
|
|
int convert_raw_to_distance(int _raw_value) { return _raw_value * 2.54; } // read value from analog port and return distance in cm
|
2010-12-22 21:23:10 -04:00
|
|
|
};
|
|
|
|
#endif
|