Using Embedded Tools for I2C, SPI, and USB Debugging for the Renesas RX63N RDK

Similar documents
Beagle USB 5000 SuperSpeed Protocol Analyzer

Test Case: Linux I2C driver testing - Slave Mode. 1. Test Case ID: TC_I2C_Lin_004

AARDVARK. EEPROM Socket Board. DIP/SOIC/TSSOP EEPROM Socket Board. Datasheet v1.10 February 1, 2010 I 2 C/SPI. Features

Using Virtual EEPROM and Flash API for Renesas MCUs RX600 Series

Quick-Start Guide. BNS Solutions. QSK62P Plus

Embedding Audio into your RX Application

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

Application Brief. Using the Total Phase CAN/I2C Activity Board Pro as an I2C- to- CAN Translator Application Brief by Rick Bogart

ZCRMZNICE01ZEMG Crimzon In-Circuit Emulator

External Headers. USB Host User LEDs. User Switches. E1 Header (Unfitted)

RL78 Project Configuration Tips

M16C/62P QSK QSK62P Plus Tutorial 1. Software Development Process using HEW4

Getting Started with Renesas Development Tools

CST8152 Compilers Creating a C Language Console Project with Microsoft Visual Studio.Net 2010

ez80f91 Modular Development Kit

CST8152 Compilers Creating a C Language Console Project with Microsoft Visual Studio.Net 2005

The industrial technology is rapidly moving towards ARM based solutions. Keeping this in mind, we are providing a Embedded ARM Training Suite.

CST8152 Compilers Creating a C Language Console Project with Microsoft Visual Studio.Net 2003

Avnet Zynq Mini Module Plus Embedded Design

Getting Started with STK200 Dragon

USB Debug Adapter. Power USB DEBUG ADAPTER. Silicon Laboratories. Stop. Run. Figure 1. Hardware Setup using a USB Debug Adapter

Get Connected with USB on RX62N RX62N USB

Configuring the Xilinx Spartan-6 LX9 MicroBoard

ET-PIC 24 WEB-V1. o Central Processing Unit (CPU) o System. o nanowatt Power Managed Modes. o Analog Features

Note that FLIP is an Atmel program supplied by Crossware with Atmel s permission.

Renesas Starter Kit for RX111

Hands on Experience with AVR32

EP7209 Development Kit. Quick Start User s Guide

BASICS OF THE RENESAS SYNERGY PLATFORM

STM32L4R9I-EVAL. Evaluation board with STM32L4R9AI MCU. Features

Wireless Sensor Networks. FireFly 2.2 Datasheet

Quick Start Guide: RL78G14 Motor Control Starter Kit

Using Altia to Design a GUI and Deploy on Renesas SH7269

AC/DC. Adapter. Ribbon. Cable Serial. Serial. Adapter. Figure 1. Hardware Setup using an EC2 Serial Adapter

Cypress FM4 Tools Set-up with Keil 5.x

AD5669R - Microcontroller No-OS Driver

Embedded Design without an OS. By Peter de Ruiter D&E September 21 st, Transfer BV

CHAPTER 1 Introduction of the tnano Board CHAPTER 2 tnano Board Architecture CHAPTER 3 Using the tnano Board... 8

Quick Start Guide for the Turbo upsd DK3300-ELCD Development Kit- RIDE

Quick-start Guide for YRDKRX63N v3.3

WRITING CONSOLE APPLICATIONS IN C

17 Hatidhar st. Ra anana 43665, Israel Fax: Tel: UDEC-1. Universal Debug Center User Manual & Quick Start

AT-501 Cortex-A5 System On Module Product Brief

Installation and Maintenance

Migration from HEW to e 2 studio Development Tools > IDEs

ECE4703 Real-Time DSP Orientation Lab

Code Composer Studio Operation Manual

