Zephyr API Documentation 4.2.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
midi2.h File Reference
#include <stdint.h>
#include <zephyr/audio/midi.h>
#include <zephyr/net/socket.h>
#include <zephyr/posix/poll.h>

Go to the source code of this file.

Data Structures

struct  netmidi2_user
 A username/password pair for user-based authentication. More...
struct  netmidi2_userlist
 A list of users for user-based authentication. More...
struct  netmidi2_session
 A Network MIDI2 session, representing a connection to a peer. More...
struct  netmidi2_ep
 A Network MIDI2.0 Endpoint. More...

Macros

#define NETMIDI2_NONCE_SIZE   16
 Size, in bytes, of the nonce sent to the client for authentication.
#define NETMIDI2_EP_DEFINE(_var_name, _ep_name, _piid, _port)
 Statically declare a Network (UDP) MIDI 2.0 endpoint host.
#define NETMIDI2_EP_DEFINE_WITH_AUTH(_var_name, _ep_name, _piid, _port, _secret)
 Statically declare a Network (UDP) MIDI 2.0 endpoint host, with a predefined shared secret key for authentication.
#define NETMIDI2_EP_DEFINE_WITH_USERS(_var_name, _ep_name, _piid, _port, ...)
 Statically declare a Network (UDP) MIDI 2.0 endpoint host, with a predefined list of users/passwords for authentication.

Enumerations

enum  netmidi2_auth_type { NETMIDI2_AUTH_NONE , NETMIDI2_AUTH_SHARED_SECRET , NETMIDI2_AUTH_USER_PASSWORD }
 Type of authentication in Network MIDI2. More...

Functions

int netmidi2_host_ep_start (struct netmidi2_ep *ep)
 Start hosting a network (UDP) Universal MIDI Packet endpoint.
void netmidi2_broadcast (struct netmidi2_ep *ep, const struct midi_ump ump)
 Send a Universal MIDI Packet to all clients connected to the endpoint.
void netmidi2_send (struct netmidi2_session *sess, const struct midi_ump ump)
 Send a Universal MIDI Packet to a single client.