Merge branch 'master' of github.com:collin80/SavvyCAN into WIP
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
# SavvyCAN
|
||||
Qt based cross platform canbus tool
|
||||
(C) 2015-2018 EVTV and Collin Kidder
|
||||
(C) 2015-2021 EVTV and Collin Kidder
|
||||
|
||||
A Qt5 based cross platform tool which can be used to load, save, and capture canbus frames.
|
||||
This tool is designed to help with visualization, reverse engineering, debugging, and
|
||||
capturing of canbus frames.
|
||||
|
||||
Really requires at a resolution of at least 1024x768. Fully multi-monitor capable. Works on 4K monitors as well.
|
||||
Please use the "Discussions" tab here on GitHub to ask questions and interact with the community.
|
||||
|
||||
Requires at a resolution of at least 1024x768. Fully multi-monitor capable. Works on 4K monitors as well.
|
||||
|
||||
You are highly recommended to use the
|
||||
[CANDue board from EVTV](http://store.evtv.me/proddetail.php?prod=ArduinoDueCANBUS&cat=23).
|
||||
@@ -46,12 +48,15 @@ http://www.qcustomplot.com/
|
||||
However, this source code is integrated into the source for SavvyCAN and one isn't required
|
||||
to download it separately.
|
||||
|
||||
This project requires 5.8.0 or higher because of a dependency on QSerialBus. However, you will get
|
||||
even more SerialBus goodness if you use QT 5.11 or 5.12
|
||||
This project requires 5.10.0 or higher because of a dependency on QtSerialBus. However, you will get
|
||||
even more SerialBus goodness if you use QT 5.11 or higher.
|
||||
|
||||
NOTE: QT6 currently lacks support for QtSerialBus and many other QT sub-features. At this time you cannot
|
||||
use QT6 to compile SavvyCAN. Support for QT6 should be possible around QT6.2.
|
||||
|
||||
## Instructions for compiling:
|
||||
|
||||
[Download the newest stable version of Qt directly from qt.io](https://www.qt.io/download/) (You need 5.8.x or newer)
|
||||
[Download the newest stable version of Qt directly from qt.io](https://www.qt.io/download/) (You need 5.10.x or newer)
|
||||
|
||||
```sh
|
||||
cd ~
|
||||
@@ -60,7 +65,7 @@ git clone https://github.com/collin80/SavvyCAN.git
|
||||
|
||||
cd SavvyCAN
|
||||
|
||||
~/Qt/5.8/gcc_64/bin/qmake
|
||||
~/Qt/5.10/gcc_64/bin/qmake
|
||||
|
||||
make
|
||||
```
|
||||
|
||||
@@ -188,6 +188,7 @@ void SerialBusConnection::framesReceived()
|
||||
{
|
||||
frame_p->setExtendedFrameFormat(recFrame.hasExtendedFrameFormat());
|
||||
frame_p->setFrameId(recFrame.frameId() + 0x20000000ull);
|
||||
frame_p->isReceived = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -197,7 +198,8 @@ void SerialBusConnection::framesReceived()
|
||||
frame_p->setTimeStamp(recFrame.timeStamp());
|
||||
frame_p->setFrameType(recFrame.frameType());
|
||||
frame_p->setError(recFrame.error());
|
||||
frame_p->isReceived = true;
|
||||
/* If recorded frame has a local echo, it is a Tx message, and thus should not be marked as Rx */
|
||||
frame_p->isReceived = !recFrame.hasLocalEcho();
|
||||
|
||||
if (useSystemTime) {
|
||||
frame_p->setTimeStamp(QCanBusFrame::TimeStamp(0, QDateTime::currentMSecsSinceEpoch() * 1000ul));
|
||||
|
||||
+3
-3
@@ -1283,7 +1283,7 @@ bool FrameFileIO::isPCANFile(QString filename)
|
||||
{
|
||||
while (!inFile->atEnd()) {
|
||||
lineCounter++;
|
||||
if (lineCounter > 10)
|
||||
if (lineCounter > 25)
|
||||
{
|
||||
break;
|
||||
}
|
||||
@@ -1423,7 +1423,7 @@ bool FrameFileIO::loadPCANFile(QString filename, QVector<CANFrame>* frames)
|
||||
{
|
||||
int numBytes = line.mid(37,2).trimmed().toInt();
|
||||
QByteArray bytes(numBytes, 0);
|
||||
qDebug() << thisFrame.payload().length();
|
||||
//qDebug() << thisFrame.payload().length();
|
||||
thisFrame.isReceived = true;
|
||||
thisFrame.bus = 0;
|
||||
if (line.at(25) == ' ') {
|
||||
@@ -1434,7 +1434,7 @@ bool FrameFileIO::loadPCANFile(QString filename, QVector<CANFrame>* frames)
|
||||
if (line.at(40) == 'R') {
|
||||
thisFrame.setFrameType(QCanBusFrame::RemoteRequestFrame);
|
||||
} else {
|
||||
QList<QByteArray> tokens = line.mid(40, thisFrame.payload().length() * 3).split(' ');
|
||||
QList<QByteArray> tokens = line.mid(40, numBytes * 3).split(' ');
|
||||
thisFrame.setFrameType(QCanBusFrame::DataFrame);
|
||||
for (int d = 0; d < numBytes; d++)
|
||||
{
|
||||
|
||||
@@ -5,6 +5,9 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
QApplication a(argc, argv);
|
||||
|
||||
//Add a local path for Qt extensions, to allow for per-application extensions.
|
||||
a.addLibraryPath("plugins");
|
||||
|
||||
//These things are used by QSettings to set up setting storage
|
||||
a.setOrganizationName("EVTV");
|
||||
a.setApplicationName("SavvyCAN");
|
||||
|
||||
Reference in New Issue
Block a user