You are here

项目编号 026:Bluetooth Low Energy Data Logging on F-RAM | 赛普拉斯半导体

项目编号 026:Bluetooth Low Energy Data Logging on F-RAM

In project #025, we demonstrated how you can use Cypress F-RAM as exteral storage memory to perform Over-the-Air Bluetooth Low Energy firmware upgrades. F-RAM is ideal to store data for such mission-critical applications like firmware bootloading due to its endurance and fast serial interface (100 trillion read/write cycles!)

In today's project, we will demonstrate how you can use F-RAM for data storage of vital information from your wearable products while consuming very little power. Recall, the Cypress F-RAM devices only consume 300-µA of active current and 6-µA of standby current making them ideal for sensor-based wearable electronics. 

In this example, we implement a Bluetooth Low Energy Heart Rate Sensor Profile on the BLE Pioneer Kit, similar to how we did in Project #002Additionally, the Heart Rate Measurements are stored on the external serial F-RAM device over an I2C interface. Once a Bluetooth Low Energy connection is established with a GAP Client (e.g. a mobile phone), this project will send the measured heart rate data to the Client via Notifications on a 1-second connection interval. The same data is sent to the F-RAM over I2C for data logging and also to a terminal (COM port) over UART for debugging purposes.

Using this example, you can create projects where the measured sensor data is stored on an external nonVolatile memory in realible way while consuming very little power.

You can download this PSoC Creator project along with a detailed PDF of instructions, here from GitHub:


   BLE Pioneer Kit Block Diagram


Humbert's picture

In the fram_logging.c, cannot understand what is the uint8 temp_buf[len+ADDR_SIZE] for, could anyone help?

barrysmale's picture

I found a bug in the Project #026: BLE Data Logging on F-RAM by Gagan Luthra. Line 29which is memcpy(&temp_buf[2], write_buf, len); The &temp_buf[2] should be &temp_buf[4]. The first 4 bytes should be the FRam address followed by the data packet. I checked out the write and read compare. Before I was getting lots of errors :=( , but now I get none :-)
Cheers, Barry

Chad.Wagner_1573706's picture

The FRAM read/write routines are broken in this project. The ones in "BLE_OTA_External_Memory_Bootloader" are much better written.

The FRAM address should be 2 bytes not 4 bytes, and this project should use the page select in the Memory Slave Device Address for the upper memory locations.

ronijames11_3081306's picture

Hello super schöner Webblog den ihr da habt. Bin gerade über die Google Suche darüber gestolpert.  Gefällt mir echt super gut. macht weiter so. MFG Martina

ultimate ecom mastery course scam

angelina_3306851's picture

Marvelous and fascinating article. Incredible things you've generally imparted to us. Much obliged. Simply keep making this kind out of post. casino tivoli