# RTTTL tunes extension

**URL:** <https://forum.makecode.com/t/rtttl-tunes-extension/4193>\
**Category:** Arcade\
**Tags:** extension\
**Created:** [October 30, 2020, 11:52pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193 "2020-10-30T23:52:05Z")\
**Posts on this page:** 16\
**Page:** 2

<div class="post-metadata">

**Author:** ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)\
**Post date:** [May 12, 2021, 7:20pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/21 "2021-05-12T19:20:03Z")

</div>

Testing… [https://github.com/pelikhan/pxt-rtttl](https://github.com/pelikhan/pxt-rtttl)

---

<div class="post-metadata">

**Author:** ![Dylsaster](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dylsaster/32/4215_2.png) [@Dylsaster](https://forum.makecode.com/u/Dylsaster)\
**Post date:** [May 13, 2021, 1:17am UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/22 "2021-05-13T01:17:32Z")

</div>

Does anyone know how to turn a song into rtttl?

---

<div class="post-metadata">

**Author:** ![UnsignedArduino](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/unsignedarduino/32/592_2.png) [@UnsignedArduino](https://forum.makecode.com/u/UnsignedArduino)\
**Post date:** [May 13, 2021, 3:33pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/23 "2021-05-13T15:33:09Z")

</div>

There are various MIDI to RTTTL converters online…a quick Google search turns up [this](http://midi.mathewvp.com/midi2RTTL.php). Also many music scoring programs will export to MIDI as well…

---

<div class="post-metadata">

**Author:** ![Agent\_14](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/agent_14/32/17567_2.png) [@Agent\_14](https://forum.makecode.com/u/Agent_14)\
**Post date:** [May 13, 2021, 6:35pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/24 "2021-05-13T18:35:23Z")

</div>

My google search gives a bunch of unrelated junk 😒

---

<div class="post-metadata">

**Author:** ![ShyamRBarretBad](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/shyamrbarretbad/32/5277_2.png) [@ShyamRBarretBad](https://forum.makecode.com/u/ShyamRBarretBad)\
**Post date:** [November 10, 2021, 4:35pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/25 "2021-11-10T16:35:27Z")

</div>

Im confused on how I Increase the bpm… Please help…!!

---

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [November 10, 2021, 8:13pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/26 "2021-11-10T20:13:20Z")

</div>

Take a look at this quick snippet of Beethoven’s _Ode to Joy_:

 ![arcade-screenshot](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/d/d119e45f121972e67406206897dfd8ba121ba7a6.png)

There are two tempo indicators. You can ignore the tempo indicator (`b=140`) in the RTTTL. To change the tempo at which the music is played, change the value at the end of the `play melody` block. To play the RTTTL at its intended speed, just double the tempo indicated in the RTTTL. (That’s why I’m playing this one at 280 beats per minute.)

Here’s the RTTTL text, so that you can copy it and paste it without retyping it.

```auto
ode:d=4,o=5,b=140:b,b,b,c6,d6,d6,c6,b,a,g,g,a,b,b.,8a,2a

```

Just holler if you have any other questions.

---

<div class="post-metadata">

**Author:** ![ShyamRBarretBad](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/shyamrbarretbad/32/5277_2.png) [@ShyamRBarretBad](https://forum.makecode.com/u/ShyamRBarretBad)\
**Post date:** [November 10, 2021, 9:22pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/27 "2021-11-10T21:22:52Z")

</div>

Thank you!

---

<div class="post-metadata">

**Author:** ![ShyamRBarretBad](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/shyamrbarretbad/32/5277_2.png) [@ShyamRBarretBad](https://forum.makecode.com/u/ShyamRBarretBad)\
**Post date:** [November 11, 2021, 6:20pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/28 "2021-11-11T18:20:13Z")

</div>

I know this is off topic but I don’t know why I am getting an error in this project. I am making this for a school project btw.

> **[Day 5/6](https://arcade.makecode.com/04188-47290-52897-87766)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

---

<div class="post-metadata">

**Author:** ![MakeCode](https://avatars.discourse-cdn.com/v4/letter/m/f475e1/32.png) [@MakeCode](https://forum.makecode.com/u/MakeCode)\
**Post date:** [November 11, 2021, 7:19pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/29 "2021-11-11T19:19:38Z")

</div>

It looks like your overlap container calls Bad\_projectile (and other projectiles) by name, but they may not exist yet (depending on whether the left or up buttons have been pressed.)

To get rid of this issue, use the red ‘sprite’ and ‘otherSprite’ variables from inside the overlap container to refer to the two items that collide.

Hope that helps!

---

<div class="post-metadata">

**Author:** ![ShyamRBarretBad](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/shyamrbarretbad/32/5277_2.png) [@ShyamRBarretBad](https://forum.makecode.com/u/ShyamRBarretBad)\
**Post date:** [November 15, 2021, 4:40pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/30 "2021-11-15T16:40:51Z")

</div>

That worked, (thanks btw), but now when the projectile is shot from ‘PLayer\_1’, the ‘PLayer\_1’ is losing health. Same for the other sprite  
Updated code: [https://arcade.makecode.com/#editor](https://arcade.makecode.com/#editor)

---

<div class="post-metadata">

**Author:** ![zacharytam0411](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/zacharytam0411/32/6128_2.png) [@zacharytam0411](https://forum.makecode.com/u/zacharytam0411)\
**Post date:** [April 29, 2022, 6:52pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/31 "2022-04-29T18:52:29Z")

</div>

My song is like this: # Super Mario - Main Theme:d=4,o=5,b=125:a,8f.,16c,16d,16f,16p,f,16d,16c,16p,16f,16p,16f,16p,8c6,8a.,g,16c,a,8f.,16c,16d,16f,16p,f,16d,16c,16p,16f,16p,16a#,16a,16g,2f,16p,8a.,8f.,8c,8a.,f,16g#,16f,16c,16p,8g#.,2g,8a.,8f.,8c,8a.,f,16g#,16f,8c,2c6,16p,8a.,8f.,8c,8a.,f,16g#,16f,16c,16p,8g#.,2g,8a.,8f.,8c,8a.,f,16g#,16f,8c,2c6,a,8f.,16c,16d,16f,16p,f,16d,16c,16p,16f,16p,16f,16p,8c6,8a.,g,16c,a,8f.,16c,16d,16f,16p,f,16d,16c,16p,16f,16p,16a#,16a,16g,2f  
But the pauses wont work  
Can you help me?

---

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [April 29, 2022, 7:42pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/32 "2022-04-29T19:42:54Z")

</div>

Welcome, @zacharytam0411 !

Good catch! The RTTTL spec uses a `p` to indicate a rest. MakeCode uses an `r` instead.

For now, if you change your rest notes to use `r`, your RTTTL melody will work with this extension. I’ll also make a pull request to correct the bug and allow both notations to indicate a rest.

---

<div class="post-metadata">

**Author:** ![TZG](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/tzg/32/7392_2.png) [@TZG](https://forum.makecode.com/u/TZG)\
**Post date:** [May 2, 2022, 4:51pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/33 "2022-05-02T16:51:10Z")

</div>

So I’m trying to add songs, but I don’t know how, plz help.

---

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [May 3, 2022, 5:23pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/34 "2022-05-03T17:23:11Z")

</div>

Hi @TZG ! Do you mean in general, or RTTTL in specific?

If you’re asking about RTTTL specifically, then jump back a few posts. I show you how to add a snippet of _Ode to Joy_ in Blocks. It’s post #26 from November 2021. [RTTTL tunes extension - #26 by AlexK](https://forum.makecode.com/t/rtttl-tunes-extension/4193/26) You’ll need to add the extension first to you project; that’s in post #7 from November 2020. [RTTTL tunes extension - #7 by AlexK](https://forum.makecode.com/t/rtttl-tunes-extension/4193/7)

If you’re asking about melodies in general, then take a look at the melody editor. It’s a good place to start if you’re not familiar with music notation. Add a **play melody** block to your workspace, and then click on the melody block (the white block with notes) to open the melody editor. See screenshot below.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/d/d9190467e1d17aaa5a28f9ba8c46866033efd5eb.png)

If you have any questions, then feel free to ask. RTTTL questions can go here; you should ask questions about the melody editor in a new thread.

---

<div class="post-metadata">

**Author:** ![TZG](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/tzg/32/7392_2.png) [@TZG](https://forum.makecode.com/u/TZG)\
**Post date:** [May 4, 2022, 9:48pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/35 "2022-05-04T21:48:18Z")

</div>

Thanks. I hope it helps!

---

<div class="post-metadata">

**Author:** ![Astronomicality22](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/astronomicality22/32/18365_2.png) [@Astronomicality22](https://forum.makecode.com/u/Astronomicality22)\
**Post date:** [April 1, 2024, 8:36pm UTC](https://forum.makecode.com/t/rtttl-tunes-extension/4193/36 "2024-04-01T20:36:20Z")

</div>

How do i add things like music samples? I have… admittedly way too many samples. But I want to make something like one of the Past mixes of Sonic CD music with my samples in makecode, to enhance the Zune project with samples. Any suggestions?

[Previous page](https://forum.makecode.com/t/rtttl-tunes-extension/4193.md?page=1)
