grpC_RAMARA_CROS/PjtKEIL_Step_Integration/Src/principal.c

64 lines
1.3 KiB
C

#include "DriverJeuLaser.h"
#include "Affichage_Valise.h"
extern short int LeSignal[];
extern int DFT_ModuleAuCarre( short int * Signal64ech, char k);
int moduleSignal[64] ;
int score[4];
short int dma_buf[64] ;
void callback() {
Start_DMA1(64);
Wait_On_End_Of_DMA1();
Stop_DMA1;
for (int j=0; j<64 ; j++) {
moduleSignal[j] = DFT_ModuleAuCarre(&(dma_buf[0]), j);
}
}
int main(void)
{
// ===========================================================================
// ============= INIT PERIPH (faites qu'une seule fois) =====================
// ===========================================================================
// Après exécution : le coeur CPU est clocké à 72MHz ainsi que tous les timers
CLOCK_Configure();
//Systick_Period_ff(5000*72);
//Systick_Prio_IT(11, callback) ;
//SysTick_On ;
//SysTick_Enable_IT ;
//Init_TimingADC_ActiveADC_ff( ADC1, 72 ) ;
//Single_Channel_ADC( ADC1, 2 );
//Init_Conversion_On_Trig_Timer_ff( ADC1, TIM2_CC2, 225 );
//Init_ADC1_DMA1( 0, dma_buf );
//La malette
Init_Affichage();
Prepare_Afficheur(1, 11);
Prepare_Afficheur(2, 22);
Prepare_Afficheur(3, 33);
Prepare_Afficheur(4, 44);
Mise_A_Jour_Afficheurs_LED();
//============================================================================
while (1)
{
}
}