I have been looking in to this problem myself today.
When you run the Wizard for configuring the controller, it saves the configuration to /opt/retropie/emulators/retroarch/configs/USBGamepad.cfg, but Retroarc actually is using /opt/retropie/emulators/retroarch/configs/USB_Gamepad.cfg.
Check the file USBGamepad.cfg and edit the file USB_Gamepad.cfg with the proper settings.