You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.0 KiB
39 lines
1.0 KiB
/**
|
|
* Driver for Nokia 5110 SPI LCD display
|
|
*/
|
|
|
|
#ifndef GFX_NOKIA_H
|
|
#define GFX_NOKIA_H
|
|
|
|
/* Pin definitions:
|
|
Most of these pins can be moved to any digital or analog pin.
|
|
DN(MOSI)and SCLK should be left where they are (SPI pins). The
|
|
LED (backlight) pin should remain on a PWM-capable pin. */
|
|
// SCE - Chip select, pin 3 on LCD.
|
|
// RST - Reset, pin 4 on LCD.
|
|
// DC - Data/Command, pin 5 on LCD.
|
|
// DN(MOSI) - Serial data, pin 6 on LCD.
|
|
// SCLK - Serial clock, pin 7 on LCD.
|
|
// LED - Backlight LED, pin 8 on LCD.
|
|
|
|
/* 84x48 LCD Defines: */
|
|
#include <stdbool.h>
|
|
#include <stdint.h>
|
|
#include "utf8.h"
|
|
#include "display_spec.h"
|
|
|
|
// This will actually draw on the display, whatever is currently
|
|
// in the displayMap array.
|
|
void LCD_updateDisplay();
|
|
|
|
// Set contrast can set the LCD Vop to a value between 0 and 127.
|
|
// 40-60 is usually a pretty good range.
|
|
void LCD_setContrast(uint8_t contrast);
|
|
|
|
/* Invert colors */
|
|
void LCD_invertDisplay(bool invert);
|
|
|
|
//This sends the magical commands to the PCD8544
|
|
void LCD_setup(void);
|
|
|
|
#endif // GFX_NOKIA_H
|
|
|