Content originally posted in LPCWare by IanB on Tue Mar 29 03:58:23 MST 2016
Short answer - You don't!
The 8-bit port problem! - are you driving a dot-matrix display, by any chance? I've never had a good explanation as to why the port pins are arranged completely randomly. Going right back to the 8049, 8051, ATmegas and most microchip parts, the ports run consecutively; but not these devices.
If you want 8 consecutive port pins, then look at the LPC12xx (but remember that the inputs are not 5V tolerant).
Next up is the 64-pin version of the LPC15xx. Note that the 48-pin version has PIO0_0 to PIO0_8 all nicely in a row, but someone had the bright idea to spoil it by sticking the ISP-reset pin right in the middle on PIO0_4.