### Versions

DVBViewer plugin version | %s
Supported DVBViewer versions: | %s
Supported Recording Service versions: | %s

### Plugin actions

This plugin provides a huge amount of actions (more than 200, almost everything that can be done with DVBViewer and Recording Service), however, just the most important ones are described here. To learn more about DVBViewer actions (especially the ones which are not described here), see also this wiki.
Actions are executed via the COM interface of the DVBViewer or via Web interface of Recording Service.

Action | Description
--- | ---
Start | Start DVBViewer
IsConnected | True if DVBViewer ist started and connected to the plugin
IsDVBViewerProcessRunning | True if dvbviewer.exe process is running
GetNumberOfClients | Get the number of clients connected to the DVBViewerService.
WaitUntilPluginIdle | Waits until the plugin is idle and pauses execution of background tasks. Supposed to be called before suspend.
CloseDVBViewer | Closes the application
IsRecording | True if there is a recording running
GetNumberOfActiveRecordings | Returns the number of active recording timers
StopAllActiveRecordings | Terminate all active recording timers
GetTimerDetails | Get the details of one or all recording timers.
AddRecording | Add a recording timer to the DVBViewer timer list.
GetDateOfRecordings | Get the list of recording timer dates. Deprecated, will be removed in a future release - use GetTimerDetails instead.
GetRecordingsIDs | Get a list of recording timer IDs. Deprecated, will be removed in a future release - use GetTimerDetails instead.
GetRecordingDetails | Get a list of all recordings along with their recording details from DVBViewer as well as from Recording Service.
DeleteRecordings | Deletes recordings according to the given search criteria. Might be used to implement a housekeeping of recordings.
GetChannelDetails | Get the technical details of one or all DVBViewer channels
TuneChannel | Tunes DVBViewer to an arbitrary channel with the given channelID
ShowWindow | Shows a OSD Window on the screen.
ShowInfoinTVPic | Show the Infobar in the TVPicture.
DeleteInfoinTVPic | Deletes the Infobar in the TVPicture.
GetSetupValue | Get a setup value of the setup.xml of the DVBViewer.
SendAction | Send an action to the DVBViewer (Values are defined in the action.ini of the DVBViewer)
TaskScheduler | Add the next recording date or all recording dates to the Windows task scheduler (The DVBTaskScheduler can be replaced by this method)
UpdateEPG | Update the EPG database of the DVBViewer
IsEPGUpdating | True while the DVBViewerService is updating the EPG information

### Plugin events

The plugin supports two types of generation events.

1. Compatible to the events.of plugin version 1.2
2. The event messages is splited into the event string and the payload. In this case, a event can be better interpreted by a python script or command.

Both types can be used in parallel Following events can be fired:

Event | Result(s) | Fired by | Description
--- | --- | --- | ---
DVBViewerIsConnected |  | Viewer | The event gets fired when the DVBViewer is connected to the plugin.
Action | Action ID | Viewer | The event gets fired whenever a new action is processed. (Description here)
Channel | ChannelNr | Viewer | The event gets fired on every channelchange
AddRecord | Timer ID | Viewer / Service | The event gets fired whenever a new Timer is added.
TimerListUpdated |  | Viewer / Service | The event gets fired whenever the timer list is changed.
RecordingListUpdated |  | Viewer / Service | The event gets fired whenever the the recording list has changed.
StartRecord | Timer ID, Number of active recordings | Viewer / Service | The event gets fired whenever a recording starts.
EndRecord | Timer ID, Number of active recordings | Viewer / Service | The event gets fired whenever a recording ends.
AllActiveRecordings Finished |  | Viewer / Service | The event gets fired whenever the last active recording finishs.
Window | OSD Window ID | Viewer | The event gets fired whenever a OSD-window is activated.
ControlChange | OSD Window ID, Control ID | Viewer | The event gets fired whenever an OSD Control gets the focus.
SelectedItemChange |  | Viewer | The event gets fired whenever the selectedItem in an OSD list changes.
RDS | RDS Text | Viewer | The event gets fired whenever a new RDS Text arrives.
Playlist | Filename | Viewer | The event gets fired whenever a new playlistitem starts playing.
Playbackstart |  | Viewer | The event gets fired whenever a media playback starts.
PlaybackEnd |  | Viewer | The event gets fired whenever a media playback ends.
Close |  | Viewer | The event gets fired when the DVBViewer is shutting down.
EPGUpdateFinished |  | Viewer | The event gets fired whenever the UpdateEPG action finishs.
PlaystateChange | PlayerState | Viewer | The event gets fired whenever the play state changes. (PLAY, PAUSE or STOP)
RatioChange | Ratio | Viewer | The event gets fired whenever the ratio changes. (133 = 4:3, 178 = 16:9)
DisplayChange | DisplayType | Viewer | The event gets fired whenever the display type changes. (NONE, OSD, TV, DVD, MEDIA, SLIDESHOW, TELETEXT)
RenderPlaystateChange | RendererType, PlaysState | Viewer | The event gets fired whenever the internal playstate changes.
RendererChange | RendererType | Viewer | The event gets fired whenever the renderer changes.
NumberOfClientsChanged |  | Service | The event gets fired whenever the number of clients connected to the service change.
NoClientActive |  | Service | The event gets fired whenever the last client disconnects from the service.
ServiceNotAlive |  | Service | The event gets fired whenever the service not alive.
DVBViewerEventHandlingNotAlive |  | Viewer | The event gets fired whenever the DVBViewer can't sent events.

### Render types and Play states

Follwing tables show the possible RendererTyes and PlaysStates:

RendererType | Type of renderer causing the event
--- | ---
-1 | Ratio changed, PlaysState shows ratio (only on RenderPlaystateChange event)
0 | Unknown
1 | VideoAudioDVD
2 | DVB
3 | MPG2TS

PlaysState | state changed into
--- | ---
0 | Stop
1 | Pause
2 | Play

### Start methods

Two different start methods of the DVBViewer are supported and can be selected in the configuration:

1. Via the COM interface (like plugin version 1.2) - this method is deprecated an no longer recommended!
2. By command line (default).

### Watchdog

This plugin implements a watchdog which detects if the DVBViewer is running, and synchronizes the number of active recording with the internal counter. The watchdog is always enabled and the period of checking can be changed in the configuration (default: 60s). The watchdog is also responsible for monitoring the DVBViewerService. Through the watchdog is at the beginning and end of each recording an event fired.