SiliconBlue. SiliconBlue Technologies iceman65 Board. Programmable Solutions for Consumer Handheld. 7-MAY-2008 (v1.

Programming in the MAXQ environment

Quick Start Guide TWR-S08PT60. 5-Volt S08P Family of 8-bit MCUs for Industrial and Appliance Applications TOWER SYSTEM

YWireless-RX65N Smart Home Gateway Getting Started Guide

Figure 1. JTAGAVRU1 application The JTAGAVRU1 is supported by AVR Studio. Updated versions of AVR Studio is found on

Mega128-Net Mega128-Net Mega128 AVR Boot Loader Mega128-Net

I2C and SPI Foundation

How to: Flash the DC/DC LED Lighting Kit s F28035 controlcard so that it works with the GUI

OK335x Products Guide. Contents

Symphony SoundBite Reference Manual

Texas Instruments TUSB8040 EEPROM Programming Utility. User s Guide

LPC2148 DEV BOARD. User Manual.

78M6618 PDU1 Firmware Quick Start Guide

USB Debug Adapter. Power USB DEBUG ADAPTER. Silicon Laboratories. Stop. Run. Figure 1. Hardware Setup Using a USB Debug Adapter

IP7-MZC Multi Zone Controller ZX4L Zone Expansion. Hardware Installation Manual

USB Debug Adapter. Power USB DEBUG ADAPTER. Silicon Laboratories. Stop. Run. Figure 1. Hardware Setup Using a USB Debug Adapter

DEVBOARD3 DATASHEET. 10Mbits Ethernet & SD card Development Board PIC18F67J60 MICROCHIP

Name: Serial MP3 Player A manual

CoiNel Technology Solutions LLP. LPC2148 ARTIST Instruction Manual LPC2148 ARTIST. Instruction manual. Revision 1

ez80190 Development Kit Quick Start Guide

You have a PC with a USB interface, running Microsoft Windows XP (SP2 or greater) or Vista You have the Workshop Installation Software Flash Drive

Click-A-Tune. User Manual

Z8 Encore! XP/Z8 Encore! Development Kits

Blue Point Engineering

USB Debug Adapter. Power USB DEBUG ADAPTER. Silicon Laboratories. Stop. Run. Figure 1. Hardware Setup Using a USB Debug Adapter

Implementing Bootloaders on Renesas MCUs

Introduction. Key features and lab exercises to familiarize new users to the Visual environment

KNJN I2C bus development boards

LPC1788 Mio Board. The functional details of the board are as follows-

SONiX TECHNOLOGY CO.,LTD.

Migrating from CubeSuite+ to Eclipse RL78 Family

ZIC2410 User Guide Device-Programmer Software Manual

Control Center Serial

25. DECUS Symposium THE Application Development Environment for OpenVMS

ice40 Ultra Self-Learning IR Remote User s Guide

ADS MultiTrace Tutorial v2.0

i.mx 6UltraLite Evaluation Kit Quick Start Guide s datasheet has been downloaded from at this pag

Old Company Name in Catalogs and Other Documents

X5105 Firmware Update. Instruction

CANvu 355 & VeeCAN 320 SDK

S32K118 EVB QUICK START GUIDE APPLIES FOR: S32K118 EVB (SCH_29945 REV B) EXTERNAL USE

Xilinx Vivado/SDK Tutorial

USB485 USB to RS485 Converter Card

FireWire Hi-Speed USB Combo Quick Installation Guide

Jade IdeaBoxx. Product Manual

YourBell INEXPENSIVE, RELIABLE USB PRODUCTS.

Quick Start Guide EX-9686U/A-L(A9) Copyright TOPSCCC Technology CO., LTD. All rights reserved

USB485. USB to RS485 Converter Card. User Manual for connecting with Windows Vista Version 1.01

3.1 I-7560 Pin Assignment and Specifications: Introduction

Figure 26 CC Debugger Interface

Forza 4 ASCII Game. Demo for the AK-MACHX

Key Specifications. Description. Applications. BC127-DEV-KIT BC127 Development Board v3. Manual Rev B

LibUSB: Create a Solution Without the Class Struggle!

Transcription:

Using Embedded Tools for I2C, SPI, and USB Debugging for the Renesas RX63N RDK Renesas Electronics America Inc.

Renesas Technology & Solution Portfolio 2

Agenda Introduction to the Renesas RX63N RDK Introduction to Total Phase Development Tools Lab Q&A Beagle protocol analyzers and Data Center Software Aardvark I2C/SPI Host Adapter and Flash Center Software Development Start Up Bug 1: I2C Bug 2: Read I2C LCD 3

Renesas RX63N RDK 4

Renesas RX63N RDK User push buttons RS-232 Serial Port Graphics LCD J-Link debugger Ext. Power 5 VDC Digital sensors Temp & Accel PMOD expansion Expansion header Speaker I2C/SPI Debug Connector Stereo headphone jack Application header WiFi/Bluetooth 10/100 Ethernet (Opt. IEEE1588) 128 Mb PCM Memory USB Host/Function SD-Card MIC and amplifier POT VR1 CAN transceiver LED Ring Expansion header 5

Total Phase Development Tools 6

By using debugging tools manufactured by Total Phase, you can: Debug in real time Quickly evaluate embedded systems Program EEPROMS and flash memories Easily collaborate with colleagues Maximize productivity 7

General purpose I 2 C/SPI master or slave Active communication on the I 2 C bus up to 800 khz Active communication up to 8 MHz as an SPI master and up to 4 MHz as an SPI slave Aardvark I 2 C/SPI Host Adapter 8

Control Center Software Designed to work with the Aardvark I 2 C/SPI Host Adapter Read and Write I 2 C/SPI messages XML Batch Script support Built-in Help System Multiple adapter support Windows, Linux, Mac OS X 9

Non-intrusively monitor an I 2 C or SPI bus Interactive Real-Time Display, Filter, and Search Monitors I 2 C data up to 4 MHz Monitors SPI data up to 24 MHz Beagle I 2 C/SPI Protocol Analyzer 10

Non-intrusively monitor high-, full-, and low-speed USB 2.0 Interactive Real-Time Display, Filter, and Search Real-time class-level decoding 64 MB on-board hardware buffer Beagle USB 480 Protocol Analyzer 11

Designed to work with the Beagle Protocol Analyzers LiveDisplay LiveFilter LiveSearch 32-bit and 64-bit support Tree View and Block View Windows, Linux, Mac OS X 12

Lab Introduction 13

Lab Introduction Physical Set Up Beagle USB 480 Protocol Analyzer Host Computer Hub Renesas RX63N RDK External Power Beagle I 2 C/SPI Protocol Analyzer Aardvark I 2 C/SPI Host Adapter Ribbon Cable EEPROM Activity Board 14

Lab Introduction Logical Set Up I 2 C EEPROM RX63N RDK Beagle USB 480 Protocol Analyzer I 2 C Bus Aardvark I 2 C/SPI Host Adapter Beagle I 2 C/SPI Protocol Analyzer USB PC 15

Beagle Protocol Analyzers 16

Beagle Protocol Analyzers Objective: Introduce the Beagle protocol analyzers Task: Set up and start a live capture using the Data Center Software 17

Beagle Protocol Analyzers Configuring the Beagle analyzer for use 1. Open the Data Center Software. 2. Click Connect to Analyzer. 3. Select the I2C/SPI analyzer and Click OK. 18

Beagle Protocol Analyzers Configuring the Beagle analyzer for use 4. Click Device Settings. 5. Change the capture protocol to I2C. 6. Set the sampling rate to 50 MHz. 7. Set the protocol lens to I2C. 19

Beagle Protocol Analyzers Configuring the Beagle analyzer for use 4. Click Device Settings. 5. Change the capture protocol to I2C. 6. Set the sampling rate to 50 MHz. 7. Set the protocol lens to I2C. 8. Start the capture. 20

Aardvark I 2 C/SPI Host Adapter 21

Objective: Introduce Aardvark I 2 C/SPI Host Adapter. Task: Use the Aardvark adapter and Flash Center Software to read and write from the I 2 C EEPROM. 22

Configuring the Aardvark I 2 C/SPI Host Adapter for use 1. Open the Flash Center Software 2. Click on Add Adapters 3. Select Aardvark I 2 C/SPI Host Adapter 4. Click Add 23

5. Turn on the Target Power button 6. Click on Choose Target to specify which part you will be using 24

7. Select I 2 C EEPROM under Device Type 8. Under Manufacturer, select Atmel 9. Under Part Number, choose AT24C02 10. Click OK 25

Reading and Erasing the SPI EEPROM Contents 11. Click the Read Target icon 12. Click Erase 13. Select OK 14. Click Read Target again 26

Writing Data to the I 2 C EEPROM 15. Click the Clear button to clear the local buffer 16. Click into the ASCII editor 17. On the first line, type abcdefghijklmnop 27

18. Select the Program and Verify icon 19. Click OK if presented with a warning about exceeding capacity 20. Verify the transactions in Data Center 28

Development Start Up 29

Objective: Access the project content and application Task: Load and set up the lab project using the e 2 Studio designed by Renesas 30

1. Open e 2 Studio 2. Select Browse in the Workspace Launcher 3. Browse to C:\<PATH_TO_FILES>\e2studioworkspace\TPRX63N.work 31

4. Select Project Build All 5. Select Run Debug (F11) 6. Select Go (F8) 32

7. The Renesas DevCon 2012 message will be displayed on the LCD along with a prompt to reinsert the USB cable. Beagle USB 480 Protocol Analyzer Host Computer Hub Renesas RX63N RDK External Power Beagle I 2 C/SPI Protocol Analyzer Aardvark I2 C /SPI Host Adapter Ribbon Cable EEPROM Activity Board 33

Installing the Driver 8. Reinsert the USB cable (near the Ethernet connector) 9. In the Windows Found New HW wizard, select No, not this time (If you are running Windows 7, Select Browse my computer. ) 10.Click Next 34

Installing the Driver 11.Select Install from a specific location (If you are running Windows 7, select Let me pick. ). 12.Click Next 35

Installing the Driver 13. If asked for the libusb driver, select Browse and point to the directory <PATH>\material\libusb-drivers\x86. 36

Installing the Driver 14.In Windows Device Manager, check that Windows has enumerated the RX properly. You should have it listed under the libusb-win32 device class 37

15.Launch the RX63N LibUSB GUI by double-clicking the launcher C:\<PATH_TO_FILES>\libusb-gui\launch.bat 38

Bug 1 I 2 C to LCD 39

Problem: The EEPROM data is incorrectly displayed on the LCD screen Task: Use Total Phase tools to diagnose and solve the problem 40

1. Click LibUSB Connect in the RX63N GUI. 41

Testing Application Functions 2. Click LED Control 3. Type Aardvark and click Write LCD 4. Click Clear LCD 5. Click I2C to LCD 42

Spend the next few minutes solving the bug in sending data from the EEPROM to the LCD Beagle USB 480 Protocol Analyzer Host Computer Hub Renesas RX63N RDK External Power Beagle I2C/SPI Protocol Analyzer Aardvark I2C/SPI Host Adapter Ribbon Cable EEPROM Activity Board 43

Solution Using the Beagle I 2 C analyzer, we can quickly see this problem. When we used Flash Center, the Data Center displays this transaction. The first byte of data is 00. Remember that 00 is our offset. When we click I 2 C to LCD, the Data Center displays these transactions. Note that the data is being pushed to the LCD starting at offset 08. The correct offset is 00 as shown in the first write transaction. 44

Correcting the source code and verifying the solution 6. Make the corrections to source code in line 254. 253 case USB_LIBUSB_CMD_I2C_LCD: 254 i2c_eeprom_read(0x50, 8, data, 12); 255 lcd_display(lcd_line1, "I2C -> LCD"); 256 lcd_display(lcd_line2, data); 257 break; 45

Correcting the source code and verifying the solution 7. Save and rebuild the project referring to the handout 8. Click Connect in the Application Box 9. Click I2C to LCD to verify the solution. 46

Bug 2 - Read I 2 C 47

Problem: Data is incorrectly read from the EEPROM Task: Use Total Phase tools to diagnose and solve the problem 48

Writing and reading from the EEPROM 1. Click I2C to GUI You can see the data is incorrectly displayed in the application. 49

Spend the next few minutes solving the bug in reading data from the EEPROM. Beagle USB 480 Protocol Analyzer Host Computer Hub Renesas RX63N RDK External Power Beagle I2C/SPI Protocol Analyzer Aardvark I2C/SPI Host Adapter Ribbon Cable EEPROM Activity Board 50

Evaluating the I 2 C data Using the Beagle analyzers, we can quickly isolate this problem. When we Read I2C, the Data Center displays these transactions. Using the Details pane, we can see the data is being read correctly from the I2C EEPROM. 51

Evaluating the USB data using the Beagle USB 480 analyzer 2. Open another Data Center Software 3. Click Connect to Analyzer. 4. Select the USB analyzer and Click OK. 52

Evaluating the USB data using the Beagle USB 480 analyzer 5. Go to Capture Settings and adjust the Data Capture Limit to 700 MB 6. Start the Capture 53

Reset the device to see the enumeration details 7. Go to the Bus Pane 8. In e 2 studio click Reset then Go (F8) 9. Reinsert the USB cable 10. RX600 LibUSB Demo should appear in the bus pane 54

Filter out extraneous USB data 11. Go to the Filter tab 12. Uncheck Collapsed & SOFs 13. Apply filter Only data of interest is displayed in the capture log 55

Spend the next few minutes analyzing the USB data to identify the bug. Beagle USB 480 Protocol Analyzer Host Computer Hub Renesas RX63N RDK External Power Beagle I2C/SPI Protocol Analyzer Aardvark I2C/SPI Host Adapter Ribbon Cable EEPROM Activity Board 56

Evaluating the USB data Using the Beagle USB 480 analyzer, we can diagnose this problem. When we Read I2C, the Data Center displays these input reports. Using the Details pane, we can see the data is being read backwards over USB. 57

Correcting the source code and verifying the solution 14. Make the corrections to source code. 232 uint32_t usb_bulk_send_in_packet (uint16_t ip, int16_t fn, uint32_t val) { 233 USB_ER_t err_code; 234 int16_t state; 235 236 static uint8_t data[4]; 237 for (int i = 0, s = 0; i < 4; i++, s+=8) { 238 data[i] = (uint8_t)((val >> s) & 0xff); 239 } 240 write(fn, data, 4); 58

Correcting the source code and verifying the solution 15. Save and rebuild the project referring to the handout 16. Click Connect in the GUI 17. Click I2C to GUI to verify the solution. 59

Questions and Answers 60

Renesas Electronics America Inc.