I've an interrupt clocked at 100kHz - so need it to be as efficient (e.g. minimum clocks) as possible.
So I changing the calls to libraries, to direct writes to the memory mapped registers. This basically just removes the checking in the library that the parameters are correct.
One thing confuses me. In GPIOPinWrite we have:
HWREG(ui32Port + (GPIO_O_DATA + (ui8Pins << 2))) = ui8Val;
but in hw_types.h HWREG is defined as:
#define HWREG(x) \ (*((volatile uint32_t *)(x)))
So doesn't this say that its a pointer to a uint32_t; so why is GPIOPinWrite putting a uint8_t into memory address? So should HWREGB be used - or am I misunderstanding the code?