Author Topic: Light-weight usb oscilloscope with Matlab support?  (Read 7428 times)

0 Members and 1 Guest are viewing this topic.

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Light-weight usb oscilloscope with Matlab support?
« on: May 29, 2019, 07:59:27 pm »
I'm looking for a portable light-weight usb oscilloscope with Matlab support, with sensitivty 0-100 mV for a respiration belt sensor. The oscilloscope will be carried around 24 *7.

Which oscilloscope do you recommend?
 

Offline thm_w

  • Super Contributor
  • ***
  • Posts: 6337
  • Country: ca
  • Non-expert
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #1 on: May 29, 2019, 08:52:53 pm »
Thats more of a battery powered data logger, not oscilloscope. Most should save to a csv file that would be compatible with matlab.
What is the bandwidth requirement?
Profile -> Modify profile -> Look and Layout ->  Don't show users' signatures
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #2 on: May 30, 2019, 05:15:08 am »
No, a battery powered data logger is not suitable, since I need a life stream of data into Matlab. It s for training monitoring analyse purposes.

Here is the data sheet of the sensor i already own: 

http://m-cdn.adinstruments.com/product-data-cards/TN1132-DCW-18A.pdf 

It´s from Adinstrumens. They also have data recorders with Matlab support. The data aqisition can be plotted and analysed live in Matlab. And also Iworx have data recorders which can do that. I found here one on ebay:

https://www.ebay.ch/itm/iWorx-IWX-214-4-Channel-Data-Recorder/382898311178?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m1438.l2649

Unfortunately, these data recorders from Adinstruments and Iworx are heavy weight, and I m looking for a light weight. 

Any recommendations?
 

Offline DaJMasta

  • Super Contributor
  • ***
  • Posts: 2296
  • Country: us
    • medpants.com
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #3 on: May 30, 2019, 05:49:04 am »
I think this is data logger territory, not for the ability to store, but for the ability to digitize and directly transfer to a host PC (so an acquisition card/module), but required bandwidth and sample rate is the important part of this equation.  If it's low enough, then you need a suitable ADC on the end of a USB or other connection that will software interface with matlab (and I'd imagine there are some options), if you start needing more bandwidth or sample rate than a direct recorder can handle, then maybe a scope with acquisition memory and lower transfer speeds to the host could be viable (like capturing fast, short bursts to send after an acquisition).  If you need a lot of samples per second, more than USB can handle continuously, your best bet is probably a scope running a PC OS that you can load matlab onto, but that's not likely to be all that portable.

Would something like NI's USB DAQ devices work for you?  There are quite a few variants and quite a few other vendors, but that's the type of device your application suggests to me, unless there are requirements it can't fulfill.
 
The following users thanked this post: Peter Gamma

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #4 on: May 30, 2019, 04:58:12 pm »
Thank you for your recommendation, DaJMasta , very helpful. I m not a specialyst for oscilloscopes and data loggers. I changed my point of view. I have to explore the data logger territory, which is new for me.

Do the NI's USB DAQ  you mentioned have Matlab support? And is it possible to live stream from a sensor via NI's USB DAQ to Matlab? And do they have a buffer, so that it is not necessary to have them always connected to a PC?
 

Offline DaJMasta

  • Super Contributor
  • ***
  • Posts: 2296
  • Country: us
    • medpants.com
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #5 on: May 30, 2019, 07:08:04 pm »
Haven't used them with matlab myself, so can't say for sure, but a quick google reveals a number of devices and software advertising support for matlab.  Notably, the Data Acquisition Toolbox, which supports https://www.mathworks.com/help/daq/data-acquisition-toolbox-supported-hardware.html

I believe most of the NI DAQ series are just for streaming with little or no recording capability, but there are many devices for that as well.  An interesting mention on that support page which could be very relevant... you can probably use a PC sound card for your data acquisition.  Maybe with a simple amplifier to make full use of a line input channel, an integrated PC sound card will probably get you 16 bits or so worth of dynamic range with at least 48kHz of sample rate on two channels, so it could be as simple as configuring your PC's sound input system to feed into matlab and plugging your signal into the input.
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #6 on: May 30, 2019, 08:33:48 pm »
I’m checking several options for a setup, at the moment. Since the setup I’m assembling is for a mobile application, I would prefer a mini PC for data aquisition rather than a PC soundcard.

