SOMO-14D file addressing

Hello all!

I want to use the SOMO-14D sound module to add speech to a telemetry system. The msg's are number like "12.43" or "4255" and words like "battery, altitude", etc. I have been thinking on how to link these numbers and words to file numbers from 0 to 512 but didn't find a good solution.

Can you please give me some ideas how to do it.

thanks,
Manuel

I want to use the SOMO-14D sound module

A link, please.

The msg's are number like "12.43" or "4255" and words like "battery, altitude", etc. I have been thinking on how to link these numbers and words to file numbers from 0 to 512 but didn't find a good solution.

Do you want 12.43 to sound like "twelve point forty three" or "one two point four three"? Big difference in how you program the module to get the two different outputs.

Pauls,

Thanks for your interest.

The SOMO-14D can be find here: http://www.4dsystems.com.au/prod.php?id=73

I would like to sound "twelve point forty three"

Thanks,
Manuel

If you have 512 files available, I'd use the first 100 for the sounds for the numbers 0 to 99. Then, use the remaining numbers for things like "point", "thousand", "hundred", "battery", etc.

You can always separate the number into integer and fractional parts. 12.43 becomes 12 and 43. Play the sound for the integer part, the sound for point, and the sound for the fractional part.

For numbers greater than 100, separate the thousands digit (num / 1000), the hundreds digit (num /100 - 10 * thousands digit), and the remaining vale (num % 100). Then, play the sound for the thousands digit, the sound for thousand, etc.

PaulS, thanks again,

Can you please clarify the following:

the hundreds digit (num /100 - 10 * thousands digit),

I understand the "num/100" to get the hundreds digit but not understand " -10 * thousands digit".

thanks,
Manuel

Suppose the number is 4289. The thousands digit, 4, can be obtained by dividing by 1000. Dividing by 100 gives the result of 42. Since the thousands digit is 4, multiplying by 10 gives 40. 42 - 40 is 2, which is the hundreds digit.

You could do (val / 100) % 10 to get the same result, if that's easier to follow.

PaulS,

Thanks for the clarification. I already understood.

Manuel