Borrar filtros
Borrar filtros

Print in LCD I2C Arduino in matlab

7 visualizaciones (últimos 30 días)
Khaled Al-Faleh
Khaled Al-Faleh el 25 de Abr. de 2017
Comentada: Justin Primero el 9 de Jun. de 2019
Hi guys, I have a code in arduino and I want to run it by using matlab which display message I'm using arduino lcd i2c and here is my code in arduino please I need to solve this issue .. or can I load my arduino code file in matlab and use it ?
//load libraries
#include <Wire.h>
#include <LCD.h>
#include <LiquidCrystal_I2C.h>
//Define variables
#define I2C_ADDR 0x3F //Define I2C Address where the PCF8574A is
#define BACKLIGHT_PIN 3
#define En_pin 2
#define Rw_pin 1
#define Rs_pin 0
#define D4_pin 4
#define D5_pin 5
#define D6_pin 6
#define D7_pin 7
//Initialise the LCD
LiquidCrystal_I2C lcd(I2C_ADDR, En_pin,Rw_pin,Rs_pin,D4_pin,D5_pin,D6_pin,D7_pin);
void setup()
{
//Define the LCD as 16 column by 2 rows
lcd.begin (16,2);
//Switch on the backlight
lcd.setBacklightPin(BACKLIGHT_PIN,POSITIVE);
lcd.setBacklight(HIGH);
//goto first column (column 0) and first line (Line 0)
lcd.setCursor(0,0);
//Print at cursor Location
lcd.print("Finally!");
//goto first column (column 0) and second line (line 1)
lcd.setCursor(0,1);
lcd.print("Work :)");
}
void loop(){ }
  1 comentario
Justin Primero
Justin Primero el 9 de Jun. de 2019
Have you solved this issue? If yes, I'd like to know how. Thanks.

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Arduino Hardware en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by