Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved. Using Embedded Tools for I2C, SPI, and USB Debugging for.

Slides:



Advertisements
Similar presentations
FatMax Licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 2.5 LicenseCreative Commons Attribution-NonCommercial-ShareAlike 2.5.
Advertisements

DE2-115 Control Panel - Part I
MM Player Supervised by: Dr. Luai Malhis. Prepared by: Mustafa Assaf & Mahmoud Musa.
Inputs: Digital and 4 configurable for Digital or 10 bit Analog Outputs:4 - 8 amp Relays or 700ma Transistors (1 PWM) 4 Line by 18 Character fully.
DB2 Tools Pertemuan 3 Matakuliah: T0413 Tahun: 2009.
Design and Development of High Performance PC Based Logic Analyzer MSc Project by Rab Nawaz Advisor: Dr. Shahid Masud.
1 of 6 Parts of Your Notebook Below is a graphic overview of the different parts of a OneNote 2007 notebook. Microsoft ® OneNote ® 2007 notebooks are digital.
LAUNCHXL2-RM57L – Project 0
Using PDG with e2studio: Example
COMPREHENSIVE Windows Tutorial 10 Improving Your Computer’s Performance.
VC707 Power Bus Reprogramming
1 Chapter Overview Introduction to Windows XP Professional Printing Setting Up Network Printers Connecting to Network Printers Configuring Network Printers.
SKP8CMINI-15,17 Tutorial 1 Software Development Process using HEW4
Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved. Using a Renesas Code Generation Tool for RL78 Devices.
Renesas Technology America Inc. 1 SKP8CMINI Tutorial 1 Introduction.
M16C/Tiny SKP Tutorial 1 Software Development Process using HEW4
®® Microsoft Windows 7 Windows Tutorial 10 Improving Your Computer’s Performance.
1. 2 LXU800 User’s Manual 1.Installation – Windows XP UI Features Introduction Data Connection & Disconnection.
Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved. Class ID: CL06B Sensors Fundamentals Dragos Bogdan, MCU Application.
Interconnection Protocol Mustafa Kara Term Work.
Part 1 Using the ARM board And start working with C Tutorial 5 and 6
ID A20L:Using Embedded Tools for I2C, SPI, and USB Debugging and Development for Renesas MPU and MCUs Kumaran Santhanam VP Technology Version: 1.1 Total.
Ch 11 Managing System Reliability and Availability 1.
Silicon Labs ToolStick Development Platform
The 6713 DSP Starter Kit (DSK) is a low-cost platform which lets customers evaluate and develop applications for the Texas Instruments C67X DSP family.
Lesson 4 Computer Software
Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved. Class ID: Rapid Development on the Renesas RX63N RDK using.
Using the PSoC USB March 17, 2012 Lloyd Moore, President/Owner.
AT91SAM9261-EK WinCE 6.0 DEMO ATMEL AT91 Application & Support Group
NetBurner MOD 5282 Network Development Kit MCF 5282 Integrated ColdFire 32 bit Microcontoller 2 DB-9 connectors for serial I/O supports: RS-232, RS-485,
SMART Board Demo February 8, Topics Interactive Whiteboards Connecting to the SMART Board SMART Board Basics Using the SMART Board and Tools Helpful.
Please Dial in, class will begin shortly
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Introduction Purpose  This training course provides an overview of the installation and.
COMPUTER SYSTEM LABORATORY Lab10 - Sensor II. Lab 10 Experimental Goal Learn how to write programs on the PTK development board (STM32F207). 2013/11/19/
Hands-On Virtual Computing
U81X0 Downloading Tool Manual 1 ( Version 1.2 ) FlashRW For U81X0 Version 4.0.0(Build #95V) February 2004 LG Electronics Inc.
High Speed Data Converter University
Hands-On Microsoft Windows Server 2008 Chapter 12 Managing System Reliability and Availability.
AT91SAM9261-EK WinCE 5.0 DEMO ATMEL AT91 Application & Support Group Version 1.O February 2007.
1 Chapter Overview Using the New Connection Wizard to configure network and Internet connections Using the New Connection Wizard to configure outbound.
Lab 1 Department of Computer Science and Information Engineering National Taiwan University Lab1 - Sensor 2014/9/23/ 13 1.
The Mechanics Of Computers The Operating System (OS) & Hardware.
Agilent Technologies Copyright 1999 H7211A+221 v Capture Filters, Logging, and Subnets: Module Objectives Create capture filters that control whether.
Development of a microprocessor project with LPC2388 development board.
Getting to Know Your Computer Your File System Applications What’s running on your machine Its own devices Networking.
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Introduction Purpose  This course gives an overview of the Toolchain feature of the High.
SAM9260-EK WinCE DEMO AT91 SAM9 Product Group. Version 1.0 October 2006.
SAM9260-EK WinCE DEMO AT91 SAM9 Product Group. Version 1.0 October 2006.
U81X0 Downloading Tool Manual 1 ( Version 2.0) FlashRW For U81X0 Version 4.0.0(Build #100V) April 2004 LG Electronics Inc.
Debugging TI RTOS TEAM 4 JORGE JIMENEZ JHONY MEDRANO ALBIEN FEZGA.
Part A Final Dor Obstbaum Kami Elbaz Advisor: Moshe Porian August 2012 FPGA S ETTING U SING F LASH.
Renesas Technology America Inc. 1 SKP8CMINI Tutorial 2 Creating A New Project Using HEW.
1 Terminology. 2 Requirements for Network Printing Print server Sufficient RAM to process documents Sufficient disk space on the print server.
Implementation of Embedded OS Lab4 Cortex-M3 Programming.
ChibiOS/RT Demo A free embedded RTOS
Digital Literacy: Computer Basics
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Introduction Purpose  This training course describes Coverage, a utility that is used.
Programming and Debugging with the Dragon and JTAG Many thanks to Dr. James Hawthorne for evaluating the Dragon system and providing the core content for.
Testing and Verifiation of Kmote using Tiny OS Manish Aggarwal Guide :- Proff Purushottam K.
Lets Learn fundamentals !!
DE2-115 Control Panel - Part I
Programming and Debugging with the Dragon and JTAG
Lab 1: Using NIOS II processor for code execution on FPGA
Computer System Laboratory
Implementation of Embedded OS
RX111 Promotion Board (RPB) hands on
Getting Started with Vivado
Introduction to arduino
Presentation transcript:

Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved. Using Embedded Tools for I2C, SPI, and USB Debugging for the Renesas RX63N RDK

© 2012 Renesas Electronics America Inc. All rights reserved.2 Renesas Technology & Solution Portfolio

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

© 2012 Renesas Electronics America Inc. All rights reserved.4 Renesas RX63N RDK

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

© 2012 Renesas Electronics America Inc. All rights reserved.6 Total Phase Development Tools

© 2012 Renesas Electronics America Inc. All rights reserved.7 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

© 2012 Renesas Electronics America Inc. All rights reserved.8 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

© 2012 Renesas Electronics America Inc. All rights reserved.9 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 Control Center Software

© 2012 Renesas Electronics America Inc. All rights reserved.10 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

© 2012 Renesas Electronics America Inc. All rights reserved.11 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

© 2012 Renesas Electronics America Inc. All rights reserved.12 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

© 2012 Renesas Electronics America Inc. All rights reserved.13 Lab Introduction

© 2012 Renesas Electronics America Inc. All rights reserved.14 Lab Introduction Beagle USB 480 Protocol Analyzer Hub Beagle I 2 C/SPI Protocol Analyzer Aardvark I 2 C/SPI Host Adapter EEPROM Activity Board Host Computer External Power Ribbon Cable Renesas RX63N RDK Physical Set Up

© 2012 Renesas Electronics America Inc. All rights reserved.15 Logical Set Up RX63N RDK I 2 C EEPROM I 2 C Bus Beagle I 2 C/SPI Protocol Analyzer PC Aardvark I 2 C/SPI Host Adapter Beagle USB 480 Protocol Analyzer USB Lab Introduction

© 2012 Renesas Electronics America Inc. All rights reserved.16 Beagle Protocol Analyzers

© 2012 Renesas Electronics America Inc. All rights reserved.17 Objective: Introduce the Beagle protocol analyzers Task: Set up and start a live capture using the Data Center Software Beagle Protocol Analyzers

© 2012 Renesas Electronics America Inc. All rights reserved.18 1.Open the Data Center Software. 2. Click Connect to Analyzer. 3. Select the I2C/SPI analyzer and Click OK. Configuring the Beagle analyzer for use Beagle Protocol Analyzers

© 2012 Renesas Electronics America Inc. All rights reserved.19 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. Configuring the Beagle analyzer for us e Beagle Protocol Analyzers

© 2012 Renesas Electronics America Inc. All rights reserved.20 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. Configuring the Beagle analyzer for use Beagle Protocol Analyzers

© 2012 Renesas Electronics America Inc. All rights reserved.21 Aardvark I 2 C/SPI Host Adapter

© 2012 Renesas Electronics America Inc. All rights reserved.22 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.

© 2012 Renesas Electronics America Inc. All rights reserved.23 1.Open the Flash Center Software 2.Click on Add Adapters 3.Select Aardvark I 2 C/SPI Host Adapter 4.Click Add Configuring the Aardvark I 2 C/SPI Host Adapter for use

© 2012 Renesas Electronics America Inc. All rights reserved.24 5.Turn on the Target Power button 6.Click on Choose Target to specify which part you will be using

© 2012 Renesas Electronics America Inc. All rights reserved.25 7.Select I 2 C EEPROM under Device Type 8.Under Manufacturer, select Atmel 9.Under Part Number, choose AT24C02 10.Click OK

© 2012 Renesas Electronics America Inc. All rights reserved Click the Read Target icon 12.Click Erase 13.Select OK 14.Click Read Target again Reading and Erasing the SPI EEPROM Contents

© 2012 Renesas Electronics America Inc. All rights reserved Click the Clear button to clear the local buffer 16.Click into the ASCII editor 17.On the first line, type abcdefghijklmnop Writing Data to the I 2 C EEPROM

© 2012 Renesas Electronics America Inc. All rights reserved Select the Program and Verify icon 19.Click OK if presented with a warning about exceeding capacity 20.Verify the transactions in Data Center

© 2012 Renesas Electronics America Inc. All rights reserved.29 Development Start Up

© 2012 Renesas Electronics America Inc. All rights reserved.30 Objective: Access the project content and application Task: Load and set up the lab project using the e 2 Studio designed by Renesas

© 2012 Renesas Electronics America Inc. All rights reserved.31 1.Open e 2 Studio 2.Select Browse in the Workspace Launcher 3.Browse to C:\ \e2studio- workspace\TPRX63N.work

© 2012 Renesas Electronics America Inc. All rights reserved Select Project Build All 5.Select Run Debug (F11) 6.Select Go (F8)

© 2012 Renesas Electronics America Inc. All rights reserved.33 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 Hub Beagle I 2 C/SPI Protocol Analyzer Aardvark I2 C /SPI Host Adapter EEPROM Activity Board Host Computer External Power Ribbon Cable Renesas RX63N RDK

© 2012 Renesas Electronics America Inc. All rights reserved.34 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 Installing the Driver

© 2012 Renesas Electronics America Inc. All rights reserved Select “Install from a specific location” (If you are running Windows 7, select “Let me pick.”). 12.Click Next Installing the Driver

© 2012 Renesas Electronics America Inc. All rights reserved If asked for the libusb driver, select ‘Browse’ and point to the directory \material\libusb-drivers\x86. Installing the Driver

© 2012 Renesas Electronics America Inc. All rights reserved In Windows Device Manager, check that Windows has enumerated the RX properly. You should have it listed under the “libusb-win32 device” class Installing the Driver

© 2012 Renesas Electronics America Inc. All rights reserved Launch the RX63N LibUSB GUI by double-clicking the launcher C:\ \libusb-gui\launch.bat

© 2012 Renesas Electronics America Inc. All rights reserved.39 Bug 1 – I 2 C to LCD

© 2012 Renesas Electronics America Inc. All rights reserved.40 Problem: The EEPROM data is incorrectly displayed on the LCD screen Task: Use Total Phase tools to diagnose and solve the problem

© 2012 Renesas Electronics America Inc. All rights reserved.41 1.Click LibUSB Connect in the RX63N GUI.

© 2012 Renesas Electronics America Inc. All rights reserved.42 2.Click LED Control 3.Type Aardvark and click Write LCD 4.Click Clear LCD 5.Click I2C to LCD Testing Application Functions

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

© 2012 Renesas Electronics America Inc. All rights reserved.44 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. Solution

© 2012 Renesas Electronics America Inc. All rights reserved.45 6.Make the corrections to source code in line 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; Correcting the source code and verifying the solutio n

© 2012 Renesas Electronics America Inc. All rights reserved.46 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. Correcting the source code and verifying the solution

© 2012 Renesas Electronics America Inc. All rights reserved.47 Bug 2 - Read I 2 C

© 2012 Renesas Electronics America Inc. All rights reserved.48 Problem: Data is incorrectly read from the EEPROM Task: Use Total Phase tools to diagnose and solve the problem

© 2012 Renesas Electronics America Inc. All rights reserved.49 1.Click I2C to GUI Writing and reading from the EEPROM You can see the data is incorrectly displayed in the application.

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

© 2012 Renesas Electronics America Inc. All rights reserved.51 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. Evaluating the I 2 C data

© 2012 Renesas Electronics America Inc. All rights reserved.52 2.Open another Data Center Software 3.Click Connect to Analyzer. 4.Select the USB analyzer and Click OK. Evaluating the USB data using the Beagle USB 480 analyzer

© 2012 Renesas Electronics America Inc. All rights reserved.53 5.Go to Capture Settings and adjust the Data Capture Limit to 700 MB 6. Start the Capture Evaluating the USB data using the Beagle USB 480 analyzer

© 2012 Renesas Electronics America Inc. All rights reserved 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 Reset the device to see the enumeration details

© 2012 Renesas Electronics America Inc. All rights reserved Go to the Filter tab 12. Uncheck Collapsed & SOFs 13. Apply filter Filter out extraneous USB data Only data of interest is displayed in the capture log

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

© 2012 Renesas Electronics America Inc. All rights reserved.57 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. Evaluating the USB data

© 2012 Renesas Electronics America Inc. All rights reserved 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; 234int16_t state; 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); Correcting the source code and verifying the solution

© 2012 Renesas Electronics America Inc. All rights reserved Save and rebuild the project referring to the handout 16.Click Connect in the GUI 17.Click I2C to GUI to verify the solution. Correcting the source code and verifying the solution

© 2012 Renesas Electronics America Inc. All rights reserved.60 Questions and Answers

Renesas Electronics America Inc. © 2012 Renesas Electronics America Inc. All rights reserved.