Adafruit will not be shipping orders Thanksgiving Day, Thursday November 22, 2018. Expedited orders placed after 11am ET Wednesday November 21 will go out Friday November 23.
0

Arduino – Updated LiquidCrystal library

Lcdblue162Ard Lrg-1
Arduino – LiquidCrystal library, now updated from Adafruit! Include 4-bit and 8-bit modes and more functionality. If you are running Arduino 0016 or earlier, please download the current version of the LiquidCrystal library and install it in your hardware/libraries folder.

The LiquidCrystal library allows you to control LCD displays that are compatible with the Hitachi HD44780 driver. There are many of them out there, and you can usually tell them by the 16-pin interface.


Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, or even use Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for MakeCode, CircuitPython, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.

Join 8,700+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython – Python on Microcontrollers is here!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Follow Adafruit on Instagram for top secret new products, behinds the scenes and more https://www.instagram.com/adafruit/


Maker Business — Spotlight on Makeblock, one of the latest companies to find success in the STEAM market

Wearables — Emphasize the light

Electronics — Avoid serial confusion!

Biohacking — BDNF a Biohackers Best Friend

Python for Microcontrollers — Python powers costumes, and community @circuitpython @micropython @ThePSF #Python

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !



14 Comments

  1. I thought the old library already had 4 and 8 bit modes. What other changes were made, is there a change log?

    Thanks

  2. theres a change log on the developers mailing list. its nearly completely rewritten and works much better.

  3. Looks like a nice rewrite. One feature of the HD44780 driver that no one seems to pay attention to is defining custom characters so it’s nice to see that added.

    Question… why not check the drivers busy flag instead of using fixed delays for each command?

    I wrote a complete library some time ago (which no one seems to use… sigh) that does away with the fixed delays and I found it to be more reliable (and more efficient) than using delays.

    http://www.slashdev.ca/arduino-lcd-library/

  4. for arduino users, a pin is more valuable than 1 ms

  5. I tried compiling the sample HelloWorld sketch and I am getting the following errors:-

    o: In function `loop’:
    C:\DOCUME~1\ckng\LOCALS~1\Temp\build46647.tmp/Temporary_4160_8511.cpp:52: undefined reference to `LiquidCrystal::setCursor(unsigned char, unsigned char)’

    o: In function `setup’:
    C:\DOCUME~1\ckng\LOCALS~1\Temp\build46647.tmp/Temporary_4160_8511.cpp:45: undefined reference to `LiquidCrystal::begin(unsigned char, unsigned char, unsigned char)’

    Couldn’t determine program size: C:\Program Files\Arduino\hardware/tools/avr/bin/avr-size: ‘C:\DOCUME~1\ckng\LOCALS~1\Temp\build46647.tmp\HelloWorld.hex’: No such file

    Can anyone help? I am an Arduino newbie. Thanks!

  6. CK,
    Delete or move the old LiquidCrystal library from the hardware folder.

    -chaz

  7. Does this improved adafruit LCD library support 4×20 modules? I can get the Hello World! sketch to work. But the serial LCD sketch does not seem to display properly. I am using LCDsmartie 5.3 to send winamp track data to the display. But only lines one and three display data. Line one works, but line three only sort of works. When I tell LCDsmartie to put stuff on lines 4 or 2 it is blank or goes to line 3. Bug in the software or am I doing something wrong??

  8. “only lines one and three display data”

    I believe that the 4 line modules work as 2 individually addressed modules if that makes any sense or helps you.

  9. Confused Robot

    I have never programmed a library for the arduino and am just learning c/processing. So I really don’t understand the changes that where made from the original lcd library or how the software works/determines how many lines the display has available so it displays correctly.

    I do know that each line is considered 40 long regardless of how long the visible line is and if you have more than 2 lines they are split 20 on first line, 20 on third line, then 20 on second line and 20 on fourth line. But how the software handles that, if it does, I don’t know. As I understand it one controller can control up to 2×40 or 4×20. The only time you would see dual controllers is on a display with 4×40, etc. lines or more.

  10. please post in the forums for questions / troubleshooting – thx!

  11. Forums? I don’t see a link to a forum…

  12. http://www.ladyada.net/forums/

  13. You say this library is only for Arduino versions later than 16? But 16 is the current version for windows/mac/linux! Can somebody tell me if this works with version 16?

  14. hi joseph – please post up in the forums http://www.ladyada.net/forums/

Sorry, the comment form is closed at this time.