Provide accurate pressure and temperature data for engine management systems, tire pressure monitoring, and other automotive systems
A
A
Hardware Overview
How does it work?
Pressure 23 Click - 07BA is based on the MS5849-07BA, an ultra-compact, chlorine-resistant absolute pressure sensor developed by TE Connectivity. This high-performance sensor delivers precise absolute pressure measurements with a 24-bit resolution and transmits the data digitally via I2C or SPI interfaces. It is engineered to operate within pressure ranges from 0.4 to 7 bar and features a media-protected design with a chlorine-resistant gel coating, making it ideal for harsh environments. Additionally, it measures temperature over a wide range from -20 to +85°C and makes an excellent choice for applications requiring reliable and precise pressure and temperature measurements in challenging environments. The MS5849-07BA sensor combines a piezoresistive pressure cell with an amplifier A/D interface IC, all enclosed in a
robust QFN package. This package includes a grounded metal ring that shields the electronic components and facilitates secure O-ring mounting. The sensor processes the measured pressure and temperature signals, converting them into a 24-bit data word. It also stores six unique coefficients that enable highly accurate software correction for both pressure and temperature measurements when processed by a host microcontroller unit (MCU). As mentioned, Pressure 23 Click - 07BA can communicate with the host MCU using the 4-Wire SPI serial interface and the I2C interface. The SPI interface supports clock frequencies up to 10MHz, while the I2C clock supports up to 3.4MHz. The desired communication interface can be chosen over the 5 COMM SEL jumpers, where the SPI is set by default. If your goal is the I2C, you can
select the I2C address over the ADDR SEL jumper (0 set by default). The chosen communication interface provides flexibility in configuring the oversampling rate and optimizing both speed and power consumption based on application requirements. Besides communication pins, this board also uses an interrupt INT pin, which will be raised for different conditions, such as pressure and temperature thresholds, finished ADC conversion, and more. This Click board™ can be operated only with a 3.3V logic voltage level. The board must perform appropriate logic voltage level conversion before using MCUs with different logic levels. Also, it comes equipped with a library containing functions and an example code that can be used as a reference for further development.
Features overview
Development board
Discovery kit with STM32F407VG MCU, powered by the STM32F407 microcontroller, simplifies audio application development. It offers a robust platform with features like the ST-LINK/V2-A debugger, STMEMS digital accelerometer, digital microphone, and integrated audio DAC with a class D speaker driver. It has LEDs, push buttons, and a USB OTG
Micro-AB connector for versatile connectivity. The STM32F407VGT6 MCU boasts a 32-bit Arm Cortex-M4 with FPU, 1MB Flash memory, and 192KB RAM, housed in an LQFP100 package. Equipped with USB OTG FS, MEMS accelerometer, omnidirectional digital microphone, and user-friendly buttons, it ensures seamless operation.
The board accommodates various add-ons via extension headers while offering flexible power supply options, including ST-LINK, USB VBUS, or external sources. Supported by comprehensive free software and a range of IDEs, it empowers developers with flexibility and ease of use, making it an ideal choice for audio-centric projects.
Microcontroller Overview
MCU Card / MCU

Architecture
ARM Cortex-M4
MCU Memory (KB)
10
Silicon Vendor
STMicroelectronics
Pin count
100
RAM (Bytes)
100
You complete me!
Accessories
STM32F4 Discovery Shield is the perfect extension for your STM32F4 Discovery Board from STMicroelectronics. This versatile shield features four mikroBUS™ host sockets, a USB-UART module, and a CAN transceiver, expanding the capabilities of your Discovery board. Acting as a docking station, the STM32F4 Discovery Shield enables you to effortlessly transform your board into various applications, whether it's an RFID lock, SMS-triggered control switch, GPS tracking device, full-blown weather station, or any other idea you have in mind. With its seamless integration and enhanced functionality, this shield empowers you to explore endless possibilities and quickly bring your projects to life.
Used MCU Pins
mikroBUS™ mapper
Take a closer look
Click board™ Schematic

Step by step
Project assembly
Track your results in real time
Application Output
1. Application Output - In Debug mode, the 'Application Output' window enables real-time data monitoring, offering direct insight into execution results. Ensure proper data display by configuring the environment correctly using the provided tutorial.

