background image

 
 

 

Getting Started With EZ-

BLE™ PRoC™ Module 

 

www.cypress.com

 

Document No.: 001-96841 Rev. ** 

Introduction 

Bluetooth  Low  Energy  (BLE)  is  an  ultra-low-power 
wireless  standard  defined  by  the  Bluetooth  Special 
Interest 

Group 

(SIG) 

for 

low-power, 

short-range 

communication. It features a physical layer, protocol stack, 
and profile architecture, all designed and optimized for the 
lowest  power  consumption.  BLE  operates  in  the  2.4-GHz 
ISM band, with a data rate of 1 Mbps. 

BLE  is  used  in  a  wide  range  of  applications.  The  use  of 
BLE in these applications also varies widely in production 
volume,  from  very  low-  to  high-volume  end  products.  As 
such,  fully  qualified,  certified,  BLE  modules  have  fast 
become  the  design  preference.  The  use  of  modules 
removes 

time 

consuming 

and 

costly 

qualification/certification processes. 

The  Cypress  EZ-BLE  PRoC Module  is  a  fully  integrated, 
qualified  and  certified,  programmable  system  that 
integrates 32-kHz and 24-MHz crystal oscillators,  passive 
components,  on-board  chip  antenna,  and 

Cypress‘s 

PRoC

™  BLE  chip  (BLE  radio,  programmable  analog  and 

digital  peripherals,  memory,  and  an  ARM

®

  Cortex

®

-M0 

microcontroller)  on  a  small  10  mm  ×  10  mm  ×  1.8  mm 
module. 

The EZ-BLE PRoC Module enables a quick time-to-market 
and  eliminates  costly  certification  and  qualification 
processes, offering an effective alternative to completing a 
BLE  system  design  from  ground  up.  In  addition  to 
reducing  the  cycle  time,  certification  and  qualification 
expenses, the programmable peripherals and GPIOs allow 
great  flexibility  using  PSoC Creator  IDE,  the  schematic-
based  design  tool  for  designing  applications  with  EZ-BLE 
PRoC Module, and a speedy time to market. 

The BLE stack library is integrated with PSoC Creator and 
is  free-of-cost.  It  can  be  easily  configured  using  a  simple 
graphical  user  interface,  allowing  you  to  jumpstart  your 
BLE design in minutes. 

The  EZ-BLE  PRoC  Module  offers  a  best-in-class  current 
consumption of 150 nA while retaining the SRAM contents 
and  the  ability  to  wake  up  from  an  interrupt.  The  EZ-BLE 
PRoC Module consumes only 60 nA while maintaining the 
wakeup  capability  in  its  nonretention  power  mode.  The 
capacitive  touch-sensing  feature  in  the  EZ-BLE  Module, 
known as CapSense

®

, offers an unprecedented signal-to-

noise ratio, best-in-class waterproofing, and a wide variety 
of  sensor  types  such  as  buttons,  sliders,  and  proximity 
sensors  that  are  gaining  increased  popularity  in  wearable 
electronic  devices  such  as  activity  monitors,  health,  and 
fitness equipment. 

If  you  are  a  first-

time  user  of  Cypress‘s  PSoC  or  PRoC 

family  of  products,  it  is  recommended  that  you  read 

Appendix B

 for a list of commonly used terms. 

More Information 

Cypress provides a wealth of data at 

www.cypress.com 

to 

help  you  accelerate  learning  on  the  EZ-BLE  PRoC 
Module,  as  well  as  Cypress‘s  PSoC  and  PRoC  family  of 
silicon  devices.  If  you  are  a  first-

time  user  of  Cypress‘s 

PSoC or PRoC family of products, it is recommended that 
you  read 

Appendix  B:  Cypress  Terms  of  Art

  for  a  list  of 

commonly used terms.  

Following  is  an  abbreviated  list  of  resources  for  the  
EZ-BLE PRoC Module: 

 

Datasheets

Describe 

and 

provide 

electrical 

specifications for the 

EZ-BLE PRoC Module

 

Application  Notes  and  Code  Examples

:

  Covers  a 

broad  range  of  topics,  from  basic  to  advanced  level. 
Many of the application notes include code examples. 
PSoC  Creator  provides  additional  code  examples

see 

Appendix C: Code Examples

 

Technical  Reference  Manuals  (TRMs)

Provide 

detailed  descriptions  of  the  architecture  and  registers 
in each PSoC 4 BLE device family.

 

 

CapSense  Design  Guide

:

  Learn  how  to  design 

capacitive touch-sensing applications with the EZ-BLE 
PRoC Module. 

 

Development Tools 

 

