MIDI Set Tempo meta message

The MIDI set tempo meta message sets the tempo of a MIDI sequence in terms of microseconds per quarter note.

This message belongs to the category of MIDI meta messages. Since this is a meta message, it may exist in MIDI files, but it is never sent over MIDI ports to a MIDI device.

This message consists of six bytes of data. The first byte is the status byte and has a hexadecimal value of 0xFF, which means that this is a meta message. The second byte is the meta message type 0x51 and signifies that this is a set tempo message. The third byte has the value 0x03, which means that there are three bytes remaining. The remaining three bytes carry the number of microseconds per quarter note.

The following is an example of a MIDI set tempo meta message.

0xFF 0x51 0x03 0x07 0xA1 0x20

The status byte 0xFF shows that this is a meta message. The second byte is the meta type 0x51 and signifies that this is a set tempo meta message. The third byte is 3, which means that there are three remaining bytes. These three bytes form the hexadecimal value 0x07A120 (500000 decimal), which means that there are 500,000 microseconds per quarter note.

Since there are 60,000,000 microseconds per minute, the message above translates to: set the tempo to 60,000,000 / 500,000 = 120 quarter notes per minute (120 beats per minute).

This message would normally appear in the first track chunk. If this message does not appear, the default tempo is 120 beats per minute as in the example above. This message is important if the MIDI time division is specified in "pulses per quarter note", as such MIDI time division defines the number of ticks per quarter note, but does not itself define the length of the quarter note. The length of the quarter note is then defined with the set tempo meta message described here.

See also:
Musical Instrument Digital Interface (MIDI)

Comments

admin: First posted on 2013 05 15

Roberto, 2013 05 15: You just saved my life! Great post!!

Nice ! But the real formula is BPM = (60/(500,000e-6))*b/4, with b the lower numeral of the time signature. You assumed b=4

Dear thanks for very good article!

My question is: How to send Tempo meta message to DAW?

Is there a way for a vst plugin or external software to send this message to one of the popular DAW software?

Thanks in advance!

Best regard
Marko

To my knowledge, no. This is a meta message and, if the DAW acts like a MIDI device, then it is not sent to a MIDI device but simply exists in a MIDI file. This makes sense. The other way to say it is: You can only change the tempo of a MIDI sequence that was already recorded.

If some MIDI sequence is already recorded though, most DAWs should be able to handle it. Orinj does that by defining an actual Set Tempo message. MuseScore probably does the same, but the user input is the MuseScore tempo defined as quarter note (or other note) per minute. In Cubase, you can specify tempo in advanced audio settings, which I assume will set up MIDI tempo accordingly, but I can't be sure.

Add new comment

Filtered HTML

  • Freelinking helps you easily create HTML links. Links take the form of [[indicator:target|Title]]. By default (no indicator): Click to view a local node.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters shown in the image.