This commit is contained in:
e2002
2023-03-10 21:44:34 +03:00
parent 30ded099ae
commit 9ac7b0efc6
5 changed files with 49 additions and 4 deletions

View File

@@ -65,6 +65,8 @@ https://aliexpress.com/item/32965676064.html
- or **GC9A01A** 1.28' 240x240 https://aliexpress.com/item/1005004069703494.html?sku_id=12000029869654615
- or **ILI9488** 3.5' 480x320 SPI https://aliexpress.com/item/1005001999296476.html?sku_id=12000018365356570
- or **ILI9486** (Testing mode) 3.5' 480x320 SPI https://aliexpress.com/item/1005001999296476.html?sku_id=12000018365356568
- or **SSD1322** 2.8' 256x64 SPI https://aliexpress.com/item/1005003480981568.html
(see [Wiki](https://github.com/e2002/yoradio/wiki/Available-display-models) for more details)
##### Controls
- Three tact buttons https://www.aliexpress.com/item/32907144687.html
@@ -222,6 +224,9 @@ Work is in progress...
---
## Version history
#### v0.9.045
- added support for SSD1322 256x64 2.8' OLED display https://aliexpress.com/item/1005003480981568.html
#### v0.9.022
- optimization of the display of the list of stations
- now the playlist size can be changed with one parameter in the yoRadio/src/displays/conf/display<span>_XXXX_</span>conf.h file --> _const ScrollConfig playlistConf_ param #3

View File

@@ -315,6 +315,7 @@ void Jamis_SSD1322::drawPixel(int16_t x, int16_t y, uint16_t color) {
ssd1322_swap(x, y);
y = HEIGHT - y - 1;
break;
default: break;
}
buffer[(x >> 1) + (y)*WIDTH/2] &= (x % 2) ? 0xF0 : 0x0F;
buffer[(x >> 1) + (y)*WIDTH/2] |= (color << (!(x & 1) * 4) );

View File

@@ -33,9 +33,16 @@
#endif
#include <Adafruit_GFX.h>
#define BLACK 0 ///< Draw 'off' pixels
#define WHITE 0xf ///< Draw 'on' pixels
#define GRAY_D 0xd
#define GRAY_B 0xb
#define GRAY_9 0x9
#define GRAY_7 0x7
#define GRAY_5 0x5
#define GRAY_3 0x3
#define GRAY_2 0x2
#define GRAY_1 0x1
#define INVERSE 2 ///< Invert pixels
#define SSD1322_DISPLAYOFF 0xAE

View File

@@ -1,7 +1,7 @@
#ifndef options_h
#define options_h
#define YOVERSION "0.9.042"
#define YOVERSION "0.9.045"
/*******************************************************
DO NOT EDIT THIS FILE.

View File

@@ -12,7 +12,9 @@
#ifndef DEF_SPI_FREQ
#define DEF_SPI_FREQ 16000000UL /* set it to 0 for system default */
#endif
#ifndef SSD1322_GRAYSCALE
#define SSD1322_GRAYSCALE false
#endif
const unsigned char logo [] PROGMEM=
{
0x06, 0x03, 0x00, 0x0f, 0x07, 0x80, 0x1f, 0x8f, 0xc0, 0x1f, 0x8f, 0xc0,
@@ -35,7 +37,37 @@ const unsigned char logo [] PROGMEM=
#include "tools/utf8RusGFX.h"
void DspCore::initDisplay() {
#if !SSD1322_GRAYSCALE
#include "tools/oledcolorfix.h"
#else
config.theme.background = TFT_BG;
#if DSP_INVERT_TITLE
config.theme.meta = TFT_BG;
config.theme.metabg = GRAY_9;
config.theme.metafill = GRAY_9;
#else
config.theme.meta = GRAY_9;
config.theme.metabg = TFT_BG;
config.theme.metafill = TFT_BG;
#endif
config.theme.clock = TFT_FG;
config.theme.weather = GRAY_2;
config.theme.title1 = GRAY_B;
config.theme.title2 = GRAY_3;
config.theme.rssi = GRAY_5;
config.theme.ip = GRAY_2;
config.theme.vol = TFT_FG;
config.theme.bitrate = TFT_FG;
config.theme.digit = TFT_FG;
config.theme.buffer = TFT_FG;
config.theme.volbarout = GRAY_9;
config.theme.volbarin = GRAY_9;
config.theme.plcurrent = TFT_BG;
config.theme.plcurrentbg = GRAY_7;
config.theme.plcurrentfill = GRAY_7;
for(byte i=0;i<5;i++) config.theme.playlist[i] = GRAY_1;
#endif //!SSD1322_GRAYSCALE
begin();
cp437(true);
flip();