Skip navigation
Home > All Places > Topics > Cypress Community Blogs > ModusToolbox Blog > Blog > 2020 > June
2020

Welcome to the third session of the ModusToolbox Training Series!

 

In the previous session, we learnt about Digital Peripherals on PSoC 6 and how you can interact with them using the HAL, the PDL, and the BSP.

 

In this session, we are going to introduce you to the industry-leading capacitive touch sensing solution, CapSense. You will learn how to build basic CapSense Applications in Modus Toolbox using the CapSense Middleware Library. This session has interesting demo projects at the end to get started with building your own CapSense application!

 

Duration: 90 mins

 

Hardware:

The exercises created as part of this training series have been tested to work on the following boards. The exercises might need minor modifications if being used for a different board.

 

Contents:

  1. Introduction to CapSense Technology
  2. CapSense Widgets
  3. Self Capacitance vs Mutual Capacitance sensing
    • When to use Self Cap, When to use Mutual Cap
  4. Introduction to CapSense Hardware Architecture
  5. Basic Terminologies to understand this training
  6. CapSense Performance Tuning
    • SmartSense
    • Manual Tuning
  7. CapSense Middleware Library
  8. ModusToolbox CapSense Configurator Tool
  9. Build your first CapSense Project
    • CapSense Initialization
    • Scanning and Processing
    • Checking Widget Status
  10. CapSense Data Structure
  11. CapSense Tuner GUI
    • Adding CapSense Tuner Support using EZI2C interface
    • Viewing CapSense Raw data
    • Tuning your sensors at run time!
    • Measuring Signal to Noise for your sensors
  12. Advanced Topics
    • Firmware filters
    • Multi Frequency Scanning
    • Pipeline Scanning using Low Level APIs
    • Liquid Tolerance in CapSense Designs
    • Built in Self Test
    • Gestures detection in CapSense
  13. Resources

 

Using the Training Material:

The presentation used in the video is attached to the blog. Jump to 1 : 43 s in the video to get started with the session.

 

The training material and exercises are hosted here: ModusToolbox Training Session 3 Github Repository

 

Have any Questions?

Feel free to drop in your queries in the Cypress Developer Community.

Welcome to the second session of the ModusToolbox Training Series!

 

In the last session, we set up ModusToolbox, got an overview of the software but we didn't exactly get our hands dirty by creating any applications.

 

In this session, we are going to learn all about Digital Peripherals on the PSoC6 and how you can interact with them using the HAL, the PDL, and the BSP. This session comes packed with plenty of exercises and by the end of it, you will have sufficient knowledge to create applications on our own!

 

Duration: 90 mins

 

Hardware:

The exercises created as part of this training series have been tested to work on the following boards. The exercises might need minor modifications if being used for a different board.

 

Contents:

  1. A quick recap of Session 1
  2. What’s new in ModusToolbox 2.1?
  3. Introduction to Digital Peripherals
    1. PSoC 6 Device Architecture
    2. PSoC 6 Digital Peripherals
      • Programmable Digital
      • Fixed Function Digital
  4. High-Speed Input / Output Matrix (HSIOM)
  5. Smart-IO
    1. Smart-IO Configurator
    2. Look-up table (LUT)
    3. Using Smart-IO in your application
    4. Exercises
  6. TCPWM
    1. Overview
    2. Counter functionality
    3. Understanding HAL
    4. Using Timer in your application using HAL and PDL
    5. Using Counter in your application using PDL
    6. Using PWM in your application using HAL and PDL
    7. Exercises on TCPWM
  7. Serial Communication Blocks (SCB)
    1. Introduction to UART / SPI / I2C
    2. Using SCBs in your application using HAL and PDL
    3. Exercises on SCBs
  8.   Resources

 

Using the Training Material:

The presentation used in the video is attached to the blog. Jump to 4:15s in the video to skip the general introductions and get right to the training.

 

The training material and exercises are hosted here: ModusToolbox Training Session2 Github Repository

 

