SPI+GIROSCOPIO
SPI+GIROSCOPIO
#include "stm32f4xx.h"
#define N 1000
#define SPI1RSTR 0x1000
#define CS_LO (uint16_t) 0x8
short int data=0;
short int cont=8;
short int x,y,z;
int main(void){
RCC->AHB1ENR |= 1; //ABILITO PORTA A PERCHè SPC,MISO E MOSI DI SPI1 SONO COLLEGATI A PA5,PA6,PA7...