Skip to content

Commit cf51da2

Browse files
committed
Updating IL9163 to fix cppcheck warnings
1 parent 28d9523 commit cf51da2

File tree

7 files changed

+7
-7
lines changed

7 files changed

+7
-7
lines changed

src/v2/lcd/base/ssd1306_common.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -679,7 +679,7 @@ template <class O, class I> static uint8_t getMaxScreenItems(NanoDisplayOps<O, I
679679
}
680680

681681
template <class O, class I>
682-
static uint8_t calculateScrollPosition(NanoDisplayOps<O, I> &display, SAppMenu *menu, uint8_t selection)
682+
static uint8_t calculateScrollPosition(NanoDisplayOps<O, I> &display, const SAppMenu *menu, uint8_t selection)
683683
{
684684
if ( selection < menu->scrollPosition )
685685
{

src/v2/lcd/il9163/lcd_il9163.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ template <typename I> class InterfaceIL9163: public I
112112
const int8_t m_dc = -1; ///< data/command pin for SPI, -1 for i2c
113113
NanoDisplayBase<InterfaceIL9163<I>> &m_base; ///< basic lcd display support interface
114114
uint8_t m_rotation = 0x00;
115-
static const uint8_t m_rgb_bit = 0b00000000;
115+
uint8_t m_rgb_bit = 0b00000000;
116116
};
117117
/**
118118
* Class implements basic functions for 16-bit mode of IL9163-based displays

src/v2/lcd/sh1106/lcd_sh1106.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ template <class I> void InterfaceSH1106<I>::startBlock(lcduint_t x, lcduint_t y,
3939
commandStart();
4040
this->send(0xB0 | y); // set page
4141
this->send(((x+2)>>4) | 0x10); // high column
42-
this->send(((x+2) & 0x0f) | 0x00); // low column
42+
this->send(((x+2) & 0x0f)); // low column
4343
if ( m_dc >= 0 )
4444
{
4545
setDataMode(1);

src/v2/lcd/sh1107/lcd_sh1107.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ template <class I> void InterfaceSH1107<I>::startBlock(lcduint_t x, lcduint_t y,
3838
m_page = y;
3939
commandStart();
4040
this->send(0xB0 | y); // set page
41-
this->send( ((x + m_seg_offset) & 0x0f ) | 0x00); // low column
41+
this->send( ((x + m_seg_offset) & 0x0f ) ); // low column
4242
this->send((((x + m_seg_offset) >> 4) & 0x07 ) | 0x10); // high column
4343
if ( m_dc >= 0 )
4444
{

tools/templates/lcd/il9163/fields/Interface~CONTROLLER~

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ private:
22
const int8_t m_dc = -1; ///< data/command pin for SPI, -1 for i2c
33
NanoDisplayBase<Interface~CONTROLLER~<I>> &m_base; ///< basic lcd display support interface
44
uint8_t m_rotation = 0x00;
5-
static const uint8_t m_rgb_bit = 0b00000000;
5+
uint8_t m_rgb_bit = 0b00000000;

tools/templates/lcd/sh1106/functions/startBlock/code

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
commandStart();
44
this->send(0xB0 | y); // set page
55
this->send(((x+2)>>4) | 0x10); // high column
6-
this->send(((x+2) & 0x0f) | 0x00); // low column
6+
this->send(((x+2) & 0x0f)); // low column
77
if ( m_dc >= 0 )
88
{
99
setDataMode(1);

tools/templates/lcd/sh1107/functions/startBlock/code

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
m_page = y;
33
commandStart();
44
this->send(0xB0 | y); // set page
5-
this->send( ((x + m_seg_offset) & 0x0f ) | 0x00); // low column
5+
this->send( ((x + m_seg_offset) & 0x0f ) ); // low column
66
this->send((((x + m_seg_offset) >> 4) & 0x07 ) | 0x10); // high column
77
if ( m_dc >= 0 )
88
{

0 commit comments

Comments
 (0)