The file Exercises_ReadMe.pdf attached to the blog highlights the steps to import the exercises into ModusToolbox and use them.

 

In the next session, we will learn about Cypress's industry-leading capacitive touch sensing solution CapSense and how we can create exciting applications using it in ModusToolbox.

 

Have any Questions?

Feel free to drop in your queries in the Cypress Developer Community.

ModusToolbox software is a set of multi-platform development tools and libraries that lets you create interesting applications on your favorite Cypress kits. Due to its vastness, understanding all the features and aspects that come with it might be a challenge! They say a picture speaks a thousand words, so having a video series, you can only imagine how helpful they will be to accelerate this process and we have done just that.

 

Introducing the ModusToolbox Training Series!

 

In the first session, we will have a deep dive into the world of ModusToolbox and understand all the features and capabilities on a high level!

 

Duration: 90 mins

 

Pre-Requisites:

  • Download ModusToolbox™ 2.1 from here.
  • Follow the steps to install it here.
  • Once installed, follow the steps mentioned in the Getting Started Guide to create your first application.

 

Note:

  • If there are firewall restrictions, you need to follow a couple more steps to get your environment configured as mentioned here.
  • If the user name on your system contains spaces or special characters, follow the steps mentioned in the User Guide to install ModusToolbox at a custom location.
  • If application creation fails, please refer to this KBA to get your environment cleaned.
  • Once the application is built, program the kit.
  • If you’ve reached this stage, great! You’re ready for the training!

 

(OPTIONAL) To understand the training better, take some time to go through the following material:

 

Hardware:

The exercises created as part of this training series have been tested to work on the following boards. The exercises might need minor modifications if being used for a different board.

 

Contents:

  1. Introduction to ModusToolbox 2.0
    1. What is ModusToolbox?
    2. What comes with the installer?
    3. Design Goals
    4. Where is the SDK?
  2. Core Tools
    1. Build Infrastructure
      1. Introduction
      2. Creating a project
      3. Autodiscover and project creation
      4. Libraries, .lib files and make getlibs
  • Library Manager
  • Creating an executable
  • Building code from within the IDE
  • Program and Debug
  1. Configurators and Tools
    1. Introduction
    2. New configurators and tools
    3. Utilities
    4. ModusToolbox IDE
  2. Software Enablement
    1. Introduction
    2. Low-level resources
    3. Peripheral Driver Library (PDL)
    4. Hardware Abstraction Layer (HAL)
    5. Board Support Package (BSP)
    6. PDL, HAL, BSP, what do you use?
    7. Middleware
    8. Code examples
  3. Supported Ecosystems
    1. PSoC6 MCU and Bluetooth SoC Ecosystem
    2. MbedOS Ecosystem
    3. Amazon FreeRTOS Ecosystem
    4. Amazon FreeRTOS Libraries
  4. Resources

 

Using the Training Material:

The presentation used in the video is attached to the blog. All the materials that will be part of this training series can be found here: ModusToolbox Training Github Repository

 

This being an introductory session does not have any exercises. In the next session, we will look at the Digital Peripherals in PSoC6 and some cool exercises to crystallize your learnings.

 

Have any Questions?

Feel free to drop in your queries in the Cypress Developer Community.

This blog has the details of benchmark test performed for BLE GATT Throughput between Cypress BT SoC CYW20820/CYW20721 and different Android and iPhones.

The firmware used to perform the measurement is available on GitHub as a Code Example. Go through the Readme file associated with the code example to get a quick understanding of BLE throughput and the parameters used to tune it. Using this code example, you can easily perform the throughput measurement on your own with just a BT SoC based Cypress kit and your phone!

 

Let’s get started by checking out how the benchmarking is done.

 

Test Setup

To conduct this activity, CYW920820EVB-02/CYW920721EVB-02 were used as BLE GAP Peripheral and GATT Server with custom throughput measurement service. The iPhones and the Android Phones listed below were used as a BLE GAP Central and GATT Client:

  • Google Pixel 3
  • Google Pixel 3A                                
  • Samsung Galaxy S8
  • Samsung Galaxy S10 Plus
  • iPhone X
  • iPhone 11

