Fixes and tweaks to correct pins etc.