If the PI0 GPIO pin controlling the buzzer (PIGPIO_OUT_SOUND) is high without playing drive head sequence, the buzzer is emitting annoying noise coming from the 5V supply voltage. In case of PIGPIO_OUT_SOUND low the buzzer is quiet. Please make sure to set the pin always low after a head noise sequence is finished. Tested modification of main.cpp:
if (options.SoundOnGPIO() && headSoundCounter > 0)
{
headSoundFreqCounter--; // Continue updating a GPIO non DMA sound.
if (headSoundFreqCounter <= 0)
{
headSoundFreqCounter = headSoundFreq;
headSoundCounter -= headSoundFreq * 8;
if (headSoundCounter <=0 and IEC_Bus::OutputSound == false) {headSoundCounter += headSoundFreq * 8;}
IEC_Bus::OutputSound = !IEC_Bus::OutputSound;
}
}
In addition the settings in options.txt aren't behaving like described. SoundOnGPIOFreq value results only in half the frequency. SoundOnGPIODuration is definitely not micro seconds, but I couldn't reverse engineer the effect.
If the PI0 GPIO pin controlling the buzzer (PIGPIO_OUT_SOUND) is high without playing drive head sequence, the buzzer is emitting annoying noise coming from the 5V supply voltage. In case of PIGPIO_OUT_SOUND low the buzzer is quiet. Please make sure to set the pin always low after a head noise sequence is finished. Tested modification of main.cpp:
In addition the settings in options.txt aren't behaving like described. SoundOnGPIOFreq value results only in half the frequency. SoundOnGPIODuration is definitely not micro seconds, but I couldn't reverse engineer the effect.