element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • 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 & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • 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
      • Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Vietnam
      • 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
Personal Blogs
  • Community Hub
  • More
Personal Blogs
Legacy Personal Blogs Switch from TI-RTOS to SimpleLink POSIX: LCD Display Driver
  • Blog
  • Documents
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Jan Cumps
  • Date Created: 14 May 2018 2:48 PM Date Created
  • Views 1264 views
  • Likes 3 likes
  • Comments 0 comments
  • lcd
  • boosterpack
  • rtos
  • driverlib
  • nokia_5110_lcd
  • msp432
  • simplelink
  • ti-rtos
  • launchpad
Related
Recommended

Switch from TI-RTOS to SimpleLink POSIX: LCD Display Driver

Jan Cumps
Jan Cumps
14 May 2018

A real world migration from TI-RTOS to the POSIX API of TI SimpleLink.

Texas Instruments migrated from the proprietary TI-RTOS to the open POSIX API.

I'm migrating a project that extensively used the TI paradigms to that POSIX API. You're my witness.

image

The blog assumes that you are a TI-RTOS user and want to adapt to the new ways of working.

I know that LCD Display is two times the word display. Get over it.

This time the topic is SimpleLink and MSP432 DriverLib Display Driver related. Not POSIX specific, but an impact of switching to SimpleLink.

This is similar to the EEPROM API topic covered two posts ago.

 

It's going to be a short article because the impact of switching is easy.

The TI-RTOS distribution i was using for the black pre-production MSP432 LaunchPad didn't have an LCD driver. Someone backported it for that release:

 

this port was the work of: John Pocreva

https://e2e.ti.com/support/embedded/tirtos/f/355/t/552357

 

That backport was a great piece of work. I'm saying goodbye to it now though, because SimpleLink has the driver.

 

There's very little that changed. I have to initialise it differently and that's about it.

 

#include <ti/display/DisplayExt.h>

 

    Display_init();
    /* Initialize display and try to open LCD type of display. */
    Display_Params params;
    Display_Params_init(&params);
    params.lineClearMode = DISPLAY_CLEAR_BOTH;
//    Display_Handle hLcd = Display_open(Display_Type_LCD | Display_Type_GRLIB, ¶ms);
    Display_Handle hLcd = Display_open(Display_Type_LCD, &params);
    if (!hLcd) {
        return NULL; // we didn't get a display handle. Check if the following is defined: BOARD_DISPLAY_USE_LCD
    }
    Graphics_Context *context = DisplayExt_getGraphicsContext(hLcd);
    GrContextForegroundSet(context, ClrBlack);
    GrContextBackgroundSet(context, ClrWhite);


    GrClearDisplay(context);
    GrContextFontSet(context, &g_sFontCmss12);

    GrStringDraw(context, "The Breadboard", -1, 10, 15, 0);
    GrStringDraw(context, "Electronic Load", -1, 15, 30, 0);
    GrStringDraw(context, "Copyright Free", -1, 13, 45, 0);
    GrStringDraw(context, "Version 0", -1, 22, 60, 0);


    GrFlush(context);

 

(if you see strange text in this code, it means &params. The syntax highlighter on the forum is playing up lately)

 

That's actually it. By default the display works compatible with UART output. But you can use the graphic libs to draw, position, etc ...

Ah yes, define this symbol (in your project settings) if you want to compile the LCD code in the firmware:

 

BOARD_DISPLAY_USE_LCD

 

Related Blog
Switch from TI-RTOS to SimpleLink POSIX: Threads and Semaphores
Switch from TI-RTOS to SimpleLink POSIX: EEPROM API

Switch from TI-RTOS to SimpleLink POSIX: From MailBox to Message Queue

Switch from TI-RTOS to SimpleLink POSIX: LCD Display Driver
Switch from TI-RTOS to SimpleLink POSIX: Sleep when Idle
  • Sign in to reply
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