I added a function to PFOMO.com to Play ABC notation and files. I foy are not familial with ABC notation I'd start here...
Wikipedia: https://en.wikipedia.org/wiki/ABC_notation
Official ABC source: https://abcnotatin.com
I had to tweak some of the input code to:
- Commands can span lines
- Recall history with lines spanning multiple lines
- You can paste in to the command prompt. Mobile has a button you can use to paste into the command prompt. It's goofy and I hope to fix it.
I added fetchContents() to go through a public proxy(s) to get to some of the file contents through URLs.
As public proxies are subject to usage limits, I searched for a few and added them in a failover flow. THIS IS VERY LIMITIMG. Be patient and look at my workaround in PROXY FAILURE below.
PlayABC works in two modes
You can pass it a string of ABC Notation
You can pass it a URL to an .ABC file
String of ABC notation
You can pass a string of ABC notation and do something as simeple as play middle C
playabc C
You can pass as much of a string as you want with modification to your needed ABC Header as you want. I tested with the following:
playabc A B c d
playabc A B c/2 c/2 d
playabc L:1/8 A2 B2 c c d2
playabc M:3/4 A B c/2 c/2 d
playabc K:G A2 B2 c c d2
playabc X:2 A2 B2 c c d2
Play around and see if there is more needed.
The only Headers I currently support at the prompt are K:, L:, M:, and X:
URL
Find a song and try it out.
playabc https://trillian.mit.edu/~jc/music/book/EverydaySongBook/075_Round_Row_Row_Row_Your_Boat.abc
I found that by testing the source URL to make sure of the returned file contents were the actual .ABC contents helped.
This collection was at https://trillian.mit.edu/~jc/music/book/EverydaySongBook/
PROXY FAILURE
I did find issues with using the public proxies after a bit, but I was able to get to the file in another browser tab and open the file to pull the needed values like this....
playabc K:D L:1/8 M:2/4 X:75 [| "^1"D2 D2 | D> E F2 | "^2"F> E F> G | A4 | (3"^3"d d d (3A A A | (3F F F (3D D D | "^4"A> G F> E | D4 |]
A Collection of Collections
https://abcnotation.com/tunes