Never use ATQ! Use SAK only for non 14443-4 cards(e.g. Mifare Classic)! ATS is also bad practice as different card vendor can set it differently.
Now how to do it:
Only way how to think about card and don't get crazy is imagine it like it is full communication stack(see OSI model).
Keep in mind that your goal is to connect two applications, one in the card and one in your computer. 14443-4 provides mechanism for sending messages and don't care about its content.
On top of it there are implemented interfaces of different cards and if both sides: card - carddriver are compatible they will communicate. If not, there will be errors on that level. So you know you will need to use different card driver.
Complete communication stack will look like this:
Your Application
| CardProtocol/7816-4
| | 14443-4
| | | 14443
| | | | radio waves
| | | 14443 (in card)
| | 14443-4 (in card)
| CardProtocol/7816-4 (in card)
Application/Appdata (in card)
Of course between every layer has to be some interface.
If you have two applications which wants to communicate try one and then try
second.
error on application level => there is no compatible application on card
error on CardProtocol level => there is not compatible card
Point is your communication has to succed on all levels so don't worry to try to communicate with card by not compatible protocol - if you (by some miracle) will not get error on CardProtocol level you will definitely get one on your application level and result will be same.
Good Luck!
P.S. There are some more complex situations like "one app over two protocols/types of cards" but they can be handled easily too.