@Palliser,
Thanks for the example. How do yo determine the mask?
uint32_t pin_13 = (1u << 27); // mask for pin 13