This User's Manual note is intended to demonstrate how to use and interface with Omron’s
MEMS differential pressure sensor(D6F-PH). It should be noted that this document is intended
to supplement the datasheet, which should be referenced when using the sensor.
2. Structure
Fig.1 shows the internal cross-section view of the MEMS differential pressure sensor
(D6F-PH). Air will flow from one inlet and out the other passing over the MEMS flow chip
surface. The MEMS chip is able to measure the airflow as air passes over the chip.
Fig.1 the internal cross-section view of MEMS differential pressure sensor (D6F-PH)
proportional to the square root of
the gas flow rate through the
a conventional
square of the gas flow velocity
4. Principle of Pressure detection
By using a thermal mass flow sensor, Omron’s MEMS differential pressure sensor can detect
fine changes in differential pressure.
Fig. 3 Principle of differential pressure sensor (a) and relationship between flow rate
and differential pressure (b)
5. Features of Product
By using a thermal mass flow method, Omron’s MEMS differential pressure sensor is more
sensitive compared with that of a conventional differential pressure sensor in the low-pressure
range.
Blue:conventional method
Fig. 4 Comparison with conventional method and thermal mass flow method
When connecting the D6F-PH sensor in a bypass configuration, the sensor is able to
detect fine pressure changes. This is achieved by providing an orifice in the main channel,
which generates a small pressure change before and after the orifice. The D6F-PH will be
connected to the bypass flow path from the pressure port which is provided before and after
the orifice.
of main channel
Fig. 5 Recommended tube connection method of D6F-PH
Here, the inner diameter of the bypass tube which is connected to the D6F-PH is 4[mm]
and its length is 800[mm] or less.
For the I2C output, the D6F-PH will require a pull-up resistor to each clock line(SCL) and
data line (SDA). A pull-up resistor of 2.2[kΩ] (recommended value) should be implemented
between the Vcc as shown in Fig.6. In addition, please adjust the pull-up resistor’s value
depending on the transfer rate of SCL and the I2C wire length.
Fig. 6 Electrical connection method of D6F-PH
* Precautions when connecting the flow sensor
An error may occur during communications due to the effect of the noise of the customer’s environment.
In such a case, check the following points, and correct the communications error.
(1) Checking the communications speed
This product supports an SCL frequency of up to 400 kHz, however, if there is a likelihood of
occurrence of a communications error, we recommend using the SCL frequency at 100 kHz.
(2) Checking the wiring cable
If the length of the cable used to connect the customer-controlled microcontroller and an OMRON
flow sensor is long, the effect of noise may be more prominent. In such a case, OMRON
recommends using a shielded cable.
(3) Checking the pull-up resistor’s value
A pull-up resistor is necessary for I2C communications of this product. Although the recommended
resistor value is 2.2[kΩ], please select the optimum resistor value according to the length of the cable
used to connect the customer-controlled microcontroller and the OMRON flow sensor. A
communications error is judged unless an ACK is returned from the sensor side. The ACK response
time is equal to one clock cycle of SCL. If an ACK response is not returned after this time has
elapsed, it results in a communications error. In such a case, turn off the device.
In case access to internal registers are needed, the target register’s address needs to be set
to the Interface Configuration Register (address:00h and 01h).
Control
R/W Data
No. of bytes (Max. 4)
Fig. 7 Configuration overview
Table5. Interface Configuration Register Map
Function Note
Upper byte:bit[15:8] of 16bit data, Lower byte:bit[7:0] of 16bit data
The access address registers are used to access internal register blocks including sensor
register map, ADC register map, and internal memory. It specifies the data transfer start address
with auto increment for multiple byte data transfer.
Table6. Access Address Register
7-2-2. Serial Control Register (02h)
Table7. Serial Control Register (02h)
The serial control register contains various bits to modify the behavior of the serial access.
•Acc_ctl2 [1:0] – Access Control bits
0 0 = 16bits address (A15-A0) access ( internal ROM and registers)
0 1 = 8bits address (A7-A0) access and used to access MCU internal 256 byte dual
port RAM.
1 0 = reserved
1 1 = reserved
•R_WZ – Read or Write access select bit
0 = Write Access
1 = Read Access
• Req- Request bit
0 = the previous request is done
1 = new request. After the serial bus bridge controller finishes a request, it will clear
Req to 0. For write requests the bridge controller moves the data in write data
buffers to the location pointed by access address. For read requests the bridge
controller stores the read data into data buffer.
•D_byte_cnt3 [3:0]
Transfer data byte count. It only supports 1, 2, 3, 4 data byte transfer.
There are four write data buffer registers at address: 03h – 06h. To perform a write, the host
can either use a single command or perform separate writes to the following addresses.
The host can write to sensor register map in single byte transfer:
The host can burst write data start from address = 00h with following data byte,
A[15:8]、A[7:0]、18h、data[0].
Or the host can do four serial bus writes and write one data byte into serial bus register with
the following steps.
・Write A[15:8] to address = 00h of interface configuration registers.
・Write A[7:0] to address = 01h of interface configuration registers.
・Write data[0] to address = 03h of interface configuration registers.
・Write 18h to address = 18h of interface configuration registers.(1byte, new request, write)
[Note] Read Serial Control register(02h). If Req = 0 (02h[3]), controller is finished with write.
7-2-4. Read Buffer Registers (07h – 0Ah)
There are four read data buffer registers at address: 07h – 0Ah. To perform a read, the host
can either use a single streaming command or perform separate commands to the following
addresses. After the read request is done by the internal serial bus bridge controller, the Req
bit is cleared to 0 and read data is stored in rd_buf1 – rd_buf4 (address = 07h – 0Ah).
For single byte read request the host can burst write A[15:8], A[7:0], 1Ch at start address =
00h. The host needs to read the command register until the Req bit is cleared to 0, then read
“read data buffer” for read data at address = 07h.
The host can perform a single byte read by individually programming the following registers.
・Write A[15:8] to address = 00h of interface configuration registers.
・Write A[7:0] to address = 01h of interface configuration registers.
・Write 1Ch to address = 02h of interface configuration registers.(1byte, new request, read)
[Note] Read address = 02h. If Req = 0 (02h[3]), controller is finished with read data[0] from
address = 07h.
Initialization process after the device is turned on. Initialization must be performed to load the
trimming data of NVM.
・ Write 00h in the initialization register (0Bh)
For details, refer to Section 7-2-7. Example of I2C Access Commands.
7-2-6. Power Sequence Register (0Dh)
Table 8. Power Sequence Register (0Dh)
Table 9. Details of Power Sequence Register
h0(0000b): Idle
h2(0010b): Active
cleared after execution)
The state is h0 after the initialization process, or when the power supply is reset.
The state is h2 when 06h is written in D040.
The state is h9 during the operation.
When a hardware reset is performed, the hardware reset bit is automatically cleared to “0” after
the execution of reset, the internal register returns to the default value, and the internal trimming
value is reloaded from the non-volatile memory. This hardware reset function is similar to the
power reset function.
Notes
· When using hardware reset, set bits 0 to 6 to “0”.
•CRC_EN – CRC check calculation enable (See below for more information about the
・ CRC Overview
MSB
NONE NONE NONE NONE NONE NONE
CRC)
• 0 = CRC check calculation disable
• 1 = CRC check calculation enable
Description of the CRC calculation
The CRC is used as an error detection method in a data communication. Our flow sensor
use the CRC8 polynomial x^8 + x^5 + x^4 + 1. The following is an example of I2C access 2
byte read using CRC function.
1. The data bit sequence will be aligned in a line.
2. The polynomial bit string will be aligned under the line of the data bit sequence.
3. If the data bit above the leftmost the polynomial bit sequence is 0, the polynomial bit
sequence is shifted one bit to the right. If the data bit above the leftmost polynomial bit
sequence is 1, the data bit and the polynomial bit are calculated by XOR. Then the
polynomial bit sequence are shifted one bit to the right.
4. 1-3steps are repeated until the polynomial bit sequence reaches the right end of the data bit
sequence.
The following example shows how to calculate the CRC byte based on XOR calculation.
The measured data is sent to the dedicated registers. These registers contain, respectively,
upper byte and lower byte of the sensing signals of the sensor.
For example, the compensated flow data is given by the concatenation COMP_DATA1_H &
COMP_DATA1_L in unsigned 16bit number. And the raw flow data is given by the
concatenation UCFM1_H & UCFM1_L and it is expressed as a 2’s complement of signed
16bit number.
8-1. Data alignment
Sensing data is represented as 16bit numbers. The data is split and sent in two consecutive
bytes to Flow Registers in “Big Endian” format.
“Big Endian” means that the upper byte of the number is stored in a register at the lowest
address, and the lower byte at the highest address.
8-2. Register content
・COMP_DATA1_H & COMP_DATA1_L [D051h – D052h] : Compensated Data (unsigned)
These registers contain compensated flow rate data.
Where、Pv is Register content stored in the Compensated Flow Data registers [D051h
– D052h].
○ If pressure range is 0-250[Pa]
Dp[Pa] = (Pv - 1024)/60000*RANGE ( RANGE = 250 )
Where、Pv is Register content stored in the Compensated Flow Data registers [D051h
– D052h].
・TMP_H & TMP_L [D061h – D062h] : Temperature data (signed)
The values stored in these registers represent the temperature data measured by the
internal temperature of the ASIC.
The following formula can be applied to convert register data into temperature value.
℃
] = (Rv – 10214) / 37.39
Tv [
Where, Tv is Converted temperature value in the degC format, and Rv is Register
content stored in the Temperature Data register.
Note: Temperature data is for reference ONLY. Its accuracy is not specified in the
device specifications.
The below tables provide a few basic examples of the data that is read in Flow Sensor
Registers when the device is subject to given flow and temperature. The values listed in the
tables are given under the hypothesis of perfect device calibration (i.e. no offset, no gain error,
etc).
Table14. Temperature Data registers content vs. Temperature value
2. Execute MCU mode after desired configuration registers
Writing 06h to the Sensor Control Register (D040h) will execute the MCU mode outlined
in Section 6 with the configured setting for the ADC Resolution and Gain, Compensation.
Reading the Sensor control register after writing a 06h will show the MUX selection
chosen by the MCU. After running the process, MS bit will be set to “0”.
[Caution]: Do not read or write to the Device while the MCU is executing. It would be
safe to read/write only after 33ms.
I2C command: Write 06h to the Sensor Control Register (D040h) (MS=1&MCU_on)
START Slave Address ACK Access Address ACK Reg Address H ACK Reg Address L
Please change the RANGE_MODE
define for your target Product
10. Sample Source Code
The following is a sample source code of the D6F-PH control in the case of using
STM32microcontroller. The I2C control unit will need to be adjusted to whatever microcontroller is
used.
Thank you for your usage of products of Omron Corporation (“Omron”). Without any special
agreements, this Terms and Conditions shall apply to all transactions regardless of who sells.
Place an order, accepting this Terms and Conditions.
1. DEFINITIONS
The following terms used herein have following meaning.
(1) Omron Products; Electronic components sold by Omron
(2) Catalogues; Any and all catalogues (including the Components Catalogue), specifications,
instructions and manuals relating to Omron Products, including electronically provided data.
(3) Conditions; Use conditions, rating, performance, operating environment, handling procedure,
precautions and/or prohibited use of Omron Products described in the Catalogues.
(4) User Application(s); Application of Omron Products by a customer, including but not limited
to embedding Omron Products into customer’s components, electronic circuit boards,
devices, equipments or systems
(5) Fitness; (a)performance, (b) no infringement of intellectual property of third party, (c)
compliance with laws and regulations and (d)conformity to various standards by Omron
Products in User Applications.
2. NOTE ABOUT DESCRIPTIONS
Please understand following as to contents of the Catalogues.
(1) Rating and performance is tested separately. Combined conditions are not warranted.
(2) Reference data is intended to be used just for reference. Omron does NOT warrant that the
Omron Product can work properly in the range of reference data.
(3) Examples are intended for reference. Omron does not warrant the Fitness in usage of the
examples.
(4) Omron may discontinue Omron Products or change specifications of them because of
improvements or other reasons.
3. NOTE ABOUT USE
Please understand followings as to your adoption and use of Omron Products
(1) Please use the product in conformance to the Conditions, including rating and performance.
(2) Please confirm the Fitness and decide whether or not Omron Products are able to be
adopted in the User Application.
(3) Omron will not warrant any items in 1.(5) (a) to (d) of User Application nor the Fitness.
(4) If you use Omron Products in the application below, please ensure followings; (i) allowance
in aspect of rating and performance, (ii) safety design which can minimize danger of the
Application when the product does not work properly and (iii) periodical maintenance of the
product and the Application.
(a) Applications requiring safety, including, without limitation, nuclear control facilities,
combustion facilities, aerospace and aviation facilities, railroad facilities, elevating
facilities, amusement facilities, medical facilities, safety devices or other applications
which has possibility to influence lives or bodies
(b) Applications requiring high reliability, including, without limitation, supplying systems of
gas, water and electric power and applications handling right, title, ownership or property,
such as payment systems
(c) Applications in a harsh condition or environment, including, without limitation, outdoor
facilities, facilities with potential of chemical contamination or electromagnetic interference,
facilities with vibration or impact and facilities on continual operation for a long period
(d) Applications under conditions or environment which are not described in this specification
(5) Omron Products shown in this catalogue are not intended to be used in automotive
applications (including two wheel vehicles). Please DO NOT use the Omron Products in the
automotive application.
(6)THE PRODUCTS CONTAINED IN THIS CATALOG ARE NOT SAFETY RATED. THEY
ARE NOT DESIGNED OR RATED FOR ENSURING SAFETY OF PERSONS, AND
SHOULD NOT BE RELIED UPON AS A SAFETY COMPONENT OR PROTECTIVE DEVICE
FOR SUCH PURPOSES. Please refer to separate catalogs for OMRON's safety rated
products.
4. WARRANTY
Warranty of Omron Products is subject to followings.
(1) Warranty Period; One year after your purchase
(2) Warranty; Omron will provide, free of charge, replacements of the same number of
malfunctioning products
(3) Exceptions; This warranty does not cover malfunctions caused by any of the following.
(a) Usage in the manner other than its original purpose
(b) Usage out of the Conditions
(c) Cause which could not be foreseen by the level of science and technology at the time of
shipment of the product
(d) Cause outside Omron or Omron Products, including force majeure such as disasters
5. LIMITATION ON LIABILITY
THE WARRANTY DESCRIBED IN THIS “TERMS AND CONDITIONS” IS A WHOLE AND
SOLE LIABILITY FOR OMRON PRODUCTS. THERE ARE NO OTHER WARRANTIES,
EXPRESSED OR IMPLIED. OMRON AND DISTRIBUTORS ARE NOT LIABLE FOR ANY
DAMAGES ARISEN FROM OR RELATING TO OMRON PRODUCTS.
6. PROGRAMMABLE PRODUCTS
OMRON shall not be responsible for the user's programming of a programmable product, or any
consequence thereof.
7. EXPORT CONTROLS
Buyer shall comply with all applicable laws and regulations of Japan and/or other related
countries at the time of export or provision to non-citizens of Omron Products or their technical
information.