summaryrefslogtreecommitdiffstats
path: root/CAN-binder/low-can-binding/can/can-bus-dev.cpp
AgeCommit message (Collapse)AuthorFilesLines
2017-04-27Create method to handle both CAN frames.Romain Forlot1-1/+1
Change-Id: Ie876614266fd2e7089754a8f917d25d316de4c98 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh> Fix: wrong call since renaming of function to more generic name Change-Id: I2adebb855bc815ba6ab14a1002b17d9c9fb293fd Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-27Don't use FD frame with BCM socket. Seems not working...Romain Forlot1-2/+14
Change-Id: I4f1d5cd489011675cf55914647b57c7332dec1b9 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-27Reworked reading CAN devices from BCM socket.Romain Forlot1-3/+6
Now reading thread hold in can_bus_t object instead of can_bus_dev_t and reading happens using select(). Change-Id: Ib8cc68c4484679168519f3c0fa485fedd1616c74 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-27Typo, rename, formatRomain Forlot1-2/+0
Change-Id: I8250ef78f0b540617bd249873250f62ad6361fdf Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-27Renaming confusing member "address_" to "index_"Romain Forlot1-5/+6
Change-Id: I0ec6d74e9adb791f8bef44f76c74be8365cdf037 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-24Misc: Cleanup, typo, formating and comments update.Romain Forlot1-2/+1
Change-Id: Icac565b9a3a80dc05a1a3470a35e223c8c564347 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-24Create a received job for BCM Socket to handle filtering.Romain Forlot1-0/+27
Filter is created using can_signals description and send with appropriate BCM header structure. This is the simplest way to do, no temporal filtering for now is available. Change-Id: Iee49f011ba9316880735d2765c1c23a8b2d3c4d2 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-24Rename and handling write on socket using stream instead of specific methodRomain Forlot1-12/+8
Created special struct to handle bcm messages with can_frame and canfd_frame. We can now just send both of them seamlessly. Change-Id: Ia84e9cf2ab1dd0716cb09f6bb342a208e54f8e06 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-22Use BCM socket as default cleaning up the old RAW socket code.Romain Forlot1-23/+4
Also use CAN FD frames by default. Change-Id: I5bad10e537653b1a96c2e3012d38dde8627d3caa Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-22Improve logging messagesRomain Forlot1-8/+8
Added for all log messages function name at beginning using __FUNCTION__ macro. Change-Id: Ia0f476ca81b9f79c6d49b425c0520894c59797ea Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-20Update commentsRomain Forlot1-2/+4
Change-Id: Ib21f810170308a16462ffe9c174448a86bf791d4 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-20Remove timeout socket option.Romain Forlot1-2/+0
This will be handle by BCM socket Change-Id: Ie0348135fcc596ab21727846f3b47751664c9e11 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-20Separate socket configuration and openingRomain Forlot1-6/+8
Change-Id: I94cad718b516f24c5d1833e09df89f03e529f48a Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-20Use same function to open BCM and RAW CAN socketsRomain Forlot1-4/+4
Using one a another socket type is made using a boolean. Change-Id: I0445c8550f289d1e0020f6496c638bc95e8db443 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-20Specializing socket class to CAN socket operations.Romain Forlot1-41/+16
Move all legacy opening RAW CAN socket operation to socket class. Each operations on a CAN socket has to be simple and made by the socket class. Simple BCM socket open operation is implemented. Future will be to open specialized BCM CAN sockets on demand. Change-Id: If285b97afb9871245ab1f13cd9f0401fbd9adf95 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-04-14Change directory architecture to use 2 separated projects.Romain Forlot1-0/+255
Each projects, binder and generator, has to be compiled separatly. CAN-binder will host high and low level binding CAN-config-generator only the generator used for low level binding. build.sh script just launch both build in their respective dir. Change-Id: Ic77932660fcca507b23a631d4e4e790f608880ae Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>