Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow DMA remapping on Robus L0 #477

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions network/robus_network/HAL/STM32L0/robus_hal.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ void RobusHAL_ComInit(uint32_t Baudrate)
ROBUS_DMA_CLOCK_ENABLE();

LL_DMA_SetPeriphRequest(ROBUS_DMA, ROBUS_DMA_CHANNEL, ROBUS_DMA_REQUEST);
LL_SYSCFG_SetRemapDMA_USART(ROBUS_DMA_REMAP);
LL_DMA_SetDataTransferDirection(ROBUS_DMA, ROBUS_DMA_CHANNEL, LL_DMA_DIRECTION_MEMORY_TO_PERIPH);
LL_DMA_SetChannelPriorityLevel(ROBUS_DMA, ROBUS_DMA_CHANNEL, LL_DMA_PRIORITY_LOW);
LL_DMA_SetMode(ROBUS_DMA, ROBUS_DMA_CHANNEL, LL_DMA_MODE_NORMAL);
Expand Down
3 changes: 3 additions & 0 deletions network/robus_network/HAL/STM32L0/robus_hal_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,9 @@
#ifndef ROBUS_DMA_REQUEST
#define ROBUS_DMA_REQUEST LL_DMA_REQUEST_3
#endif
#ifndef ROBUS_DMA_REMAP
#define ROBUS_DMA_REMAP LL_SYSCFG_USART1TX_RMP_DMA1CH2
#endif

/*******************************************************************************
* COM TIMEOUT CONFIG
Expand Down
Loading