How to do real time dot product of signals acquired from a sensor with the signals in a custom made library

1 view (last 30 days)
How can I do dot product analysis of real time signals from a sensor to the signals in my custom library ? I have data stored in excel with one coloumn as time and the other coloumn as voltage readings. It is a continous data out of which there are some recorded vibrations from the sensor. I'm trying to find signal similarity by doing dot product of real time signal with all the signals of my library and giving me the maximum value and identifying the closest similar signal from my library to the real time signal. For example, I stored 3 signals which are single tap, double tap and triple tap. If I connect my sensor to matlab using arduino (if required) and do a tap, it should do dot product of the sensor's voltage readings to the signals in the library and show me that it's a single tap. As am new to matlab, I have a lot of questions.
First, Do I need Arduino or will matlab take it real time from the port directly ?
Second, In what format should I make my custom library and how to upload it to matlab ?
Third, Will matlab distinguish between a vibration and no vibration, i.e how will matlab know when and where to perform the dot product in real time (It should perform dot product when we are having a signal) ?
Fourth, length of my signal, What happens if my real time signal is short or my library signal is short ?
If someone can help me with the code of - uploading the library, loop to run dot product of the real time signal with all the signals in the library and displaying the maximum value and the name of the signal with which it got that value,and to take real time input from a sensor, it would be helpful.

Answers (0)

Categories

Find more on Vibration Analysis in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!