Invalid DMA stream associated to I2C1 RX/TX

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderator: RoccoMarco

Post Reply
pito
Posts: 199
Joined: Sun Nov 06, 2011 3:54 pm

Invalid DMA stream associated to I2C1 RX/TX

Post by pito »

Hi, moving to chibi3.0 with my source (stm32VL) and getting this error:

Code: Select all

Compiling hal.c
In file included from C:\ChibiStudio\Chibi30/os/hal/include/i2c.h:89:0,
                 from C:\ChibiStudio\Chibi30/os/hal/include/hal.h:53,
                 from C:\ChibiStudio\Chibi30/os/hal/src/hal.c:29:
C:\ChibiStudio\Chibi30/os/hal/ports/STM32/I2Cv1/i2c_lld.h:240:2: error: #error "invalid DMA stream associated to I2C1 RX"
C:\ChibiStudio\Chibi30/os/hal/ports/STM32/I2Cv1/i2c_lld.h:246:2: error: #error "invalid DMA stream associated to I2C1 TX"


What else I need to setup and where, plz?
pito
Posts: 199
Joined: Sun Nov 06, 2011 3:54 pm

Re: Invalid DMA stream associated to I2C1 RX/TX

Post by pito »

It seems we miss definitions of

Code: Select all

STM32_I2C1_RX_DMA_MSK
STM32_I2C1_TX_DMA_MSK

in stm32_registry.h ..
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Invalid DMA stream associated to I2C1 RX/TX

Post by Giovanni »

Hi,

Thanks fixed. The F1 platform is not yet tested in 3.0 even if drivers are largely the same, please report any problem you may find.

Giovanni
Legath
Posts: 21
Joined: Thu Oct 17, 2013 3:24 pm

Re: Invalid DMA stream associated to I2C1 RX/TX

Post by Legath »

Hi

i have found the same issue with spi on the same board
May be i need additional defines?
i have found
os/hal/platforms/STM32L1xx/hal_lld.h:248:#define STM32_SPI2_RX_DMA_MSK STM32_DMA_STREAM_ID_MSK(1, 4)


but STM32_SPI_SPI2_RX_DMA_STREAM not defined in all cases,
because STM32_ADVANCED_DMA disabled for l152 and this is not f3 and f0 family
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Invalid DMA stream associated to I2C1 RX/TX

Post by Giovanni »

hi,

STM32_ADVANCED_DMA is defined in a different file for F0 and F3 (stm32_registry.h). I don't understand your other point. In general make sure to use the correct mcuconf.h file, it changes from family to family.

Giovanni
Legath
Posts: 21
Joined: Thu Oct 17, 2013 3:24 pm

Re: Invalid DMA stream associated to I2C1 RX/TX

Post by Legath »

Hi Giovanni,

you are right again. Makefile project compile successfully.
i butterfingered :D . i 'll check eclipse and generic build environment.

Thanks for your efforts.
Post Reply