CY8CKIT-042-BLE  Bluetooth  Low  Energy  (BLE) 
Pioneer  Kit

  is  an  easy-to-use  and  inexpensive 

development  platform  for  BLE.  This  kit  includes 
connectors  for  Arduino™  compatible  shields  and 
the  EZ-BLE  PRoC  Module  Evaluation  daughter 
board. 

 

CySmart  BLE  Host  Emulation  Tool  for 

Windows

iOS

,  and 

Android

  is  an  easy-to-use  GUI  that 

enables  you  to  test  and  debug  your  BLE 
Peripheral applications. 

See 

Development  Kits  and  Evaluation  Boards

  for  an 

overview of available for the EZ-BLE PRoC Module. 

 

Technical Support 

 

Frequently  Asked  Questions  (FAQs)

:  Learn  more 

about our BLE ecosystem 

 

BLE  Forum

:  See  if  your  question  is  already 

answered  by  fellow  developers  on  the 

PSoC  4 

BLE

 and 

PRoC BLE

 forums. 

 

Cypress  support:  Still  no  luck?  Visit  our 

support

 

page  and  create  a 

technical  support  case

  or 

contact  a 

local  sales  representative

.  If  you  are  in 

the  United  States,  you  can  talk  to  our  technical 
support  team  by  calling  our  toll-free  number:  +1-
800-541-4736. Select option 8 at the prompt. 

 

Summary of Contents for EZ-BLE PRoC AN9684

Page 1: ...application note also guides you to more resources to accelerate in depth learning about the Cypress BLE module solution Contents Introduction 2 More Information 2 EZ BLE PRoC Module Overview 3 EZ BL...

Page 2: ...precedented signal to noise ratio best in class waterproofing and a wide variety of sensor types such as buttons sliders and proximity sensors that are gaining increased popularity in wearable electro...

Page 3: ...ll BLE functionality It includes PCB substrate 10 mm 10 mm 0 5 mm Cypress PRoC BLE chip refer to PRoC BLE Silicon Features for information on the Cypress BLE chip Crystal oscillators 32 768 kHz watch...

Page 4: ...O of the PRoC BLE silicon device are exposed on the CYBLE 022001 00 module in order to minimize the module footprint size The EZ BLE PRoC Module contains 21 connections on the bottom side of the modu...

Page 5: ...Pad 11 center 11 12 0 76 mm Distance from Pad 11 center to Pad 12 center 12 13 0 76 mm Distance from Pad 12 center to Pad 13 center 13 14 0 76 mm Distance from Pad 13 center to Pad 14 center 14 15 0...

Page 6: ...ration In this mode all peripherals are available Sleep mode In this mode the CPU is in sleep mode SRAM is in retention and all the peripherals are available Any interrupt wakes up the CPU and returns...

Page 7: ...st Recommended PCB Layout The recommended host PCB layout pattern is shown in Figure 5 Dimensions shown are in mm Figure 5 Host Board Recommended PCB Layout Pattern Note that the pad length shown incl...

Page 8: ...nd The BLE physical layer divides the ISM band into 40 RF channels with a channel spacing of 2 MHz 37 of which are data channels and 3 are advertisement channels Link Layer LL The link layer implement...

Page 9: ...s 0 to 512 bytes Implementation specific 0x0003 0x2A00 UUID for Device Name Cypress HRM Read Only No Authentication No Encryption Example Format Several types of attributes are defined by Bluetooth SI...

Page 10: ...describes the type of application and general expected behavior of that device Figure 10 shows an example of a Heart rate monitor Profile The GAP layer operates in one of four roles Broadcaster This...

Page 11: ...the data operates as the GAP central and implements the heart rate collector profile In this example the heart rate sensor profile implements two standard services the heart rate service that compris...

Page 12: ...rt Android app 5 CySmart iOS app 6 Bluetooth Low Energy Development Kit CY8CKIT 042 7 EZ BLE PRoC EVAL Board CYBLE 022001 EVAL PSoC Creator Software PSoC Creator is a state of the art easy to use IDE...

Page 13: ...on The exception to this is the L2CAP configuration specified in Bluetooth v4 1 which allows advanced users to configure the L2CAP layer of the stack if desired Developing Bluetooth Low Energy Applica...

Page 14: ...8CKIT 042 BLE Pioneer Kit The CY8CKIT 042 BLE Pioneer Kit shown in Figure 14 is an Arduino Uno compliant BLE development kit for the PRoC BLE family of devices including the CYBLE 022001 00 module The...

Page 15: ...on files CYBLE 022001 EVAL EZ BLE PRoC Module Evaluation Board The EZ BLE PRoC Module Evaluation board CYBLE 022001 EVAL is a simple evaluation board designed to fan out the EZ BLE PRoC Module CYBLE 0...

