Skip to content

Commit 83ed59e

Browse files
authored
Merge pull request #289 from NickIOT72/master
Add compatibilty with CH32V203 devices
2 parents 78d6a13 + 7a21306 commit 83ed59e

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

Adafruit_SSD1306.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@
4949
#endif
5050

5151
#if !defined(__ARM_ARCH) && !defined(ENERGIA) && !defined(ESP8266) && \
52-
!defined(ESP32) && !defined(__arc__) && !defined(__RL78__)
52+
!defined(ESP32) && !defined(__arc__) && !defined(__RL78__) && \
53+
!defined(CH32V20x)
5354
#include <util/delay.h>
5455
#endif
5556

@@ -940,7 +941,7 @@ void Adafruit_SSD1306::drawFastVLineInternal(int16_t x, int16_t __y,
940941
}
941942
}
942943
} // endif positive height
943-
} // endif x in bounds
944+
} // endif x in bounds
944945
}
945946

946947
/*!

Adafruit_SSD1306.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@
2525
#define _Adafruit_SSD1306_H_
2626

2727
// ONE of the following three lines must be #defined:
28-
//#define SSD1306_128_64 ///< DEPRECTAED: old way to specify 128x64 screen
28+
// #define SSD1306_128_64 ///< DEPRECTAED: old way to specify 128x64 screen
2929
#define SSD1306_128_32 ///< DEPRECATED: old way to specify 128x32 screen
30-
//#define SSD1306_96_16 ///< DEPRECATED: old way to specify 96x16 screen
30+
// #define SSD1306_96_16 ///< DEPRECATED: old way to specify 96x16 screen
3131
// This establishes the screen dimensions in old Adafruit_SSD1306 sketches
3232
// (NEW CODE SHOULD IGNORE THIS, USE THE CONSTRUCTORS THAT ACCEPT WIDTH
3333
// AND HEIGHT ARGUMENTS).
3434

3535
// Uncomment to disable Adafruit splash logo
36-
//#define SSD1306_NO_SPLASH
36+
// #define SSD1306_NO_SPLASH
3737

3838
#if defined(ARDUINO_STM32_FEATHER)
3939
typedef class HardwareSPI SPIClass;

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ WICED | X | | | No hardware SPI - bitbang onl
5252
ATtiny85 | | X | |
5353
Particle | X | | |
5454
RTduino | X | | |
55+
CH32 RISC-V | X | | |
5556

5657
* ATmega328 : Arduino UNO, Adafruit Pro Trinket, Adafruit Metro 328, Adafruit Metro Mini
5758
* ATmega32u4 : Arduino Leonardo, Arduino Micro, Arduino Yun, Teensy 2.0, Adafruit Flora, Bluefruit Micro
@@ -62,5 +63,6 @@ RTduino | X | | |
6263
* ATtiny85 : Adafruit Gemma, Arduino Gemma, Adafruit Trinket
6364
* Particle: Particle Argon
6465
* RTduino : [RTduino](https://github.com/RTduino/RTduino) is the Arduino ecosystem compatibility layer for [RT-Thread RTOS](https://github.com/RT-Thread/rt-thread) BSPs
66+
* CH32 RISC-V: CH32V203
6567

6668
<!-- END COMPATIBILITY TABLE -->

0 commit comments

Comments
 (0)