Setting pin mode on pin assignment