User Tools

Site Tools


arduino_code_errors

If you want to send us your comments, please do so. Thanks
More on comments


Arduino code errors

long

Make sure long is the first item after the = like in

varA = ((long) varB * varC * varD)/ varE;

Display issues with I2C displays

When the text is not displayed correct check

  • The 5V powersupply
  • The two 10k pullupresistors on SCL and SDA to +5V
  • The adress of the display. It should look like: LiquidCrystal_I2C lcd(0x3F, 20, 4); where 0x3F is the I2C address of the display
  • Test with an other Arduinoboard and display
  • Check LiquidCrystal_I2C.cpp . It should contain, if you are using the LCD_I2C library,:
#define printIIC(args)	Wire.write(args)
inline size_t LiquidCrystal_I2C::write(uint8_t value) {
  send(value, Rs);
  //return 0;
  return 1;
}

Serial.print()

When Serial.print does not show the number represented by the variable, or shows a rectangle, use

Serial.print(somevariable, DEC);

Also BIN, HEX and OCT can be used


Main subjects on this wiki: Linux, Debian, HTML, Microcontrollers, Privacy

RSS
Disclaimer
Privacy statement
Bugs statement
Cookies
Copyright © : 2014 - 2024 Webevaluation.nl and the authors
Changes reserved.

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies
arduino_code_errors.txt · Last modified: 27-05-2020 16:15 by wim