Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion OLEDDisplay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -762,7 +762,6 @@ void inline OLEDDisplay::drawInternal(int16_t xMove, int16_t yMove, int16_t widt
int16_t xPos = xMove + (i / rasterHeight);
int16_t yPos = ((yMove >> 3) + (i % rasterHeight)) * displayWidth;

int16_t yScreenPos = yMove + yOffset;
int16_t dataPos = xPos + yPos;

if (dataPos >= 0 && dataPos < displayBufferSize &&
Expand Down
4 changes: 2 additions & 2 deletions OLEDDisplay.h
Original file line number Diff line number Diff line change
Expand Up @@ -273,10 +273,10 @@ class OLEDDisplay : public Print {
char *logBuffer = NULL;

// Send a command to the display (low level function)
virtual void sendCommand(uint8_t com) {};
virtual void sendCommand(uint8_t com) {(void)com;};

// Connect to the display
virtual bool connect() {return true;};
virtual bool connect() {return false;};

// Send all the init commands
void sendInitCommands();
Expand Down
5 changes: 3 additions & 2 deletions OLEDDisplayUi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ void OLEDDisplayUi::drawFrame(){
switch (this->state.frameState){
case IN_TRANSITION: {
float progress = (float) this->state.ticksSinceLastStateSwitch / (float) this->ticksPerTransition;
int16_t x, y, x1, y1;
int16_t x = 0, y = 0, x1 = 0, y1 = 0;
switch(this->frameAnimationDirection){
case SLIDE_LEFT:
x = -(this->display->getWidth()) * progress;
Expand Down Expand Up @@ -332,7 +332,7 @@ void OLEDDisplayUi::drawIndicator() {
return;
}

uint8_t posOfHighlightFrame;
uint8_t posOfHighlightFrame = 0;
float indicatorFadeProgress = 0;

// if the indicator needs to be slided in we want to
Expand Down Expand Up @@ -372,6 +372,7 @@ void OLEDDisplayUi::drawIndicator() {
const uint8_t *image;

uint16_t x,y;

for (byte i = 0; i < this->frameCount; i++) {

switch (this->indicatorPosition){
Expand Down
2 changes: 1 addition & 1 deletion SSD1306Wire.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ class SSD1306Wire : public OLEDDisplay {
// If the minBoundY wasn't updated
// we can savely assume that buffer_back[pos] == buffer[pos]
// holdes true for all values of pos
if (minBoundY == ~0) return;
if (minBoundY == (uint8_t)(~0)) return;

sendCommand(COLUMNADDR);
sendCommand(minBoundX);
Expand Down