Adeeb Shihadeh
80dac4cd94
cleanup CAN definitions ( #1170 )
2022-11-29 15:56:43 -08:00
Igor Biletskyy
bd8d2481dd
H7: free up 29120 bytes of RAM ( #1120 )
...
free up some RAM
2022-10-25 21:15:46 -07:00
Greg Hogan
2f3e2825e5
CAN-FD non-ISO support ( #1082 )
...
CAN FD non-ISO support
2022-10-12 15:28:20 -07:00
Igor Biletskyy
a19f12559e
check if set CAN speed is valid ( #1073 )
...
* check
* MISRA
2022-09-16 23:51:55 -07:00
Igor Biletskyy
fd226de0a4
board struct: add has_canfd ( #1072 )
...
* add
* gate this
* and this
* forgot white
2022-09-16 21:56:48 -07:00
Igor Biletskyy
f029c99440
health packet: fix confusing variable names ( #1068 )
...
* fix naming
* different buffer overflows
* naming
2022-09-15 13:08:46 -07:00
Igor Biletskyy
0eef8cf333
CAN: health message for each CAN module ( #1067 )
...
* initial can health pkt
* MISRA: variable scope
* MISRA 10.4
* typo
* add total_fwd_cnt
* check size of can_health_t
* improve
* comment
* that's better
* move
* add health check to tests
* why?
* ...
* revert later
* meh
* Revert "meh"
This reverts commit 0eb84321942a494454c17c242e7309deb8a92341.
* Revert "revert later"
This reverts commit 2d98957a8fd5350d50ebb1d26c9912f984d72043.
* adjust test
2022-09-15 13:04:10 -07:00
Igor Biletskyy
860e5a4d21
Red Panda: auto switching to CAN FD with BRS ( #868 )
...
* add canfd autoenable
* add check to tests
* fix default speeds
* add autoswitch test
2022-03-07 14:25:19 -08:00
Shane Smiskol
2d96ef02df
GM ignition: remove signal with noise and false positives ( #845 )
2022-02-03 12:30:07 -08:00
Adeeb Shihadeh
00138a7f66
Add blocked message counter to health packet ( #841 )
...
* Add blocked message counter to health packet
* move that
* update python
* fix struct
Co-authored-by: Comma Device <device@comma.ai >
2022-01-27 17:46:24 -08:00
Jafar Al-Gharaibeh
9ac35a4a7b
Mazda: more generic ignition signal ( #809 )
...
Signed-off-by: Jafar Al-Gharaibeh <to.jafar@gmail.com >
2021-12-24 14:53:27 -08:00
Igor Biletskyy
8d0d148681
Move shared definitions into separate file ( #808 )
...
* refactor definitions includes
* fix include
* revert dlc_to_len
* ...
* change name
2021-12-16 14:38:22 -08:00
Igor Biletskyy
ca67da626f
Fix MISRA violations 10.1 and 10.4 ( #796 )
...
* misra 10.1
* misra 10.4
* misra 10.4 in usb_protocol.h
* don't cast
2021-12-01 14:13:38 -08:00
Igor Biletskyy
c8b48ec23a
Enable CAN FD support ( #772 )
...
* enable CAN FD
* ...
2021-11-15 16:27:16 -08:00
Igor Biletskyy
ae26b75d7b
CAN_FIFOMailBox to CANPacket struct + USB dynamic packet size ( #739 )
...
* Squashed commits, no cleanup
* Few fixes
* No init = garbage
* Only receive with new canpacket
* Add send with canpacket
* Revert "Add send with canpacket"
This reverts commit 7d06686ddd6d447c714b5289d31af24403d36931.
* Packet must be aligned to word, or bad performance
* Cleaner
* Fix tests
* Tests...
* MISRA 10.4
* More MISRA
* libpandasafety_py
* cffi
* even more tests...
* typo
* ...
* ...
* ...
* Slight cleanup
* MISRA 6.1
* MISRA 17.7
* Bug in bxcan + even style
* MISRA 10.1
* Revert "MISRA 10.1"
This reverts commit 404ae7fcc39556f80f528de9015702e69f4ea0a5.
* ...
* MISRA 10.1 and 10.4 suppress until next PR
* MISRA 20.1
* ...
* test_honda
* ...
* ...
* test_toyota
* test_volkswagen_mqb
* test_volkswagen_pq
* Sketchy thing...
* Revert "Sketchy thing..."
This reverts commit 3b2e5715bdc1954f7b7b3b7469ba3d0eaa06bdf9.
* remove comment
* bxcan extended address bug
* Concept, experimental dynamic usb packet size
* increase each buffer to 10240 bytes
* raise python bulk read/write limits
* ...
* Move packet size to start
* Experimental send, stream-like
* New receive test, stream-like
* cleanup
* cleanup + rebase fixes
* MISRA
* Extra receive method, stream-like, commented out
* type change
* Revert back to buffer for send, stream commented
* forgot ZLP
* lower buffer, add rx failsafe
* ... remove ZLP
* return ZLP back
* Add tx checks to panda fw
* TX stream with counter
* fix counter overflow
* 13 free slots should be enough
* limit tx usb packet
* ...
* Revert max_bulk_msg doubling
* python lib improve speed
* Stream with counter for RX, dirty, needs cleanup
* Increase chunk length to 4096 bytes
* cleanup fdcan.h
* cleanup __init__.py
* MISRA 12.1
* MISRA 10.8
* remove non-streaming usb functions
* more main.c cleanup
* MISRA 15.6
* MISRA 15.5
* MISRA 18.4 and suppress objectIndex
* handling usb pakcets > 63bytes, naming and cleanup
* Cleanup old from tests and update CANPacket_t struct
* Switch to 4 bit DLC instead of 6 bit length
* ops)
* ...
* pylint
* receive python buffer increase
* USB increase receive packet len
* tweak buffers
* No need for so high limits
* MISRA 20.1 workaround
* performance tweaks
* cleanup, dlc to data_len_code naming
* main.c naming
* comments and cleanup for main.c usb
* clean py lib
* pylint
* do not discard good rx messages on stream fail
* cleanups
* naming
* remove bitstruct lib and lower tx limit
* bitstruct lefovers
* fix bug in VW test
* remove adjusting data size and assert on wrong len
* ...
* test new memcpy before merging
* Revert "test new memcpy before merging"
This reverts commit 399465a264835061adabdd785718c4b6fc18c267.
* macros for to/fromuint8_t array
* MISRA hates me!
* tests.c include macros instead
* move CANPacket to can_definitions.h
* vw_pq python test fix
* new memcpy test, REMOVE
* check without alignment
* revert macros for uint8 arrays
* Revert "revert macros for uint8 arrays"
This reverts commit 581a9db735a42d0d68200bd270d87a8fd34e43fe.
* check assert
* Revert "check assert"
This reverts commit 9e970d029a50597a1718b2bb0260196c050fd77f.
* one more variation
* Revert "one more variation"
This reverts commit f6c0528b7ac7e125750dc0d9445c7ce97f6954b5.
* what about read performance
* Revert "what about read performance"
This reverts commit d2610f90958a816fe7f1822157a84f85e97d9249.
* check struct alignment to word
* check for aligned memcpy again
* cleanup
* add CANPacket structure diagram
* update CANPacket and add USB packet struct
* bugfix + refactoring of EP1
* move dlc_to_len to header
* missed include
* typo...
* MISRA
* fk
* lower MAX_CAN_MSGS_PER_BULK_TRANSFER
* bump CAN_PACKET_VERSION to 2
* bump python lib CAN_PACKET_VERSION to 2
* rename parse_can_buffer to unpack_can_buffer
* CANPacket_t const fields
* Revert "CANPacket_t const fields"
This reverts commit cf91c035b7706a14e317550c5f0501ae3fce7c70.
* test.c relative path
* cleanup
* move macros to safety_declarations
* Refactor pack/unpack funcs and add unittest
* usb_protocol.h
* oops
* Update .github/workflows/test.yaml
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com >
* remove print from unittest
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com >
2021-11-12 16:36:34 -08:00
Igor Biletskyy
76c7191b19
refactor bus settings into bus_config struct ( #773 )
...
* refactor bus settings into bus_config struct
2021-11-11 13:26:53 -08:00
Adeeb Shihadeh
2e5de6e99c
Mazda: CAN ignition ( #758 )
2021-10-30 15:32:27 -07:00
Adeeb Shihadeh
1b0295a3ef
remove USB command for bus forwarding ( #749 )
2021-10-28 23:40:11 -07:00
Greg Hogan
80260c6bcc
expose TX messages blocked by safety hook ( #742 )
...
* expose tx messages blocked by safety hook
* update unit tests
* preserve bus of original message
* update tests
2021-10-18 12:26:24 -07:00
Igor Biletskyy
87f81b96a5
Move CAN buffers rx_q and txgmlan_q to RAM D1 on STM32H7 ( #734 )
...
* Add RAM D1 to linker script
* Check idea with bigger buffers
* Move rx_q and txgmlan to RAM D1 on H7
2021-10-07 11:07:19 -07:00
Greg Hogan
7e99d5245f
expose DEBUG flag and improve debug console output ( #728 )
...
* expose debug flags and improve debug console output
* puth4
* other flags need to be set more locally
* fix misra violations
* fix misra violation
* fix misra violation
2021-09-25 21:46:19 -07:00
Willem Melching
fb8f452d68
Try resuming outep3 on can buffer clear ( #716 )
...
* try resuming outep3 on can buffer clear
* simplify
* more cleanup
Co-authored-by: Greg Hogan <gregjhogan@gmail.com >
2021-09-08 10:59:00 -07:00
Igor Biletskyy
ad90646001
Support for STM32H7 and Red Panda ( #694 )
...
* H7 drivers
* Include H7 into the code
* fix flash write for H7
* get serial from flasher.h from F4 and H7
* flash.sh and recover.sh for gen3
* add set_data_speed for BRS CAN FD
* build all fws
* gen3 to panda lib
* gen3 name in scons project
* disable fd can and brs
* gen3 to CI tests
* jenkins fix for new tests and build_all
* fix pedal test
* pedal in panda tests again...
* cleanup llfdcan.h
* cleanup clock.h
* Add LDORDY bit check instead of delay
* missing define in stm32h735xx.h lib
* board_id helper
* enable debug detection again
* clean gpio inits
* fix board_id helper, make cleaner
* comment MCUs in stm lib for faster misra
* target MCU
* misra-5.5
* improve headers and misra speed
* cleanup CI tests
* change naming from gen3 to h7
* readable if statement
* cleanup llusb.h
* only cycle one transceifer in bus-off
* move unused funcs to common header
* bus_off_err reset
* misra 10.4 fdcan
* extern to can_data_speed variable
* limit can_data_speed array size to 3
* reinit fd can on data speed change
* Improve test with ELM327 and extaddr check
* bugfix for fdcan
* panda python config naming
* abstracted init request in llfdcan
* misra fdcan
* Improve llusb.h for H7
2021-08-02 20:26:15 -07:00
Igor
863993dab9
refactor CAN ( #695 )
2021-07-16 12:22:28 -07:00