Creating a Project with PSoC Designer



Similar documents
Start A New Project with Keil Microcontroller Development Kit Version 5 and Freescale FRDM-KL25Z

To Begin Customize Office

Working with SQL Server Integration Services

Lab 3: Introduction to Data Acquisition Cards

EasyC. Programming Tips

EPIC 950 THERMAL TICKET PRINTER

Planning and Managing Projects with Microsoft Project Professional 2013

Procedure for updating Firmware of EZ4 W or ICC50 W

13 Managing Devices. Your computer is an assembly of many components from different manufacturers. LESSON OBJECTIVES

How to install and use the File Sharing Outlook Plugin

Impact Call PC. call001. Impact Call User s Guide

Advanced Outlook Tutorials

Knowledgebase Article

Kepware Technologies KEPServerEX Client Connectivity Guide for GE's Proficy ifix

Document Revision Date: August 14, Create a New Data Protection Policy in the Symantec.cloud Management Portal

WebSphere Business Monitor V6.2 Business space dashboards

ANYWHERE POLLING - POLLING WITH A QUESTION LIST

RTI Integration Release Notes

USBSPYDER08 Discovery Kit for Freescale MC9RS08KA, MC9S08QD and MC9S08QG Microcontrollers User s Manual

Building an Embedded Processor System on a Xilinx Zync FPGA (Profiling): A Tutorial

LYON COUNTY GEOMOOSE 2 HELP DOCUMENT

Microsoft Access 2010 handout

Appendix 1 Install RightNow on your PC

Sample Table. Columns. Column 1 Column 2 Column 3 Row 1 Cell 1 Cell 2 Cell 3 Row 2 Cell 4 Cell 5 Cell 6 Row 3 Cell 7 Cell 8 Cell 9.

SA-9600 Surface Area Software Manual

Smart Connection 9 Element Labels

TestManager Administration Guide

PCB Artist Tutorial:

Creating and Using Links and Bookmarks in PDF Documents

SKP16C62P Tutorial 1 Software Development Process using HEW. Renesas Technology America Inc.

Intro to Web Development

TUTORIAL 4 Building a Navigation Bar with Fireworks

USER S MANUAL. AXIS Mobile Monitor

Fireworks 3 Animation and Rollovers

Excel basics. Before you begin. What you'll learn. Requirements. Estimated time to complete:

WebSphere Business Monitor V7.0 Business space dashboards

Modeling Fire Hazard By Monica Pratt, ArcUser Editor

TM SysAid Chat Guide Document Updated: 10 November 2009

Corsair Link v2.4 Manual. Initial Set-up. Placing devices within the chassis

DsPIC HOW-TO GUIDE Creating & Debugging a Project in MPLAB

INF-USB2 and SI-USB Quick Start Guide

An Introduction to MPLAB Integrated Development Environment

Manual. Sealer Monitor Software. Version

v v Alarm Notifications: [Y] Bounding boxes for analytics: [N]

Using the ievo fingerprint reader with Net2

TakeMySelfie ios App Documentation

Data Director Create a New Answer Sheet

Scheduling Guide Revised August 30, 2010

INTRODUCTION 5 COLLABORATION RIBBON 5 SELECT THE UPDATING METHOD 6 MAKE YOUR PROJECT COLLABORATIVE 8 PROCESSING RECEIVED TASK UPDATES 9

IGSS. Interactive Graphical SCADA System. Quick Start Guide

How to Mimic the PanelMate Readout Template with Vijeo Designer

Microsoft Outlook Tips & Tricks

Hands-On Lab. Building a Data-Driven Master/Detail Business Form using Visual Studio Lab version: Last updated: 12/10/2010.

CONFIGURING VIRTUAL TERMINAL: This is the screen you will see when you first open Virtual Terminal

SMART Ink 1.5. Windows operating systems. Scan the following QR code to view the SMART Ink Help on your smart phone or other mobile device.

Microsoft Outlook 2007 Calendar Features

Before you can use the Duke Ambient environment to start working on your projects or

Twido Simulator - Online Help Scope What's in this Part? Twido Simulator Overview What's in this Chapter? How to Use Twido Simulator

USER GUIDE Version 2.0

Meyer Sound Remote Monitoring System 4.0

Windows Live Movie Maker

Simply Accounting Intelligence Tips and Tricks Booklet Vol. 1

WebSphere Business Monitor V6.2 KPI history and prediction lab

Task Card #2 SMART Board: Notebook

STIM202 Evaluation Kit

OPERATION MANUAL. MV-410RGB Layout Editor. Version 2.1- higher

Database Forms and Reports Tutorial

Using Flow Control with the HEAD Recorder

Tutorials Drawing a 555 timer circuit

NetCDF Tutorial. Copyright Esri All rights reserved.

Scan to PC Desktop: Image Retriever 5.2 for Xerox WorkCentre C2424