2. UART Terminal - Use the UART Terminal to monitor data transmission via a USB to UART converter, allowing direct communication between the Click board™ and your development system. Configure the baud rate and other serial settings according to your project's requirements to ensure proper functionality. For step-by-step setup instructions, refer to the provided tutorial.

3. Plot Output - The Plot feature offers a powerful way to visualize real-time sensor data, enabling trend analysis, debugging, and comparison of multiple data points. To set it up correctly, follow the provided tutorial, which includes a step-by-step example of using the Plot feature to display Click board™ readings. To use the Plot feature in your code, use the function: plot(*insert_graph_name*, variable_name);. This is a general format, and it is up to the user to replace 'insert_graph_name' with the actual graph name and 'variable_name' with the parameter to be displayed.

Software Support
Library Description
This library contains API for Pressure 23 Click - 07BA driver.
Key functions:
pressure2307ba_get_measurement_data
- Pressure 23 07BA gets the measurement data function.pressure2307ba_get_calibration_data
- Pressure 23 07BA gets the calibration data function.pressure2307ba_read_adc
- Pressure 23 07BA ADC data reading function.
Open Source
Code example
The complete application code and a ready-to-use project are available through the NECTO Studio Package Manager for direct installation in the NECTO Studio. The application code can also be found on the MIKROE GitHub account.
/*!
* @file main.c
* @brief Pressure 23 07BA Click example
*
* # Description
* This example demonstrates the use of Pressure 23 07BA Click board by reading and displaying
* the pressure and temperature measurements.
*
* The demo application is composed of two sections :
*
* ## Application Init
* The initialization of I2C or SPI module and log UART.
* After driver initialization, the app sets the default configuration.
*
* ## Application Task
* The demo application reads and displays the Pressure [mBar]
* and Temperature [degree Celsius] data.
* Results are being sent to the UART Terminal, where you can track their changes.
*
* @author MikroE Team
*
*/
#include "board.h"
#include "log.h"
#include "pressure2307ba.h"
static pressure2307ba_t pressure2307ba;
static log_t logger;
void application_init ( void )
{
log_cfg_t log_cfg; /**< Logger config object. */
pressure2307ba_cfg_t pressure2307ba_cfg; /**< Click config object. */
/**
* Logger initialization.
* Default baud rate: 115200
* Default log level: LOG_LEVEL_DEBUG
* @note If USB_UART_RX and USB_UART_TX
* are defined as HAL_PIN_NC, you will
* need to define them manually for log to work.
* See @b LOG_MAP_USB_UART macro definition for detailed explanation.
*/
LOG_MAP_USB_UART( log_cfg );
log_init( &logger, &log_cfg );
log_info( &logger, " Application Init " );
// Click initialization.
pressure2307ba_cfg_setup( &pressure2307ba_cfg );
PRESSURE2307BA_MAP_MIKROBUS( pressure2307ba_cfg, MIKROBUS_1 );
err_t init_flag = pressure2307ba_init( &pressure2307ba, &pressure2307ba_cfg );
if ( ( I2C_MASTER_ERROR == init_flag ) || ( SPI_MASTER_ERROR == init_flag ) )
{
log_error( &logger, " Communication init." );
for ( ; ; );
}
if ( PRESSURE2307BA_ERROR == pressure2307ba_default_cfg ( &pressure2307ba ) )
{
log_error( &logger, " Default configuration." );
for ( ; ; );
}
log_info( &logger, " Application Task " );
log_printf( &logger, " _______________________ \r\n" );
Delay_ms ( 100 );
}
void application_task ( void )
{
static float temperature, pressure;
if ( PRESSURE2307BA_OK == pressure2307ba_get_measurement_data( &pressure2307ba, &pressure, &temperature ) )
{
log_printf( &logger, " Pressure : %.2f mBar \r\n", pressure );
log_printf( &logger, " Temperature : %.2f degC \r\n", temperature );
log_printf( &logger, " _______________________ \r\n" );
Delay_ms ( 1000 );
}
}
int main ( void )
{
/* Do not remove this line or clock might not be set correctly. */
#ifdef PREINIT_SUPPORTED
preinit();
#endif
application_init( );
for ( ; ; )
{
application_task( );
}
return 0;
}
// ------------------------------------------------------------------------ END
Additional Support
Resources
Category:Pressure