Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <clib.h>
- #include "..\biblio\carte.h"
- #define CS0 2
- #define CS1 3
- void main (void)
- {
- int iCapture;
- float iv;
- BIOS_Set_Focus(FOCUS_APPLICATION);
- bus_init();
- fast_adc_init();
- hal_instal_ISR();
- while (BIOS_kbhit()==0)
- {
- iCapture=fast_adc_read(0);
- iv=((float)iCapture*5.0)/4096.0;
- printf("en volt: %f V \n",iv);
- printf ("Valeur: %d\n", iCapture);
- RTX_Sleep_Time(1000);
- }
- BIOS_Set_Focus(FOCUS_SHELL);
- }
Add Comment
Please, Sign In to add comment