Here are modifications to TivoWebPlus v2.1.b3 to enable it to create a NpkChannelDefinition subobject when it schedules a recording. If a NpkChannelDefinition subobject doesn't exist, my TivoHD will reboot if I try to view, edit or delete a TWP scheduled recording using the Tivo's menus, due to the channel number and call sign being missing from the Tivo's To Do list. (I am able to view/edit/delete the recording using TWP.) I can also get spontaneous reboots, when navigating the Tivo's menus, if a TWP scheduled recording, with a missing channel number and call sign, exists. Neither of these conditions occur with these modifications applied. Note that these modifications were created based on the code fragment, created by jkozee, here.
For manrec.itcl:
Code:
Index: modules/manrec.itcl
===================================================================
RCS file: /cvsroot/tivowebplus/TivoWebPlus/modules/manrec.itcl,v
retrieving revision 1.17.2.13
diff -r1.17.2.13 manrec.itcl
356a357,361
>
> # Create the NpkChannelDefinition subobject.
> # proc create_NpkChannelDefinition contained in the ui_record module.
> loadModule ui_record
> create_NpkChannelDefinition $recording $chnsel
For ui_record.itcl:
Code:
Index: modules/ui_record.itcl
===================================================================
RCS file: /cvsroot/tivowebplus/TivoWebPlus/modules/ui_record.itcl,v
retrieving revision 1.12.2.10
diff -r1.12.2.10 ui_record.itcl
251a252,254
>
> # Create the NpkChannelDefinition subobject.
> create_NpkChannelDefinition $recording $stationfsid
257a261,295
> proc create_NpkChannelDefinition { recordingObj iStationID } {
>
> #
> # For version > 7 need to create a NpkChannelDefinition subobject to avoid system
> # reboots due to missing channel number and call sign in the To Do list.
> #
> # input parameters:
> # recordingObj = newly creating recording dbobj
> # iStationID = internal Tivo station id
> #
>
> if {$::version > 7} {
> if [getStationData chinfo $iStationID 0] {
> set channelNumber $chinfo(stanum)
> set callSign $chinfo(sign)
> } else {
> # If unable to retrieve channelNumber and callSign information set them to "placeholder" values in the
> # NpkChannelDefinition subobject. They will be set to the correct values when the recording begins.
> set channelNumber 9999
> set callSign "NA"
> }
> set major [lindex [split $channelNumber "."] 0]
> set minor [lindex [split $channelNumber "."] 1]
> if {$minor == ""} {
> set xml "<TvBusEnvelope xs:type=\"TvNpkChannelDefinition\"><channelNumber><major>$major</major></channelNumber><strCallSign>$callSign</strCallSign></TvBusEnvelope>"
> } else {
> set xml "<TvBusEnvelope xs:type=\"TvNpkChannelDefinition\"><channelNumber><major>$major</major><minor>$minor</minor></channelNumber><strCallSign>$callSign</strCallSign></TvBusEnvelope>"
> }
> set NpkChannelDefinition [tvidl serialtodb [tvidl xmltoserial $xml]]
> foreach item $NpkChannelDefinition {
> dbobj $recordingObj add NpkChannelDefinition $item
> }
> }
> }
>
Note: I have only tested these on a TivoHD running software version 11.0k.