ADC_IN0 on F030K6 not reading 3V3 voltage_divider
I'm pluging into ADC_IN0 1x pull-up and 5x buttons, that when i pressed some button, it adds a resistor to ground and make a voltage_divider... then i read the value on ADC.
But when i pressed the button, however, my ADC shows 0 on the variable and not the Vout from voltage_divider, like 1V or 0,5V.
I'm using CubeIDE with default ADC_IN0 config and making the while(1) as follow:
hadc.Instance->CHSELR |= ADC_CHSELR_CHANNEL(ADC_CHANNEL_0);
HAL_ADC_Start(&hadc);
HAL_ADC_PollForConversion(&hadc,10);
value_adc=HAL_ADC_GetValue(&hadc);