I Can't found reference for read all substract of array in MDK V5, where is the code generate from CubeMX it's activate adc1, adc2, adc3, adc5, adc6,& adc7. can any one help me ?
uint8_t ADC_buffer[6]; HAL_Init(); SystemClock_Config(); MX_GPIO_Init(); MX_DMA_Init(); MX_ADC1_Init(); MX_USART1_UART_Init(); HAL_ADC_Start_DMA(&hadc1, (uint32_t *)ADC_buffer, 6); while (1) { A1=ADC_buffer[0]; A2=ADC_buffer[1]; A3=ADC_buffer[2]; A5=ADC_buffer[3]; A6=ADC_buffer[4]; A7=ADC_buffer[5]; }
Thank you Mr. Westonsupermare Pier. Oh ya i see, sorry mr.Westonsupermare Pier, I think general function with CubeMX so I don't describe the chip. i using STM32F103C8T6, any 6 pin ADC is configured where is pin 4 is not used ( only 1,2,3,5,6,7 pins configured). My problem is, i get same value for for each pin (any different but little only 1 in last digit), i see in youtube tutorial work perfectly but not for me