Samsung channel list format


From SamyGO
Jump to: navigation, search

Channel Lists

Samsung TV Sets store channel information in several files on /mtd_rwarea. The files can be extracted to a usb drive using a hidden built-in export/import function, by pressing Vol- and then holding enter for 5-10 seconds.

Following files are known:

  • map-AirA for analogue terrestrial channels
  • map-AirD for digital terrestrial channels
  • map-CableA for analogue cable channels
  • map-CableD for digital cable channels
  • map-SateD for digital satellite channels
  • clone.bin binary file containing all settings of a TV Set

map-AirD / map-CableD

map-AirD and map-CableD are very similar in their structure. The list always contains a multiple of 1000 entries. If a there are less than a multiple of 1000 entries, the list is filled with null characters. Each entry has a fixed length of 248 bytes, what makes file size also a multiple of 248.000 bytes. The structure of a 248 byte entry is the following (start to count bytes at 1):

  • Byte 1-2: channel number
  • Byte 3-4: VPID
  • Byte 5-6: PCR PID
  • Byte 7: favourite bitmask (&0x01 favourite)
  • Byte 8: Not verified, maybe QAM modulation (0x41 QAM64, 0x42 QAM256)
  • Byte 9: status bitmask (&0x80 active)
  • Byte 10: Service Type (0x01 TV, 0x02 Radio, 0x0C DATA, 0x19 HD)
  • Byte 11-12: SID
  • Byte 13-14: ONID
  • Byte 15-16: NID
  • Byte 24: encryption bitmask (byte 24 & 0x20, encrypted)
  • Byte 27-28: frequency
  • Byte 29-30: logical channel number LCN (used on freeview, uk)
  • Byte 33-34: symbol rate (in ksymb/s)
  • Byte 35-36: bouqet
  • Byte 37-38: TSID
  • Byte 44-243: channel name (100 chars unicode)
  • Byte 245-246: parental lock (0x00 no lock, 0x01 locked)
  • Byte 247: on x79 devices favourite bitmask: &0x01 fav1, &0x02 fav2, &0x04 fav3, &0x08 fav4
  • Byte 248: checksum over bytes 1-247

16-bit fields are big endian.

map-SateD

Number of list entries is always a multiple of 1000, missing entries are filled with null characters. Entry length is fixed to 144 bytes, so file size is a multiple of 144.000 bytes. Fixed length structure consists of the following:

  • Byte 1-2: channel number
  • Byte 3-4: VPID
  • Byte 5-6: PID (same as VPID on video channels)
  • Byte 7: MPEG4 (0x00 on MPEG2, 0x01 on MPEG4 channels)
  • Byte 9-14: 0x0001 0307 0500
  • Byte 15: service type (0x01 TV, 0x02 Radio, 0x0C Data, 0x19 HD)
  • Byte 17-18: SID
  • Byte 19-20: Transponder ID (matched against TransponderDataBase.dat)
  • Byte 21-22: Sat ID (matched against SatDataBase.dat)
  • Byte 23-24: 0x0000
  • Byte 25-26: TSID
  • Byte 27-28: 0x00
  • Byte 29-30: ONID
  • Byte 31-32: 0xFFFF
  • Byte 33-34: ????, 0xFFFF when channel is new, after that an unknown number
  • Byte 35-36: ????, 0xFFFF when channel is new, after that an unknown number
  • Byte 37-138: channel name (50 chars)
  • Byte 139-140: bouqet (always the same for channels of one provider)
  • Byte 142: parental lock marker (not tested yet)
  • Byte 143: favourite bitmask (the lowest 4 bits represent a favourite list from 1-4, if its 1, the channel is on it, if 0, its not)
  • Byte 144: checksum over bytes 1-143

Fields are in big endian 16bit.

Clone.bin

Clone.bin is a binary file containing every setting of a TV, in one single file. Firmware T-CRLPEUHC is known to produce a Clone.bin, when using built-in import/export feature.

The channel block of the file has exactly as many entries as channels are in the list, the block starts at byte offset 0x1342 and its max. length is to byte offset 0x14F59. Empty entries are filled with 0xFF. The structure of the entries is fixed length 81 bytes, consisting of the following:

  • Byte 1-50: channel name (50 chars)
  • Byte 51-52: channel number
  • Byte 53-54: VPID
  • Byte 55-56: PID (mainly same as vpid, differs on radio channels)
  • Byte 57: frequency
  • Byte 58: 0x04
  • Byte 59: MPEG4? (0x01 on SD channels, 0x21 on HD channels)
  • Byte 60-61: NID
  • Byte 62-63: TSID
  • Byte 64-65: ONID
  • Byte 66-67: SID
  • Byte 68-71: 0xFFFF FFFF
  • Byte 72: service type (0x01 TV, 0x02 Radio, 0x19 HD)
  • Byte 73: 0x04
  • Byte 74: seems to be a bitmask, if bitvalue 0x04 is in it, the channel is encrypted, other bits unknown
  • Byte 75: 0x25
  • Byte 76: character length of channel name
  • Byte 77-81: 0x00 0000 0000

In contrast to map-AirD, map-CableD and map-SateD fields are little endian 8bit.