The 'self' in def irqHandler(self, sm): was a hangover from the full program where it was a class.
Needed sm.active(0) in the handler to stop the PIO running
Needed wrap_target() at the end of the program to keep it in a loop until stopped. Otherwise it just reran and piled up the interrupts.
Learn something every day!!!!