Thanks for the help everyone. I put together the subclass that Alexander described and will post it here in case it helps anyone else. It does compile but hasn't been tested in any way.
PIDEncoder.h
Code:
#include "Encoder.h"
#include "PIDSource.h"
class PIDEncoder : public Encoder, PIDSource
{
public:
//constructor
PIDEncoder(UINT32 aSlot, UINT32 aChannel,
UINT32 bSlot, UINT32 bChannel,
bool reverseDirection, EncodingType encodingType);
//destructor
~PIDEncoder();
//virtual from PIDSource
double PIDGet();
private:
};
PIDEncoder.cpp
Code:
#include "PIDEncoder.h"
//constructor
PIDEncoder::PIDEncoder(UINT32 aSlot, UINT32 aChannel,
UINT32 bSlot, UINT32 bChannel,
bool reverseDirection, EncodingType encodingType) : Encoder(aSlot,aChannel,bSlot,bChannel,reverseDirection,encodingType)
{
}
//destructor
PIDEncoder::~PIDEncoder()
{
}
//virtual from PIDSource
double PIDEncoder::PIDGet()
{
return this->GetDistance();
}