I'm trying to play a stereo signal using these two phase shifted tones and I can't make it
import numpy as np
import sounddevice as sd
fs = 44100
duration = 1
frequency = 440
phase = 90 * 2 * np.pi / 360
sine_A = (np.sin(2 * np.pi * np.arange(fs * duration) * frequency / fs + phase)).astype(
np.float32)
sine_B = (np.sin(2 * np.pi * np.arange(fs * duration) * frequency / fs)).astype(np.float32)
sumSine= np.array([sine_A, sine_B])
sd.play(sumSine)
And it returns me the following error:
sounddevice.PortAudioError: Error opening OutputStream: Invalid number of channels
I can't track which is the problem