Project overview

The main intent of this project is to showcase TE Connectivity/Measurement Specialties’ sensor portfolio and Panasonic’s PAN1740 Bluetooth Low Energy module.

This project consists of two applications:

The first is a BLE server or peripheral that reads and serves up the sensor data. This is the standalone board that is battery operated with the three sensors on it: temperature, pressure, and humidity. This application can be interfaced to any BLE central that is capable of reading raw BLE packets, such as an Android, iOS, or custom application. This is also demonstrated in the Create a Weather Station with TE Connectivity sensors – Another Geek Moment.

The other is a BLE client or central that gathers the sensor data from the server, formats it, and prepares the data for transfer to a PIC32 via an SPI bus. This application was designed to interface with PICtail Plus Connector on Microchip’s Low-Cost Controllerless Graphics Board. The graphics interface is shown here: PIC32 Low-Cost Controllerless Graphics Interface to Newhaven Color LCD

Hardware

Sensor Board

Schematic:

Figure 1

Layout:

Figure 2

Figure 1 shows the schematic of the sensor board. The PAN1740 provides the processing power for the board with the onboard Cortex M0 in the module. The sensors are interfaced via I2C bus, and the data is processed and broadcast via the Bluetooth module.

Figure 2 shows the basic layout of the board. Further detail on the 4 layer board layout and gerbers can be found in the attached resources.

Client Module

Schematic:

Figure 3

Layout:

Figure 4

Figure 3 shows the schematic of the client board that interfaces with the Controllerless graphics board. It utilizes the PICTail Plus board edge connector to interface with the SPI bus. With the lack of a 3.3v power pin on the connector, this board required a 3.3v regulator of its own.

Figure 4 shows the basic layout of the client board.

Firmware

The firmware created for the Cortex M0 microcontroller that is embedded in the PAN1740 module was created in KEIL µVision 5 using Dialog Semiconductor’s SDK3.0.10.1.

The firmware on the BLE server board collects the raw data from the sensors and calculates actual values from the calibration data provided by the TE Connectivity sensors. It then uses a custom profile, which utilizes a 128-bit UUID, to transmit the data over the BLE connection. Using Dialog Semiconductor’s app note AN-B-029, will walk the developer through creating a custom profile.

The firmware on the BLE client board takes advantage of the custom profile from above to easily read the data made available on the BLE connection. The data is read in and stored, then transmitted over the SPI bus to the PIC32 for display.

The firmware for each board is stored on the external EEPROM. When the PAN1740 boots with an empty OTP memory, it searches for a program residing on an external device. This makes the module very versatile for development, as the EEPROM can be re-programmed many times. Once development has been completed the program can be burned to the OTP memory, allowing for the elimination of the EEPROM for added power savings and faster boot times.

The EEPROM can be programmed with Dialog’s SmartSnippets software using an FTDI USB – RS232 cable (TTL-232R-3V3) and small programming points integrated into the board layout.