libsigrok/hardware/serial-dmm
Alexandru Gagniuc 3098b3902d serial-dmm: Simplify wrapper layout
Wrappers for hw_init, hw_cleanup, clear_instances, and hw_scan are needed for
each subdriver due to the nature of serial-dmm. These wrappers are implemented
as macros, in order to reduce the number of lines of code.

For each of those functions, we have a separate wrapper list, then we connect
them together in a first-class driver using a DRV macro, and yet another list
(the DRV list).

Instead of declaring those wrappers in separate lists, include them in the DRV
macro. This approach reduces the number of macro lists from five to just one.

From the perspective of adding a new subdriver, this also greatly reduces the
number of places needed to hook in a new device.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
2012-12-13 23:16:34 +01:00
..
Makefile.am Rename tekpower-dmm to serial-dmm. 2012-12-02 14:21:18 +01:00
api.c serial-dmm: Simplify wrapper layout 2012-12-13 23:16:34 +01:00
protocol.c serial-dmm: Use a macro for receive_data() wrappers. 2012-12-13 01:34:21 +01:00
protocol.h serial-dmm: Use a macro for receive_data() wrappers. 2012-12-13 01:34:21 +01:00