Headphones work but laptop speakers do not

Previous discussions about this motherboard advise that speaker output for onboard audio codec ALC1220 is not restored correctly when system is booted

A Manjaro user with same motherboard found a workaround to reset the speaker control in ALSA

amixer --card=0 sset Headphone 100% unmute

No Sound (Temporary Fix) alsamixer MSI Ge75 Raider


Another workaround for this motherboard was confirmed to work in Linux Mint forum
[Laptop] No sound from built in speakers - Linux Mint Forums
linux mint cinnamon 20 no sound until plugging headphone - Linux Mint Forums

Edit PulseAudio configuration for speaker output

sudo nano +102,10 /usr/share/pulseaudio/alsa-mixer/paths/analog-output-speaker.conf

Change this section:

[Element Headphone]
switch = off
volume = off

To this:

[Element Headphone]
switch = off
volume = merge