Skip to content

Commit 3811195

Browse files
committed
Honor 'blocking' parameter in inky_frame and inky_frame_7 update functions
1 parent cb06a20 commit 3811195

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

libraries/inky_frame/inky_frame.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,11 @@ namespace pimoroni {
6666
}
6767

6868
void InkyFrame::update(bool blocking) {
69-
while(is_busy()) {
69+
while(blocking && is_busy()) {
7070
tight_loop_contents();
7171
}
7272
uc8159.update((PicoGraphics_PenP4 *)this);
73-
while(is_busy()) {
73+
while(blocking && is_busy()) {
7474
tight_loop_contents();
7575
}
7676
uc8159.power_off();

libraries/inky_frame_7/inky_frame_7.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,11 @@ namespace pimoroni {
6565
}
6666

6767
void InkyFrame::update(bool blocking) {
68-
while(is_busy()) {
68+
while(blocking && is_busy()) {
6969
tight_loop_contents();
7070
}
7171
inky73.update((PicoGraphics_PenInky7 *)this);
72-
while(is_busy()) {
72+
while(blocking && is_busy()) {
7373
tight_loop_contents();
7474
}
7575
inky73.power_off();

0 commit comments

Comments
 (0)