It may have been used for every call, the wording suggests it's used for a
'listen' up kind of command....  but especially with the Unit Prelude call
use I don't think they played ATTENTION everytime they were going to play
another bugle call.

We use it in re-enacting for
a: Attention, Battalion
b: Time to get your kit on: 15 minute warning to 'The Assembly' on Company
c: Plant the Color on the Road, sound The Attention, and reform Column for
Road March
d: At the Route Step on a march, Sound the Attention go back to cadence
step, realign the ranks and reestablish correct distances and alignment.
(Captains go to the Front of their Company!). Shoulder Arms, get ready for
the next command (usually HALT, by the bugle).

RJ Samp

   Am working out a daily camp and battle schedule of calls, signals, etc. I
 may have missed this somewhere, but how often and in what contexts was
 Attention used?   I'm not real clear from Rabbai's book. It almost seems it
 could be used prior to every sounding.


     In the Navy and Marine Corps the call "Attention" is always sounded
immediately prior to sounding "To the Color" in the morning flag raising, and
prior to the call "Retreat" in the evening flag lowering.   This causes
anyone on base or aboard ship (when in port) to halt, come to attention, and
face the colors.  Upon the sounding of To the Color or Retreat, military
personnel, if covered (that is wearing a hat) render a hand salute.  
Following a short silence after "To the Color" and after "Retreat", the call
"Carry on" is sounded.  At this point, the salute is terminated, and
personnel are free to continue on with what they were doing.
     In the Navy and Marine Corps, any calls to attention of men in formation
is done strictly upon voice command, sometimes initiated with the sounding at
the start of a ceremony with "Adjutant's Call"