ardupilot/libraries/AP_BattMonitor/AP_BattMonitor_SMBus.h
Gustavo Jose de Sousa 13753a192e AP_BattMonitor: standardize inclusion of libaries headers
This commit changes the way libraries headers are included in source files:

 - If the header is in the same directory the source belongs to, so the
 notation '#include ""' is used with the path relative to the directory
 containing the source.

 - If the header is outside the directory containing the source, then we use
 the notation '#include <>' with the path relative to libraries folder.

Some of the advantages of such approach:

 - Only one search path for libraries headers.

 - OSs like Windows may have a better lookup time.
2015-08-19 20:42:23 +09:00

31 lines
906 B
C++

/// -*- tab-width: 4; Mode: C++; c-basic-offset: 4; indent-tabs-mode: nil -*-
#ifndef AP_BATTMONITOR_SMBUS_H
#define AP_BATTMONITOR_SMBUS_H
#include <AP_Common/AP_Common.h>
#include <AP_Param/AP_Param.h>
#include <AP_Math/AP_Math.h>
#include "AP_BattMonitor_Backend.h"
#define AP_BATTMONITOR_SMBUS_TIMEOUT_MICROS 5000000 // sensor becomes unhealthy if no successful readings for 5 seconds
class AP_BattMonitor_SMBus : public AP_BattMonitor_Backend
{
public:
/// Constructor
AP_BattMonitor_SMBus(AP_BattMonitor &mon, uint8_t instance, AP_BattMonitor::BattMonitor_State &mon_state) :
AP_BattMonitor_Backend(mon, instance, mon_state)
{}
// virtual destructor to reduce compiler warnings
virtual ~AP_BattMonitor_SMBus() {}
};
// include specific implementations
#include "AP_BattMonitor_SMBus_PX4.h"
#include "AP_BattMonitor_SMBus_I2C.h"
#endif // AP_BATTMONITOR_SMBUS_H