Skip to content

polybuildr/sangeet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sangeet

Plays notes from a file.

Install

To install, just:

$ npm install -g sangeet

However, sox is also required for sangeet to work.

You can build this from source, or use a prebuilt package if it is available.

$ sudo apt-get install sox # Ubuntu-like
$ sudo yum install sox # Fedora-like

Usage

Usage: sangeet [options] <file>

Options:

  -h, --help                    output usage information
  -V, --version                 output the version number
  -i --instrument <instrument>  instrument to use (piano or flute)
  -d --duration <duration>      duration of a full length note (in seconds)
  -o --outfile <outfile>        save output to outfile, don't play it directly

Data file

The data file should look like this:

40
41
42 2
43 0.5
44 0.5
45

This will mean:

  • play note 40 for one note duration
  • play note 41 for one note duration
  • play note 42 for two note durations
  • play note 43 for half note duration
  • play note 44 for half note duration
  • play note 45 for one note duration

The note numbers correspond to piano key frequencies, where key 40 is the middle C. Wikipedia: Piano key frequencies

About

Plays notes from a file.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published