VF PROJET A ENVOYER

This commit is contained in:
leo 2025-12-04 12:51:11 +01:00
parent 38722b033e
commit 1dba92b392

View file

@ -15,8 +15,6 @@ void MyADC_Init(ADC_TypeDef *ADC, char channel){
}
void start_conversion(ADC_TypeDef *ADC){
//ADC->CR2 |= ADC_CR2_EXTSEL;
//ADC->CR2 |= ADC_CR2_EXTTRIG; // Permettre le démarage externe
ADC->CR2 |= ADC_CR2_SWSTART; // demander une conversion externe
//Si on veut faire par scrutation et non par intéruption, laisser les lignes suivantes
//while(!(ADC->SR & ADC_SR_EOC)); // attendre la fin (EOC = 1)
@ -35,10 +33,3 @@ void ADC1_2_IRQHandler(void){
ADC1->CR1 &=~ ADC_SR_EOC;
ptr_function();
}
//void Set_samp_ts(ADC_TypeDef *ADC, int Rain){
// float ts;
// float cylcle;
// ts = 9.010913347*(Rain +1000.00)*0.000000000008;
// cycle = ts*12/0.000001;
// ADC->SMPR1 |=