On my search, I found

https://learn.adafruit.com/adafruit-data-logger-shield/overview

It would be nice, to have a minicomputer for a data logger, which is flexible. And the Arduino is supported by Matlab.

The Limitation of my setup is probably given by the sensor I use. It’s a Respiratory Belt Transducer from Adinstruments.

http://m-cdn.adinstruments.com/product-data-cards/TN1132-DCW-18A.pdf

The data logger must be in the sensitive enough for this sensor. What about a combination of a high quality usb data logger for signal aquisition attached to an Arduino for Data buffering and streaming to Matlab?
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #7 on: May 31, 2019, 10:02:47 am »
From the Picotech Support, I got the information, that I don't need an oscilloscope (and also no data logger?) to connect my Adinstruments Respiratory belt transducer for instance to a rasperry pi, which is very helpful information.
 
Rather I need a small Analog-to-Digital converter to connect the respiratory belt sensor to the Rasperri Pi.

Any recommendations what kind of Analog-to-Digital converter could be suitable to connect the respiratory belt sensor to the Rasperri Pi?
« Last Edit: May 31, 2019, 10:04:23 am by Peter Gamma »
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #8 on: June 05, 2019, 04:38:58 am »
My concept for a low-cost and lightweight usb oscilloscope, usb data grabber, usb analog to digital converter with Matlab support is the following:

1. owon-vds1022i

https://www.eevblog.com/forum/testgear/owon-vds1022i-quick-teardown-(versus-the-hantek-6022be)/

2. owon-vds1022i to Matlab SCPI interface

https://www.eevblog.com/forum/testgear/owon-ag-1012-awg-matlab/

try to modify the example for Rigol, ask the Owon support for help, or ask the community here and the Matlab community for help until we got a working solution.

3. Rasperri Pi with Owon Software for Linux

as data buffer and for streaming to PC

https://www.eevblog.com/forum/testgear/owon-vds1022i-quick-teardown-(versus-the-hantek-6022be)/300/

4. PC with Matlab

Should work theoretically.
« Last Edit: June 05, 2019, 05:58:41 am by Peter Gamma »
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #9 on: September 04, 2019, 09:36:58 pm »
you can probably use a PC sound card for your data acquisition.  Maybe with a simple amplifier to make full use of a line input channel, an integrated PC sound card will probably get you 16 bits or so worth of dynamic range with at least 48kHz of sample rate on two channels, so it could be as simple as configuring your PC's sound input system to feed into matlab and plugging your signal into the input.
Did not test the Owon oscilloscope with SCPI and Matlab yet. The Owon oscilloscope has only a resolution of 8 bit. The idea to use a PC sound card for data acquisition is interesting, since a resolution of 16 bit or higher would be fine.

I found with Google Oscilloscope software which can read out 16 bit from a PC sound card. And also in Matlab there is support to read out from a PC sound card.

I thought about buying a high quality sound card to get a higher resolution than 16 bit. Does someone has experience with PC sound cards for data acquisition with bitrates higher than 16 bit? Does it work, and is it worth buying?

 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #10 on: September 20, 2019, 02:33:26 pm »
I bought a soundblaster sound card on ebay with 24 bit  and 192 kHz of sample rate for 40 USD and tested it with a ecg sensor I bought on aliexpress:

https://de.aliexpress.com/item/32228816701.html?spm=a2g0s.9042311.0.0.3cb14c4djZ3Uk5

Since the ecg sensor has 3 leads I did a "brute force" test and plugged the ecg sensor in the mic-in port of the soundcard, to test whether the included board with the sensor might be unnecessary. Unfortunately, there was only noise when I recorded the signal from the mic-in with audacity.

Then I found this video on Youtube:



This looks like the solution I m looking for, low-cost and high quality. When it works with ecg sensors, it should also work with respiration sensors. It s the best solution I could find for my needs to this day. Thank you all for your support :-+!
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9888
  • Country: us
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #11 on: September 21, 2019, 01:10:37 am »
Answering only the question of a portable scope that connect via USB to MATLAB

