fix(driver_twai): fixed twaifd slow bitrate trans faile on correct bitrate

This commit is contained in:
wanckl
2026-06-24 14:15:51 +08:00
committed by Wan Lei
parent 9f694876bf
commit 15a1a86a0a
11 changed files with 23 additions and 11 deletions
@@ -61,6 +61,7 @@ static uint32_t twai_ll_get_brp_max(void);
#define TWAI_LL_BRP_DIV_THRESH 128
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX 16 //the max register value
#define TWAI_LL_TSEG2_MAX 8
#define TWAI_LL_SJW_MAX 4
@@ -38,6 +38,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 16384
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX 16 //the max register value
#define TWAI_LL_TSEG2_MAX 8
#define TWAI_LL_SJW_MAX 4
@@ -33,6 +33,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 32768
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX (TWAI_TIME_SEGMENT1 + 1)
#define TWAI_LL_TSEG2_MAX (TWAI_TIME_SEGMENT2 + 1)
#define TWAI_LL_SJW_MAX (TWAI_SYNC_JUMP_WIDTH + 1)
@@ -33,6 +33,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 32768
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX (TWAI_TIME_SEGMENT1 + 1)
#define TWAI_LL_TSEG2_MAX (TWAI_TIME_SEGMENT2 + 1)
#define TWAI_LL_SJW_MAX (TWAI_SYNC_JUMP_WIDTH + 1)
@@ -33,6 +33,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 32768
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX (TWAI_TIME_SEGMENT1 + 1)
#define TWAI_LL_TSEG2_MAX (TWAI_TIME_SEGMENT2 + 1)
#define TWAI_LL_SJW_MAX (TWAI_SYNC_JUMP_WIDTH + 1)
@@ -33,6 +33,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 32768
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX (TWAI_TIME_SEGMENT1 + 1)
#define TWAI_LL_TSEG2_MAX (TWAI_TIME_SEGMENT2 + 1)
#define TWAI_LL_SJW_MAX (TWAI_SYNC_JUMP_WIDTH + 1)
@@ -38,6 +38,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 32768
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX 16 //the max register value
#define TWAI_LL_TSEG2_MAX 8
#define TWAI_LL_SJW_MAX 4
@@ -38,6 +38,7 @@ extern "C" {
#define TWAI_LL_BRP_MAX 16384
#define TWAI_LL_TSEG1_MIN 1
#define TWAI_LL_TSEG2_MIN 1
#define TWAI_LL_PROP_MAX 0 //hardware don't support prop_seg
#define TWAI_LL_TSEG1_MAX 16 //the max register value
#define TWAI_LL_TSEG2_MAX 8
#define TWAI_LL_SJW_MAX 4