QuickBooks 2016 Getting Started Guide for Financial Institutions. Financial Institution Support OFX Connectivity Group

Bluetooth + USB 16 Servo Controller [RKI-1005 & RKI-1205]

Fleet Manager Quick Guide (Non Maintenance Mode)

ShoreTel Contact Center Using ShoreWare Agent Toolbar

Acrobat PDF Forms - Part 2

Presentations and PowerPoint

MAS 500 Intelligence Tips and Tricks Booklet Vol. 1

Outlook Tips & Tricks. Training For Current & New Employees

Ansur Test Executive. Users Manual

Ventura County Credit Union Online Banking User Guide

Microsoft Office 2007 Orientation Objective 1: Become acquainted with the Microsoft Office Suite 2007 Layout

Dispatch Board Maintenance. User Guide

Sharing Files and Whiteboards

Using your Bluetooth laptop with the Logitech wireless hub

Legal Notes. Regarding Trademarks KYOCERA Document Solutions Inc.

Creating a Calendar in CorelDRAW

TabletWorks Help Index 1

Application. 1.1 About This Tutorial Tutorial Requirements Provided Files

Pattern Graphix Pattern Graphix is a program complex that provides the automatic detection of the technical analysis patterns in MetaTrader 4.

Connecting the Console Port to a PC

How to create and personalize a PDF portfolio

GPS Tracking Software Training and User Manual

Gephi Tutorial Visualization

Configuration Manager

KCU Communication. PC Software Installation and User s Guide For KCU-30 / KCU-40 / KCU-50 modules. System requirement: Windows XP or above

Globalstar User Guide for Mac

Scribe Online Integration Services (IS) Tutorial

Working with Video in PowerPoint 2010

Transcription:

Creating a Project with PSoC Designer PSoC Designer is two tools in one. It combines a full featured integrated development environment (IDE) with a powerful visual programming interface. The two tools require and support two different design processes. In the Chip-Level view you specify exactly how you want the device configured. This allows you direct access to all of the features of your PSoC device and complete control over the routing, system resource use, and firmware development: Step 1: Create a new project Step 2: Choose a base device to work with. Step 3: Choose and configure user modules that give the PSoC device the functionality you need. Step 4: Connect the user modules to each other and to the proper pins. Step 5: Write firmware for your project in C or assembly language. Step 6: Program the PSoC device and test the program In System Level view you have a visual programming interface configures the PSoC device and writes the low level firmware for you: Step 1: Create a new project Step 2: Select the inputs and outputs Step 3: Define the behavior of the inputs and outputs Step 4: Simulate and verify your design Step 5: Build the program Step 6: Program the PSoC device and test the program You must choose one of the two design methods to start with when you create a project. You can start in the System-Level view and switch to Chip-Level view, but the converse is not true. The project structure necessary to support the System-Level view is not created for Chip-Level Projects. Both of the interfaces share a common code editor, builder, debug, emulation, and programming tools. This tutorial guides you through a small project that you can program on one of the PSoC evaluation boards such as the CY3210-PSoCEval1. The project reads the voltage from a potentiometer and sets the LED to off, on, or blinking depending on the voltage level. You can choose to do the project in the Chip-Level view or the System-Level view. When you are finished with the tutorial you will be familiar with the entire design process. Step 1: Create a New Project In PSoC Designer 5, you create a new project for your new design before you begin to design. 1. Click the File menu and select New Project. 2. In the Project types box, choose a Chip-Level Project for complete control of the project, or choose an System-Level Editor Project for rapid development. Choose any desired name for the project and click OK. Depending on your choice above, select a link below to continue with the tutorial. Chip-Level Project System-Level Project

Return to Top Step 2: Select the Inputs and Outputs PSoC Designer s System-Level view has a catalog of devices that can be used to acquire real-world inputs such as temperature, voltage, and switch state and devices that can be used in real-world output functions such as fan speed commands, relay closure/opening, and LED lighting. These devices are known as drivers. There are four types of drivers; input, output, valuators, and interfaces, each type with its own tab in the Driver Catalog. 1. To add an input driver, click the Inputs tab at the bottom of the Driver Catalog window. If you do not see the Driver Catalog window, choose Driver Catalog from the View menu. 2. Open the Voltage Input folder, then the DC folder and select a DC 0.000 to 5.000 V input and drag it on to the design window. The Add Input Driver dialog displays. 3. Change the Name to Voltage. Click OK. Figure 1. Voltage Driver Now, click the Outputs tab. The output driver section of the driver catalog will open. 5. Select Display, then LED, Single Color, and finally On/Off with blink. Drag it on to your design and name it IndicatorLED using the process described above. The Add Output Driver dialog contains properties that can be set for this driver. Sometimes there are read only properties shown in gray. All of the properties shown here are black to show that you can set the value. 6. Select OFF for the Initial Value. 7. Select 2 for the BlinkRate. 8. Leave the Current Mode at its default value (Sourcing). Click OK. Figure 2. LED Driver Step 3: Define Input/Output Behavior Once you have the inputs and outputs defined, the next step is to define how the system outputs will behave as a result of inputs. A Transfer Function is the name given to the method of defining this