https://www.mathworks.com/hardware-support/digilent-analog-discovery.html
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #12 on: September 21, 2019, 03:34:03 am »
Thank you. There are also usb sound cards with 24 bit resolution. And Matlab has soundcard support. But does it work with multiple inputs? The easiest solution is probably to use several PCs with a single sound card for multiple inputs and stream the signal to one PC with Matlab. Still more affordable than a Adinstruments equipement for thousands of $$$.

For a mobile solution, I found the low-cost biomedical tool-kit Bitalino:

https://bitalino.com/en/

Bitalino has only 8 bit resolution, but as a mobile solution it is the best I could find :-+.
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #13 on: September 21, 2019, 04:37:01 pm »

Do be precise, the Bitalino revolution board has 4 analog ports with 10-bit and another 2 with 6-bit:

https://bitalino.com/datasheets/REVOLUTION_BITalino_Board_Kit_Datasheet.pdf
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #14 on: September 21, 2019, 08:55:31 pm »
One more problem solved. For more than one channel input, use a sound mixer device with multiple inputs and this:

https://ch.mathworks.com/help/daq/multichannel-audio-input-and-output-1.html

You can have a whole "Halleluja chorus" in Matlab  :).
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #15 on: September 23, 2019, 01:02:46 pm »
I did not find an affordable sound mixer which connects the individual channels to a PC. Has someone experience with connecting several usb sound cards to a PC?
 

Offline Old Printer

  • Frequent Contributor
  • **
  • Posts: 746
  • Country: us
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #16 on: September 23, 2019, 04:10:20 pm »
Have you run the Owon software on Linux on the Raspberry Pi yet? Or maybe you have moved past that. Software is a notorious weak point on the low end USB scopes. The Analog Discovery usb scope is 12 bit and will run on the Raspberry Pi according to Atila , the Digilent tech wiz.
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #17 on: September 23, 2019, 07:52:41 pm »
I dropped the Owon software on Linux on the Raspberry Pi option, and have become a soundcard freak, because of simplicity. Soundcards have normally 16 bit resolution, as far as I know, and with a PC solution with Matlab there is almost any software option availabe.

Maybe dividing the project in two options is more simple: One for stationary use with a PC, and one for mobile use with a Bitalino. But also for a mobile solution I can imagine to use a mini-PC like this one:

https://de.aliexpress.com/item/33063507615.html?spm=a2g0o.productlist.0.0.7eac42c2thZOKA&algo_pvid=d366485e-b3df-499e-b72b-bc1fb2f556f6&algo_expid=d366485e-b3df-499e-b72b-bc1fb2f556f6-40&btsid=78419bef-3a89-4d7a-8e10-6ce684449b47&ws_ab_test=searchweb0_0,searchweb201602_5,searchweb201603_52

These mini-PC dont have a mic-in, but they can probably also be used with a usb sound card like this one:

https://de.aliexpress.com/item/32492176855.html?spm=a2g0o.productlist.0.0.6d3d13bdJFIbH7&algo_pvid=22504589-b9eb-48af-87de-24cdd6192d6f&algo_expid=22504589-b9eb-48af-87de-24cdd6192d6f-0&btsid=85f8b440-6523-44f6-bab5-cbf8294ed861&ws_ab_test=searchweb0_0,searchweb201602_5,searchweb201603_52

And if several sensors are needed, more soundcards could be attached. Has someone experience in using a multi-soundcard setup with a PC?







 
 

Offline rodpp

  • Frequent Contributor
  • **
  • Posts: 307
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #18 on: September 23, 2019, 11:32:09 pm »
Maybe you can provide more information about your application, so that we can help with some hint about the hardware needed.

- How many channels are you going to acquire;
- Single ended or differential;
- Sample rate;
- Resolution;
- Portable powered by a battery, or could be connected in a PC.
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #19 on: September 24, 2019, 02:34:18 am »
Data sheet of the sensor i already own: 

http://m-cdn.adinstruments.com/product-data-cards/TN1132-DCW-18A.pdf 

