lib/SSD1306_Shim/SSD1306_Shim.cpp
// Issue list of commands to SSD1306, same rules as above re: transactions.
// This is a private function, not exposed.
Issue list of commands to SSD1306, same rules as above re: transactions.
This is a private function, not exposed.
Issue list of commands to SSD1306 same rules as above re : transactions . This is a private function not exposed .
void SSD1306_Shim::ssd1306_commandList(const uint8_t *c, uint8_t n) {
  if (wire) { 
    wire->beginTransmission(i2caddr);
    WIRE_WRITE((uint8_t)0x00); 
    uint8_t bytesOut = 1;
    while (n--) {
      if (bytesOut >= WIRE_MAX) {
        wire->endTransmission();
        wire->beginTransmission(i2caddr);
        WIRE_WRITE((uint8_t)0x00); 
        bytesOut = 1;
      }
      WIRE_WRITE(pgm_read_byte(c++));
      bytesOut++;
    }
    wire->endTransmission();
  } else { 
    SSD1306_MODE_COMMAND
    while (n--)
      SPIwrite(pgm_read_byte(c++));
  }
}
void SSD1306_Shim :: ssd1306_commandList ( const uint8_t * c , uint8_t n ) { if ( wire ) { wire -> beginTransmission ( i2caddr ) ; WIRE_WRITE ( ( uint8_t ) 0x00 ) ; uint8_t bytesOut = 1 ; while ( n -- ) { if ( bytesOut >= WIRE_MAX ) { wire -> endTransmission ( ) ; wire -> beginTransmission ( i2caddr ) ; WIRE_WRITE ( ( uint8_t ) 0x00 ) ; bytesOut = 1 ; } WIRE_WRITE ( pgm_read_byte ( c ++ ) ) ; bytesOut ++ ; } wire -> endTransmission ( ) ; } else { SSD1306_MODE_COMMAND while ( n -- ) SPIwrite ( pgm_read_byte ( c ++ ) ) ; } }
Issue list of commands to SSD1306, same rules as above re: transactions.
Issue list of commands to SSD1306 same rules as above re : transactions .
// I2C // Co = 0, D/C = 0 // Co = 0, D/C = 0 // SPI -- transaction started in calling function