Solved !!! Figured out how to stand on my left foot, hold my right hand behind my back, then jump three times and it WORKS !!!
Final code:
void hmi_thread_entry(void)
{
// configurator is set up for touch screen using RIIC channel 0, suffix_A pins
// My hardware dictates that I use the suffix_B pin for SDA
// To do this I will make P401, input, NOT peripheral
// then I will make P407 peripheral output for RIIC = SDA0_B
// remove P401 as peripheral and make input
R_IOPORT4->PCNTR1 &= 0xFFFFFFFD; // force this pin to input when GPIO selected
g_ioport.p_api->pinCfg( IOPORT_PORT_04_PIN_01, (0x00000000 | IOPORT_CFG_PULLUP_ENABLE) ); // 0x00000012
// set P407 = mid level drive, open drain, sda0_B (RIIC group B pin)
R_IOPORT4->PCNTR1 |= 0x00800080; // make this an output
g_ioport.p_api->pinCfg( IOPORT_PORT_04_PIN_07, 0x00000000 ); // PMR = 0, make input
g_ioport.p_api->pinCfg( IOPORT_PORT_04_PIN_07, (0x00000000 | IOPORT_PERIPHERAL_RIIC | IOPORT_CFG_DRIVE_MID | IOPORT_CFG_NMOS_ENABLE | IOPORT_CFG_PULLUP_ENABLE | IOPORT_CFG_PORT_DIRECTION_OUTPUT | 0x00000001) );
g_ioport.p_api->pinCfg( IOPORT_PORT_04_PIN_07, (0x00000000 | IOPORT_CFG_PERIPHERAL_PIN | IOPORT_PERIPHERAL_RIIC | IOPORT_CFG_DRIVE_MID | IOPORT_CFG_NMOS_ENABLE | IOPORT_CFG_PULLUP_ENABLE | IOPORT_CFG_PORT_DIRECTION_OUTPUT | 0x00000001) );
while (1)
{
hmi_thread_main();
}
}
Hope this helps others ...
Steve D