I'm having trouble with the PTB1 pin.. I cannot get it to output high.
Is there anything wrong with the following code? Is there anything "different" about PTB1? (I can't see anything from the manual)
#define PORTB_PCR1 (*(volatile uint32_t *)0x4004A004)
PORTB_PCR1 |= PORT_PCR_MUX(1);
#define GPIOB_PDDR (*(volatile uint32_t *)0x400FF054)
GPIOB_PDDR |= (1 << 1);
#define PORTB_PCR2 (*(volatile uint32_t *)0x4004A008)
// PORTB_PCR2 |= PORT_PCR_MUX(1);
//GPIOB_PDDR |= (1 << 2);
#define GPIOB_PSOR (*(volatile uint32_t *)0x400FF044)
// GPIOB_PSOR |= (1 << 2);
GPIOB_PSOR |= (1 << 1);
Included is some commented out code that sets PB2, which works. "works" = measure the pin with a multimeter and get ~3v. However I never get any output from PBT1.
I'm testing the MCU pin leg directly, so I assume it's not related to the rest of the PCB design.
This is driving me crazy, any help appreciated!