mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-02-02 19:09:13 +01:00
Add play-jingle-bells.ps1
This commit is contained in:
parent
d2a829c494
commit
4bac359793
@ -157,6 +157,7 @@ play-beep.ps1, plays a beep sound
|
|||||||
play-files.ps1, plays the given audio files
|
play-files.ps1, plays the given audio files
|
||||||
play-happy-birthday.ps1, plays the Happy Birthday song
|
play-happy-birthday.ps1, plays the Happy Birthday song
|
||||||
play-imperial-march.ps1, plays the Imperial March (Star Wars)
|
play-imperial-march.ps1, plays the Imperial March (Star Wars)
|
||||||
|
play-jingle-bells.ps1, plays Jingle Bells
|
||||||
play-mission-impossible.ps1, plays the Mission Impossible theme
|
play-mission-impossible.ps1, plays the Mission Impossible theme
|
||||||
play-m3u.ps1, plays the given playlist (M3U file format)
|
play-m3u.ps1, plays the given playlist (M3U file format)
|
||||||
play-mp3.ps1, plays the given sound file (MP3 file format)
|
play-mp3.ps1, plays the given sound file (MP3 file format)
|
||||||
|
Can't render this file because it has a wrong number of fields in line 82.
|
@ -14,6 +14,7 @@ Mega Collection of PowerShell Scripts
|
|||||||
* [play-files.ps1](Scripts/play-files.ps1) - plays the given audio files
|
* [play-files.ps1](Scripts/play-files.ps1) - plays the given audio files
|
||||||
* [play-happy-birthday.ps1](Scripts/play-happy-birthday.ps1) - plays the Happy Birthday song
|
* [play-happy-birthday.ps1](Scripts/play-happy-birthday.ps1) - plays the Happy Birthday song
|
||||||
* [play-imperial-march.ps1](Scripts/play-imperial-march.ps1) - plays the Imperial March (Star Wars)
|
* [play-imperial-march.ps1](Scripts/play-imperial-march.ps1) - plays the Imperial March (Star Wars)
|
||||||
|
* [play-jingle-bells.ps1](Scripts/play-jingle-bells.ps1) - plays Jingle Bells
|
||||||
* [play-mission-impossible.ps1](Scripts/play-mission-impossible.ps1) - plays the Mission Impossible theme
|
* [play-mission-impossible.ps1](Scripts/play-mission-impossible.ps1) - plays the Mission Impossible theme
|
||||||
* [play-m3u.ps1](Scripts/play-m3u.ps1) - plays the given playlist (M3U file format)
|
* [play-m3u.ps1](Scripts/play-m3u.ps1) - plays the given playlist (M3U file format)
|
||||||
* [play-mp3.ps1](Scripts/play-mp3.ps1) - plays the given sound file (MP3 file format)
|
* [play-mp3.ps1](Scripts/play-mp3.ps1) - plays the given sound file (MP3 file format)
|
||||||
|
161
Scripts/play-jingle-bells.ps1
Normal file
161
Scripts/play-jingle-bells.ps1
Normal file
@ -0,0 +1,161 @@
|
|||||||
|
<#
|
||||||
|
.SYNOPSIS
|
||||||
|
play-jingle-bells.ps1
|
||||||
|
.DESCRIPTION
|
||||||
|
Plays Jingle Bells
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\play-jingle-bells.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz
|
||||||
|
License: CC0
|
||||||
|
#>
|
||||||
|
|
||||||
|
$Notes = New-Object -TypeName psobject -Property @{
|
||||||
|
REST = 0
|
||||||
|
GbelowC = 196
|
||||||
|
A = 220
|
||||||
|
Asharp = 233
|
||||||
|
B = 247
|
||||||
|
C = 262
|
||||||
|
Csharp = 277
|
||||||
|
D = 294
|
||||||
|
Dsharp = 311
|
||||||
|
E = 330
|
||||||
|
F = 349
|
||||||
|
Fsharp = 370
|
||||||
|
G = 392
|
||||||
|
Gsharp = 415
|
||||||
|
AA = 440
|
||||||
|
AAsharp = 466
|
||||||
|
BB = 493
|
||||||
|
CC = 523
|
||||||
|
CCsharp = 554
|
||||||
|
DD = 587
|
||||||
|
DDsharp = 622
|
||||||
|
EE = 659
|
||||||
|
FF = 698
|
||||||
|
FFsharp = 740
|
||||||
|
GG = 784
|
||||||
|
GGsharp = 830
|
||||||
|
}
|
||||||
|
$Duration = New-Object -TypeName psobject -Property @{
|
||||||
|
WHOLE = 1600
|
||||||
|
HALF = 800
|
||||||
|
QUARTER = 400
|
||||||
|
EIGHTH = 200
|
||||||
|
SIXTEENTH = 100
|
||||||
|
}
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.HALF )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.D, $Duration.HALF )
|
||||||
|
Start-Sleep -m $Duration.EIGHTH
|
||||||
|
[System.Console]::Beep($Notes.D, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.E, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.E, $Duration.HALF)
|
||||||
|
Start-Sleep -m $Duration.EIGHTH
|
||||||
|
[System.Console]::Beep($Notes.E, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.HALF )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.C, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.D, $Duration.HALF )
|
||||||
|
Start-Sleep -m $Duration.QUARTER
|
||||||
|
[System.Console]::Beep($Notes.D, $Duration.EIGHTH )
|
||||||
|
[System.Console]::Beep($Notes.E, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.DD, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
Start-Sleep -m $Duration.EIGHTH
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.HALF)
|
||||||
|
Start-Sleep -m $Duration.EIGHTH
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.AA, $Duration.EIGHTH)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.CC, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.BB, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.G, $Duration.QUARTER)
|
||||||
|
[System.Console]::Beep($Notes.F, $Duration.HALF)
|
||||||
|
exit 0
|
Loading…
Reference in New Issue
Block a user