Skip to content

Commit b2f6df6

Browse files
committed
ESP32: SPI: fix spi close command
Signed-off-by: Davide Bettio <davide@uninstall.it>
1 parent 18aaf94 commit b2f6df6

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ might lead to a crash in certain situations.
2525
certain VM instructions are used.
2626
- Fixed ESP32 GPIO interrupt trigger `none`
2727
- Fixed an issue where a timeout would occur immediately in a race condition
28+
- Fixed SPI close command
2829

2930
## [0.6.5] - 2024-10-15
3031

src/platforms/esp32/components/avm_builtins/spi_driver.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ static NativeHandlerResult spidriver_consume_mailbox(Context *ctx)
672672
globalcontext_get_process_unlock(ctx->global, target);
673673
mailbox_remove_message(&ctx->mailbox, &ctx->heap);
674674

675-
return cmd == CLOSE_ATOM ? NativeTerminate : NativeContinue;
675+
return cmd == SPICloseCmd ? NativeTerminate : NativeContinue;
676676
}
677677

678678
bool spi_driver_get_peripheral(term spi_port, spi_host_device_t *host_dev, GlobalContext *global)

0 commit comments

Comments
 (0)