From dbb8c45a9f22ca7b2322fb28b3bdd0e957493896 Mon Sep 17 00:00:00 2001 From: Will Toohey Date: Tue, 6 Apr 2021 20:19:19 +1000 Subject: [PATCH] H44B drv: add missed deinit code, comments --- src/main/aciodrv/h44b.c | 3 +++ src/main/jbio-p4io/h44b.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/src/main/aciodrv/h44b.c b/src/main/aciodrv/h44b.c index 5d68bbf..3df7774 100644 --- a/src/main/aciodrv/h44b.c +++ b/src/main/aciodrv/h44b.c @@ -13,6 +13,8 @@ bool aciodrv_h44b_init( struct aciodrv_device_ctx *device, uint8_t node_id) { + // unlike input devices like KFCA, H44B has no watchdog or special init code + // requirements - shared ACIO node initialisation is enough return true; } @@ -24,6 +26,7 @@ bool aciodrv_h44b_lights( struct ac_io_message msg; log_assert(device); + log_assert(lights); msg.addr = node_id + 1; msg.cmd.code = ac_io_u16(AC_IO_H44B_CMD_SET_OUTPUTS); diff --git a/src/main/jbio-p4io/h44b.c b/src/main/jbio-p4io/h44b.c index 2f54e41..eac3a8a 100644 --- a/src/main/jbio-p4io/h44b.c +++ b/src/main/jbio-p4io/h44b.c @@ -76,6 +76,8 @@ bool jb_io_h44b_init(const char *port, int32_t baud) { } bool jb_io_h44b_fini(void) { + aciomgr_port_fini(acio_manager_ctx); + return true; }