Normally, we will have an agreement, we signal "count" or "attitude" or for a few people perhaps "suit preference" on partner's opening lead. But if you always signal just one of these three things, then you are not defending optimally. Flexibility to change the meaning of a "signal" from time to time is necessary to defend well. When you fill out an ACBL convention card, there is a place where you mark your primary signal as either attitude, count, or suit preference. For this thread, we will assume everyone either plays their "primary signal" as attitude or count. i hope this thread will eventually grow into many examples where you can learn what conditions lead to a situation where "flexibility" to change the meaning of your signal will be clear to both partners.
I think most beginners/intermediates us "attitude" as the primary signal. It is essential to establish sound agreements with you partner on situations where the primary choice (attitude) is not appropriate so you will switch and send either count or suit preference (and in rare cases, even count in different suit can come into play). So the first question is when is attitude not appropriate? The simple answer is when you can't like a suit or when you already requested the lead of the suit (say by a lead directing double), or when some other signal becomes blindly clear (as in the side suit signal we will talk about much later).
I will start with two hands have already posted in these forums. Example 1 is from the advanced forum

You (west) start with the Diamond Ace and your partner plays the six. Is there any reason you can see for your partner to give you a signal other than your "primary signal" on this hand? I think not. If your primary signal is "count" then your partner card is giving you his count in diamonds. IF it your primary signal is attitude, then he is giving you attitude. (Of course, partner might have singleton, or Q6 doubleton where his first card is forced).
Some people play the lead of the KING request count, even when playing primary signal as attitude. I am not sure of the usefulness of this idea, but when partner can see the queen (either in dummy or his hand) your intent is clear.
The next hand is also from these forums. You (west) lead the heart JACK which when partner follows with a spot card you would be unsure if he is giving primary signal or something else. But when South can't win the trick and plays a low heart, things have changed -- but only if you are playing "attitude" as your primary signal.

As Frances Hinden said when this hand was first posted. "This is actually an interesting point at trick 1: when the jack of hearts holds the trick, we know partner wants to encourage (whether or not he has the AQ or just the Q) so partner's card at trick 1 should be count, not attitude. On this partner hand it doesn't help, because we can't tell the difference between 3 and 5, but it doesn't take much to change the hand slightly and we would be very interested in the heart count."
Of course, if you typically give count at trick one as your primary signal, your partner's play would still be count. In addition, partner might have AQ5 tripleton and will have to play the five regardless of your count signal to just to leave you on lead at trick two.
i hope others join me in posting hands similar to the ones above to help illustrate when the primary signal applies and when it doesn't, and also join in the discussion pointing out alternative views to signals in examples posted in this thread. To keep this thread loading quickly, i will use images like above rather than actual handviewer links. I may even edit post with handviewer diagrams others post in this thread, converting the hand to an image so this thread will load faster.