Add a new connection type - Lawicel. It works for some devices, not
all. More development needed but this is a start. Also added ability to set serial speed and bus speed in the device setup which may be useful for other connection devices too.
This commit is contained in:
@@ -4,10 +4,11 @@
|
||||
#include "gvretserial.h"
|
||||
#include "mqtt_bus.h"
|
||||
#include "socketcand.h"
|
||||
#include "lawicel_serial.h"
|
||||
|
||||
using namespace CANCon;
|
||||
|
||||
CANConnection* CanConFactory::create(type pType, QString pPortName, QString pDriverName)
|
||||
CANConnection* CanConFactory::create(type pType, QString pPortName, QString pDriverName, int pSerialSpeed, int pBusSpeed)
|
||||
{
|
||||
switch(pType) {
|
||||
case SERIALBUS:
|
||||
@@ -16,6 +17,8 @@ CANConnection* CanConFactory::create(type pType, QString pPortName, QString pDri
|
||||
return new GVRetSerial(pPortName, false);
|
||||
case REMOTE:
|
||||
return new GVRetSerial(pPortName, true); //it's a special case of GVRET connected over TCP/IP so it uses the same class
|
||||
case LAWICEL:
|
||||
return new LAWICELSerial(pPortName, pSerialSpeed, pBusSpeed);
|
||||
case KAYAK:
|
||||
return new SocketCANd(pPortName);
|
||||
case MQTT:
|
||||
|
||||
Reference in New Issue
Block a user