The measurements were done for both 1M and 2M PHY. An MTU size of 515 was exchanged between both the devices and DLE(Data Length Extension) was enabled. The BT SoC is programmed to send a request for connection interval of 26.25 ms, but the interval chosen depends on the Central device. Ellisys Bluetooth Sniffer was used to collect BLE air logs for all measurements.

The data traffic is only one way, i.e., GATT notifications from the BT SoC (Tx) to the smartphone (Rx). But the code example can operate for two more modes of data traffic; First mode is where, the data traffic from smartphone (Tx) to BT SoC (Rx) and the second mode mode is where, the both the Tx and Rx operation of data happen simultaneously on both the devices. For these two modes, we need a custom feature in Android/iOS CySmart app which can send frequent, automated GATT write/notifications. The android/iOS apps currently available on Playstore/Appstore do not have this feature. So, the values presented here are for GATT notifications from BT SoC to smartphone.

 

Throughput rates for 2M PHY

The below table summarizes the results obtained for 2M PHY:

 

Test ID

BT SoC -> Phone

MTU

Connection Interval

BLE GATT Throughput

1.

CYW20721 -> iPhone 11

515

26.25 ms

311 kbps

2.

CYW20721 -> iPhone 11 Pro

515

26.25 ms

365 kbps

3.

CYW20820 -> iPhone X

515

26.25 ms

340 kbps

4.

CYW20721 -> Google Pixel 3

515

45.00 ms

1236 kbps

5.

CYW20721 -> Samsung Galaxy S10 Plus

515

26.25 ms

1222 kbps

6.

CYW20820 -> iPhone X

247

26.25 ms

362 kbps

7.

CYW20820 -> Google Pixel 3A

247

45.00 ms

1303 kbps

8.

CYW20820 -> Samsung Galaxy S8

247

26.25 ms

1320 kbps

Note: The throughput values are averaged for 15 readings.

 

By now, you might have observed that with the iPhone, we get a lesser throughput (with the same parameters exchanged) compared to Android. This is because, iPhone which is the LL master in the connection, is terminating the connection event length in a connection interval. Let us compare one connection interval captured by the sniffer for both Android and iPhone to understand this:

 

  One connection interval (26.25 ms) for Android: Samsung Galaxy S10 Plus

Screenshot (391).png

   

   One connection interval (26.25 ms) for iPhone: iPhone 11

Screenshot (390).png

 

Notice that, in case of Android, most of the interval (25 ms) is utilized for data transfer, whereas, in case of iPhone, the connection event is terminated by Central after 7 ms from start of the interval. 

This means, the remaining air time is wasted and not utilized for data transfer. This is the reason, for lesser throughput in case of iPhone for the negotiated parameters.

 

Throughput rates for 1M PHY

The below table summarizes the results obtained for 1M PHY:

 

Test ID

BT SoC -> Phone

MTU

Connection Interval

BLE GATT Throughput

1.

CYW20721 -> iPhone 11

515

26.25 ms

130 kbps

2.

CYW20721 -> iPhone 11 Pro

515

26.25 ms

82 kbps

3.

CYW20820 -> iPhone X

515

30.00 ms

160 kbps

4.

CYW20721 -> Google Pixel 3

515

45.00 ms

527 kbps

5.

CYW20721 -> Samsung Galaxy S10 Plus

515

26.25 ms

222 kbps

Note: The throughput values are averaged for 15 readings.

 

Ellisys Sniffer Logs

A look into the Instant Throughput graph of entire data traffic captured by Ellisys Sniffer:

                                                         

                                                             CYW20721 -> Google Pixel 3

Screenshot (387).png

 

Three Ellisys log files are attached with this blog for reference:

  1. Ellisys Sniffer logs for CYW20721 -> iPhone 11 (1M)
  2. Ellisys Sniffer logs for CYW20721 -> Google Pixel 3 (2M) and Samsung Galaxy S10 Plus (2M)

Filter Blog

By date:
By tag: