mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 06:28:27 -04:00
Decouple BinComm from FastSerial, now that we can use Stream instead.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@405 f9c3cf11-9bcb-44bc-f272-b75c42450872
This commit is contained in:
parent
96a80f1c66
commit
ed24b47fb3
@ -45,7 +45,7 @@
|
|||||||
#define DEC_MESSAGE_TIMEOUT 100
|
#define DEC_MESSAGE_TIMEOUT 100
|
||||||
|
|
||||||
BinComm::BinComm(const BinComm::MessageHandler *handlerTable,
|
BinComm::BinComm(const BinComm::MessageHandler *handlerTable,
|
||||||
FastSerial *interface) :
|
Stream *interface) :
|
||||||
_handlerTable(handlerTable),
|
_handlerTable(handlerTable),
|
||||||
_interface(interface)
|
_interface(interface)
|
||||||
{
|
{
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
#ifndef APM_BinComm_h
|
#ifndef APM_BinComm_h
|
||||||
#define APM_BinComm_h
|
#define APM_BinComm_h
|
||||||
|
|
||||||
#include <FastSerial.h>
|
|
||||||
#include "WProgram.h"
|
#include "WProgram.h"
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
@ -184,11 +183,11 @@ public:
|
|||||||
/// registered; handlers are called in the order
|
/// registered; handlers are called in the order
|
||||||
/// they appear in the table.
|
/// they appear in the table.
|
||||||
///
|
///
|
||||||
/// @param interface The FastSerial interface that will be used
|
/// @param interface The stream that will be used
|
||||||
/// for telemetry communications.
|
/// for telemetry communications.
|
||||||
///
|
///
|
||||||
BinComm(const MessageHandler *handlerTable,
|
BinComm(const MessageHandler *handlerTable,
|
||||||
FastSerial *interface);
|
Stream *interface);
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////
|
||||||
/// @name Decoder interface
|
/// @name Decoder interface
|
||||||
@ -227,7 +226,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
const MessageHandler *_handlerTable; ///< callout table
|
const MessageHandler *_handlerTable; ///< callout table
|
||||||
FastSerial *_interface; ///< Serial port we send/receive using.
|
Stream *_interface; ///< Serial port we send/receive using.
|
||||||
|
|
||||||
/// Various magic numbers
|
/// Various magic numbers
|
||||||
enum MagicNumbers {
|
enum MagicNumbers {
|
||||||
|
Loading…
Reference in New Issue
Block a user