Zephyr API Documentation 4.0.0
A Scalable Open Source RTOS
|
Modem CMUX . More...
Data Structures | |
struct | modem_cmux_config |
Contains CMUX instance configuration data. More... | |
struct | modem_cmux_dlci_config |
CMUX DLCI configuration. More... | |
Typedefs | |
typedef void(* | modem_cmux_callback) (struct modem_cmux *cmux, enum modem_cmux_event event, void *user_data) |
Enumerations | |
enum | modem_cmux_event { MODEM_CMUX_EVENT_CONNECTED = 0 , MODEM_CMUX_EVENT_DISCONNECTED } |
Functions | |
void | modem_cmux_init (struct modem_cmux *cmux, const struct modem_cmux_config *config) |
Initialize CMUX instance. | |
struct modem_pipe * | modem_cmux_dlci_init (struct modem_cmux *cmux, struct modem_cmux_dlci *dlci, const struct modem_cmux_dlci_config *config) |
Initialize DLCI instance and register it with CMUX instance. | |
int | modem_cmux_attach (struct modem_cmux *cmux, struct modem_pipe *pipe) |
Attach CMUX instance to pipe. | |
int | modem_cmux_connect (struct modem_cmux *cmux) |
Connect CMUX instance. | |
int | modem_cmux_connect_async (struct modem_cmux *cmux) |
Connect CMUX instance asynchronously. | |
int | modem_cmux_disconnect (struct modem_cmux *cmux) |
Close down and disconnect CMUX instance. | |
int | modem_cmux_disconnect_async (struct modem_cmux *cmux) |
Close down and disconnect CMUX instance asynchronously. | |
void | modem_cmux_release (struct modem_cmux *cmux) |
Release CMUX instance from pipe. | |
Modem CMUX .
typedef void(* modem_cmux_callback) (struct modem_cmux *cmux, enum modem_cmux_event event, void *user_data) |
#include <zephyr/modem/cmux.h>
enum modem_cmux_event |
#include <zephyr/modem/cmux.h>
Enumerator | |
---|---|
MODEM_CMUX_EVENT_CONNECTED | |
MODEM_CMUX_EVENT_DISCONNECTED |
int modem_cmux_attach | ( | struct modem_cmux * | cmux, |
struct modem_pipe * | pipe ) |
#include <zephyr/modem/cmux.h>
Attach CMUX instance to pipe.
cmux | CMUX instance |
pipe | Pipe instance to attach CMUX instance to |
int modem_cmux_connect | ( | struct modem_cmux * | cmux | ) |
#include <zephyr/modem/cmux.h>
Connect CMUX instance.
This will send a CMUX connect request to target on the serial bus. If successful, DLCI channels can be now be opened using modem_pipe_open()
cmux | CMUX instance |
int modem_cmux_connect_async | ( | struct modem_cmux * | cmux | ) |
#include <zephyr/modem/cmux.h>
Connect CMUX instance asynchronously.
This will send a CMUX connect request to target on the serial bus. If successful, DLCI channels can be now be opened using modem_pipe_open().
cmux | CMUX instance |
int modem_cmux_disconnect | ( | struct modem_cmux * | cmux | ) |
#include <zephyr/modem/cmux.h>
Close down and disconnect CMUX instance.
This will close all open DLCI channels, and close down the CMUX connection.
cmux | CMUX instance |
int modem_cmux_disconnect_async | ( | struct modem_cmux * | cmux | ) |
#include <zephyr/modem/cmux.h>
Close down and disconnect CMUX instance asynchronously.
This will close all open DLCI channels, and close down the CMUX connection.
cmux | CMUX instance |
struct modem_pipe * modem_cmux_dlci_init | ( | struct modem_cmux * | cmux, |
struct modem_cmux_dlci * | dlci, | ||
const struct modem_cmux_dlci_config * | config ) |
#include <zephyr/modem/cmux.h>
Initialize DLCI instance and register it with CMUX instance.
cmux | CMUX instance which the DLCI will be registered to |
dlci | DLCI instance which will be registered and configured |
config | Configuration to apply to DLCI instance |
void modem_cmux_init | ( | struct modem_cmux * | cmux, |
const struct modem_cmux_config * | config ) |
#include <zephyr/modem/cmux.h>
Initialize CMUX instance.
cmux | CMUX instance |
config | Configuration to apply to CMUX instance |
void modem_cmux_release | ( | struct modem_cmux * | cmux | ) |
#include <zephyr/modem/cmux.h>
Release CMUX instance from pipe.
Releases the pipe and hard resets the CMUX instance internally. CMUX should be disconnected using modem_cmux_disconnect().
cmux | CMUX instance |