Announcement

Collapse
No announcement yet.

music help (especially computer people)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • music help (especially computer people)

    I just got it in my head to make our robot for the Botball competition play music from SMB or Zelda. It has a function which will play a certain frequency for a certain period of time. Unfortunately, all the sheet music I've found for those games is rather complicated (for me, at least) and I'm not sure it's feasible to actually use it. Is there any simple way to do this?

  • #2
    Using sheet music, one can create MIDI tracks. You could then rig a way for the bot to play a MIDI recording. Not sure how that would work, though.
    Tutto nel mondo è burla

    Comment


    • #3
      You should it have it play the dungeon music from the Mario Brothers!
      Monkey!!!

      Comment


      • #4
        I'm going with the zelda's lullaby from zelda 64, since it's the easiest to do and I have the notes for it.

        I'm only doing the upper set of lines.

        Comment


        • #5
          Can you read music?
          Tutto nel mondo è burla

          Comment


          • #6
            Sort of.

            Comment


            • #7
              So what exactly are you asking of us? Without knowing how the machine works to make the sounds, it's kinda hard to know what you want...
              Tutto nel mondo è burla

              Comment


              • #8
                This will be of no help whatsoever Kuci, but I *used* to know how to do this! I can't for the life of me remember.

                In the 'olden days' of computers a lot of programming languages used to take commands alond the lines of "Sound (duration), (frequency), (pitch(?)), I used to know how to convert, lemme think...........

                Comment


                • #9
                  Originally posted by Boris Godunov
                  So what exactly are you asking of us? Without knowing how the machine works to make the sounds, it's kinda hard to know what you want...
                  Oh, I don't need help any more, actually. I figured something out.

                  Comment


                  • #10
                    IIRC if he's not being too fussy over the quality (and lets face it, it's a robot that plays Mario for Godsake!), he just wants to convert a musical note into a frequency?

                    It must be easy to do because I've done it when I was 12 or so!!

                    Comment


                    • #11
                      Well, tuning A is 440 Hz. At least, it was set as such in Bach's time, but has gradually creeped up to 445 Hz nowadays. Good for orchestras, not as good for singers...
                      Tutto nel mondo è burla

                      Comment


                      • #12
                        void play_music() {
                        while(1) {
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(na,2.*bl);
                        tone(ng/2.,bl/2.);
                        tone(na,bl/2.);
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(na,2.*bl);
                        sleep(bl);
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(2.*na,2.*bl);
                        tone(ng,bl);
                        tone(nd,2.*bl);
                        tone(nc,bl/2.);
                        tone(nb,bl/2.);
                        tone(na,2.*bl);
                        sleep(bl);
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(na,2.*bl);
                        tone(ng/2.,bl/2.);
                        tone(na,bl/2.);
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(na,2.*bl);
                        sleep(bl);
                        tone(nb,2.*bl);
                        tone(nd,bl);
                        tone(2.*na,2.*bl);
                        tone(ng,bl);
                        tone(2.*nd,6.*bl);
                        sleep(bl);
                        tone(2.*nd,2.*bl);
                        tone(2.*nc,bl/2.);
                        tone(2.*nb,bl/2.);
                        tone(2.*nc,bl/2.);
                        tone(2.*nb,bl/2.);
                        tone(ng,2.*bl);
                        tone(2.*nc,2.*bl);
                        tone(2.*nb,bl/2.);
                        tone(2.*na,bl/2.);
                        tone(2.*nb,bl/2.);
                        tone(2.*na,bl/2.);
                        tone(ne,2.*bl);
                        tone(2.*nd,2.*bl);
                        tone(2.*nc,bl/2.);
                        tone(2.*nb,bl/2.);
                        tone(2.*nc,bl/2.);
                        tone(2.*nb,bl/2.);
                        tone(ng,bl);
                        tone(2.*nc,bl);
                        tone(2.*ng,6.*bl);
                        sleep(4.);
                        }
                        }



                        EDIT: it killed my indents

                        Comment


                        • #13
                          Like I say, I did it when I was 12

                          Comment

                          Working...
                          X