Timer Workflow

Timer Handling

After the EPG the most important item is the timer (See Timer for details). Timers inform the TV Recorder of a show that the user wishes to record, timers can be scheduled locally on the TV Recorder, generated by a series recording, a keyword recording or a one-off recording on the IceTV interactive website.

Timers are handled in a similar fashion to Shows but there is no concept of incremental timer updates, we always send all current timers in each request.

All “Forget” timers will be sent first, these should be deleted, “Record” timers are either new timers or updates to existing timer (or indeed existing timers with no change).

As timers are processed you need to create a queue of updates that need to be sent back to the IceTV server, once the processing is complete you can send all updates in a single PUT request to /shows/timers

NOTE: “Forget” timers that you have processed should be sent back in the update with the state of “completed”, this tells the IceTV server that the TV Recorder has unscheduled the timer.

images/download/attachments/917511/timer_handling_2.png

Timers pass through a number of states during their lifetime, these states (and the triggers for change appear below). At each change in state the TV Recorder must send the newly updated timer information to the server.

images/download/attachments/917511/timer_lifecycle_2.png

Local Timers

Timers created locally on the TV Recorder must be sent to the IceTV server, this can be done for a single timer via a POST to /shows/timers or in a batch as a PUT to /shows/timers.

Locally generated timers initially have no id, this will be generated by the server and returned to the client in the response from the request that created them.

The TV Recorder should match the timers in the response to the locally generated timers and update them as needed.