mirror of
https://github.com/jscrane/r65emu.git
synced 2024-12-21 12:29:51 +00:00
display orientation
This commit is contained in:
parent
c8d22f487c
commit
f47148382b
@ -20,7 +20,6 @@ bool hardware_reset() {
|
||||
extern SPIClass SPIRAM_DEV;
|
||||
SPIRAM_DEV.begin();
|
||||
SPIRAM_DEV.setModule(SPIRAM_SPI);
|
||||
// SPIRAM_DEV.setClockDivider(SPI_CLOCK_DIV2);
|
||||
SPIRAM_DEV.setClockDivider(1);
|
||||
SPIRAM_DEV.setDataMode(SPI_MODE0);
|
||||
|
||||
@ -30,7 +29,6 @@ bool hardware_reset() {
|
||||
#if defined(TFT_BACKLIGHT)
|
||||
digitalWrite(TFT_BACKLIGHT, HIGH);
|
||||
#endif
|
||||
utft.InitLCD();
|
||||
|
||||
_cpu->reset();
|
||||
return sd;
|
||||
|
@ -6,9 +6,10 @@
|
||||
|
||||
extern UTFT utft;
|
||||
|
||||
void UTFTDisplay::begin(unsigned bg, unsigned fg) {
|
||||
void UTFTDisplay::begin(unsigned bg, unsigned fg, int orient) {
|
||||
_bg = bg;
|
||||
_fg = fg;
|
||||
utft.InitLCD(orient);
|
||||
_dx = utft.getDisplayXSize();
|
||||
_dy = utft.getDisplayYSize();
|
||||
|
||||
|
@ -1,9 +1,12 @@
|
||||
#ifndef __UTFT_DISPLAY_H__
|
||||
#define __UTFT_DISPLAY_H__
|
||||
|
||||
#define PORTRAIT 0
|
||||
#define LANDSCAPE 1
|
||||
|
||||
class UTFTDisplay {
|
||||
public:
|
||||
void begin(unsigned bg, unsigned fg);
|
||||
void begin(unsigned bg, unsigned fg, int orient = LANDSCAPE);
|
||||
void clear();
|
||||
void error(char *);
|
||||
void status(const char *);
|
||||
|
Loading…
Reference in New Issue
Block a user