|
Zephyr API Documentation 4.3.0-rc1
A Scalable Open Source RTOS
|
#include <string.h>#include <zephyr/devicetree.h>#include <zephyr/drivers/hwinfo.h>#include <zephyr/sys/byteorder.h>#include "ump_stream_responder.h"Macros | |
| #define | BIT_IF(cond, n) |
| #define | MIDI_CI_VERSION_FORMAT_UMP_1_1 0x01 |
| MIDI-CI version identifier for UMP v1.1 devices. | |
Functions | |
| static bool | ep_has_midi1 (const struct ump_endpoint_dt_spec *ep) |
| static bool | ep_has_midi2 (const struct ump_endpoint_dt_spec *ep) |
| static struct midi_ump | make_endpoint_info (const struct ump_endpoint_dt_spec *ep) |
| Build an Endpoint Info Notification Universal MIDI Packet. | |
| static struct midi_ump | make_function_block_info (const struct ump_endpoint_dt_spec *ep, size_t block_num) |
| Build a Function Block Info Notification Universal MIDI Packet. | |
| static size_t | fill_str (struct midi_ump *ump, size_t offset, const char *src, size_t len) |
| Copy an ASCII string into a Universal MIDI Packet while leaving some most significant bytes untouched, such that the caller can set this prefix. | |
| static int | send_string (const struct ump_stream_responder_cfg *cfg, const char *string, uint32_t prefix, size_t offset) |
| Send a string as UMP Stream, possibly splitting into multiple packets if the string length is larger than 1 UMP. | |
| static int | ump_ep_discover (const struct ump_stream_responder_cfg *cfg, const struct midi_ump pkt) |
| Handle Endpoint Discovery messages. | |
| static int | ump_fb_discover_block (const struct ump_stream_responder_cfg *cfg, size_t block_num, uint8_t filter) |
| static int | ump_fb_discover (const struct ump_stream_responder_cfg *cfg, const struct midi_ump pkt) |
| Handle Function Block Discovery messages. | |
| const char * | ump_product_instance_id (void) |
| int | ump_stream_respond (const struct ump_stream_responder_cfg *cfg, const struct midi_ump pkt) |
| Respond to an UMP Stream message. | |
| #define BIT_IF | ( | cond, | |
| n ) |
| #define MIDI_CI_VERSION_FORMAT_UMP_1_1 0x01 |
MIDI-CI version identifier for UMP v1.1 devices.
|
inlinestatic |
|
inlinestatic |
Copy an ASCII string into a Universal MIDI Packet while leaving some most significant bytes untouched, such that the caller can set this prefix.
| ump | The ump into which the string is copied | |
| [in] | offset | Number of bytes from the most-significant side to leave free |
| [in] | src | The source string |
| [in] | len | The length of the source string |
|
inlinestatic |
Build an Endpoint Info Notification Universal MIDI Packet.
|
inlinestatic |
Build a Function Block Info Notification Universal MIDI Packet.
|
inlinestatic |
Send a string as UMP Stream, possibly splitting into multiple packets if the string length is larger than 1 UMP.
| [in] | cfg | The responder configuration |
| [in] | string | The string to send |
| [in] | prefix | The fixed prefix of UMP packets to send |
| [in] | offset | The offset the strings starts in the packet, in bytes |
|
inlinestatic |
Handle Endpoint Discovery messages.
| [in] | cfg | The responder configuration |
| [in] | pkt | The discovery packet to handle |
|
inlinestatic |
Handle Function Block Discovery messages.
| [in] | cfg | The responder configuration |
| [in] | pkt | The discovery packet to handle |
|
inlinestatic |