mv canbus to its own file

This commit is contained in:
canpadawan
2016-06-08 11:31:49 +02:00
parent 97db24b698
commit 38d3b34832
2 changed files with 104 additions and 6 deletions
+28 -5
View File
@@ -1,11 +1,34 @@
#ifndef CAN_BUS_H
#define CAN_BUS_H
#ifndef CANBus_H
#define CANBus_H
class CAN_Bus
class CANConnectionContainer;
class CANBus
{
public:
CAN_Bus();
CANBus();
CANBus(const CANBus&);
virtual ~CANBus(){}; /*TODO: remove connection from CANBus and add CANBus as an element of CANConnection */
int busNum;
int speed;
bool listenOnly;
bool singleWire;
bool active; //is this bus turned on?
CANConnectionContainer* container;
void setSpeed(int); // new speed
void setListenOnly(bool); //bool for whether to only listen
void setSingleWire(bool); //bool for whether to use single wire mode
void setEnabled(bool); //whether this bus should be enabled or not.
void setContainer(CANConnectionContainer *);
CANConnectionContainer* getContainer();
void setBusNum(int);
int getSpeed();
int getBusNum();
bool isListenOnly();
bool isSingleWire();
bool isActive();
};
#endif // CAN_BUS_H
#endif // CANBus_H