Implement task for sending CAN data via UART #21

Merged
eeeck merged 71 commits from dev_serial-send into main 2026-06-18 15:35:23 +02:00
Owner
No description provided.
eeeck added this to the v0.1.0 milestone 2026-06-17 08:44:35 +02:00
eeeck added the feature label 2026-06-17 08:44:35 +02:00
eeeck self-assigned this 2026-06-17 08:44:35 +02:00
eeeck added this to the Thesis SCRUM project 2026-06-17 08:44:35 +02:00
eeeck added 33 commits 2026-06-17 08:44:36 +02:00
- Less overhead, simpler to manage
- Semaphores are apparently overkill for a simple blink timer
- To find a way to handle overflows on the FIFO buffer
- Are now unnecessary with the move to task notification
Reviewed-on: erickahmed/j1939_logger#20
- This is efficient specifically for
  STM32F4x with Thumb-2 IT block
  optimization enabled (-02 or -03)
- It uses safe way to release semaphore
- Yields in case task interrupted was of lower priority: UART has
  minimal latency
- Avoids snprintf
- Can be read from minicom/screen, but it's also friendly for other MCU
- This single function was AI generated
- Not really used by CubeMX so worth removing
- Moving CAN event flag to vCANLoggerListen to avoid possible race
  condition and to make ISR leaner
- Check queue instantly
- Use DMA to move tx_buffer to UART peripheral
- Use a semaphore to DMA is being done, to avoid moving to next loop
  iteration and overwriting tx_buffer
- HAL_UART_TxCpltCallback will release semaphore when DMA done
- Would have caused destruction of the queue data itself
- No RTOS event, just queue put and get: cleaner way to send data and
  more clear separation of concerns
eeeck moved this to In Progress in Thesis SCRUM on 2026-06-17 08:44:44 +02:00
eeeck added a new dependency 2026-06-17 08:45:07 +02:00
eeeck force-pushed dev_serial-send from d69cb0231b to a6daf6c172 2026-06-17 18:07:14 +02:00 Compare
eeeck added 1 commit 2026-06-17 18:07:28 +02:00
eeeck force-pushed dev_serial-send from a6daf6c172 to 6ad1acc2ee 2026-06-17 18:07:28 +02:00 Compare
eeeck added 14 commits 2026-06-17 20:52:29 +02:00
eeeck added 1 commit 2026-06-17 21:45:22 +02:00
eeeck added 1 commit 2026-06-18 08:29:27 +02:00
eeeck force-pushed dev_serial-send from 604e9e603b to 4967cd9b32 2026-06-18 08:29:27 +02:00 Compare
eeeck added 1 commit 2026-06-18 08:44:33 +02:00
- This was blocking the CPU from vectoring to
  HAL_CAN_RxFifo0MsgPendingCallback
eeeck added 1 commit 2026-06-18 09:01:34 +02:00
- They were wrongly calculated on 168MHz but APB1 bus is at 42 MHz (168
  / 4)
eeeck added 3 commits 2026-06-18 09:10:08 +02:00
eeeck added 1 commit 2026-06-18 09:11:57 +02:00
eeeck added 4 commits 2026-06-18 13:08:18 +02:00
eeeck added 1 commit 2026-06-18 13:24:39 +02:00
eeeck force-pushed dev_serial-send from 86398ebcff to 9f1e7ba267 2026-06-18 13:24:39 +02:00 Compare
eeeck added 1 commit 2026-06-18 13:42:22 +02:00
eeeck added 5 commits 2026-06-18 13:43:43 +02:00
eeeck added 2 commits 2026-06-18 15:03:05 +02:00
eeeck added 1 commit 2026-06-18 15:05:56 +02:00
eeeck force-pushed dev_serial-send from a5067fd9a9 to 2880ae64dc 2026-06-18 15:05:56 +02:00 Compare
eeeck added 1 commit 2026-06-18 15:15:59 +02:00
eeeck marked the pull request as ready for review 2026-06-18 15:33:15 +02:00
eeeck merged commit 5b5edc2ead into main 2026-06-18 15:35:23 +02:00
eeeck deleted branch dev_serial-send 2026-06-18 15:35:23 +02:00
eeeck moved this to Done in Thesis SCRUM on 2026-06-18 15:36:14 +02:00
Sign in to join this conversation.