Implementation of ADG2404 Driver.
More...
#include <stdio.h>
#include <stdlib.h>
#include "adg2404.h"
#include "no_os_error.h"
#include "no_os_alloc.h"
Implementation of ADG2404 Driver.
- Author
- Antoniu Miclaus (anton.nosp@m.iu.m.nosp@m.iclau.nosp@m.s@an.nosp@m.alog..nosp@m.com)
Copyright 2025(c) Analog Devices, Inc.
SPDX-License-Identifier: BSD-3-Clause
◆ adg2404_enable()
Enable/disable the multiplexer.
- Parameters
-
| dev | - The device structure. |
| enable | - true to enable, false to disable. |
- Returns
- 0 in case of success, negative error code otherwise.
◆ adg2404_init()
Initialize the device.
- Parameters
-
| device | - The device structure. |
| init_param | - The structure that contains the device initial parameters. |
- Returns
- 0 in case of success, negative error code otherwise.
◆ adg2404_remove()
Free the resources allocated by adg2404_init().
- Parameters
-
| dev | - The device structure. |
- Returns
- 0 in case of success, negative error code otherwise.
◆ adg2404_select_channel()
Select the multiplexer channel.
- Parameters
-
| dev | - The device structure. |
| channel | - Channel to select (ADG2404_CH_OFF, ADG2404_S1 to ADG2404_S4). |
- Returns
- 0 in case of success, negative error code otherwise.