Skip to content

Commit 83120eb

Browse files
committed
Actually fix building ports without parallel displays
1 parent f4bb3cc commit 83120eb

File tree

6 files changed

+13
-4
lines changed

6 files changed

+13
-4
lines changed

shared-bindings/displayio/__init__.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,9 @@
4040
#include "shared-bindings/displayio/I2CDisplay.h"
4141
#include "shared-bindings/displayio/OnDiskBitmap.h"
4242
#include "shared-bindings/displayio/Palette.h"
43+
#if CIRCUITPY_PARALLELBUS
4344
#include "shared-bindings/paralleldisplay/ParallelBus.h"
45+
#endif
4446
#include "shared-bindings/displayio/Shape.h"
4547
#include "shared-bindings/displayio/TileGrid.h"
4648

shared-bindings/paralleldisplay/ParallelBus.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@
2424
* THE SOFTWARE.
2525
*/
2626

27-
#ifndef MICROPY_INCLUDED_SHARED_BINDINGS_DISPLAYBUSIO_PARALLELDISPLAY_H
28-
#define MICROPY_INCLUDED_SHARED_BINDINGS_DISPLAYBUSIO_PARALLELDISPLAY_H
27+
#pragma once
2928

3029
#include "common-hal/paralleldisplay/ParallelBus.h"
3130

@@ -50,5 +49,3 @@ void common_hal_paralleldisplay_parallelbus_send(mp_obj_t self, display_byte_typ
5049
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length);
5150

5251
void common_hal_paralleldisplay_parallelbus_end_transaction(mp_obj_t self);
53-
54-
#endif // MICROPY_INCLUDED_SHARED_BINDINGS_DISPLAYBUSIO_PARALLELDISPLAY_H

shared-module/displayio/Display.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@
2929
#include "py/runtime.h"
3030
#include "shared-bindings/displayio/FourWire.h"
3131
#include "shared-bindings/displayio/I2CDisplay.h"
32+
#if CIRCUITPY_PARALLELDISPLAY
3233
#include "shared-bindings/paralleldisplay/ParallelBus.h"
34+
#endif
3335
#include "shared-bindings/microcontroller/Pin.h"
3436
#include "shared-bindings/time/__init__.h"
3537
#include "shared-module/displayio/__init__.h"

shared-module/displayio/EPaperDisplay.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@
3131
#include "shared-bindings/displayio/ColorConverter.h"
3232
#include "shared-bindings/displayio/FourWire.h"
3333
#include "shared-bindings/displayio/I2CDisplay.h"
34+
#if CIRCUITPY_PARALLELDISPLAY
3435
#include "shared-bindings/paralleldisplay/ParallelBus.h"
36+
#endif
3537
#include "shared-bindings/microcontroller/Pin.h"
3638
#include "shared-bindings/time/__init__.h"
3739
#include "shared-module/displayio/__init__.h"

shared-module/displayio/__init__.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@
3535
#include "shared-bindings/displayio/FourWire.h"
3636
#include "shared-bindings/displayio/Group.h"
3737
#include "shared-bindings/displayio/I2CDisplay.h"
38+
#if CIRCUITPY_PARALLELDISPLAY
3839
#include "shared-bindings/paralleldisplay/ParallelBus.h"
40+
#endif
3941
#if CIRCUITPY_RGBMATRIX
4042
#include "shared-bindings/rgbmatrix/RGBMatrix.h"
4143
#endif
@@ -48,7 +50,9 @@ typedef struct {
4850
mp_obj_base_t bus_base;
4951
displayio_fourwire_obj_t fourwire_bus;
5052
displayio_i2cdisplay_obj_t i2cdisplay_bus;
53+
#if CIRCUITPY_PARALLELDISPLAY
5154
paralleldisplay_parallelbus_obj_t parallel_bus;
55+
#endif
5256
#if CIRCUITPY_RGBMATRIX
5357
rgbmatrix_rgbmatrix_obj_t rgbmatrix;
5458
#endif

shared-module/displayio/display_core.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@
3030
#include "py/runtime.h"
3131
#include "shared-bindings/displayio/FourWire.h"
3232
#include "shared-bindings/displayio/I2CDisplay.h"
33+
#if CIRCUITPY_PARALLELDISPLAY
3334
#include "shared-bindings/paralleldisplay/ParallelBus.h"
35+
#endif
3436
#include "shared-bindings/microcontroller/Pin.h"
3537
#include "shared-bindings/time/__init__.h"
3638
#include "shared-module/displayio/__init__.h"

0 commit comments

Comments
 (0)