behavior in PSoC Designer. A PSoC Designer output can have several transfer function types. See the IDE Guide (Help -> Documentation) for details on the types and uses of transfer functions. 1. Right click the IndicatorLED output and select Transfer Function from the popup menu. 2. Select PriorityEncoder, and click the OK button. The Priority Encoder Transfer Function definition screen shows up (see Figure 3). When you start typing in the if and then boxes, PSoC Express will automatically complete parts of your entry to aid you with creating valid expressions. In addition, some of the auto complete entries will have tool tips. 3. Select Voltage from the list and a tool tip will indicate that a scaling factor of 1000 has been applied to Voltage so 5 volts is represented as 5000. Figure 3. Priority Encoder Transfer Function 4. Click on the if box of the priority encoder. 5. Begin typing a V, select Voltage, and then type in < 1500. 6. Click on the then IndicatorLED = box of the priority encoder, and begin typing an I. 7. Select IndicatorLED OFF. 8. Press [Enter] in the then box. A second row appears in the priority encoder. 9. Use this same process to enter two more rows: a. if Voltage<3000 then IndicatorLED = IndicatorLED BLINKING b. if 1 then IndicatorLED = IndicatorLED ON 10. Note that the voltage values used were 1500 and 3000. Because the scaling factor associated with Voltage is 1000, these correspond to 1.5 volts and 3 volts respectively. Note also that the last if expression entered was 1. This is used as a catch-all case. If none of the other previous if statements were satisfied then this if statement is satisfied, and its then expression will set the output value. 11. Click OK. A red line is now drawn between the Voltage input driver and the IndicatorLED output driver indicating that the output has a dependency on the input. 12. From the File menu, select Save.

Step 4: Simulate and Verify Your Design Based on the behavior specified in step 2, we expect the LED to be off if the input voltage is less than 1.5 volts, we expect the LED to be blinking if the voltage is between 1.5 volts (inclusive) and 3 volts (exclusive), and we expect the LED to be on if the voltage is at or above 3 volts. PSoC Express provides simulation capability to prove this out. To simulate the Voltage Monitor example: 1. Click the Simulation tab at the top of the screen. A slider widget appears next to the Voltage icon, and a Current Value box widget appears next to the IndicatorLED icon. 2. Slide the slider to approximately 1 V. The LED widget should indicate a value of 0 (Off). 3. Slide the slider to approximately 2 V. The LED widget should indicate a value of 2 (Blinking). 4. Slide the slider to approximately 4 V. The LED widget should indicate a value of 1 (On). If the behavior meets your expectations, you are ready for the next step. If not, you can go back to the Design tab, make some changes to your design, and return to Simulation to verify your changes. Step 5: Build the Program You selected the inputs and outputs, defined the system behavior, and verified it through simulation. Now, you are ready to put your design into target hardware. PSoC Express is ready too, waiting for your command to build a program file for the right-size PSoC device based upon your design. 1. Choose Generate/Build Project from the Build menu. The PSoC Device Configuration Selection screen appears. This screen allows you to choose your desired PSoC device along with some system options that include defining system voltage and program loop update rate (the behaviors defined in the design are translated into a loop that runs periodically). Only PSoC configurations that will meet the input/output requirements of your design are shown. They are listed in order from least expensive to most expensive.

Figure 4. PSoC Device Configuration Selection 2. Choose the PSoC chip that you have available in your evaluation kit (most likely the CY8C27443). 3. Select 5.0V from the Supply Voltage dropdown list. 4. Select 64Hz from the Sample Rate dropdown list. 5. Click the Next button. PSoC Express will automatically assign the drivers to pins on the selected chip. This window shows a chip footprint, and indicates pins assigned to drivers in dark blue. Unassigned pins are light blue, and pins that cannot be used for input or output are white. Depending on the evaluation kit you have, you may want to reassign the pins in order to test the program. If so, you can manually reassign any pin. Drag the blue rectangle associated with an input/output driver off the top of the pin. As you drag, you will see that that one or more pins on the footprint are highlighted in green. The green highlighting indicates that those pins will accept the driver that you are assigning. Drop the blue rectangle on any one of these pins. 6. After all input/output drivers have been assigned to pins, click the Next button. PSoC Designer now converts the system design into microcontroller code and stores it in a.hex file. Upon completion, PSoC Designer also shows the resulting pin assignments along with hypertext links to a bill of materials, a datasheet, and a schematic that have been custom created for your design. You are now ready to program your PSoC device. Programming the PSoC device is exactly the same regardless of which of the design methods you choose. Click the link below to go to the last section of the tutorial. Program Your PSoC Device