Page 16: ...number of I Os supported on the CYBLE 022001 00 module When designing applications PSoC Creator will only display connections that are available on the CYBLE 022001 00 module and CYBLE 022001 EVAL The...

Page 17: ...Top Side The CYBLE 022001 EVAL also includes the following elements Cmod A 2 2 nF capacitor mounted on the evaluation board used with the CY8CKIT 042 BLE capacitive sensing slider buttons and proximi...

Page 18: ...th the CY8CKIT 042 BLE baseboard highlighted in red in Figure 20 Table 3 details all connections on the CY8CKIT 042 BLE baseboard and provides the equivalent Port Pin connection on the CYBLE 022001 EV...

Page 19: ...1_5 J11 XRES XRES J11 P1_7 NC J11 GND GND J11 P1_6 NC J11 VDD VDD J12 GND GND J10 VDD VDD J10 P3_6 P3_6 J10 P3_7 P3_7 J10 P3_4 NC J10 P3_5 NC J10 P3_2 NC J10 P3_3 NC J10 P3_0 NC J10 P3_1 NC J10 P4_0 N...

Page 20: ...ure 21 shows the Arduino compatible headers located on the CY8CKIT 042 BLE baseboard Figure 21 Arduino Compatible Headers on CY8CKIT 042 BLE Baseboard Connections above are labeled according to the CY...

Page 21: ...BLE PRoC Module is included with PSoC Creator 3 1 SP2 and newer versions Launch PSoC Creator and navigate to the following items Simple Component example projects Choose File Open Example projects The...

Page 22: ...s visible for BLE clients The device switches to Deep Sleep mode between BLE connection intervals For this design the BLE configuration in Table 4 is used Table 4 BLE Design Configuration Requirement...

Page 23: ...or mobile app Create the Design This section takes you on a step by step guided tour of the design process It starts with creating an empty project and guides you through hardware and firmware design...

Page 24: ...a name such as My_First_Project as shown in Figure 24 Choose an appropriate location for your new project Figure 24 Naming the New Project and Device Selector Guide Location 4 Once in the Device Sele...

Page 25: ...ion from the Device Selector Guide Click OK to start the project Figure 26 Launching the Device Selector 6 Creating a new project generates a project folder with a baseline set of files You can view t...

Page 26: ...le disable components features as Figure 29 shows Disable ADC_SAR_Seq_1 and ADC_In from the BATTERY MONITOR section In the GPIO BUTTONS section disable all buttons except SW1 In the TIMER section disa...

Page 27: ...Figure 30 Figure 30 Adding One More LED 11 You can configure the Bluetooth Low Energy Component with the following properties by double clicking on the Component as shown in Figure 31 GAP peripheral r...

Page 28: ...ind Me Target and Appearance set to Generic Keyring as shown in Figure 36 GAP security set to least security configuration with no authentication or encryption as shown in Figure 37 Figure 31 Bluetoot...

Page 29: ...tarted With EZ BLE PRoC Module www cypress com Document No 001 96841 Rev 29 Figure 33 Bluetooth Low Energy Component GAP Advertisement Settings Figure 34 Bluetooth Low Energy Component GAP Advertiseme...

Page 30: ...e www cypress com Document No 001 96841 Rev 30 Figure 35 Bluetooth Low Energy Component GAP Scan Response Packet Figure 36 Bluetooth Low Energy Component GAP General Settings Figure 37 Bluetooth Low E...

Page 31: ..._LED for LED1 as shown in Figure 38 Similarly rename the other two LEDs as Disconnect_LED and Alert_LED Configure the LED as Strong drive mode Figure 38 Renaming a Pin Component 13 Double click on SW1...

Page 32: ...gure 40 Digital Input Pin Interrupt Configuration 14 Drag and drop an Interrupt Component from the Component Catalog Change the name to Wakeup_Interrupt and wire it to the Wakeup_SW pin s irq output a...

Page 33: ...Getting Started With EZ BLE PRoC Module www cypress com Document No 001 96841 Rev 33 Figure 42 Renaming the Interrupt Component Figure 43 Wiring the Interrupt and Pin Component...

Page 34: ...ard are mapped to P3 6 green P3 7 blue and P2 6 red on the Pioneer kit baseboard These baseboard connections correspond to connections P3 6 green P3 7 blue and P3 4 red of the CYBLE 022001 EVAL module...

Page 35: ...perform initialization which includes platform initialization enabling global interrupts and initializing starting the BLE Component Figure 46 shows the flowchart for system initialization As a part...

