/var/www/restricted/ssh/stm32/www/stm32circle/ STM CircleOS forum / Compiling problems with DMA_Channel1

Username:     
Password:     
             

Forum

# 1   2009-01-25 09:37:04 Compiling problems with DMA_Channel1

FR4
Member
Registered: 2008-11-09
Posts: 26

Compiling problems with DMA_Channel1

I want to get used to converting analog signals on primer2.  I read some of the examples how to use DMA and ADC.

In ride7  i created a new circle-project and inserted following lines:

Code:

 /* DMA channel1 configuration ----------------------------------------------*/
  DMA_DeInit(DMA_Channel1); 
  DMA_InitStructure.DMA_PeripheralBaseAddr = ADC1_DR_Address;
  DMA_InitStructure.DMA_MemoryBaseAddr = (u32)&ADC_ConvertedValue;
  DMA_InitStructure.DMA_DIR = DMA_DIR_PeripheralSRC;
  DMA_InitStructure.DMA_BufferSize = 1;
  DMA_InitStructure.DMA_PeripheralInc = DMA_PeripheralInc_Disable;
  DMA_InitStructure.DMA_MemoryInc = DMA_MemoryInc_Disable;
  DMA_InitStructure.DMA_PeripheralDataSize = DMA_PeripheralDataSize_HalfWord;
  DMA_InitStructure.DMA_MemoryDataSize = DMA_MemoryDataSize_HalfWord;
  DMA_InitStructure.DMA_Mode = DMA_Mode_Circular;
  DMA_InitStructure.DMA_Priority = DMA_Priority_Low;
  DMA_InitStructure.DMA_M2M = DMA_M2M_Disable;
  DMA_Init(DMA_Channel1, &DMA_InitStructure);

Each attempt to compile this code end in errormessage:

$1

which imho means a header file is missing. But i canĀ“t find out which one. I tried to include several headers out
of the library but error just remains.
The ride ide is up to date. I also followed several tips to update *.elf and *.ld files in lib/arm/circleos directory.
Nothing helped.

Has anybody undertaken same problem and can give some clues?

Thanks

Offline

 

# 2   2009-01-25 09:53:59 Compiling problems with DMA_Channel1

sjoerd
Member
From: Stad aan het Haringvliet
Registered: 2008-09-04
Posts: 65

Re: Compiling problems with DMA_Channel1

try DMA1_Channel1 or DMA2_Channel1 if you're using DMA2

Last edited by sjoerd (2009-01-25 10:03:09)

Offline

 

# 3   2009-01-25 11:17:03 Compiling problems with DMA_Channel1

FR4
Member
Registered: 2008-11-09
Posts: 26

Re: Compiling problems with DMA_Channel1

Hi sjoerd,

sjoerd :

try DMA1_Channel1 or DMA2_Channel1 if you're using DMA2

At least that made it. Thanks

But at the past hours of testing i have the     sneaking suspicion that Ride behaves mysterious if your projectfiles are located on a partition other than the ride application.

Offline

 

# 4   2009-01-25 12:17:25 Compiling problems with DMA_Channel1

samarkh
Member
From: Gloucester UK
Registered: 2009-01-07
Posts: 84

Re: Compiling problems with DMA_Channel1

It might be a load of rubbish, but I noticed that the circle_api.h isn't automatically updated, and the latest version is 60k, the previous one 44k.

Yours Simon M.

Offline

 

Board footer