Changing porting for OPEN-SMART 2.0" TFT

OK. Sometimes I'm thinking I'm just not up to understanding bit-wise manipulations. I would like to free up digital ports 11 and 13 on a Mini-Pro to use the SPI ports, however, the display line for DB3 and DB5 have respectively used D11 and D13. I would like to re-assign them to ports D2 and D3 respectively. utft.h defines the standard OPENSMART_SHIELD_PINOUT using the LGDP4524 controller. In the utft hardware under HW_ATmega328P, I believe the ports are defined here, but I'm just not smart enough to figure it out. I understand the pin mapping of the 328, but the logic here is beyond my feeble understanding.

case 8:
// PORTD = VH;
// pulse_low(P_WR, B_WR);
// PORTD = VL;
// pulse_low(P_WR, B_WR);
#ifdef USE_OPENSMART_SHIELD_PINOUT
PORTD = (PORTD & B00101111) | ((VL) & B11010000);
PORTB = (PORTB & B11010000) | ((VL) & B00101111);
pulse_low(P_WR, B_WR);
#else
PORTB = VL & 0x3;
PORTD = VL & 0xFD;
pulse_low(P_WR, B_WR);
#endif
break;

Thanks in advance.

OK, maybe I have it. Changing D11(PB3) and D13(PB5) to D3(PD3) and D5(PD5), Port B goes from B00101111 to B00000111 and Port D goes from B11010000 to B11111000 with the & and | masks changing as well.

I'll try this a little later as I have to make some hardware wiring changes.

WORKS!