artist has asked for the wisdom of the Perl Monks concerning the following question:

Dear Monks,
I have written a small program which plays the midi-notes randomly and prints which notes it just played, on the screen. The notes are identified as perfect pitch by some good music folks in CB. I am using Win32::Midi. I have setup such a way that I have to recognize the tune it works fine because as I am trying to recognize it, I can check on the screen if my answer is right. It works fine currently.

Now I like to put it in a package. So after it plays the notes, it should say which 'notes' it played and put it in one file. I need to accomplish this. How do I do this?.

Finally I like to Burn CD out of this 'packages. ( (Sound + Speech) without too much manual process. So anyone can practice without computer. I would be able to pack 100s of such packages on single CD.

I appreciate any and every suggestions.

Thank You,
{Artist}

Replies are listed 'Best First'.
[OT] Re: Musical Notes
by liz (Monsignor) on Sep 19, 2003 at 21:38 UTC
    Wow, this takes me back. A good idea never dies. From an interview with Dr. Graper:

    What do you remember of the GUIDO lessons on PLATO at Delaware?   Did you ever actually sit down and do them as a student?   You wrote about GUIDO a couple times in your stories.

    They were excellent.  The software was truly masterful I thought (and still believe) because it was a perfect application of technology to a specific educational task.  I'm sure you know about it as much or more than I do: it took a truly dreadful, repetitive learning task (learning music intervals) and automated it.  I never had to take a class requiring it but began playing with it because of the videogame-aspect of it, later because I found I was able to use the skills it taught in actually hearing and writing down chords.  I know it sounds facetious but it was actually strange learning something at that University, and that was its appeal.

    We're talking 1977 here!

    Liz

Re: Musical Notes
by Anonymous Monk on Sep 19, 2003 at 21:46 UTC
Re: Musical Notes
by jeffa (Bishop) on Sep 20, 2003 at 14:52 UTC

    "So after it plays the notes, it should say which 'notes' it played and put it in one file..."

    One way to accomplish this could be with Cache::Cache. Here is a little example:

    use strict; use warnings; use Cache::FileCache; my $cache = new Cache::FileCache( ); my $word = $cache->get('word'); print "The word of the minute is ... "; unless (defined $word ) { print "there is no word for minute!\n"; print "Please enter the word the day: "; chomp($word = <STDIN>); $cache->set(word => $word,'1 minute'); } print "$word\n";

    jeffa

    L-LL-L--L-LL-L--L-LL-L--
    -R--R-RR-R--R-RR-R--R-RR
    B--B--B--B--B--B--B--B--
    H---H---H---H---H---H---
    (the triplet paradiddle with high-hat)
    
Re: Musical Notes
by Abigail-II (Bishop) on Sep 20, 2003 at 00:40 UTC
    So after it plays the notes, it should say which 'notes' it played and put it in one file. I need to accomplish this. How do I do this?.

    Are you asking how to open a file and write data to it? I suggest reading perldoc -f open, perldoc -f print, and perldoc perlopentut.

    Finally I like to Burn CD out of this 'packages. ( (Sound + Speech) without too much manual process. So anyone can practice without computer. I would be able to pack 100s of such packages on single CD.

    There's no standard solution for that. You'd end up calling an appropriate program on your computer. Which one that is will depend on your OS, and the installed CD burner.

    Abigail