How do I play a series of tones in a sequence?

John Zukowski

The MMAPI offers a ToneControl that allows you to specify a series of notes. You can specify characteristics like tempo, volume, and duration for each tone to play back.

After getting player with Player player = Manager.createPlayer(Manager.TONE_DEVICE_LOCATOR);, realize the player and get the ToneControl with ToneControl control = (ToneControl)player.getControl("ToneControl");. Assuming the sequence is in a byte array seq, you would then call control.setSequence(seq) before starting the player.

0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact