Arduino DLNA Server
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
tiny_dlna::DLNAMediaRenderer< ClientType > Class Template Reference

MediaRenderer DLNA Device. More...

#include <DLNAMediaRenderer.h>

Inheritance diagram for tiny_dlna::DLNAMediaRenderer< ClientType >:
Inheritance graph
[legend]

Classes

struct  ActionRule
 Individual action rule for handling specific actions. More...
 

Public Types

using HttpClient = ClientType
 
using DeviceType = DLNADevice< ClientType >
 
typedef void(* MediaEventHandler) (MediaEvent event, DLNAMediaRenderer &renderer)
 

Public Member Functions

 DLNAMediaRenderer ()
 Default constructor.
 
 DLNAMediaRenderer (IHttpServer &server, IUDPService &udp)
 Recommended constructor Construct a MediaRenderer bound to an HTTP server and IUDPService. The provided references are stored and used when calling begin().
 
bool begin ()
 Start the underlying DLNA device using the stored server/udp.
 
void end ()
 Stops processing and releases resources.
 
bool loop (int loopAction=RUN_ALL)
 Call this from Arduino loop()
 
void setHttpServer (IHttpServer &server)
 Set the http server instance the MediaRenderer should use.
 
void setUdpService (IUDPService &udp)
 Set the UDP service instance the MediaRenderer should use.
 
void setPossiblePlaybackStorageMedia (const char *v)
 Set possible playback storage media (comma-separated list)
 
const char * getPossiblePlaybackStorageMedia () const
 Get possible playback storage media.
 
void setPossibleRecordStorageMedia (const char *v)
 Set possible record storage media (comma-separated list)
 
const char * getPossibleRecordStorageMedia () const
 Get possible record storage media.
 
void setPossibleRecordQualityModes (const char *v)
 Set possible record quality modes (comma-separated list)
 
const char * getPossibleRecordQualityModes () const
 Get possible record quality modes.
 
void setPlayMode (const char *v)
 Set current play mode (e.g. NORMAL, REPEAT_ALL, INTRO)
 
const char * getPlayMode () const
 Get current play mode.
 
bool isActive ()
 Query whether renderer is active (playing)
 
void setActive (bool active)
 Set the active state (used by transport callbacks)
 
const char * getMime ()
 Provides the mime from the DIDL or nullptr.
 
void setMediaEventHandler (MediaEventHandler cb)
 Register application event handler.
 
uint8_t getVolume ()
 Get current volume (0-100)
 
void setVolume (uint8_t vol)
 Set volume and publish event (0-100)
 
bool isMuted ()
 Query mute state.
 
void setMuted (bool mute)
 Set mute state and publish event.
 
const char * getCurrentUri ()
 Access current URI.
 
const char * getCurrentUriMetadata ()
 Access the metadata as string.
 
const char * getTransportState ()
 Get textual transport state.
 
IDevicedevice ()
 Provides access to the internal DLNA device instance.
 
void setSubscriptionsActive (bool flag)
 Enable/disable subscription notifications.
 
bool isSubscriptionsActive ()
 Query whether subscription notifications are active.
 
bool play ()
 Start playback: same as setActive(true)
 
bool play (const char *urlStr)
 Start playback of a network resource (returns true on success)
 
bool setPlaybackURL (const char *urlStr)
 Defines the actual url to play.
 
bool stop ()
 Stop playback.
 
void setPlaybackCompleted ()
 Notify the renderer that playback completed.
 
size_t getRelativeTimePositionSec ()
 Get estimated playback position (seconds)
 
void publishGetRelativeTimePositionSec ()
 Publish the RelativeTimePosition property.
 
const char * getCurrentTransportActions ()
 Get a csv of the valid actions.
 
void setCustomActionRule (const char *suffix, bool(*handler)(DLNAMediaRenderer *, ActionRequest &, IHttpServer &))
 Defines a custom action rule for the media renderer.
 
void setConnectionID (const char *id)
 Set the active ConnectionID for the connection manager.
 
const char * getConnectionID ()
 Return the currently configured ConnectionID.
 
void setProtocols (const char *source, const char *sink="")
 Define the source protocol info: use csv Default is http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_TN,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_SM,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_MED,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_LRG,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HD_50_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HD_60_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HP_HD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_NTSC,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_PAL,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_HD_NA_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_NA_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_EU_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG1,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AAC_MULT5,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AC3,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_CIF15_AAC_520,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_CIF30_AAC_940,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L31_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L32_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L3L_SD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_HP_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_1080i_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_720p_AAC,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_ASP_AAC,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_SP_VGA_AAC,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_60_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_60_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HP_HD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_HD_NA,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_HD_NA_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA_T,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPLL_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPML_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPML_MP3,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_FULL,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_PRO,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_FULL,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_PRO,http-get:*:video/3gpp:DLNA.ORG_PN=MPEG4_P2_3GPP_SP_L0B_AAC,http-get:*:video/3gpp:DLNA.ORG_PN=MPEG4_P2_3GPP_SP_L0B_AMR,http-get:*:audio/mpeg:DLNA.ORG_PN=MP3,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMABASE,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMAFULL,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMAPRO,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMALSL,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMALSL_MULT5,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_ISO_320,http-get:*:audio/3gpp:DLNA.ORG_PN=AAC_ISO_320,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_ISO,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_MULT5_ISO,http-get:*:audio/L16;rate=44100;channels=2:DLNA.ORG_PN=LPCM,http-get:*:image/jpeg:*,http-get:*:video/avi:*,http-get:*:video/divx:*,http-get:*:video/x-matroska:*,http-get:*:video/mpeg:*,http-get:*:video/mp4:*,http-get:*:video/x-ms-wmv:*,http-get:*:video/x-msvideo:*,http-get:*:video/x-flv:*,http-get:*:video/x-tivo-mpeg:*,http-get:*:video/quicktime:*,http-get:*:audio/mp4:*,http-get:*:audio/x-wav:*,http-get:*:audio/x-flac:*,http-get:*:audio/x-dsd:*,http-get:*:application/ogg:http-get::application/vnd.rn-realmedia:http-get::application/vnd.rn-realmedia-vbr:http-get::video/webm:*.
 
const char * getSourceProtocols ()
 Get the current source ProtocolInfo string.
 
const char * getSinkProtocols ()
 Get the current sink ProtocolInfo string.
 
void setTransportDescr (DLNADescr &d)
 Set the transport SCPD descriptor (non-owning reference).
 
DLNADescrgetTransportDescr ()
 Get the transport SCPD descriptor reference.
 
void setControlDescr (DLNADescr &d)
 Set the control SCPD descriptor (non-owning reference).
 
DLNADescrgetControlDescr ()
 Get the control SCPD descriptor reference.
 
void setConnectionMgrDescr (DLNADescr &d)
 Set the ConnectionManager SCPD descriptor (non-owning reference).
 
DLNADescrgetConnectionMgrDescr ()
 Get the ConnectionManager SCPD descriptor reference.
 
size_t print (Print &out, void *ref=nullptr)
 renders the device xml into the provided Print output.
 
void setDeviceType (const char *st)
 
const char * getDeviceType ()
 
void setUDN (const char *id)
 Define the udn uuid.
 
const char * getUDN ()
 Provide the udn uuid.
 
void setBaseURL (const char *url)
 Defines the base url.
 
void setBaseURL (IPAddress ip, int port, const char *path=nullptr)
 Defines the base URL.
 
const char * getBaseURL ()
 Provides the base url.
 
UrlgetDeviceURL ()
 This method returns base url/device.xml.
 
void setIPAddress (IPAddress address)
 Defines the local IP address.
 
IPAddress getIPAddress ()
 Provides the local IP address.
 
const char * getIPStr ()
 Provides the local address as string.
 
void setNS (const char *ns)
 
const char * getNS ()
 
void setFriendlyName (const char *name)
 
const char * getFriendlyName ()
 
void setManufacturer (const char *man)
 
const char * getManufacturer ()
 
void setManufacturerURL (const char *url)
 
const char * getManufacturerURL ()
 
void setModelDescription (const char *descr)
 
const char * getModelDescription ()
 
void setModelName (const char *name)
 
const char * getModelName ()
 
void setModelNumber (const char *number)
 
const char * getModelNumber ()
 
void setSerialNumber (const char *sn)
 
const char * getSerialNumber ()
 
void setUniversalProductCode (const char *upc)
 
const char * getUniversalProductCode ()
 
void addService (DLNAServiceInfo s)
 Adds a service definition.
 
DLNAServiceInfogetService (const char *id)
 Finds a service definition by name.
 
DLNAServiceInfogetServiceByAbbrev (const char *abbrev)
 Finds a service definition by name.
 
Vector< DLNAServiceInfo > & getServices ()
 Provides all service definitions.
 
void clear ()
 Clears all device information.
 
void clearIcons ()
 Overwrite the default icon.
 
void addIcon (Icon icon)
 adds an icon
 
Icon getIcon (int idx=0)
 Provides the item at indix.
 
Vector< Icon > & getIcons ()
 Provides all icons.
 
 operator bool ()
 return true if active
 
virtual bool loop ()
 loop processing
 
void setSubscriptionActive (bool flag)
 
bool isSubscriptionActive ()
 

Protected Member Functions

void addChange (const char *serviceAbbrev, std::function< size_t(Print &, void *)> changeWriter)
 serviceAbbrev: AVT, RCS, CMS
 
void publishAVT ()
 
void publishRCS ()
 Publish the current RenderingControl state (Volume, Mute)
 
void publishCMS ()
 Publish a minimal ConnectionManager state (CurrentConnectionIDs)
 
void setMime (const char *mime)
 Set MIME explicitly (used when DIDL-Lite metadata provides protocolInfo)
 
void setMimeFromDIDL (const char *didl)
 
void setupTransportService (IHttpServer *server)
 
void setupConnectionManagerService (IHttpServer *server)
 
void setupRenderingControlService (IHttpServer *server)
 
void setupServicesImpl (IHttpServer *server)
 Register all services (called when HTTP server is set)
 
bool processAction (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 Process parsed SOAP ActionRequest and dispatch to appropriate handler.
 
bool processActionPlay (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionListPresets (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionPause (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionStop (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetCurrentTransportActions (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetProtocolInfo (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetCurrentConnectionIDs (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetCurrentConnectionInfo (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetDeviceCapabilities (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetTransportInfo (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetPositionInfo (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetTransportSettings (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetMediaInfo (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionSetAVTransportURI (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionSetVolume (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionSetMute (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetMute (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
bool processActionGetVolume (ActionRequest &action, IHttpServer &server, IClientHandler &client)
 
void setupRules ()
 Setup the action handling rules.
 
virtual void setupServices (IHttpServer &server, IUDPService &udp)
 to be implemented by subclasses
 
size_t printRoot (Print &out, void *ref)
 
size_t printDevice (Print &out, void *ref)
 
size_t printSpecVersion (Print &out, void *ref)
 
size_t printServiceList (Print &out, void *ref)
 
size_t printService (Print &out, void *srv)
 
size_t printIconList (Print &out, void *ref)
 
size_t printIconDlnaInfo (Print &out, Icon *icon)
 

Static Protected Member Functions

static void transportDescrCB (IClientHandler &client, IHttpServer *server, const char *requestPath, HttpRequestHandlerLine *hl)
 
static void connmgrDescrCB (IClientHandler &client, IHttpServer *server, const char *requestPath, HttpRequestHandlerLine *hl)
 
static void controlDescrCB (IClientHandler &client, IHttpServer *server, const char *requestPath, HttpRequestHandlerLine *hl)
 
static void controlCB (IClientHandler &client, IHttpServer *server, const char *requestPath, HttpRequestHandlerLine *hl)
 
static DLNAMediaRenderergetRenderer (IHttpServer *server)
 Determine the Renderer with the help of the server.
 
static void eventSubscriptionHandler (IClientHandler &client, IHttpServer *server, const char *requestPath, HttpRequestHandlerLine *hl)
 After the subscription we publish all relevant properties.
 

Protected Attributes

tiny_dlna::Str current_uri
 
tiny_dlna::Str current_mime
 
tiny_dlna::Str current_uri_metadata
 
MediaEventHandler event_cb = nullptr
 
uint8_t current_volume = 50
 
uint8_t muted_volume = 0
 
unsigned long start_time = 0
 
unsigned long time_sum = 0
 
tiny_dlna::Str transport_state = "STOPPED"
 
const char * st = "urn:schemas-upnp-org:device:MediaRenderer:1"
 
const char * usn = "uuid:09349455-2941-4cf7-9847-1dd5ab210e97"
 
DeviceType dlna_device
 
IHttpServerp_server = nullptr
 
IUDPServicep_udp_member = nullptr
 
const char * connectionID = "0"
 
const char * sourceProto = ""
 
const char * sinkProto = DLNA_PROTOCOL_AUDIO
 
const char * possiblePlaybackStorageMedia = "NETWORK"
 
const char * possibleRecordStorageMedia = "NONE"
 
const char * possibleRecordQualityModes = "NOT_IMPLEMENTED"
 
const char * currentPlayMode = "NORMAL"
 
Vector< ActionRulerules
 
DLNAMediaRendererTransportDescr default_transport_desc
 
DLNADescrp_transportDescr = &default_transport_desc
 
DLNAMediaRendererControlDescr default_control_desc
 
DLNADescrp_controlDescr = &default_control_desc
 
DLNAMediaRendererConnectionMgrDescr default_connmgr_desc
 
DLNADescrp_connmgrDescr = &default_connmgr_desc
 
bool is_active = false
 
Url device_url
 
IPAddress localhost
 
int version_major = 1
 
int version_minor = 0
 
Str base_url = "http://localhost:9876/dlna"
 
Str udn = "uuid:09349455-2941-4cf7-9847-0dd5ab210e97"
 
Str ns = "xmlns=\"urn:schemas-upnp-org:device-1-0\""
 
Str device_type
 
Str friendly_name
 
Str manufacturer
 
Str manufacturer_url
 
Str model_description
 
Str model_name
 
Str model_url
 
Str model_number
 
Str serial_number
 
Str universal_product_code
 
Vector< DLNAServiceInfoservices
 
Vector< Iconicons
 
Str url_str
 
bool is_subcription_active = false
 

Detailed Description

template<typename ClientType>
class tiny_dlna::DLNAMediaRenderer< ClientType >

MediaRenderer DLNA Device.

MediaRenderer implements a simple UPnP/DLNA Media Renderer device. It receives stream URIs via UPnP AVTransport actions and delegates actual playback and rendering to the application through an event callback API. This removes any dependency on an internal audio stack: applications handle playback themselves by registering a handler with setMediaEventHandler(). The device still supports rendering controls (volume, mute) and transport controls (play/pause/stop) and provides helper accessors like getCurrentUri() and getMime().

Usage summary:

This class is intentionally small and Arduino-friendly: methods return bool for success/failure and avoid heavy dynamic memory allocations in the hot path.

The template parameter declares the HTTP client type to use for outgoing control and subscription traffic. Supply the client that matches the networking stack in your sketch (for example WiFiClient).

Template Parameters
ClientTypeArduino Client implementation used for outbound HTTP control and event traffic (e.g. WiFiClient, EthernetClient).

Author: Phil Schatzmann

Member Typedef Documentation

◆ DeviceType

template<typename ClientType >
using tiny_dlna::DLNAMediaRenderer< ClientType >::DeviceType = DLNADevice<ClientType>

◆ HttpClient

template<typename ClientType >
using tiny_dlna::DLNAMediaRenderer< ClientType >::HttpClient = ClientType

◆ MediaEventHandler

template<typename ClientType >
typedef void(* tiny_dlna::DLNAMediaRenderer< ClientType >::MediaEventHandler) (MediaEvent event, DLNAMediaRenderer &renderer)

Constructor & Destructor Documentation

◆ DLNAMediaRenderer() [1/2]

template<typename ClientType >
tiny_dlna::DLNAMediaRenderer< ClientType >::DLNAMediaRenderer ( )
inline

Default constructor.

Initializes device metadata (friendly name, manufacturer, model) and sets default base URL and identifiers. It does not configure any audio pipeline components; use setOutput() and setDecoder() for that.

◆ DLNAMediaRenderer() [2/2]

template<typename ClientType >
tiny_dlna::DLNAMediaRenderer< ClientType >::DLNAMediaRenderer ( IHttpServer server,
IUDPService udp 
)
inline

Recommended constructor Construct a MediaRenderer bound to an HTTP server and IUDPService. The provided references are stored and used when calling begin().

Member Function Documentation

◆ addChange()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::addChange ( const char *  serviceAbbrev,
std::function< size_t(Print &, void *)>  changeWriter 
)
inlineprotected

serviceAbbrev: AVT, RCS, CMS

◆ addIcon()

void tiny_dlna::DLNADeviceInfo::addIcon ( Icon  icon)
inlineinherited

adds an icon

◆ addService()

void tiny_dlna::DLNADeviceInfo::addService ( DLNAServiceInfo  s)
inlineinherited

Adds a service definition.

◆ begin()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::begin ( )
inlinevirtual

Start the underlying DLNA device using the stored server/udp.

Reimplemented from tiny_dlna::DLNADeviceInfo.

◆ clear()

void tiny_dlna::DLNADeviceInfo::clear ( )
inlineinherited

Clears all device information.

◆ clearIcons()

void tiny_dlna::DLNADeviceInfo::clearIcons ( )
inlineinherited

Overwrite the default icon.

◆ connmgrDescrCB()

template<typename ClientType >
static void tiny_dlna::DLNAMediaRenderer< ClientType >::connmgrDescrCB ( IClientHandler client,
IHttpServer server,
const char *  requestPath,
HttpRequestHandlerLine hl 
)
inlinestaticprotected

◆ controlCB()

template<typename ClientType >
static void tiny_dlna::DLNAMediaRenderer< ClientType >::controlCB ( IClientHandler client,
IHttpServer server,
const char *  requestPath,
HttpRequestHandlerLine hl 
)
inlinestaticprotected

◆ controlDescrCB()

template<typename ClientType >
static void tiny_dlna::DLNAMediaRenderer< ClientType >::controlDescrCB ( IClientHandler client,
IHttpServer server,
const char *  requestPath,
HttpRequestHandlerLine hl 
)
inlinestaticprotected

◆ device()

template<typename ClientType >
IDevice & tiny_dlna::DLNAMediaRenderer< ClientType >::device ( )
inline

Provides access to the internal DLNA device instance.

◆ end()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::end ( )
inline

Stops processing and releases resources.

◆ eventSubscriptionHandler()

template<typename ClientType >
static void tiny_dlna::DLNAMediaRenderer< ClientType >::eventSubscriptionHandler ( IClientHandler client,
IHttpServer server,
const char *  requestPath,
HttpRequestHandlerLine hl 
)
inlinestaticprotected

After the subscription we publish all relevant properties.

◆ getBaseURL()

const char * tiny_dlna::DLNADeviceInfo::getBaseURL ( )
inlineinherited

Provides the base url.

◆ getConnectionID()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getConnectionID ( )
inline

Return the currently configured ConnectionID.

◆ getConnectionMgrDescr()

template<typename ClientType >
DLNADescr & tiny_dlna::DLNAMediaRenderer< ClientType >::getConnectionMgrDescr ( )
inline

Get the ConnectionManager SCPD descriptor reference.

◆ getControlDescr()

template<typename ClientType >
DLNADescr & tiny_dlna::DLNAMediaRenderer< ClientType >::getControlDescr ( )
inline

Get the control SCPD descriptor reference.

◆ getCurrentTransportActions()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getCurrentTransportActions ( )
inline

Get a csv of the valid actions.

◆ getCurrentUri()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getCurrentUri ( )
inline

Access current URI.

◆ getCurrentUriMetadata()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getCurrentUriMetadata ( )
inline

Access the metadata as string.

◆ getDeviceType()

const char * tiny_dlna::DLNADeviceInfo::getDeviceType ( )
inlineinherited

◆ getDeviceURL()

Url & tiny_dlna::DLNADeviceInfo::getDeviceURL ( )
inlineinherited

This method returns base url/device.xml.

◆ getFriendlyName()

const char * tiny_dlna::DLNADeviceInfo::getFriendlyName ( )
inlineinherited

◆ getIcon()

Icon tiny_dlna::DLNADeviceInfo::getIcon ( int  idx = 0)
inlineinherited

Provides the item at indix.

◆ getIcons()

Vector< Icon > & tiny_dlna::DLNADeviceInfo::getIcons ( )
inlineinherited

Provides all icons.

◆ getIPAddress()

IPAddress tiny_dlna::DLNADeviceInfo::getIPAddress ( )
inlineinherited

Provides the local IP address.

◆ getIPStr()

const char * tiny_dlna::DLNADeviceInfo::getIPStr ( )
inlineinherited

Provides the local address as string.

◆ getManufacturer()

const char * tiny_dlna::DLNADeviceInfo::getManufacturer ( )
inlineinherited

◆ getManufacturerURL()

const char * tiny_dlna::DLNADeviceInfo::getManufacturerURL ( )
inlineinherited

◆ getMime()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getMime ( )
inline

Provides the mime from the DIDL or nullptr.

◆ getModelDescription()

const char * tiny_dlna::DLNADeviceInfo::getModelDescription ( )
inlineinherited

◆ getModelName()

const char * tiny_dlna::DLNADeviceInfo::getModelName ( )
inlineinherited

◆ getModelNumber()

const char * tiny_dlna::DLNADeviceInfo::getModelNumber ( )
inlineinherited

◆ getNS()

const char * tiny_dlna::DLNADeviceInfo::getNS ( )
inlineinherited

◆ getPlayMode()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getPlayMode ( ) const
inline

Get current play mode.

◆ getPossiblePlaybackStorageMedia()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getPossiblePlaybackStorageMedia ( ) const
inline

Get possible playback storage media.

◆ getPossibleRecordQualityModes()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getPossibleRecordQualityModes ( ) const
inline

Get possible record quality modes.

◆ getPossibleRecordStorageMedia()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getPossibleRecordStorageMedia ( ) const
inline

Get possible record storage media.

◆ getRelativeTimePositionSec()

template<typename ClientType >
size_t tiny_dlna::DLNAMediaRenderer< ClientType >::getRelativeTimePositionSec ( )
inline

Get estimated playback position (seconds)

◆ getRenderer()

template<typename ClientType >
static DLNAMediaRenderer * tiny_dlna::DLNAMediaRenderer< ClientType >::getRenderer ( IHttpServer server)
inlinestaticprotected

Determine the Renderer with the help of the server.

◆ getSerialNumber()

const char * tiny_dlna::DLNADeviceInfo::getSerialNumber ( )
inlineinherited

◆ getService()

DLNAServiceInfo & tiny_dlna::DLNADeviceInfo::getService ( const char *  id)
inlineinherited

Finds a service definition by name.

◆ getServiceByAbbrev()

DLNAServiceInfo & tiny_dlna::DLNADeviceInfo::getServiceByAbbrev ( const char *  abbrev)
inlineinherited

Finds a service definition by name.

◆ getServices()

Vector< DLNAServiceInfo > & tiny_dlna::DLNADeviceInfo::getServices ( )
inlineinherited

Provides all service definitions.

◆ getSinkProtocols()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getSinkProtocols ( )
inline

Get the current sink ProtocolInfo string.

◆ getSourceProtocols()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getSourceProtocols ( )
inline

Get the current source ProtocolInfo string.

◆ getTransportDescr()

template<typename ClientType >
DLNADescr & tiny_dlna::DLNAMediaRenderer< ClientType >::getTransportDescr ( )
inline

Get the transport SCPD descriptor reference.

◆ getTransportState()

template<typename ClientType >
const char * tiny_dlna::DLNAMediaRenderer< ClientType >::getTransportState ( )
inline

Get textual transport state.

◆ getUDN()

const char * tiny_dlna::DLNADeviceInfo::getUDN ( )
inlineinherited

Provide the udn uuid.

◆ getUniversalProductCode()

const char * tiny_dlna::DLNADeviceInfo::getUniversalProductCode ( )
inlineinherited

◆ getVolume()

template<typename ClientType >
uint8_t tiny_dlna::DLNAMediaRenderer< ClientType >::getVolume ( )
inline

Get current volume (0-100)

◆ isActive()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::isActive ( )
inline

Query whether renderer is active (playing)

◆ isMuted()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::isMuted ( )
inline

Query mute state.

◆ isSubscriptionActive()

bool tiny_dlna::DLNADeviceInfo::isSubscriptionActive ( )
inlineinherited

◆ isSubscriptionsActive()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::isSubscriptionsActive ( )
inline

Query whether subscription notifications are active.

◆ loop() [1/2]

virtual bool tiny_dlna::DLNADeviceInfo::loop ( )
inlinevirtualinherited

loop processing

◆ loop() [2/2]

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::loop ( int  loopAction = RUN_ALL)
inline

Call this from Arduino loop()

◆ operator bool()

tiny_dlna::DLNADeviceInfo::operator bool ( )
inlineinherited

return true if active

◆ play() [1/2]

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::play ( )
inline

Start playback: same as setActive(true)

◆ play() [2/2]

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::play ( const char *  urlStr)
inline

Start playback of a network resource (returns true on success)

◆ print()

size_t tiny_dlna::DLNADeviceInfo::print ( Print &  out,
void *  ref = nullptr 
)
inlineinherited

renders the device xml into the provided Print output.

Parameters
outPrint target
refoptional context pointer (passed through to callbacks)

◆ printDevice()

size_t tiny_dlna::DLNADeviceInfo::printDevice ( Print &  out,
void *  ref 
)
inlineprotectedinherited

◆ printIconDlnaInfo()

size_t tiny_dlna::DLNADeviceInfo::printIconDlnaInfo ( Print &  out,
Icon icon 
)
inlineprotectedinherited

◆ printIconList()

size_t tiny_dlna::DLNADeviceInfo::printIconList ( Print &  out,
void *  ref 
)
inlineprotectedinherited

◆ printRoot()

size_t tiny_dlna::DLNADeviceInfo::printRoot ( Print &  out,
void *  ref 
)
inlineprotectedinherited

◆ printService()

size_t tiny_dlna::DLNADeviceInfo::printService ( Print &  out,
void *  srv 
)
inlineprotectedinherited

◆ printServiceList()

size_t tiny_dlna::DLNADeviceInfo::printServiceList ( Print &  out,
void *  ref 
)
inlineprotectedinherited

◆ printSpecVersion()

size_t tiny_dlna::DLNADeviceInfo::printSpecVersion ( Print &  out,
void *  ref 
)
inlineprotectedinherited

◆ processAction()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processAction ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

Process parsed SOAP ActionRequest and dispatch to appropriate handler.

Parameters
actionParsed ActionRequest
serverIHttpServer for reply
Returns
true if action handled, false if not supported

◆ processActionGetCurrentConnectionIDs()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetCurrentConnectionIDs ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetCurrentConnectionInfo()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetCurrentConnectionInfo ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetCurrentTransportActions()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetCurrentTransportActions ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetDeviceCapabilities()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetDeviceCapabilities ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetMediaInfo()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetMediaInfo ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetMute()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetMute ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetPositionInfo()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetPositionInfo ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetProtocolInfo()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetProtocolInfo ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetTransportInfo()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetTransportInfo ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetTransportSettings()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetTransportSettings ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionGetVolume()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionGetVolume ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionListPresets()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionListPresets ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionPause()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionPause ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionPlay()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionPlay ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionSetAVTransportURI()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionSetAVTransportURI ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionSetMute()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionSetMute ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionSetVolume()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionSetVolume ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ processActionStop()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::processActionStop ( ActionRequest action,
IHttpServer server,
IClientHandler client 
)
inlineprotected

◆ publishAVT()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::publishAVT ( )
inlineprotected

Publish the current AVTransport state (TransportState, CurrentTrackURI, RelativeTimePosition, CurrentTransportActions)

◆ publishCMS()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::publishCMS ( )
inlineprotected

Publish a minimal ConnectionManager state (CurrentConnectionIDs)

◆ publishGetRelativeTimePositionSec()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::publishGetRelativeTimePositionSec ( )
inline

Publish the RelativeTimePosition property.

◆ publishRCS()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::publishRCS ( )
inlineprotected

Publish the current RenderingControl state (Volume, Mute)

◆ setActive()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setActive ( bool  active)
inline

Set the active state (used by transport callbacks)

◆ setBaseURL() [1/2]

void tiny_dlna::DLNADeviceInfo::setBaseURL ( const char *  url)
inlineinherited

Defines the base url.

◆ setBaseURL() [2/2]

void tiny_dlna::DLNADeviceInfo::setBaseURL ( IPAddress  ip,
int  port,
const char *  path = nullptr 
)
inlineinherited

Defines the base URL.

◆ setConnectionID()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setConnectionID ( const char *  id)
inline

Set the active ConnectionID for the connection manager.

◆ setConnectionMgrDescr()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setConnectionMgrDescr ( DLNADescr d)
inline

Set the ConnectionManager SCPD descriptor (non-owning reference).

◆ setControlDescr()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setControlDescr ( DLNADescr d)
inline

Set the control SCPD descriptor (non-owning reference).

◆ setCustomActionRule()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setCustomActionRule ( const char *  suffix,
bool(*)(DLNAMediaRenderer< ClientType > *, ActionRequest &, IHttpServer &)  handler 
)
inline

Defines a custom action rule for the media renderer.

◆ setDeviceType()

void tiny_dlna::DLNADeviceInfo::setDeviceType ( const char *  st)
inlineinherited

◆ setFriendlyName()

void tiny_dlna::DLNADeviceInfo::setFriendlyName ( const char *  name)
inlineinherited

◆ setHttpServer()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setHttpServer ( IHttpServer server)
inline

Set the http server instance the MediaRenderer should use.

◆ setIPAddress()

void tiny_dlna::DLNADeviceInfo::setIPAddress ( IPAddress  address)
inlineinherited

Defines the local IP address.

◆ setManufacturer()

void tiny_dlna::DLNADeviceInfo::setManufacturer ( const char *  man)
inlineinherited

◆ setManufacturerURL()

void tiny_dlna::DLNADeviceInfo::setManufacturerURL ( const char *  url)
inlineinherited

◆ setMediaEventHandler()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setMediaEventHandler ( MediaEventHandler  cb)
inline

Register application event handler.

◆ setMime()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setMime ( const char *  mime)
inlineprotected

Set MIME explicitly (used when DIDL-Lite metadata provides protocolInfo)

◆ setMimeFromDIDL()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setMimeFromDIDL ( const char *  didl)
inlineprotected

Try to parse a DIDL-Lite snippet and extract the protocolInfo MIME from the <res> element. If found, set current_mime.

◆ setModelDescription()

void tiny_dlna::DLNADeviceInfo::setModelDescription ( const char *  descr)
inlineinherited

◆ setModelName()

void tiny_dlna::DLNADeviceInfo::setModelName ( const char *  name)
inlineinherited

◆ setModelNumber()

void tiny_dlna::DLNADeviceInfo::setModelNumber ( const char *  number)
inlineinherited

◆ setMuted()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setMuted ( bool  mute)
inline

Set mute state and publish event.

◆ setNS()

void tiny_dlna::DLNADeviceInfo::setNS ( const char *  ns)
inlineinherited

◆ setPlaybackCompleted()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setPlaybackCompleted ( )
inline

Notify the renderer that playback completed.

This helper updates the internal transport state to "STOPPED", marks the renderer inactive, resets the start time, logs the event and notifies the application event handler with MediaEvent::STOP so the application can perform cleanup (release resources, update UI, etc.).

◆ setPlaybackURL()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::setPlaybackURL ( const char *  urlStr)
inline

Defines the actual url to play.

◆ setPlayMode()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setPlayMode ( const char *  v)
inline

Set current play mode (e.g. NORMAL, REPEAT_ALL, INTRO)

◆ setPossiblePlaybackStorageMedia()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setPossiblePlaybackStorageMedia ( const char *  v)
inline

Set possible playback storage media (comma-separated list)

◆ setPossibleRecordQualityModes()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setPossibleRecordQualityModes ( const char *  v)
inline

Set possible record quality modes (comma-separated list)

◆ setPossibleRecordStorageMedia()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setPossibleRecordStorageMedia ( const char *  v)
inline

Set possible record storage media (comma-separated list)

◆ setProtocols()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setProtocols ( const char *  source,
const char *  sink = "" 
)
inline

Define the source protocol info: use csv Default is http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_TN,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_SM,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_MED,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_LRG,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HD_50_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HD_60_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HP_HD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_AC3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_NTSC,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_PAL,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_HD_NA_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_NA_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_EU_ISO,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG1,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AAC_MULT5,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AC3,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_CIF15_AAC_520,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_CIF30_AAC_940,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L31_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L32_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_BL_L3L_SD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_HP_HD_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_1080i_AAC,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_720p_AAC,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_ASP_AAC,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_SP_VGA_AAC,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_60_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_60_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HP_HD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AC3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AC3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_HD_NA,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_HD_NA_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU_T,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA_T,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPLL_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPML_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVSPML_MP3,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_BASE,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_FULL,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_PRO,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_FULL,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_PRO,http-get:*:video/3gpp:DLNA.ORG_PN=MPEG4_P2_3GPP_SP_L0B_AAC,http-get:*:video/3gpp:DLNA.ORG_PN=MPEG4_P2_3GPP_SP_L0B_AMR,http-get:*:audio/mpeg:DLNA.ORG_PN=MP3,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMABASE,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMAFULL,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMAPRO,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMALSL,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMALSL_MULT5,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_ISO_320,http-get:*:audio/3gpp:DLNA.ORG_PN=AAC_ISO_320,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_ISO,http-get:*:audio/mp4:DLNA.ORG_PN=AAC_MULT5_ISO,http-get:*:audio/L16;rate=44100;channels=2:DLNA.ORG_PN=LPCM,http-get:*:image/jpeg:*,http-get:*:video/avi:*,http-get:*:video/divx:*,http-get:*:video/x-matroska:*,http-get:*:video/mpeg:*,http-get:*:video/mp4:*,http-get:*:video/x-ms-wmv:*,http-get:*:video/x-msvideo:*,http-get:*:video/x-flv:*,http-get:*:video/x-tivo-mpeg:*,http-get:*:video/quicktime:*,http-get:*:audio/mp4:*,http-get:*:audio/x-wav:*,http-get:*:audio/x-flac:*,http-get:*:audio/x-dsd:*,http-get:*:application/ogg:http-get::application/vnd.rn-realmedia:http-get::application/vnd.rn-realmedia-vbr:http-get::video/webm:*.

◆ setSerialNumber()

void tiny_dlna::DLNADeviceInfo::setSerialNumber ( const char *  sn)
inlineinherited

◆ setSubscriptionActive()

void tiny_dlna::DLNADeviceInfo::setSubscriptionActive ( bool  flag)
inlineinherited

◆ setSubscriptionsActive()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setSubscriptionsActive ( bool  flag)
inline

Enable/disable subscription notifications.

◆ setTransportDescr()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setTransportDescr ( DLNADescr d)
inline

Set the transport SCPD descriptor (non-owning reference).

◆ setUDN()

void tiny_dlna::DLNADeviceInfo::setUDN ( const char *  id)
inlineinherited

Define the udn uuid.

◆ setUdpService()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setUdpService ( IUDPService udp)
inline

Set the UDP service instance the MediaRenderer should use.

◆ setUniversalProductCode()

void tiny_dlna::DLNADeviceInfo::setUniversalProductCode ( const char *  upc)
inlineinherited

◆ setupConnectionManagerService()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setupConnectionManagerService ( IHttpServer server)
inlineprotected

◆ setupRenderingControlService()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setupRenderingControlService ( IHttpServer server)
inlineprotected

◆ setupRules()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setupRules ( )
inlineprotected

Setup the action handling rules.

◆ setupServices()

virtual void tiny_dlna::DLNADeviceInfo::setupServices ( IHttpServer server,
IUDPService udp 
)
inlineprotectedvirtualinherited

to be implemented by subclasses

◆ setupServicesImpl()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setupServicesImpl ( IHttpServer server)
inlineprotected

Register all services (called when HTTP server is set)

◆ setupTransportService()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setupTransportService ( IHttpServer server)
inlineprotected

◆ setVolume()

template<typename ClientType >
void tiny_dlna::DLNAMediaRenderer< ClientType >::setVolume ( uint8_t  vol)
inline

Set volume and publish event (0-100)

◆ stop()

template<typename ClientType >
bool tiny_dlna::DLNAMediaRenderer< ClientType >::stop ( )
inline

Stop playback.

◆ transportDescrCB()

template<typename ClientType >
static void tiny_dlna::DLNAMediaRenderer< ClientType >::transportDescrCB ( IClientHandler client,
IHttpServer server,
const char *  requestPath,
HttpRequestHandlerLine hl 
)
inlinestaticprotected

Member Data Documentation

◆ base_url

Str tiny_dlna::DLNADeviceInfo::base_url = "http://localhost:9876/dlna"
protectedinherited

◆ connectionID

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::connectionID = "0"
protected

◆ current_mime

template<typename ClientType >
tiny_dlna::Str tiny_dlna::DLNAMediaRenderer< ClientType >::current_mime
protected

◆ current_uri

template<typename ClientType >
tiny_dlna::Str tiny_dlna::DLNAMediaRenderer< ClientType >::current_uri
protected

◆ current_uri_metadata

template<typename ClientType >
tiny_dlna::Str tiny_dlna::DLNAMediaRenderer< ClientType >::current_uri_metadata
protected

◆ current_volume

template<typename ClientType >
uint8_t tiny_dlna::DLNAMediaRenderer< ClientType >::current_volume = 50
protected

◆ currentPlayMode

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::currentPlayMode = "NORMAL"
protected

◆ default_connmgr_desc

template<typename ClientType >
DLNAMediaRendererConnectionMgrDescr tiny_dlna::DLNAMediaRenderer< ClientType >::default_connmgr_desc
protected

◆ default_control_desc

template<typename ClientType >
DLNAMediaRendererControlDescr tiny_dlna::DLNAMediaRenderer< ClientType >::default_control_desc
protected

◆ default_transport_desc

template<typename ClientType >
DLNAMediaRendererTransportDescr tiny_dlna::DLNAMediaRenderer< ClientType >::default_transport_desc
protected

◆ device_type

Str tiny_dlna::DLNADeviceInfo::device_type
protectedinherited

◆ device_url

Url tiny_dlna::DLNADeviceInfo::device_url
protectedinherited

◆ dlna_device

template<typename ClientType >
DeviceType tiny_dlna::DLNAMediaRenderer< ClientType >::dlna_device
protected

◆ event_cb

template<typename ClientType >
MediaEventHandler tiny_dlna::DLNAMediaRenderer< ClientType >::event_cb = nullptr
protected

◆ friendly_name

Str tiny_dlna::DLNADeviceInfo::friendly_name
protectedinherited

◆ icons

Vector<Icon> tiny_dlna::DLNADeviceInfo::icons
protectedinherited

◆ is_active

bool tiny_dlna::DLNADeviceInfo::is_active = false
protectedinherited

◆ is_subcription_active

bool tiny_dlna::DLNADeviceInfo::is_subcription_active = false
protectedinherited

◆ localhost

IPAddress tiny_dlna::DLNADeviceInfo::localhost
protectedinherited

◆ manufacturer

Str tiny_dlna::DLNADeviceInfo::manufacturer
protectedinherited

◆ manufacturer_url

Str tiny_dlna::DLNADeviceInfo::manufacturer_url
protectedinherited

◆ model_description

Str tiny_dlna::DLNADeviceInfo::model_description
protectedinherited

◆ model_name

Str tiny_dlna::DLNADeviceInfo::model_name
protectedinherited

◆ model_number

Str tiny_dlna::DLNADeviceInfo::model_number
protectedinherited

◆ model_url

Str tiny_dlna::DLNADeviceInfo::model_url
protectedinherited

◆ muted_volume

template<typename ClientType >
uint8_t tiny_dlna::DLNAMediaRenderer< ClientType >::muted_volume = 0
protected

◆ ns

Str tiny_dlna::DLNADeviceInfo::ns = "xmlns=\"urn:schemas-upnp-org:device-1-0\""
protectedinherited

◆ p_connmgrDescr

template<typename ClientType >
DLNADescr* tiny_dlna::DLNAMediaRenderer< ClientType >::p_connmgrDescr = &default_connmgr_desc
protected

◆ p_controlDescr

template<typename ClientType >
DLNADescr* tiny_dlna::DLNAMediaRenderer< ClientType >::p_controlDescr = &default_control_desc
protected

◆ p_server

template<typename ClientType >
IHttpServer* tiny_dlna::DLNAMediaRenderer< ClientType >::p_server = nullptr
protected

◆ p_transportDescr

template<typename ClientType >
DLNADescr* tiny_dlna::DLNAMediaRenderer< ClientType >::p_transportDescr = &default_transport_desc
protected

◆ p_udp_member

template<typename ClientType >
IUDPService* tiny_dlna::DLNAMediaRenderer< ClientType >::p_udp_member = nullptr
protected

◆ possiblePlaybackStorageMedia

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::possiblePlaybackStorageMedia = "NETWORK"
protected

◆ possibleRecordQualityModes

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::possibleRecordQualityModes = "NOT_IMPLEMENTED"
protected

◆ possibleRecordStorageMedia

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::possibleRecordStorageMedia = "NONE"
protected

◆ rules

template<typename ClientType >
Vector<ActionRule> tiny_dlna::DLNAMediaRenderer< ClientType >::rules
protected

◆ serial_number

Str tiny_dlna::DLNADeviceInfo::serial_number
protectedinherited

◆ services

Vector<DLNAServiceInfo> tiny_dlna::DLNADeviceInfo::services
protectedinherited

◆ sinkProto

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::sinkProto = DLNA_PROTOCOL_AUDIO
protected

◆ sourceProto

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::sourceProto = ""
protected

◆ st

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::st = "urn:schemas-upnp-org:device:MediaRenderer:1"
protected

◆ start_time

template<typename ClientType >
unsigned long tiny_dlna::DLNAMediaRenderer< ClientType >::start_time = 0
protected

◆ time_sum

template<typename ClientType >
unsigned long tiny_dlna::DLNAMediaRenderer< ClientType >::time_sum = 0
protected

◆ transport_state

template<typename ClientType >
tiny_dlna::Str tiny_dlna::DLNAMediaRenderer< ClientType >::transport_state = "STOPPED"
protected

◆ udn

Str tiny_dlna::DLNADeviceInfo::udn = "uuid:09349455-2941-4cf7-9847-0dd5ab210e97"
protectedinherited

◆ universal_product_code

Str tiny_dlna::DLNADeviceInfo::universal_product_code
protectedinherited

◆ url_str

Str tiny_dlna::DLNADeviceInfo::url_str
protectedinherited

◆ usn

template<typename ClientType >
const char* tiny_dlna::DLNAMediaRenderer< ClientType >::usn = "uuid:09349455-2941-4cf7-9847-1dd5ab210e97"
protected

◆ version_major

int tiny_dlna::DLNADeviceInfo::version_major = 1
protectedinherited

◆ version_minor

int tiny_dlna::DLNADeviceInfo::version_minor = 0
protectedinherited

The documentation for this class was generated from the following file: