PINE64
Is there a sound card input on the Pinephone which can be used by Python software? - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: PinePhone (https://forum.pine64.org/forumdisplay.php?fid=120)
+--- Forum: PinePhone Software (https://forum.pine64.org/forumdisplay.php?fid=121)
+--- Thread: Is there a sound card input on the Pinephone which can be used by Python software? (/showthread.php?tid=10385)



Is there a sound card input on the Pinephone which can be used by Python software? - Peter Gamma - 06-22-2020

Bitalino has low cost ECG devices with Open Signals or Matlab software. Both OpenSignals software and Matlab does not run on the Pinephone.

Alternatively, Scott Hardens, PhD. Sound Card ECG device could be used. Scott s Sound card ECG is an excellent research grade device, he spend more than years in developing it.

I asked Scott:
Is it possible to integrate your free and open source custom software which is written in C#, which graphs the signal in real time and displays heart rate over time into Python?

Scott s answer:

Check the link in the description to my one opamp ECG circuit video. That project makes a similar graph using Python software and you may find that useful

And here my question to the Pinephone community. Is there a sound card input on the Pinephone which can be used by Python software?

Scott Hardens Sound Card ECG:

https://www.youtube.com/watch?v=sP_-f5nsOEo


RE: Is there a sound card input on the Pinephone which can be used by Python software? - wibble - 06-22-2020

https://www.tutorialspoint.com/matlab/matlab_gnu_octave.htm - octave will probably run.

The only external sound input is the headset mic so probably not suitable. In theory you could use a USB sound device, but as with the ANT+ USB dongle there may be issues due to the USB hardware bug.


RE: Is there a sound card input on the Pinephone which can be used by Python software? - Peter Gamma - 06-22-2020

Bitalino biomedical toolkit pairs over Bluetooth and has a Matlab Toolbox. You mean the Bitalino Matlab Toolbox would eventuallly run in Octave? Great idea, and needs to tested.

Also Scott s device is a great low-cost hiqh quality device, and the idea of a usb sound card is also great. Sound cards have normally a 16 bit resulution, but there are sound cards with e.g. 32 bit, which is great for instance to use it for respiratory sensors.

Also the problem with the usb issue needs to be tested.


RE: Is there a sound card input on the Pinephone which can be used by Python software? - wibble - 06-23-2020

There's a chance it'll run in octave at least.

There are sound devices that return 32 bit data, but I'm not aware of any with anywhere near actual 32 bit resolution. If you go for something as portable as a phone you'll be lucky to get much beyond 16 bit actual resolution. What sort of respiratory sensor are you using that requires that sort of resolution anyway?


RE: Is there a sound card input on the Pinephone which can be used by Python software? - Peter Gamma - 06-23-2020

Sorry I meant (Mic-in): of the Sound BlasterX G6 is 32-bit maximal value for ADC :

https://us.creative.com/p/amplifiers/sound-blasterx-g6#specs

I ve got Adinstruments respiratory sensors:

https://www.youtube.com/watch?v=vtT_tKEEWOE&t=42s

Dr. Evan Matthews has ADCs of 16 bit, but 32 bit would be better.I v got also an Adinstruments 16 sp channel recorder, but without Labchart software. So I never got the setup working. For breath meditation I m looking for a device with high value of ADC. Also Bitalino has excellent respiratory sensors.


RE: Is there a sound card input on the Pinephone which can be used by Python software? - wibble - 06-24-2020

(06-23-2020, 08:39 PM)Peter Gamma Wrote: Sorry I meant (Mic-in): of the Sound BlasterX G6 is 32-bit maximal value for ADC :

https://us.creative.com/p/amplifiers/sound-blasterx-g6#specs

I ve got Adinstruments respiratory sensors:

https://www.youtube.com/watch?v=vtT_tKEEWOE&t=42s

Dr. Evan Matthews has ADCs of 16 bit, but 32 bit would be better.I v got also an Adinstruments 16 sp channel recorder, but without Labchart software. So I never got the setup working. For breath meditation I m looking for a device with high value of ADC. Also Bitalino has excellent respiratory sensors.
The DAC part's pretty good, although not as good as their claims. The ADC is further from the spec:
https://www.audiosciencereview.com/forum/index.php?threads/review-and-measurements-of-sound-blasterx-g6.7016/
The claimed 114dB dynamic range is 19 effective bits.

I can't see why you'd need >16 bits for that data - even 12 bits is 0.015mm resolution given the 60mm measurement range. 16 bit is ~1um resolution, assuming it's not below the electrical noise floor which would surprise me. What are you looking for in that signal? I used to do instrumentation and signal analysis for fatigue and vehicle dynamics so I've some idea of what's involved.
http://m-cdn.adinstruments.com/product-data-cards/TN1132-DCW-18A.pdf