The reason is clear, it is not getting the DMA interrupt that signals that the conversion is complete. The cause is unknown, I need to make a test but this will have to wait the weekend.
Giovanni
STM32F100 on STM32VL Discovery - Simple ADC voltage measure
Moderator: RoccoMarco
- Giovanni
- Site Admin
- Posts: 14892
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 996 times
Re: STM32F100 on STM32VL Discovery - Simple ADC voltage meas
Ok!
Thank you very much. I would be appreciated if you could help with that. It is really important project for me.
I'll try to do something by myself but I don't think I could do more
Thank you very much. I would be appreciated if you could help with that. It is really important project for me.
I'll try to do something by myself but I don't think I could do more
Re: STM32F100 on STM32VL Discovery - Simple ADC voltage meas
As an addition:
In that moment idle task is marked as current, clock task as sleeping and main as suspended.
In that moment idle task is marked as current, clock task as sleeping and main as suspended.
Re: STM32F100 on STM32VL Discovery - Simple ADC voltage meas
Again me 
Mistery solved! Together with my friend which is using ChibiOs with STM32 for almost three years in tons of projects (experience lvl - Asian. If you know what I mean
) we found a bug in config.
Previous one:
New one:
For F1 we should not set ADC_CR2_SWSTART. Now everything works.
Thanks for help once again!
Mistery solved! Together with my friend which is using ChibiOs with STM32 for almost three years in tons of projects (experience lvl - Asian. If you know what I mean
Previous one:
Code: Select all
static const ADCConversionGroup adcgrpcfg1 = {
FALSE,
ADC_GRP1_NUM_CHANNELS,
NULL,
NULL,
0, ADC_CR2_SWSTART, /* CR1, CR2 */
ADC_SMPR1_SMP_AN10(ADC_SAMPLE_1P5),
0, /* SMPR2 */
ADC_SQR1_NUM_CH(ADC_GRP1_NUM_CHANNELS),
0, /* SQR2 */
ADC_SQR3_SQ1_N(ADC_CHANNEL_IN5)
};New one:
Code: Select all
static adcsample_t samples[ADC_GRP1_NUM_CHANNELS * ADC_GRP1_BUF_DEPTH];
static const ADCConversionGroup adcgrpcfg1 = {
FALSE,
ADC_GRP1_NUM_CHANNELS,
NULL,
NULL,
0, 0, /* CR1, CR2 */
ADC_SMPR1_SMP_AN10(ADC_SAMPLE_1P5),
0, /* SMPR2 */
ADC_SQR1_NUM_CH(ADC_GRP1_NUM_CHANNELS),
0, /* SQR2 */
ADC_SQR3_SQ1_N(ADC_CHANNEL_IN5)
};For F1 we should not set ADC_CR2_SWSTART. Now everything works.
Thanks for help once again!