iMelody has been in use by some manufacturers such as Ericsson, Motorola, Siemens and Alcatel since 2001, a number of phones can now receive iMelody via the Enhanced Messaging Service.
This format was developed by the Infrared Communications association in order to have a standard ringtone format across different models and makes of mobile phone, it has some interesting features thatcan make the phone flash and vibrate, also the volume of the ringtone can be controled while it is playing.
iMelody was developed by the irDa association (infrared communications) as a standard file format for melodies. It has also been adopted as the ringtone format by the 4 companies developing the Enhanced Message Service (EMS), a smart messaging standard.
The file contains a sequence of notes in monophonic ringtone format that can also be transfered between phones, the structure is as follows;
Level 1. The file is broken down into a number of different fields, each describing the general properties of the ringtone. These include the name of the file, the composer, the tempo (bpm), the tune and some more. The fields are separated by
carriage returns and line feeds.
Level 2. Within the melody the notes and rests of the ring tone are noted.
Full Syntax
<imelody-object>::=
"BEGIN:IMELODY"<cr><line-feed>
"VERSION:"<version><cr><line-feed>
"FORMAT:"<format><cr><line-feed>
["NAME:"<characters-not-line-feed><cr><line-feed>]
["COMPOSER:"<characters-not-line-feed><cr><line-feed>]
["BEAT:"<beat><cr><line-feed>]
["STYLE:"<style><cr><line-feed>]
["VOLUME:"<volume><cr><line-feed>]
"MELODY:"<melody><cr><line-feed>]
"END:IMELODY"<cr><line-feed>
<version>::="1.2"
<format>::="CLASS1.0" | "CLASS2.0"
<beat>::="25" | "26" | ... | "899" | "900"
<style>::="S0" | "S1" | "S2"
<volume-modifier>::="V+" | "V-"
<volume>::="V0" | "V1" | ... | "V15" | <volume-modifier>
<basic-note>::="c" | "d" | "e" | "f" | "g" | "a" | "b"
<ess-note>::="&c" | "&d" | "&e" | "&f" | "&g" | "&a" | "&b"
<iss-note>::="#c" | "#d" | "#e" | "#f" | "#g" | "#a" | "#b"
<basic-ess-iss-note>::=<basic-note> | <ess-note> | <iss-note>
<octave-prefix>::="*0" | "*1" | ... | "*8"
<duration>::="0" | "1" | ... | "5"
<duration-specifier>::="." | ":" | ";"
<rest>::="r"
<led>::="ledoff" | "ledon"
<vibe>::="vibeon" | "vibeoff"
<backlight>::="backon" | "backoff"
<note>::=[<octave-prefix>]<basic-ess-iss-note><duration>[<duration-specifier>]
<silence>::=<rest><duration>[<duration-specifier>]
<repeat>::="("{<silence> | <note> | <led> | <vibe> | <volume> | <backlight>}+"@"<repeat-count>[<volume-modifier>]")"
<repeat-count>::="0" | "1" | "2" | ... (note that "0" means repeat forever,
though in this implementation it is limited to 10)
<melody>::={<silence> | <note> | <led> | <vibe> | <volume> | <backlight>}+