Merge pull request #415 from pimoroni/patch-inky-frame-wait

UC8159: Timeout compiler error fix.
This commit is contained in:
Philip Howard 2022-06-29 15:29:21 +01:00 committed by GitHub
commit c74210286f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 5 deletions

View File

@ -39,10 +39,9 @@ namespace pimoroni {
bool UC8159::is_busy() {
if(BUSY == PIN_UNUSED) {
if(timeout > 0 && absolute_time_diff_us(get_absolute_time(), timeout) > 0) {
if(absolute_time_diff_us(get_absolute_time(), timeout) > 0) {
return true;
} else {
timeout = 0;
return false;
}
}

View File

@ -26,13 +26,13 @@ namespace pimoroni {
// interface pins with our standard defaults where appropriate
uint CS = SPI_BG_FRONT_CS;
uint DC = 28;
uint DC = 28; // 27;
uint SCK = SPI_DEFAULT_SCK;
uint MOSI = SPI_DEFAULT_MOSI;
uint BUSY = PIN_UNUSED;
uint RESET = 27;
uint RESET = 27; //25;
absolute_time_t timeout = 0;
absolute_time_t timeout;
public:
enum colour : uint8_t {