void setup() {
GPIOA->MODER = (GPIOA->MODER & ~0xFFFF) | 0x5555;
GPIOB->MODER &= ~0xFFFF;
GPIOB->PUPDR = 0xAAAA;
}
void loop() {
GPIOA->ODR = GPIOB->IDR & 0xFF;
}
void setup() {
GPIOA->MODER = (GPIOA->MODER & ~0xFFFF) | 0x5555;
GPIOB->MODER &= ~0xFFFF;
GPIOB->PUPDR = 0xAAAA;
}
void loop() {
GPIOA->ODR = GPIOB->IDR & 0xFF;
}