Help selecting Arduino modules for surface vibration measurement

Hi everyone

I am trying to check the possibility of acquiring measurement of vibrations, characterized using their acceleration values, occuring during grinding operation using an Arduino. The arduino model that I have with me is UNO R3. Since I am from a mechanical engineering background and since I don't have experience using arduino prior to this work, based on some google searches and thence found youtube videos I decided to give an attempt using MPU6050 and ADXL345 modules separately.

In related research works I found that they have mounted their accelerometers (not modules but high end piezoelectric ones like these on top of grinding wheel guard and thus I followed a similar approach for basic study as shown in these photos.


When I conducted the experiments I see that unfortunately that the sensors are not capable of making measurements. So my doubt here is that is this type of sensors suitable for measuring surface vibrations? In all the tutorials that I have watched related to these sensors, they are measuring the acceleration of parts or objects which are moving. I haven't came across any projects in which they measure vibrations propagating through a surface. So if these sensors are really unsuitable is there an alternative option that could measure vibrations and help in data acquisition?

In the photos I have mounted it with the help of tapes. I tried using glue gun for rigid sticking as well but found it is also not improving the situation.

IF that is true, then you are not measuring vibrations, but sound waves traveling through the material. Try a microphone that will sense the frequencies you are interested in . Attach it to the material.

They are certainly capable, but your code may be limiting the data rate to the extent that the results are useless.

To measure vibrations using an accelerometer, you usually need to set the highest ODR (output data rate) possible, and transmit those data to the analyzer as fast as possible. For example, serial communications at the popular rate of 9600 Baud won't work for that.

For informed advice, post your code, using code tags.

may be worth moving to a faster more powerful microcontroller, e.g. an ESP32, Arduino Due, etc

First thing I would do is get a better understanding of the problem. What is the amplitude (G's) and frequency of the vibration you need to measure.

Next, make sure that your measurement device can both respond correctly, and, in the case of frequency, offload the data fast enough for your purposes.

Hi there, thanks for replying to my post.

As a preliminary to my work, I used a piezoelectric handheld vibration monitoring device (this one) to check the validity of the method and at which position I would get the maximum machining vibration signal amplitudes. It gave results in the range 1 - 10 m/s^2 as shown in the picture.

image

The limitation of this device was that it was not designed for data logging that the maximum sampling rate was just 1 sample/sec.

While I attempted to improve the sampling rate in the arduino code as well (I used delay() function) I found that the sampling rate actually was not increasing with low delay values that I was actually searching for cues on the code side as well. Following is the code that I currently use with ADXL345 module.

#include <Adafruit_ADXL345_U.h>
#include <Adafruit_Sensor.h>
#include <Wire.h>

Adafruit_ADXL345_Unified adxl = Adafruit_ADXL345_Unified(12345);

float Accx = 0;
float Accy = 0;
float Accz = 0;
float amp = 0;

 //for calibration
float readingx[] = {0.0, 0.0, 0.0, 0.0, 0.0,0.0, 0.0, 0.0, 0.0, 0.0};
float readingy[] = {0.0, 0.0, 0.0, 0.0, 0.0,0.0, 0.0, 0.0, 0.0, 0.0};
float readingz[] = {0.0, 0.0, 0.0, 0.0, 0.0,0.0, 0.0, 0.0, 0.0, 0.0};
float sumx = 0.0;
float sumy = 0.0;
float sumz = 0.0;

void setup() {
	Serial.begin(9600);

	// Try to initialize!
	if (!adxl.begin()) {
		Serial.println("Failed to find ADXL345 chip");
		while (1) {
		  delay(10);
		}
}

	Serial.println("ADXL345 Found!");

  Serial.println("Type key when ready..."); 
    for (int i=0; i<10; i++){
      while (!Serial.available()){}  // wait for a character
      
        /* Get new sensor events with the readings */
      sensors_event_t a;
      adxl.getEvent(&a);
      readingx[i] = a.acceleration.x;
      readingy[i] = a.acceleration.y;
      readingz[i] = a.acceleration.z;
      
     
      Serial.print(readingx[i]); Serial.println();
      Serial.print(readingy[i]); Serial.println();
      Serial.print(readingz[i]); Serial.println();

      while (Serial.available())
      {
        Serial.read();  // clear the input buffer
      }
    }
  for (int i = 0; i < 10; i++){
        sumx += readingx[i];   
        sumy += readingy[i];   
        sumz += readingz[i];   
  }                     
	delay(100);
}

void loop() {
	/* Get new sensor events with the readings */
	sensors_event_t a;
	adxl.getEvent(&a);
	/* Print out the values */
  Accx = a.acceleration.x-(sumx/10);
  Accy = a.acceleration.y-(sumy/10);
  Accz = a.acceleration.z-(sumz/10);
  amp = sqrt(pow(Accx,2)+pow(Accy,2)+pow(Accz,2));
  
	Serial.print(Accx);
  Serial.print(", ");
  Serial.print(Accy);
  Serial.print(", ");
  Serial.print(Accz);
  Serial.print(", ");
  Serial.println(amp);
	delay(100);
}  

Could you please mention whether the code itself is an issue? 

Hi there

In this case, when I keep my hands in place of the sensor I actually could feel the vibrations. Could that still be sound waves like you mentioned?

Hello there

I used a piezoelectric handheld vibration monitoring device (this one) to check the validity of the method and at which position I would get the maximum machining vibration signal amplitudes. It gave results in the range 1 - 10 m/s^2 as shown in the picture.

image

From the data sheet of either of the accelerometers I was not able decide whether they are suitable but decided to give it a try. SO could you mention whether they are suitable for this measurement range?

Hi

Will definitely give them a try once I identify the issue like mentioned by others in comments. Thanks for the suggestion

Well, the ADXL345 certainly has the range, and probably the resolution you need. It has a max frequency of 3kHz so you'll have to determine if that is fast enough for your needs. I can't get that from your plot.

However, that's the raw chip; you'll have to check the Adafruit board to see if there are any speed limitations that it might impose. My guess is that it doesn't but I haven't analyzed deep enough to be sure.

Absolutely the sound. That is how "ultrasound" is used to see inside your body.

Sound IS vibration in materials.

I have been looking up microphone modules after your first comment ( Analog Sound Sensor Microphone Module for Arduino ).

Are you recommending such a module because of its higher frequency capabilities? But if I use one such module then is it possible to characterize the vibration (I don't know whether I should use the term 'sound' here) as I see that they rely on a threshold and is not seen to be used for data logging. Then again my doubt still remains, that would I have been able to feel sound propagating through a surface? Asking this because I used a piezoelectric handheld vibration monitoring device (this one) as a preliminary work to check the validity of the method and at which position I would get the maximum machining vibration signal amplitudes. It gave results in the range 1 - 10 m/s^2 as shown in the picture.

image

Also after thinking that modules like ADXL maybe suitable for measuring accelerations of bodies which are in motion ( and not of surface vibrations), I have been looking up piezo sensors as well (piezo module ). Could you check the possibility of the usage of such as well?

My doubt here is that the would I have been able to feel it? I mean is it like if there a machine with a rotating mass like a motor, is the 'vibration' that you would feel if you touch its casing is sound propagating through it?

To use a microphone to characterize vibration, the microphone MUST be in contact with the device in question. Use your oscilloscope to see the output of the microphone/amplifier.
If you intend to actually measure the vibrations, you must know the response range and similar qualities of the microphone and amplifier. Then you need some method of calibration for your system. I don't know what that would be. Never heard of a vibration standard.

What you feel is a combination of vibrations from several sources. Spectral analysis of the accelerometer data will reveal characteristic frequencies.

Some of those frequencies will be directly proportional to the motor speed, and may indicate vibrations induced by rotating parts that are out of balance.

You can find plenty of information on the web using search phrases like "accelerometer vibration analysis".

Hi, @gibingp

This is a very interesting read, especially the comments at point number 2 under types of vibration sensor.

2. Velocity Sensor
The velocity sensor is a vibration sensor type made for high-temperature measurements through the usage of a current generated from a magnet traveling within a coil.
Popular due to its less susceptibility to amplifier overloads as compared to accelerometer and gyroscope sensors, velocity sensors are not to mess with!

Google;

arduino vibration sensor

Tom... :grinning: :+1: :coffee: :australia:

In a microphone sensor would a contact mean that the internal parts of the microphone should be in contact with the surface? I imagine this microphone to be consisted of a membrane which moves according to the incident sound waves. So should the membrane itself should be in contact?

What you feel is a combination of vibrations from several sources. Spectral analysis of the accelerometer data will reveal characteristic frequencies.

So by recommending a microphone module do you mean to say that the machining vibrations might be of higher frequency and above the ADXL or MPU capabilities ?

P.S In your first comment you mentioned that these modules might be capable but that the code might not be fast enough that I looked up more into the electronics basics and how configurations with libraries such as Wire.h works through which I could change sampling rate by modifying the serial communication parameters. So if you suggest another module is there no hope left in modifying the code itself?

I started with an accelerometer module since I learned acceleration of the vibration signal is best suited for applications such as in mine.

Hi there, thanks for replying to my post.

I chose an accelerometer module as I learned that characterizing vibration with its acceleration values is most suited for applications such as in mine. I was indeed looking up other modules as well, especially a piezoelectric one mentioned in your link. I am not able to find a project in which they were used for data logging though which is needed in my case.