Arduino Forum

Using Arduino => Displays => Topic started by: aaorozco on Feb 25, 2020, 07:56 pm

Title: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 25, 2020, 07:56 pm
Problem: Cannot get Hello World example to work with Arduino mkr wifi  1010 with 16x2 LCD.

I connected 1010 and LCD per description in Hello World code. Also looked at diagram examples I found online using POT and 220 ohm resister. Made sure "TOOLS" tab had wifi mkr 1010 and port being used. The code compiled and uploaded with no errors.  I just get squares. I used the wifi 1010 for other projects and it worked fine. I even tried another 16x2 LCD with  same results.

I than moved the same jumpers and connected the Mega2560 (same pins as 1010) to the same LCD. Changed the "TOOLS" tab to MEGA2650. Code complied and upload. HELLO WORLD worked.

 Need help to see why HELLO WORLD works with MEGA 2560 and not MKR WIFI 1010 using the same configuration.

Thanks

Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: pert on Feb 25, 2020, 09:08 pm
There are multiple LCD libraries, each with their own Hello World example, and multiple types of 16x2 LCDs. We need to know which of each you're using.
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: Paul__B on Feb 25, 2020, 09:55 pm
As well as the code posted according to the instructions (http://arduino.cc/forum/index.php/topic,148850.0.html), the wiring diagram and preferably, a photograph of your assembly taken outdoors in full daylight (but not sun) so that the details can actually be seen.  :smiley-lol:
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 25, 2020, 10:05 pm
Attached is the code used: I believe this is in the example tab.




#include <LiquidCrystal.h>

/*
  LiquidCrystal Library - Hello World

Demonstrates the use a 16x2 LCD display.  The LiquidCrystal
library works with all 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.

This sketch prints "Hello World!" to the LCD
and shows the time.

  The circuit:
* LCD RS pin to digital pin 12
* LCD Enable pin to digital pin 11
* LCD D4 pin to digital pin 5
* LCD D5 pin to digital pin 4
* LCD D6 pin to digital pin 3
* LCD D7 pin to digital pin 2
* LCD R/W pin to ground
* 10K resistor:
* ends to +5V and ground
* wiper to LCD VO pin (pin 3)

Library originally added 18 Apr 2008
by David A. Mellis
library modified 5 Jul 2009
by Limor Fried (http://www.ladyada.net)
example added 9 Jul 2009
by Tom Igoe
modified 22 Nov 2010
by Tom Igoe

This example code is in the public domain.

http://www.arduino.cc/en/Tutorial/LiquidCrystal
*/

// include the library code:
#include <LiquidCrystal.h>

// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup() {
  // set up the LCD's number of columns and rows:
  lcd.begin(16, 2);
  // Print a message to the LCD.
  lcd.print("hello, world!");
}

void loop() {
  // set the cursor to column 0, line 1
  // (note: line 1 is the second row, since counting begins with 0):
  lcd.setCursor(0, 1);
  // print the number of seconds since reset:
  lcd.print(millis()/1000);
}
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 26, 2020, 01:52 am
I used the scroll example with the 1010. Garbage scrolled across the LCD. Same setup as initial stated
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 26, 2020, 07:12 pm

Attached is the circuit used for Hello World. Data LDC7 - 2, LCD 6 - 3, LCD 5 - 4, LCD - 4 -5

Thanks
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 26, 2020, 07:19 pm
attached is the hello world circuit
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 27, 2020, 05:20 pm
Attached is the circuit
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: groundFungus on Feb 27, 2020, 05:28 pm
(https://forum.arduino.cc/index.php?action=dlattach;topic=667130.0;attach=348554)
OP image so we don't have to download it.  How to post images. (https://forum.arduino.cc/index.php?topic=519037.0)

Read the how to use this forum-please read sticky (https://forum.arduino.cc/index.php/topic,148850.0.html) to see how to properly post code.  Remove useless white space and format the code with the IDE autoformat tool (crtl-t or Tools, Auto Format) before posting code.
Title: Re: Cannot get Hello World example to work with Arduino mkr wifi 1010 with 16x2 LCD
Post by: aaorozco on Feb 28, 2020, 05:32 pm
Thank you for your time.

It looks like there is a bad port on the Arduino 1010 that I bought.