@@ -496,13 +496,58 @@ void Adafruit_SSD1306::Transaction::data(uint8_t byte) { send(false, byte); }
496496/* !
497497 @brief Issue a single low-level command directly to the SSD1306
498498 display, bypassing the library.
499- @param c
499+ @param cmd
500+ Command to issue (0x00 to 0xFF, see datasheet).
501+ @return None (void).
502+ */
503+ void Adafruit_SSD1306::ssd1306_command (uint8_t cmd) {
504+ Transaction trans (*this );
505+ trans.command (cmd);
506+ }
507+
508+ /* !
509+ @brief Issue a two byte low-level command directly to the SSD1306
510+ display, bypassing the library.
511+ @param cmd
512+ Command to issue (0x00 to 0xFF, see datasheet).
513+ @param a
514+ The second byte of the command.
515+ @return None (void).
516+ */
517+ void Adafruit_SSD1306::ssd1306_command (uint8_t cmd, uint8_t a) {
518+ Transaction trans (*this );
519+ trans.command (cmd, a);
520+ }
521+
522+ /* !
523+ @brief Issue a three byte low-level command directly to the SSD1306
524+ display, bypassing the library.
525+ @param cmd
500526 Command to issue (0x00 to 0xFF, see datasheet).
527+ @param a
528+ The second byte of the command.
529+ @param b
530+ The third byte of the command.
531+ @return None (void).
532+ */
533+ void Adafruit_SSD1306::ssd1306_command (uint8_t cmd, uint8_t a, uint8_t b) {
534+ Transaction trans (*this );
535+ trans.command (cmd, a, b);
536+ }
537+
538+ /* !
539+ @brief Issue a multi byte low-level command directly to the SSD1306
540+ display, bypassing the library.
541+ @param cmd
542+ Pointer to command bytes to issue.
543+ @param n
544+ Number of bytes in the command.
501545 @return None (void).
502546*/
503- void Adafruit_SSD1306::ssd1306_command (uint8_t c ) {
547+ void Adafruit_SSD1306::ssd1306_command (const uint8_t *cmd, uint8_t n ) {
504548 Transaction trans (*this );
505- trans.command (c);
549+ while (n--)
550+ trans.command (pgm_read_byte (cmd++));
506551}
507552
508553// ALLOCATE & INIT DISPLAY -------------------------------------------------
0 commit comments