UPDATE - working perfectly (when using same pins as sketch).
Changed signal out D3 to D9, changed switch from D5 to D7 and now works perfectly. Stooge, thanks, you put me on the right track.
I’m a novice with Arduino, D3 is also an interrupt pin, pin5 is also a PWM, either the square was...