Tkinter - Sounds

This is an example where we have added a sound to play when a button is pressed. ping.wav is in the same location as the .py file.
import tkinter as tk
import winsound

mywindow = tk.Tk()

def buttonPress():
    winsound.PlaySound('ping.wav', winsound.SND_FILENAME)
    print("Button Pressed!!")

# Button
button = tk.Button(mywindow,text='Press',command=buttonPress)
button.grid(row=1,column=1)

# Title Bar Icon
mywindow.iconbitmap('birdy_icon.ico')
mywindow.mainloop()
This creates the window: