summaryrefslogtreecommitdiffstats
path: root/src/plugins/canbus/tinycan
Commit message (Collapse)AuthorAgeFilesLines
...
| | * CAN: Better error messages when loading dynamic librariesAndre Hartmann2016-08-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make use of the detailed (and localized) error messages that QLibrary already provides. Example: Cannot load library pcanbasic: \ (pcanbasic: cannot open shared object file: No such file or directory) Change-Id: I3f4fd42d1872a00f2c4ecc6172ccc17995c7888e Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | | CAN-Backends: Use std::move to append QCanBusFrame to QVectorAndre Hartmann2016-09-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | For SocketCAN this was already done in 71d19b3e9ccbbfc3131fbd21d983faaca0002621 Change-Id: I734e1d83901f8ce2de189f7d873724aa4aab989f Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | CAN: Simplify debug error message generationAndre Hartmann2016-08-311-13/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The warning is already shown in PeakCanBusPlugin::createDevice() and TinyCanBusPlugin::createDevice() so it does not need to be done here. Change-Id: Ifac34d9b96eff5920d09f3c971caeda62d97839a Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | | CAN: Unify interface namesAndre Hartmann2016-08-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mostly, the interfaces now simply start with can0 and the number increases for every next interface. Some vendors distinguish between e.g. PCI and USB interfaces. In this case, the interfaces are named usb0 and pci0, with increasing numbers, respectively. Multiple channels per device are accessed by adding the channel number after a dot: can0.0 for the first channel in the first device (TinyCAN). SocketCAN is still a bit different, as it allows arbitrary interface names to be mapped to the hardware or virtual CAN busses. [ChangeLog][QtSerialBus][Unify interface names] The interface names of the different backends were unified to follow a common rule: The prefixes were unified, the numbering now always starts with zero. Change-Id: Ia2ca76a9be01b9123aed1ede90debf69871bb82c Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | | Merge "Merge remote-tracking branch 'gerrit/5.7' into dev" into refs/staging/devAlex Blasche2016-08-021-17/+32
|\ \ \
| * | | Merge remote-tracking branch 'gerrit/5.7' into devAlex Blasche2016-08-011-17/+32
| |\| | | | | | | | | | | | | | Change-Id: I5202af1faa3b92018747b38fe54524cc712d2f43
| | * | Merge remote-tracking branch 'origin/5.6' into 5.7Edward Welbourne2016-07-261-17/+32
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/canbus/peakcan/peakcanbackend.cpp One side renamed a member. The other changed some code using it. Change-Id: I14131122835ab9014894eadf4b529bdfd413e436
| | | * CAN: More information when configuration failsAndre Hartmann2016-07-191-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | ... for PEAK and TINY backends. Change-Id: I0285107616bbfbaa91df266e2116f5d7460d60ca Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| | | * Fix logic with the wrong priority of operationsDenis Shienkov2016-07-121-16/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The assignment '=' operator has a lower priority, than the comparison '==, !=' operators. Thus, the result of logical statements is wrong. Change-Id: Iab281f1f3dd95b59da94379fd68a45f75e2dd5ac Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | | QCanBusFactory: Add override to derived createDevice()Andre Hartmann2016-08-011-1/+1
|/ / / | | | | | | | | | | | | Change-Id: I78fdf3ebf0d5becd11a003596c0f3ec3aa556504 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | | QCanBus: Receive an error message from createDevice()Andre Hartmann2016-06-011-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog] Before, createDevice() could only return nullptr if anything goes wrong. Now, an optional textual error description can be returned. Task-number: QTBUG-53642 Change-Id: Ie097e5c63096ae6a6fb9a798e4a8f23219cf1cfb Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | CAN: Simplify the code of the TinyCAN backendDenis Shienkov2016-05-312-33/+14
|/ / | | | | | | | | | | | | | | | | | | We do not need to keep separate enableWriteNotification() and enableReadNotification() methods; their bodies can be moved to the open()/close() methods, that simplifies the code. Change-Id: I7a6c1dd5ccfea51b0506e717c9809faa59f13161 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | CAN: Give some methods and variables shorter namesDenis Shienkov2016-05-132-17/+18
| | | | | | | | | | | | | | | | ... that better express their purpose. Change-Id: I2a725e755695df2eab2b11289b44d90a81012f04 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com> Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | CAN: Do not use PUBLIC(PRIVATE)_HEADERS divisionDenis Shienkov2016-05-131-6/+2
| | | | | | | | | | | | | | | | | | ... also made small cosmetic dependent refactoring of plugins project files. Change-Id: I0fbfd585c14868944a3cac8ff5bd82408a5cace6 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Use DISTFILES instead of OTHER_FILESDenis Shienkov2016-05-131-1/+1
|/ | | | | | Change-Id: Id666c7c78b159955db1b494f6997437b6ea19bc1 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* CAN: Do not use QPointer class as it is overheadDenis Shienkov2016-05-043-2/+2
| | | | | | | ... and use the QScopedPointer instead, where possible. Change-Id: Ie503d5ff31af77cf6a495f324c1e93c34ff7d58b Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* CAN: Correct spelling for "CAN" and "CAN FD"Andre Hartmann2016-05-021-2/+2
| | | | | | | | | ... in comments, user and debug output, and documentation. Change-Id: I76ddf418bc1612a7310f80ee2ce596e8d6ab0721 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Frank Meerkoetter <frank.meerkoetter@basyskom.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Replace 'Q_DECL_OVERRIDE' with 'override'Denis Shienkov2016-04-262-6/+6
| | | | | Change-Id: Iebbd61359296499600fe164429e710273a94b86d Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Use 'auto' where it is possibleDenis Shienkov2016-04-221-1/+1
| | | | | | Change-Id: I3d915a6230a1f35317abc39d6266a9d46a5d9be6 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com> Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Use 'nullptr' where it is possibleDenis Shienkov2016-04-213-4/+4
| | | | | Change-Id: I729e6b53cbc0b9a16c72c2351cc95d6bd7a2a0aa Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Merge remote-tracking branch 'gerrit/5.6.0' into 5.6Alex Blasche2016-03-081-1/+1
|\ | | | | | | | | | | | | Conflicts: src/plugins/canbus/socketcan/main.cpp Change-Id: I17ac8fdbbbb4569f840bf2be1f25d571c2920451
| * Fix static builds of CAN bus pluginsv5.6.0-rc1Alex Blasche2016-02-181-1/+1
| | | | | | | | | | | | | | | | Task-number: QTBUG-51201 Change-Id: Ibb8aa4e95d642429aef702f62b96e54bd4ace2e1 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@theqtcompany.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | standardize statement order in project files a bitOswald Buddenhagen2016-03-021-2/+2
| | | | | | | | | | Change-Id: If5149893f81ef551f64c539d4b70c44f1181df37 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | consistently put qt_{module,plugin,tool} at the end of project filesOswald Buddenhagen2016-03-021-5/+5
|/ | | | | | | | this fixes static builds by ensuring that all dependencies are exported. Task-number: QTBUG-51071 Change-Id: I8bf84f36890b0c6bd3df0960112ecc12f11aa398 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* Don't attempt to write an invalid QCanBusFrameAlex Blasche2015-12-181-0/+5
| | | | | | Change-Id: I9b73c9bdfe933a74302b4871aa40d5a025496b8c Reviewed-by: Rolf Eike Beer <eb@emlix.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Improve CanFD related error reporting in peakcan and tinycanAlex Blasche2015-12-181-2/+2
| | | | | | | | | Peakcan can support CanFD but it is not implemented yet. Tinycan doesn't seem to support it. Change-Id: I274421ccdad831daa18320a06bbc8b94a3fdd710 Reviewed-by: Rolf Eike Beer <eb@emlix.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* fix typo: (un)?suported -> (un)supportedRolf Eike Beer2015-12-181-1/+1
| | | | | Change-Id: Id816a10b0e2f1394b92d940d197f28b0c43905fd Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* fix spurious dependenciesOswald Buddenhagen2015-11-111-1/+1
| | | | | | | | | most importantly, eliminate gui everywhere where it is not needed, and don't redundantly list it where it is. Change-Id: I8567e8473d976d9087a7da6d8f9f81b43148c8b2 Reviewed-by: Rolf Eike Beer <eb@emlix.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@theqtcompany.com>
* Add QCBD::BitRateKey support for the TinyCan pluginDenis Shienkov2015-09-072-9/+88
| | | | | Change-Id: Ie457ce2e2ab5375e63f4b392f0eac0758d7d6601 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Handle QCBF::ErrorFrame type for the TinyCan pluginDenis Shienkov2015-09-071-1/+22
| | | | | | | | | | | According to the latest native API, now we can handle the QCanBusFrame::ErrorFrame. Note: Not all modules support this function and the feature should be activated. Change-Id: I536fc7c43e96379a8cb40b3dc72fa9f0dfe33399 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Update the symbols header for the TinyCan pluginDenis Shienkov2015-09-072-19/+35
| | | | | | | | | | We need to update the header, according to the latest API version (v 401): http://www.mhs-elektronik.de/index.php?module=download&action=list Change-Id: I7a75d17d345e570819667865f260aa0938ed6fd0 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Introduce an API for tracking the transferred framesDenis Shienkov2015-09-062-9/+7
| | | | | | | Note: There are no this implementation for the SocketCan plugin yet. Change-Id: I0b2ca92188f8784cebf046b033590c29c2ef3180 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Optimize the CAN frames receivingDenis Shienkov2015-09-061-1/+5
| | | | | | | | | | | | | We do not need to emit a signal when each frame is received, this increases the load of the event loop. The input FIFO can contains more than one frame, thus we only need to emit the signal when all current frames were read. In this case this signal is renamed to framesReceived instead of frameReceived. Change-Id: If97cfd4304dae9549748f87dbd0b54eae4c0a0f2 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Handle missed properties for the received frame in TinyCan pluginDenis Shienkov2015-09-051-0/+2
| | | | | | | | | We need to extract the "Extended Frame Format" and the "RemoteRequestFrame/DataFrame" properties from the received TinyCan's native frame. Change-Id: Ie03f1b5343e97666839e8816e83a2ecd96e822d5 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Implement the initial support for the TINY CAN adapterDenis Shienkov2015-08-257-0/+1087
This commit implements the initial support for the CAN adapter from the MHS Elektronik: http://www.mhs-elektronik.de/ . The implementation has the following features: * The adapter is configured for the one default speed 500KBaud during opening. * The configuring of parameters is not implemented yet. * The error frame interpretation is not implemented yet. * Supports the buffered mode for the outgoing frames, but we still need the framesToWrite() method and the framesWritten() signal. Change-Id: I4d3e1861dcd4b92a56cb7b9e148ba261c3ee7cd7 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>