Midi out not working Pro12 Windows 11

My midi out has gone haywire. I have Cubase 12 pro on a decent W11 PC using UAD Apollo Twin and a NI KA-6 for midi in/out. It has behaved perfectly until recently. The midi out to external devices has become, at best, intermittent. The midi out light on the KA6 is permanently on (solid - not flashing on use). There is midi activity on the Cubase midi tracks but the midi data doesn’t make it to the KA6 as far as I can tell. It certainly doesn’t reach the external synths. The USB controller keyboards input data ok. The thing is, I tested it on my laptop and it works perfectly. I wondered about USB2 or USB3 compatibility but the laptop proved that’s not the issue. Annoyingly it appears to work sometimes. What can be stopping midi data leaving my PC and reaching the KA6? Anyone got any ideas?

Have you checked the leads , tried a different USB port/card , un-installed and reinstalled the driver , this sounds like a break down of hardware to be honest , but i would try these steps first

Yes that’s good advice. I kind of have but I’m going to simplify the setup and go through every link in the chain systematically this evening. I shall report back. Thanks.