Page 36: ...Event Handler Action CYBLE_EVT_STACK_ON Bluetooth Low Energy firmware stack within the BLE Component initialized successfully Start Advertisement and reflect advertisement state on the LEDs CYBLE_EVT...

Page 37: ...6841 Rev 37 Figure 48 Bluetooth Low Energy Stack Event Handler Flow Chart Stack ON or device disconnected Start Advertising Device connected Retrieve Connection Handle N N Y Y Return from stack event...

Page 38: ...update link status on LEDs CyBle_GappStartAdvertisement Advertising_LED_Write LED_ON Disconnect_LED_Write LED_ON Alert_LED_Write LED_OFF break case CYBLE_EVT_GAP_DEVICE_CONNECTED BLE link is establis...

Page 39: ...on of the code IasEventHandler in this example For the Find Me application that you are creating the BLE Component will generate Immediate Alert Service IAS events that will let the application know i...

Page 40: ...intervals Figure 52 and Figure 53 show the main loop flowchart and firmware define NO_ALERT 0u define MILD_ALERT 1u define HIGH_ALERT 2u define BLINK_TIMEOUT 100u define LED_NO_ALERT 200u define LED_M...

Page 41: ...te deep sleep wakeup sequence Sleep till ECO stabilizes N N Alert Level Updated Y N Process the LED status System Normal Operation System Low Power Operation for Single API call to service all the BLE...

Page 42: ...oject case MILD_ALERT if blinkTimeout 0 Alert_LED_Write Alert_LED_Read 0x01 blinkTimeout BLINK_TIMEOUT break case HIGH_ALERT Alert_LED_Write LED_ON break default break bleState CyBle_GetState if bleSt...

Page 43: ...example a Cypress CY8CKIT 002 MiniProg3 1 Select the PSoC Creator menu item Debug Select Debug Target as Figure 55 shows Figure 55 Selecting Debug Target 2 In the Select Debug Target dialog box click...

Page 44: ...on directory on your PC 3 Locate My_First_Project cywrk PSoC Creator Workspace and open it with PSoC Creator 3 1 SP2 or newer 4 Right click the project name and select Device Selector as shown in Figu...

Page 45: ...ted on the EZ BLE PRoC Module Both Disconnect_LED and Wakeup_SW will be shown as unassigned 8 To complete the assignments assign P3 4 to Disconnect_LED and P3 5 to Wakeup_SW These connections can be d...

Page 46: ...ine Wait for the driver installation to complete 2 Launch the CySmart PC application by right clicking on BLE Component Launch CySmart in the project as shown in Figure 62 it should automatically dete...

Page 47: ...w cypress com Document No 001 96841 Rev 47 Figure 62 Launching CySmart Application Figure 63 CySmart BLE Dongle Selection 3 Select the Configure Master Settings menu item and restore the values to the...

Page 48: ...Pioneer Kit to start the BLE advertisements from your design 5 In the CySmart application click the Start Scan button Your device BLE Peripheral name should appear in the Discovered devices list 6 Cl...

Page 49: ...the CySmart application as shown in Figure 66 Figure 66 Discover Attributes 8 Select the Alert Level characteristic and write a value of 0 1 or 2 to Alert Level characteristic under the IAS as Figure...

Page 50: ...unch the CySmart application 3 Press the reset or SW1 button on the BLE Pioneer Kit to start the BLE advertisements from your design 4 Your device will automatically appear in the CySmart app scan scr...

Page 51: ...on chip integrating BLE radio configurable analog and digital peripheral functions memory and an ARM Cortex M0 microcontroller The EZ BLE PRoC Module is an ideal fit for customers seeking a qualified...

Page 52: ...ith sequencer Opamps None Comparators None Current DACs One 7 bit and one 8 bit Power Supply Range 1 9 V to 5 5 V Low Power Modes Deep Sleep mode at 1 3 A Hibernate mode at 150 nA Stop mode at 60 nA S...

Page 53: ...stems or hardware design followed by export to other popular IDEs Components Free embedded ICs represented by an icon in PSoC Creator software These are used to integrate multiple ICs and system inter...

Page 54: ...rchitecture or device family For EZ BLE PRoC Module use the PRoC BLE filter Most of the PRoC BLE example projects can reconfigure to work with the EZ BLE PRoC Module Select from the menu of examples o...

Page 55: ...s com Document No 001 96841 Rev 55 Document History Document Title AN96841 Getting Started With EZ BLE PRoC Module Document Number 001 96841 Revision ECN Orig of Change Submission Date Description of...

Page 56: ...re a malfunction or failure may reasonably be expected to result in significant injury to the user The inclusion of Cypress products in life support systems application implies that the manufacturer a...

Reviews: