You are here

项目编号 031:Bluetooth Low Energy Pressure Sensor (BMP180) | 赛普拉斯半导体

项目编号 031:Bluetooth Low Energy Pressure Sensor (BMP180)

In today's project, we implement a digital Pressure Sensor with Bluetooth Low Energy connectivity on the BLE Pioneer Kit.

The PSoC 4 BLE device communicates with the BMP180 Digital Pressure Sensor over an I2C communication interface. This sensor provides Temperature, Barometric Pressure and Altitude readings to the PSoC 4 BLE device.

Bluetooth Low Energy connectivity is implemented by creating a custom Bluetooth Low Energy Profile with a custom Service called "BMP180". This Service consists of three custom Characteristics, called "Temperature", "Pressure", and "Altitude". These custom Characteristics are used for sending 4-byte sensor data as Notifications to a connect Bluetooth Low Energy GATT Client device, like the CySmart USB Dongle (included with the Bluetooth Low Energy Pioneer Kit) or a mobile phone. 

This project also shows how to monitor the sensor data graphically using the Micrium® µC/Probe application. 

You can download this PSoC Creator project along with a detailed PDF of instructions, here from GitHub: https://github.com/cypresssemiconductorco/PSoC-4-BLE/tree/master/100_Projects_in_100_Days/Day031_Digital_Sensor

   PSoC and Temperature Diagram

Comments

bobgoar's picture

I have this app working except the Micrium® µC/Probe application. The data is there in the dongle I can see it changing and have converted the data and I know it is correct. When I run the Micrum uc/probe I get the display screen and no data. The screen has small triangles with a ! mark inside them stating no data to display. What am I missing here. I think it must be how I am setup with the Micrium but do not know how to fix it. I did notice that in the example in the PFD it shows running and the name of the device. I have stop and no device. Do you have any ideals? I would like to see the raw data but don't know how to do that in the Probe program.

Thanks

Bob Lantrip/bobgoar

Srikanth's picture

You will see a caution symbol (small yellow triangle with '!' mark) at the bottom right hand side of graphical elements (Angular Gauge, Charts, etc.) in µC/Probe when the symbol/variable mapping for the corresponding graphical elements is missing. This happens if you open the µC/Probe workspace before building the example project, where the linked ELF file is not present (Note that the project’s ELF file generated only after building the project) or when the µC/Probe workspace is moved to a new directory location after downloading the example project. In both cases, the µC/Probe shows a popup window to update the ELF file location. If the correct ELF file is not selected, the variable mapping for graphical elements is lost and shows the caution symbol (as mentioned above). In this case, re-open the µC/Probe workspace after building the example project or select the generated ELF file when the µC/Probe shows a popup window to update the ELF file location. Now run the µC/Probe and you will see the data on the screen.

Srikanth's picture

You will see a caution symbol (small yellow triangle with '!' mark) at the bottom right hand side of graphical elements (Angular Gauge, Charts, etc.) in µC/Probe when the symbol/variable mapping for the corresponding graphical elements is missing.

This happens if you open the µC/Probe workspace before building the example project, where the linked ELF file is not present (Note that the project’s ELF file generated only after building the project) or when the µC/Probe workspace is moved to a new directory location after downloading the example project.

In both cases, the µC/Probe shows a popup window to update the ELF file location. If the correct ELF file is not selected, the variable mapping for graphical elements is lost and shows the caution symbol (as mentioned above). In this case, re-open the µC/Probe workspace after building the example project or select the generated ELF file when the µC/Probe shows a popup window to update the ELF file location. Now run the µC/Probe and you will see the data on the screen.

Alternatively, you can load the generated ELF file from the Symbol Browser window in µC/Probe and drag-and-drop the global variables listed under 'I2CMaster.c' onto the corresponding graphical elements in the DataScreen window to see the data. Please refer to the µC/Probe User’s Manual for details.

Also make sure that the 'Debug Interfaces' option in µC/Probe Settings window is set to 'Cypress PSoC Prog' and the KitProg/ is selected from the drop-down menu. This will enable the communication between µC/Probe and CY8CKIT-042-BLE.

nikhil.laddha_1578391's picture

As I would like to use this example for my sensor. I am using the same kit CY8CKIT 042 BLE pioneer kit. As I am running this example but as it mention for sensor VIN oin P3[4]- J2.7 I not getting any voltage and I also would like to know how I can change the voltage at this pin and for SDA and SCL line can we use internal pull up resistor as I have seen the schematic we have a internal pull up resistor.

Thank you

Srikanth's picture

In this example, the PSoC pin used for powering the sensor VIN (P3[4] / J2.9) is activated only when the PSoC 4 BLE device is in active mode and BLE notifications are sent. This pin is set to Hi-Z in Deep Sleep/inactive mode to save power consumption. Hence you will see voltage at this pin only when the example is connected to a Central device and notifications are enabled. Please make sure to enable the notifications before measuring the voltage at this pin.

You can change the voltage at this pin (also SDA and SCL pins) by changing the system power supply jumper J16 on the BLE Pioneer Baseboard (CY8CKIT-042-BLE) to the desired position/voltage level.

本网站上的所有内容和材料均“按原样”提供。赛普拉斯半导体公司及其各个供应商对这些材料用于任何用途的适用性不作陈述,并且对关于这些材料的所有担保和条件概不负责,包括但不限于有关适销性、针对特定用途之适用性、权利和不侵犯任何第三方知识产权的所有暗示担保和条件。赛普拉斯半导体公司不授予任何明示或暗示的许可(无论是以默许方式或是任何其他方式)。使用本网站上的信息可能需要第三方的许可,或赛普拉斯半导体公司的许可。

本网站上的内容可能包含或必须遵守关于使用的特定准则或限制。所有帖子和使用本网站上的内容都必须遵守本网站的条款与条件;使用这些内容的第三方必须同意遵守任何限制或准则,并遵守本网站的条款与条件。赛普拉斯半导体公司及其供应商保留随时对内容和材料、产品、计划和服务进行纠正、删除、修改、增强、改进或其他变更,或者移动或终止任何内容、产品、计划或服务的权利,恕不另行通知。