2023-10-30 09:08 AM
Hello, i have searched for this information, but couldnt find it anywhere. Whats the unit of the measured of the MEMS IMP23ABSU mic? I have used the STEVAL-STWINKT1B with the FP-SNS-DATALOG1 from which i created several .csv files that i now need to analyse. I have exported the values as "raw values" (which is an option you can choose when running the script of the dataloger).
So far i have checked the DeviceConfig.json from the dataloger and found out that the unit is "unit": "Waveform". Does that mean the values, measured from the microphone, are in Pa or dB?
You can find part of my DeviceConfig.json below.
{
"id": 7,
"name": "IMP23ABSU",
"sensorDescriptor": {
"subSensorDescriptor": [
{
"id": 0,
"sensorType": "MIC",
"dimensions": 1,
"dimensionsLabel": [
"aud"
],
"unit": "Waveform",
"dataType": "int16_t",
"FS": [
130
],
"ODR": [
8000,
16000,
32000,
48000,
96000,
192000
],
"samplesPerTs": {
"min": 0,
"max": 1000,
"dataType": "int16_t"
}
}
]
},
"sensorStatus": {
"subSensorStatus": [
{
"ODR": 192000,
"ODRMeasured": 192000,
"initialOffset": 0.19303,
"FS": 130,
"sensitivity": 1,
"isActive": true,
"samplesPerTs": 1000,
"usbDataPacketSize": 4096,
"sdWriteBufferSize": 136192,
"wifiDataPacketSize": 0,
"comChannelNumber": -1,
"ucfLoaded": false
}
]
}
}
2023-10-29 05:52 AM - last edited on 2023-10-30 02:17 AM by Pierre SENNEQUIER
Hello, i have searched for this information, but couldnt find it anywhere. Whats the unit of the measured of the MEMS IMP23ABSU mic? I have used the STEVAL-STWINKT1B with the FP-SNS-DATALOG1 from which i created several .csv files that i now need to analyse. I have exported the values as "raw values" (which is an option you can choose when running the script of the dataloger).
2023-11-03 09:03 AM
Hi @TomRett ,
Welcome to ST Community!
The raw data are in dB.
2023-11-03 10:31 AM - edited 2023-11-03 10:32 AM
Thanks for the reply! I have plotted the measured raw data and started analysing it where it looked like if i had peaks at 30000 dB (Y-Axis)? Can it be that i must normalize the Y-Axis by some factor? Is there any documentation for this?
2023-11-03 12:29 PM
Are you sure its dB? It makes more sense to me if the unit is Pascal because Lp (in dB) = 20 * log10(30000 Pa / 20 µPa) = 20 * log10(1500000) ≈ 86,99 dB (which is like a ringing telephone)
2023-11-04 04:59 AM
The Datasheet of the IMP23ABSU tells me, that the mic has an acoustic overload point of 130 dBSPL (meaning it can't measure more than 130 dB without distortion). Accordingly my sampled data has to be normalized by a given factor in order for it to be in the range of 0-130 dBSPL. Am i correct?
The DeviceConfig.json also tells about a Full Scale (FS) factor of 130. Is this factor to be used for the normalization aswell?
Thanks in advance!
2023-11-06 01:12 AM
Hi @TomRett ,
Sorry, looking closer, the data go from -32000 to +32000 so they are in LSB over 16 bits, and it seems they cover all the dynamics up to full scale, which is 130dBSPL, or 0dBV, or 1V (because 94dBSPL = -38dBV).
If you want LSB in volts, you have to do 1V/32.768 = 30uV
If you want it in dBV, LSB(dBV) = 20*log(1V/32.768)
With the conversion factor above you get dBSPL, which is directly related to Pa.
2023-11-07 11:16 PM - edited 2023-11-08 07:01 AM
So the LSB covers values as small as -32000 and the MSB is covering values as large as +32000? How can i convert it do dBSPL? The LSB represents only negative numbers out of a 16-bit integer, so how can i get the other half (MSB)?
Regarding the DeviceConfig.json:
Can i reduce the sensitivity for it not to reach the 130dbSPL? ("sensitivity": 1)
What does the ""samplesPerTs": 1000" translate to? Is this the sampling frequency of the IMP23ABSU?
Isnt the sampling frequency defined with "ODR": 192000, "ODRMeasured": 192000 ? What is the connection and the difference between ODR and ODRMeasured?
2023-11-10 12:35 AM
bump
2023-11-13 06:28 AM
Hello @TomRett
In DATALOG1, data from each sensor are saved in .dat as raw data. .dat contains bytes and data format is described in the json file you shared. So, in the case if the analog microphone, .dat contains "int16" kind of data.
Python scripts allows to elaborate, convert and plot data in different formats, both as raw data or applying the right gain in base of their physical meaning. The gain is described in the Sensitivity field of the above cited json file. For example: accelerometers data could be managed as int16 values or converted as g (gravitational acceleration). In the analog microphone use case, sensitivity is 1 and data are simply expressed as int16 values.
DATALOG1 could be a powerful demo for multisensor acquisitions, but we were not able to include a calibration procedure to guarantee a precise dBSPL measurement.
Let me also introduce you FP-SNS-DATALOG2 (link). DATALOG2 is the new and most updated Function Pack, extending functionalities and board support from the older DATALOG1. We are continuously working on DATALOG2 to let also the microphone volume and gain controllable by the user. So please evaluate the possibility to update the fiwmware and use FP-SNS-DATALOG2.
Best regards
Simone