Then I ve got a second sensor as the one used in this video:

https://youtu.be/sP_-f5nsOEo

- At least one channel is necessary
- It s for breathing sensors, heart rate sensor, evtl. eeg sensors, so only a single end is necessary
- Sample rate of 48kHz of sample should be sufficient
- It s for calculating breathing rate, heart rate, and other biosignals. This should work with 10 bit resolution, but a higher resolution would be better.
- I think it s easier to have both a portable and a stationary device. A stationary device with higher quality, and a mobile device with lower resolution.
« Last Edit: September 24, 2019, 02:40:26 am by Peter Gamma »
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9888
  • Country: us
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #20 on: September 24, 2019, 02:48:52 am »
I would consider using a BLE Bluetooth enabled micro to run the sensors and then blast the results to a Bluetooth enabled device,  PC, cell phone, tablet, whatever.  The Cypress PSoC 6 is a very low power dual core device with BLE.
 
The following users thanked this post: Peter Gamma

Offline rodpp

  • Frequent Contributor
  • **
  • Posts: 307
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #21 on: September 24, 2019, 04:03:24 am »
Ok, these specs are not much demanding.

If you have no problems buying used items, search for "National Instruments DAQ" on Ebay. They have a big range of DAQ solutions, almost all of them with Matlab support. Usually the best offers (cheaper) are for PCI boards. If you can have a legacy PC that has PCI slots, it doesn't cost much money to have a high performance DAQ platform. The last motherboard that I bought with PCI slots was a Biostar B350GT5, for AMD Ryzen CPUs. So you can have support for PCI boards in the current AMD CPUs. But probably it is the last generation that will have motherboards with PCI support.

For around USD500 you can buy an used PCI 6281 board: 16 AI (18-Bit, 625 kS/s aggregated), 2 AO (2.8 MS/s), 24 DIO

For around USD150 you can buy an used USB 6009 board: 8 AI (14-Bit, 48 kS/s), 2 AO (150 Hz), 13 DIO


But for your application, considering the portability, the National Instruments MyRIO fits well. It is a educational oriented product that you can program to run alone. It has a processor, a FPGA, ADCs, DACs, DIOs, etc: http://www.ni.com/pdf/manuals/376047c.pdf



Look at this example:

It is more than you need, but will allow you start your project very fast. And maybe you can find other uses to it.
 

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #22 on: September 24, 2019, 04:35:37 am »
Thank you both for your suggestions, I have to check this out.

@rstofer: a BLE Bluetooth enabled micro is a brilliant idea, I have to have a closer look at this option.
 

Offline Henrik_V

  • Regular Contributor
  • *
  • Posts: 156
  • Country: de
  • “ground” is a convenient fantasy
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #23 on: September 24, 2019, 09:03:44 am »
I would also go for a BT mic device if some ms delay doesn't matter.
If you open it and look at in input, it should be possible to locate the internal 15Hz to 25Hz highpass filter.
If that filter affect your measurements:

Q&D: Add a bigger capacitor in the HP filter to bring down the HP freq.

Like most soundcard ADCs, I assume you will find a ADC input biased to 1.25V (or so).  (and a 1.25V ref voltage pin (or 2.5V))
I used a INA217 and a Buffer OP for the Bias ref to read geophones with a soundcard (0.2Hz to 200Hz).
 
« Last Edit: September 24, 2019, 09:05:34 am by Henrik_V »
Greetings from Germany
Henrik

The number you have dialed is imaginary, please turn your phone 90° and dial again!
 
The following users thanked this post: Peter Gamma

Offline Peter GammaTopic starter

  • Frequent Contributor
  • **
  • Posts: 292
  • Country: ch
  • Meditation Research Institute (CH), Physiologist
    • www.petergamma.org
Re: Light-weight usb oscilloscope with Matlab support?
« Reply #24 on: September 24, 2019, 01:23:40 pm »
Thanks for these detailed information. I think it s really someting to have a closer look at and it s worth developing for it. To have a solution to stream  from a data channel over audio bluetooth to Matlab and have there a list of all the "sound cards" with all the data channels would be great.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf