#include "stm32f4xx.h"

#define RCC_AHB1ENR 	(*(volatile uint32_t *) (0x40023830))

#define GPIOA_MODER 	(*(volatile uint32_t *) (0x40020000))
#define GPIOA_OTYPER 	(*(volatile uint32_t *) (0x40020004))	
#define GPIOA_OSPEEDR 	(*(volatile uint32_t *) (0x40020008))	
#define GPIOA_PUPDR 	(*(volatile uint32_t *) (0x4002000C))	
#define GPIOA_IDR 		(*(volatile uint32_t *) (0x40020010))	
#define GPIOA_ODR 		(*(volatile uint32_t *) (0x40020014))	
#define GPIOA_BSRR 		(*(volatile uint32_t *) (0x40020018))		

int main(){

	RCC_AHB1ENR|=0x5U;
	
	//Salida LED
	GPIOA_MODER&=~(3<<2*5);
	GPIOA_MODER|=1<<2*5;
	GPIOA_OTYPER&=~(1<<5);
	GPIOA_OSPEEDR&=~(3<<2*5);
	GPIOA_OSPEEDR|=1<<2*5;
	GPIOA_PUPDR&=~(3<<2*5);
		
	while(1){
			GPIOA_ODR|=1<<5;
			GPIOA_ODR&=~(1<<5);
	}
}
