4158 views|1 replies

26

Posts

0

Resources
The OP
 

[ST waterproof pressure sensor LPS27HHW evaluation 1] Hardware preparation and data collection [Copy link]

 

First of all, I would like to thank the forum for giving me this opportunity, and also thank the forum administrator for his timely tracking and reminder, which allowed us to get the LPS27HHW sensor to try it out and share my experience with everyone.

1. Photos of the real object


Compared with the previous STM32 Sensor Kit, this development board is not directly shipped from the official website: it lacks packaging. There is only a bare board in an anti-static bag, and the pin headers were soldered by me later.

Because I downloaded some information and familiarized myself with it, the GPIOs I needed were already marked on the board: Vdd, Vdd_IO, SDA, SCL, GND, INT.

The schematic diagram of the Demo Kit is as follows:

2. Hardware Connection


The STM32L0 series MCU cannot be used due to other principles, so I used the STM32L4R9-DIC development board for testing.

STM32L4R9 has a dedicated IIC interface CN7, the schematic diagram is as follows:

The physical connections are as follows: (VddIO/SCL/SDA/INT/GND are directly connected to the corresponding pins of STM32L4R9 EXT_I2C Connect, and Vdd is directly connected to 3.3V by me)

3. Sensor related information


(The following content is from the sensor manual: https://www.st.com/resource/zh/application_note/dm00650819-lps27hhw-mems-pressure-sensor-with-waterresistant-package-stmicroelectronics.pdf If you use this sensor, you can take a closer look)

1). Pinout and description

2) Register


3). Three working modes

Power-down mode: The power-down mode is used to put the device into sleep state;

Single Shot Mode: Single Shot mode is used to perform a single data acquisition at a desired rate. After the acquisition is completed, the device is automatically set to Power-Down mode;

Continuous mode: The continuous mode is designed to continuously read data at a specific predefined selectable output data rate (ODR). The output registers are updated with the readings updated at each given time according to the selected ODR frequency;

You can choose the appropriate working mode according to the actual situation.

4). Sensor framework diagram

Data paths for standard and FIFO output registers

5).Format of reading data

Here is a simple example of how to get the air pressure LSB data and convert it to hPa:

  • Get raw data from the sensor: – PRESS_OUT_XL(@28h): 1Ah – PRESS_OUT_L(@29h): 84h – PRESS_OUT_H(@2Ah): 3Eh
  • Connect the registers in series: – PRESS_OUT_H & PRESS_OUT_L & PRESS_OUT_XL: 3E841Ah
  • Calculate the signed decimal value (from signed 2’s complement 24-bit binary): – P[LSB]: +4097050d
  • Apply Psens sensitivity: – P[hPa] = +4097050 / 4096 = +1000.2563

Temperature Data Example Here is a simple example of how to get the temperature LSB data and convert it to °C:

  • Get raw data from the sensor: – TEMP_OUT_L(@2Bh): 7Bh – TEMP_OUT_H(@2Ch): FEh
  • Connect registers in series: – TEMP_OUT_H & TEMP_OUT_L: FE7Bh
  • Calculates the signed decimal value (represented as 16-bit signed in two’s complement format): – T[LSB]: -389d
  • Applied Tsens sensitivity: – T[°C] = -389 / 100 = -3.89

6) Initialization

In the driver package provided by ST, no special initialization related content is seen.

Data output functionality may already be provided in the default register settings.

I will update the relevant content in later posts after I actually use it.

This post is from MEMS sensors

Latest reply

Thanks for sharing, very good   Details Published on 2021-2-25 22:00
 
 

1663

Posts

0

Resources
2
 

Thanks for sharing, very good

This post is from MEMS sensors
 
 
 

Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list