Thank you very much, ntrf.zns. I could pass the compilation and linking by changing the Project setting as you wrote above.
My goal is to test the ADC on Primer2, but the complied object did not work. OK, I know it must not work as it is, since it is designed only for Primer 1. So I removed the most of lines from Application_Ini() and Application_Handler(), and instead of the original lines except for , I just added the lines taken from the tutorial like the following.
enum MENU_code Application_Ini ( void )
{
if(strcmp(UTIL_GetVersion(), NEEDEDVERSION) < 0)
{
return MsgVersion();
}
LCD_DrawRect ( myx, myy, SQUARE_WIDTH, SQUARE_WIDTH, RGB_BLUE);
LCD_FillRect ( myx+1, myy+1, SQUARE_WIDTH-2, SQUARE_WIDTH-2, RGB_YELLOW);
return MENU_CONTINUE_COMMAND;
}
The compilation was successfully done and I could start the debugging. But no rectangle could see on my Primer2. This is just a test to understand how Ride7 (and Primer2) works. After getting the small win, I wanted to add more codes related to ADC handling. But I failed.... ;-(
I could see the rectangle by making a new project (not based on ECG-Primer-1.1 project), but at that time, I can not add any ADC related codes. For example, I received the following error (and more) with Application_Ini() below...
C:\Program Files (x86)\Raisonance\Ride\Examples\MyApp7.c:53: error: 'ADC_InitTypeDef' undeclared (first use in this function)
enum MENU_code Application_Ini(void)
{
// Ensure that the current OS version is recent enough
if(strcmp(UTIL_GetVersion(), NEEDEDVERSION) < 0)
{
return MsgVersion();
}
// TODO: Write your application initialization function here.
UTIL_SetPLL(SPEED_VERY_HIGH);
ADC_InitTypeDef ADC_InitStructure;
/* PCLK2 is the APB2 clock */
/* ADCCLK = PCLK2/6 = 72/6 = 12MHz*/
RCC_ADCCLKConfig(RCC_PCLK2_Div6);
/* Enable ADC1 clock so that we can talk to it */
RCC_APB2PeriphClockCmd(RCC_APB2Periph_ADC1, ENABLE);
/* Put everything back to power-on defaults */
ADC_DeInit(ADC1);
return MENU_CONTINUE_COMMAND;
}
When I add a line to include stm32f10x_adc.h, then I faced the errors like below...
C:\Program Files (x86)\Raisonance\Ride\Examples\/circle_api.h:42: error: redefinition of typedef 's32
I am in a brick wall. Any advices are greatly appreciated.