PlayTones on New Devices

It looks like my old playtone function isn't working well. I've read up on the issue with new devices with Speakers vs Tone Generators.

For example, my new EDGE 1050 does render this one (Attention.TONE_CANARY) reasonably well, but most of the other "pre defined tone generator" sounds are just quick little beeps (like Attention.SCALE).

I think I need to detect somehow if a device has a Tone Generator (and use the small set of pre-defined Attention sounds), or if it has a Speaker and CIQ 3.1, I need to create a sound from scratch using a series of frequencies and durations. I'll ignore the case of an attached headphone for now.

Creating custom sounds seems like a pain - figuring out the combination of frequencies and durations to create an alert sound that works well with the use case.

Any guidance on device detection logic to determine if we need to use the Tone Generator sounds -vs- a custom freq/duration Profile? And an efficient way to develop a library of Tone Profiles for Speaker based devices? I think I read here that the simulator doesn't do a good job of emulating Tone Profiles?

  • or if it has a Speaker and CIQ 3.1, I need to create a sound from scratch using a series of frequencies and durations.
    And an efficient way to develop a library of Tone Profiles for Speaker based devices?

    As pointed out in this thread that you literally just posted in, ToneProfile only works on devices with a beeper / hardware tone generator, and not on devices with a real speaker.

    The reason is that devices with a real speaker don't have a tone generator (either in software or hardware), so they can only play back predefined tones (which are just prerecorded audio files in this case), and not custom ToneProfile tones.

    Of course, the same limitation that applies to real speakers also applies to headphones. Even if a device has a beeper / tone generator, when headphones are connected:

    - predefined tones are played through headphones as prerecorded audio files (they sound completely different than the corresponding tones you'd hear from the beeper)

    - custom ToneProfiles are not played through headphones at all

  • To be clear, all of the above means that you don't have a solution for "creating a sound from scratch" for devices with a real speaker.

    - ToneProfile does not work

    - you cannot play a prerecorded sound file (like a .WAV or .MP3)

  • That thread really wasn't clear. Your reply here is helpful. Thank you. If I understand you.... Tone Profiles are where you manually set a sequence of frequencies and durations (or you can use pre-defined ones like Attention.SONG). And those only work on devices with a Tone Generator. If I understand that correctly, that makes sense.

    But then I understand you to say that for more modern Garmin devices with a Speaker and no Tone Generator, we need to use predefined Tones - prerecorded audio files. I have not seen a description of how to generate these and reference them. Other than in that prior thread it was mentioned that there isn't support for MP3, WAV, etc. If anyone has a reference to how to record an audio file that we can use to play an "alert" on a modern Speaker based Garmin device, that would be great to read up on.

    Ok - just saw your follow up. Maybe there isn't a solution... which is why I found the prior long thread confusing because it is hard to believe this isn't possible. Ugh. Strangely, on my Speaker based 1050, Attention.TONE_CANARY does work.

    Thanks!

  • I always use predefined tones.  Even those may sound differently beweep garmin devices, where i first noticed this with watches and edge devices and wrote a simple app that would play all the standard ones with a sideload.

    You can not add your own tone files  You need to use the standard ones like TONE_CANARY.  Those work with new devices, as you see.

  • If I understand you.... Tone Profiles are where you manually set a sequence of frequencies and durations (or you can use pre-defined ones like Attention.SONG). And those only work on devices with a Tone Generator. If I understand that correctly, that makes sense.

    Yes for tone profiles. Tone profiles only work on device with a beeper / tone generator

    For predefined tones (e.g. TONE_KEY, TONE_ALARM, and TONE_CANARY):

    - when the beeper is used, you'll get the tone-generated beeps that we're all used to

    - when the speaker or headphones is used, you'll get Garmin's prerecorded audio

    But then I understand you to say that for more modern Garmin devices with a Speaker and no Tone Generator, we need to use predefined Tones - prerecorded audio files. I have not seen a description of how to generate these and reference them.

    No. My point was that you cannot use your own prerecorded audio files, you can only use the predefined tones that Garmin supplies, which happen to be implemented as prerecorded audio, for speaker or headphones.

    Sorry, I shouldn't have used the word "file" in the first place, it probably made things more confusing than they should be.

    Strangely, on my Speaker based 1050, Attention.TONE_CANARY does work.

    That's not strange, as Garmin surely provides built-in support for all the TONE_* predefined tones by supplying prerecorded audio for each one.

    Based on what you said in the OP, it sounds like some of the prerecorded audio doesn't meet your expectations.

    Going back to the issue of ToneProfile not working on devices with a speaker, Brandon.ConnectIQ also said this:

    https://forums.garmin.com/developer/connect-iq/f/discussion/405695/the-toneprofile-does-not-work-on-venu3s/1909456#1909456

    We've also recently been talking with product teams about whether these speaker-based products have hardware that's capable of playing arbitrary tones so we can look at supporting ToneProfile.

    Honestly, I'm kind of curious as to why this can't be done in software, so the same solution would also work for connected headphones. I'm gonna guess it's too much work for a feature that only applies to CIQ.

  • Brandon.ConnectIQ also opened the door for the possibility of CIQ apps playing custom audio files in the future:

    SInce the newer products do not have a tone generator, but a speaker, do they have a possibility to play some custom sound even limited? WAW/PCM, OGG/Vorbis, MP3/MP3, M4A/AAC?

    This has been discussed, but it hasn't yet been prioritized.

    But the key is that this can't be done today.

  • Garmin should've think about this at least when they introduced the 1st device with speaker and "split" the playTone method to two, so we would be able to check with has whether custom tones work or not