Open tarbear123 opened 3 years ago
`int play_bt(string device) { string sox_params=""; string output="sudo /usr/local/bin/"+s.implementation+" "+s.opSwitch+"ps 'BLUETOOTH' "+s.opSwitch+"rt 'A2DP BLUETOOTH' "+s.opSwitch+"freq "+s.freq+" "+s.opSwitch+"audio -"; set_output(output); /*< change output device if specified / set_effects(sox_params);
ps.songName = "Bluetooth"; update_now_playing(); string cmdline="arecord -D bluealsa:HCI=hci0,DEV="+device+" -f cd -c 2 | sox -t raw -v "+s.btGain+" -G -b 16 -e signed -c 2 -r 44100 - -t wav - "+sox_params+" | "+output; cout<<"CMDLINE: "<<cmdline<<endl; //string cmdline="arecord -D bluealsa -f cd -c 2 | sox -t raw -v "+s.btGain+" -G -b 16 -e signed -c 2 -r 44100 - -t wav - "+sox_params+" | "+output; //legacy mode system(cmdline.c_str()); return 0;`
hello?
`int play_bt(string device) { string sox_params=""; string output="sudo /usr/local/bin/"+s.implementation+" "+s.opSwitch+"ps 'BLUETOOTH' "+s.opSwitch+"rt 'A2DP BLUETOOTH' "+s.opSwitch+"freq "+s.freq+" "+s.opSwitch+"audio -"; set_output(output); /*< change output device if specified / set_effects(sox_params);