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:
Collin Kidder
2022-10-04 19:48:11 -04:00
parent 2afd41b681
commit 9ebbaca668
18 changed files with 763 additions and 35 deletions
+4 -1
View File
@@ -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: