element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Energy Harvesting
  • Challenges & Projects
  • Project14
  • Energy Harvesting
  • More
  • Cancel
Energy Harvesting
Blog Revisiting the Cypress S6SAE101A00SA1002 Solar Powered IoT Device Kit
  • Blog
  • Forum
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Energy Harvesting to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: BigG
  • Date Created: 26 Aug 2019 10:56 AM Date Created
  • Views 1534 views
  • Likes 6 likes
  • Comments 2 comments
  • energyharvestingch
  • cypress psoc
Related
Recommended

Revisiting the Cypress S6SAE101A00SA1002 Solar Powered IoT Device Kit

BigG
BigG
26 Aug 2019

image

 

Back in 2016, I completed a road test for this kit:  Solar-Powered IoT Device Kit - Review

 

At the time, I was new to Cypress’s PSoC Creator and PSoC/PRoC BLE devices. This kit also happened to have problems with the available examples not working out the box. During the original road test, I found a workaround but, in hindsight, that too was not the correct way to resolve the problem as the solution I had worked out to clear the error messages and allow for the build and deploy would not work with PSoC Creator 4.2 and also gave problems if you updated any of the components.

 

So, I am now revisiting this device as I, and I’m sure others, may be thinking of using this kit for the Energy Harvesting competition.

 

 

Demonstrating the problem

 

Let’s recap, starting with the installation process of the relevant Device Kit SDK or “package” and then highlight the problem I’m referring to.

 

I've put together a short video for demo purposes (apologies once again for the poor sound quality - too much echo!). As you will see in the video, I’m using a Windows 10 PC (32 bit).

 

You don't have permission to edit metadata of this video.
Edit media
x
image
Upload Preview
image

 

 

Let me now summarise...

 

When you install the Solar Panel IoT Device (SPID) Kit package, all files are stored here (we will return to this directory later): C:\Program Files\Cypress\Solar-Powered IoT Device Kit

 

When you open up PSoC Creator, following installation of the SPID Kit package, you should have on the Start Page a new listing under “Kits”, which will provide you with a list of examples, as shown:

 

image

 

Unfortunately, if you then select to use any of the examples shown here, you will encounter problems.

 

Let me use the “LED_ONOFF.cywk” example to demonstrate the issue. So, if you click on the “LED_ONOFF.cywk" you will get this dialog box noting an error:

 

image

 

Clicking "OK" will still open up the project. You will then get the following as your project structure (shown on left) and for your "TopDesign" you will see this:

 

image

 

As it is quite common, when loading up old projects, to see these type of messages, we know we can normally resolve this by updating the component using the "Component Update Tool":

 

image

 

This then provides you with the latest component. As I discovered in my original road test, doing this still creates errors when building the project:

 

image

 

The error messages are pretty clear. The Bootloadable component is looking for a .hex and a .elf file and it cannot find those.

 

During my original road test I found those files in the Cypress folder within the Program Files directory and copied those across to my workspace folder and then pointed the Bootloadable component to those files. So whilst this solved the immediate problem, it was actually not the correct methodology to deploy.

 

 

Providing a workable solution

 

So, to understand how to do this properly, you need to understand and know how to use two components, namely Bootloader and Bootloadable. I will explain these concepts later.

 

Let's now demonstrate a simple workable solution.

 

Step 1 is to ignore this listing:

 

image

 

 

Step 2 is to use Windows File Manager and go to the "SPID Kit Firmware" folder within the "Program Files" directory to select the example you want to use:

 

C:\Program Files\Cypress\Solar-Powered IoT Device Kit\1.0\Firmware

 

The LED_ONOFF example is listed under "Other"

 

image

 

 

Step 3 is to copy this folder within File Manager and paste this folder into your chosen project "workspace" (usually this would be in the Documents folder)

 

image

 

 

Step 4 is to go back to Cypress PSoC Creator and select "Open Existing Project" from the Start Page or choose Open Project/Workspace from the File menu.

 

Find your LED_ONOFF folder within your chosen workspace and click on this folder. You will see two folders listed:

 

  • LED_ONOFF.cydsn
  • UART_Bootloader.cydsn

 

Now click on the "LED_ONOFF.cydsn" folder.

 

 

Step 5 is to open up the PSoC Creator Workspace file (not the Project file)

 

image

 

 

When you open up that PSoC Creator Workspace file, you should see the following:

 

image

 

Don't worry. These error messages can be quickly resolved by updating the components using the "Component Update Tool". Once done you should see this, an error free(ish) project:

 

image

 

 

Step 6 is to "BUILD ALL Projects":

 

But wait... the Errors have returned!

 

image

 

Not to worry. These can now be readily resolved by opening up the LED_ONOFF project's "TopDesign".

 

 

Step 7 is to fix the dependencies in the "Bootloadable" component by selecting the correct hex file

 

image

 

So, we double click on the "Bootloadable component" to open up the Configure dialog box and then we select the "Dependencies" tab. We now click "Browse..." to find the correct hex file.

 

This hex file will be found within the following subfolder within "UART_Bootloader.cydsn" folder: your PSoC Creator Workspace... \LED_ONOFF\UART_Bootloader.cydsn\CortexM0\ARM_GCC_541\Debug

 

image

 

When you select the file and collect OK the "elf" file location will be automatically updated too.

 

 

Step 8 is to rebuild the LED_ONOFF project

 

image

 

We have now successfully built the project.

 

Now what?

 

Step 9 is to open up the "Bootloader Host..." tool within the Tools menu (and don't forget to plug the USB cable into device)

 

You may find that the required file if not found (not always the case).

 

image

 

Then it is a case of pressing the device reset button and then selecting the "Program" (F5) Action. You may have to try this a couple of times to get timing right for the bootload process to kick in.

 

You will then get the success message (note progress bar does not completely finish and that is seen as normal).

 

image

 

Step 10 is to now bask in the glory, having cracked this one.

 

Ok, we've cracked it but it still does not explain the "how does it work".

 

 

Understanding Bootloader and Bootloadable

image

 

We’ve just seen in the LED_ONOFF example that we had to link the Bootloadable, via dependancies with a Bootloader.

 

So what the heck are Bootloaders and Bootloadables and how exactly do you apply these components to your PSoC Creator project for this device?  Why are they in separate projects, for example?

 

Well, fortunately for me, Cypress Semiconductor has an excellent application note, titled “PSoC - Introduction to Bootloaders (AN73854)”, which explains these concepts and how they apply to PSoC Creator projects (phew that saves me trying to sprout bootloader theory).

 

So in summary then...

 

Bootloaders and Bootloadables only apply when you want to facilitate the ability to flash the device via the USB. If you wanted to only flash the device using the JTAG header, you would not need a bootloader.

 

So, when we want to transfer the compiled firmware from our PSoC Creator / Computer (or host) to the device (or target), the mechanism that handles the data transfer from host to target flash memory is called bootloading, or a bootload operation, or just bootload for short. The data (i.e. the firmware) that is placed in flash memory is called the application or bootloadable.

 

As illustrated in the diagram below, the bootloader code would usually be separate from application code. Thus it is common to see these as two separate projects, which is what we see here where each example workspace in PSoC Creator contains two separate projects or applications.

 

image

 

If we now refer back to the LED_ONOFF project, we can have a closer look at the separate Bootloader project. As shown in the TopDesign view, we have two components (ignore I/O interface) namely Bootloader and UART:

 

image

 

Now, you may be wondering why a UART component? To answer that question, we need to look at the device.

 

Here we see that there is a low-power USB to UART bridge controller (CY7C65213) and it is through this controller that we are ablte to transfer our firmware to the EZ-BLE module via UART:

 

image

 

If we now look at the Bootloader component, the TopDesign view has provided a nice summary “Bootloader decodes and executes the host commands. It also formulates the response packets. After successful bootload operation, the program control will be transferred to the new application firmware.” So it is our all in one command translator and command transfer handler.

 

If we double click on the Bootloader component we are given the configuration options.

 

Here you’ll notice a drop down option for Communication component which you need to set. As our device has a USB-UART bridge controller component we choose UART. Everything else is left as is.

 

image

 

Then for the UART component, you’ll notice that the baud rate is set to 115200. Note, that this appears to differ to the Bootloader documentation which says you should use baud rate of 57600. So, I left at 115200 as it worked perfectly for me.

 

Then, as seen in the first video, we have to link the application project to the Bootloader and we do this by configuring the Dependencies within the Bootloadable component.

 

image

 

What we did not touch in the LED_ONOFF project was the “Checksum exclude section” value.

 

What we will see in the next video, is a demonstration of how to get the “Simple_BLE” project working.

 

In this video demo you will also see an error being generated, when the “Checksum exclude section” value is left as is. So, while the reason for having to change this is still unclear, this is something we have to modify (change checksum exclude section size to 1 byte) to get the project to build if we include a BLE component in our project.

 

You don't have permission to edit metadata of this video.
Edit media
x
image
Upload Preview
image

 

 

In summary

 

Hopefully you found this tutorial useful, as this is a fantastic little device which offers great energy harvesting features.

 

Good luck with your next new application.

  • Sign in to reply

Top Comments

  • clem57
    clem57 over 6 years ago +1
    BigG well done. I like the way you tackled the problems within the scope of the software. I will need to remmeber that one. Clem
  • BigG
    BigG over 6 years ago +1
    I received some feedback from the Cypress forum on why you need to add in at least one byte to the "Checksum exclude section" in the bootloadable component: Apparently, the latest BLE component places…
  • BigG
    BigG over 6 years ago

    I received some feedback from the Cypress forum on why you need to add in at least one byte to the "Checksum exclude section" in the bootloadable component:

     

    Apparently, the latest BLE component places cyBle_flashStorage in cy_checksum_exclude section by default. You can refer to BLE_gatt.c for more details.

     

    cy_boot component checks whether required and provided cy_checksum_exclude sizes mach, if not throws an error (cm0gcc.ld).

     

    cyBle_flashStorage requires 0x285 bytes and linker file allocates 640 bytes in a BLE project  by default. Once you add at least 1 byte in the checksum exclude size (bootloadable configuration window), one flash row will be added and cyBle_flashStorage can be placed in cy_checksum_exclude section successfully (Simple_BLE.map).

     

    https://community.cypress.com/thread/48736

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • clem57
    clem57 over 6 years ago

    BigG  well done. I like the way you tackled the problems within the scope of the software. I will need to remmeber that one.

    Clem

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube