• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Microcontrollers » Hercules™ Safety Microcontrollers » Hercules™ Safety Microcontrollers Forum » Using the uart on the USB developper kit.
Share
Hercules™ Safety Microcontrollers
  • Forum
  • E2E Wiki
Options
  • Subscribe via RSS

Forums

Using the uart on the USB developper kit.

This question is answered
Cor Jansen
Posted by Cor Jansen
on Jul 29 2012 13:15 PM
Intellectual665 points

I want to use the uart for communication to my own hardware.

Currently the LINTX and LINRX lines are connected to the FT2232 chip to make a COM link to the host computer (through USB).

Is this connection needed for debugging or for printf support? Or are debugging and standard IO routed through the JTAG port (and through USB)?

If I disconnect the current LINTX and LINRX connectons and connect to my own hardware, what functionality of the development tools will I miss?

Is there a software manual describing the standard IO routing and possible options?

Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Jul 30 2012 08:19 AM
    Expert8985 points

    Cor,

    The SCI connected to the FTDI is not used at all for emulation.

    If you need to use this SCI port, it is available for the end user.

    I often use it with a windows terminal when I want to log stuff out of the micro. (via a USB/COM port)

    Which board/part are you using?

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Jul 30 2012 08:22 AM
    Verified Answer
    Verified by Cor Jansen
    Expert8985 points

    Cor,

    I forgot one point.

    All STDIO function are using the JTAG port.
    For  example, printf will print in a RAM buffer on chip and the debugger will read this buffer via JTAG.
    Note: this is not real time. The debugger will have to stop the CPU execution to be able to read the memory via JTAG.

    One option to make the printf realtime is to over write the printf to print to an SCI port.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Jul 30 2012 08:24 AM
    Intellectual665 points

    That is great!

    I use the RM4 USB evaluation board.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Jul 30 2012 18:20 PM
    Intellectual665 points

    Hello Jean-Marc,

    I did study the help files available at CCS. I understand that I can remap the low level IO functions.

    But it is not clear to me what exactly to do to remap the stdout en stdin functions to the uart.

    Could you please share this information with me? Could you show an example? I'm sure a lot of people would like to do that.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Jul 31 2012 13:18 PM
    Expert8985 points

    Cor,

    I've created a quick project that demonstrate the use of SCI port to perform printf function. 1830.Printf_Serial.zip

    The key element is the file "retarget.c". In this file, the standard fputs and fputc used by printf are re-defined to use the SCI driver.
    The SCI driver and  code initialization are generated using HalCoGen.

    The CCS5 and HalCogen project are included in the zip file.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Jul 31 2012 15:28 PM
    Expert8985 points

    Cor,

    I forgot to provide some additional comments on how it works.

    The file retarget.c has conditional code. It is necessary in the project compiler options to set the symbol "UART_SUPPORT" in order to use the SCI port for printf.
    Other case, the printf will still print in the console within CCS.

    The serial port is setup has:

    115200 bits per second, 8 data bits and 1 stop bit. Of course this can be changed in HalCogen driver for SCI2.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Aug 01 2012 15:50 PM
    Intellectual665 points

    Thanks

    But I have a problem when importing the CCS project. It says ''compiler definition not available'' and I need to install ARMv5.1.

    I can not find out how to check which version is installed.

    And I do not know where to get the correct version.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Aug 01 2012 17:15 PM
    Expert8985 points

    Cor,

    Sorry for this problem.

    Can you tell me which version of CCS and code gen tools (compiler) you are using?

    I will re-create the project with the same environment.

    On my side, I used for this project a Alpha version of the compiler and this is the reason why it is not working for you.

    Again sorry.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Aug 01 2012 18:44 PM
    Intellectual665 points

    CCS 5.2.1 (is this also the compiler version?)

    HalCoGen 3.01.01

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Aug 01 2012 21:58 PM
    Expert8985 points

    Cor,

    The release number you provided me is for Code Composer Studio.

    To find out what compiler is install on your system, please follow these instructions.

    In CCS, open a project and right click on it to select: Resource->General

    Under Advanced Settings, open Compiler version. This will list all version of the compiler.
    Send me this information and I will re-package the project.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Aug 02 2012 03:22 AM
    Intellectual665 points

    it is TI v4.9.5

    Where can I found others or newer versions?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Aug 02 2012 06:45 AM
    Expert8985 points

    To update CCS, go to the help menu and click on install new software.
    Click on Work with and select all available sites.
    Select TI Compiler Update, unclick show only the latest version of available software and select the version you want to install.

    The latest version for the compiler is V5.0.0

    I recommend using this release. A lot of improvement in term of code size and code execution is part of this release, with a better support for FPU.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Aug 02 2012 10:16 AM
    Intellectual665 points

    Hellop Jean-Marc,

    I updated the compiler to 5.0.0 as you suggested.

    When importing your Serial Demo project, it still aborts with the message that I need compiler 5.1

    For existing projects I now can select the 5.0.0 compiler so the update succeeded.

    If I need 5.1, where can I find it? It was not in the list of available versions.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Marc Mifsud
    Posted by Jean-Marc Mifsud
    on Aug 02 2012 11:35 AM
    Expert8985 points

    Cor,

    Here is attached the new version for the project. This time I'm using CGT 5.0.0

    6102.Printf_Serial.zip

    The version 5.1 I was using before is a beta version and it can't be distributed yet.

    Best regards,

    Jean-Marc

    Application Engineer


    If my reply answers your question please click on the green button "Verify Answer".

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Cor Jansen
    Posted by Cor Jansen
    on Aug 02 2012 13:03 PM
    Intellectual665 points

    Hi again

    I still have the problem that when importing the project that it wants compiler version 5.1.

    So I made a new project (using compiler 5.0.0), and copied your files into it. Compiled it and run it on the USB evaluation board.

    I get the printf() message on the CSS console, but I do not see it on the terminal program that connects to the correct COM port.

    I could not figure out if the software writes to the SCI port or LIN port. The USB evaluation board does not have SCI connected.

    So it should be the LIN interface. Is that correct?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
12
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use