Skip to content

Commit

Permalink
Modify setTextXY
Browse files Browse the repository at this point in the history
  • Loading branch information
lanselambor committed Jan 29, 2019
1 parent 31e030e commit 1ff3d33
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions MT3620_Grove_Shield_Library/Sensors/GroveOledDisplay96x96.c
Original file line number Diff line number Diff line change
Expand Up @@ -306,19 +306,9 @@ void setTextXY(unsigned char Row, unsigned char Column)
}
else if (Drive_IC == SH1107G)
{
uint8_t col_l;

if (Column % 2 == 0)
{
col_l = 0x00;
}
else
{
col_l = 0x08;
}
sendCommand((uint8_t)(0xb0 + Row));
sendCommand(col_l);
sendCommand((uint8_t)(0x10 + (Column / 2)));
sendCommand(0xb0 + (Row & 0x0F)); // set page/row
sendCommand(0x10 + ((Column >> 4) & 0x07)); // set column high 3 bytex
sendCommand(Column & 0x0F); // set column low 4 byte
}
}

Expand Down

0 comments on commit 1ff3d33

Please sign in to comment.