| 1 |
/* |
| 2 |
* Copyright (C) 2010-2021 Team Kodi (https://kodi.tv) |
| 3 |
* Copyright (C) 2010 Alwin Esch (Team Kodi) |
| 4 |
* |
| 5 |
* SPDX-License-Identifier: GPL-2.0-or-later |
| 6 |
* See LICENSE.md for more information. |
| 7 |
*/ |
| 8 |
|
| 9 |
#pragma once |
| 10 |
|
| 11 |
/** Current VNSI Protocol Version number */ |
| 12 |
#define VNSI_PROTOCOLVERSION 13 |
| 13 |
|
| 14 |
/** Start of RDS support protocol Version */ |
| 15 |
#define VNSI_RDS_PROTOCOLVERSION 8 |
| 16 |
|
| 17 |
/** Minimum VNSI Protocol Version number */ |
| 18 |
#define VNSI_MIN_PROTOCOLVERSION 5 |
| 19 |
|
| 20 |
/** Packet types */ |
| 21 |
#define VNSI_CHANNEL_REQUEST_RESPONSE 1 |
| 22 |
#define VNSI_CHANNEL_STREAM 2 |
| 23 |
#define VNSI_CHANNEL_KEEPALIVE 3 |
| 24 |
#define VNSI_CHANNEL_NETLOG 4 |
| 25 |
#define VNSI_CHANNEL_STATUS 5 |
| 26 |
#define VNSI_CHANNEL_SCAN 6 |
| 27 |
#define VNSI_CHANNEL_OSD 7 |
| 28 |
|
| 29 |
/** Response packets operation codes */ |
| 30 |
|
| 31 |
#define CONFNAME_PMTTIMEOUT "PmtTimeout" |
| 32 |
#define CONFNAME_TIMESHIFT "Timeshift" |
| 33 |
#define CONFNAME_TIMESHIFTBUFFERSIZE "TimeshiftBufferSize" |
| 34 |
#define CONFNAME_TIMESHIFTBUFFERFILESIZE "TimeshiftBufferFileSize" |
| 35 |
#define CONFNAME_TIMESHIFTBUFFERDIR "TimeshiftBufferDir" |
| 36 |
#define CONFNAME_PLAYRECORDING "PlayRecording" |
| 37 |
#define CONFNAME_AVOIDEPGSCAN "AvoidEPGScan" |
| 38 |
|
| 39 |
/* OPCODE 1 - 19: VNSI network functions for general purpose */ |
| 40 |
#define VNSI_LOGIN 1 |
| 41 |
#define VNSI_GETTIME 2 |
| 42 |
#define VNSI_ENABLESTATUSINTERFACE 3 |
| 43 |
#define VNSI_PING 7 |
| 44 |
#define VNSI_GETSETUP 8 |
| 45 |
#define VNSI_STORESETUP 9 |
| 46 |
#define VNSI_GETSOCKET 10 |
| 47 |
#define VNSI_INVALIDATESOCKET 11 |
| 48 |
|
| 49 |
/* OPCODE 20 - 39: VNSI network functions for live streaming */ |
| 50 |
#define VNSI_CHANNELSTREAM_OPEN 20 |
| 51 |
#define VNSI_CHANNELSTREAM_CLOSE 21 |
| 52 |
#define VNSI_CHANNELSTREAM_SEEK 22 |
| 53 |
#define VNSI_CHANNELSTREAM_STATUS_SOCKET 23 |
| 54 |
#define VNSI_CHANNELSTREAM_STATUS_REQUEST 24 |
| 55 |
|
| 56 |
/* OPCODE 40 - 59: VNSI network functions for recording streaming */ |
| 57 |
#define VNSI_RECSTREAM_OPEN 40 |
| 58 |
#define VNSI_RECSTREAM_CLOSE 41 |
| 59 |
#define VNSI_RECSTREAM_GETBLOCK 42 |
| 60 |
#define VNSI_RECSTREAM_POSTOFRAME 43 |
| 61 |
#define VNSI_RECSTREAM_FRAMETOPOS 44 |
| 62 |
#define VNSI_RECSTREAM_GETIFRAME 45 |
| 63 |
#define VNSI_RECSTREAM_GETLENGTH 46 |
| 64 |
|
| 65 |
/* OPCODE 60 - 79: VNSI network functions for channel access */ |
| 66 |
#define VNSI_CHANNELS_GETCOUNT 61 |
| 67 |
#define VNSI_CHANNELS_GETCHANNELS 63 |
| 68 |
#define VNSI_CHANNELGROUP_GETCOUNT 65 |
| 69 |
#define VNSI_CHANNELGROUP_LIST 66 |
| 70 |
#define VNSI_CHANNELGROUP_MEMBERS 67 |
| 71 |
#define VNSI_CHANNELS_GETCAIDS 68 |
| 72 |
#define VNSI_CHANNELS_GETWHITELIST 69 |
| 73 |
#define VNSI_CHANNELS_GETBLACKLIST 70 |
| 74 |
#define VNSI_CHANNELS_SETWHITELIST 71 |
| 75 |
#define VNSI_CHANNELS_SETBLACKLIST 72 |
| 76 |
|
| 77 |
/* OPCODE 80 - 99: VNSI network functions for timer access */ |
| 78 |
#define VNSI_TIMER_GETCOUNT 80 |
| 79 |
#define VNSI_TIMER_GET 81 |
| 80 |
#define VNSI_TIMER_GETLIST 82 |
| 81 |
#define VNSI_TIMER_ADD 83 |
| 82 |
#define VNSI_TIMER_DELETE 84 |
| 83 |
#define VNSI_TIMER_UPDATE 85 |
| 84 |
#define VNSI_TIMER_GETTYPES 86 |
| 85 |
|
| 86 |
/* OPCODE 100 - 119: VNSI network functions for recording access */ |
| 87 |
#define VNSI_RECORDINGS_DISKSIZE 100 |
| 88 |
#define VNSI_RECORDINGS_GETCOUNT 101 |
| 89 |
#define VNSI_RECORDINGS_GETLIST 102 |
| 90 |
#define VNSI_RECORDINGS_RENAME 103 |
| 91 |
#define VNSI_RECORDINGS_DELETE 104 |
| 92 |
#define VNSI_RECORDINGS_GETEDL 105 |
| 93 |
|
| 94 |
/* OPCODE 120 - 139: VNSI network functions for epg access and manipulating */ |
| 95 |
#define VNSI_EPG_GETFORCHANNEL 120 |
| 96 |
|
| 97 |
/* OPCODE 140 - 159: VNSI network functions for channel scanning */ |
| 98 |
#define VNSI_SCAN_SUPPORTED 140 |
| 99 |
#define VNSI_SCAN_GETCOUNTRIES 141 |
| 100 |
#define VNSI_SCAN_GETSATELLITES 142 |
| 101 |
#define VNSI_SCAN_START 143 |
| 102 |
#define VNSI_SCAN_STOP 144 |
| 103 |
|
| 104 |
/* OPCODE 160 - 179: VNSI network functions for channel scanning */ |
| 105 |
#define VNSI_OSD_CONNECT 160 |
| 106 |
#define VNSI_OSD_DISCONNECT 161 |
| 107 |
#define VNSI_OSD_HITKEY 162 |
| 108 |
|
| 109 |
/* OPCODE 180 - 189: VNSI network functions for deleted recording access */ |
| 110 |
#define VNSI_RECORDINGS_DELETED_ACCESS_SUPPORTED 180 |
| 111 |
#define VNSI_RECORDINGS_DELETED_GETCOUNT 181 |
| 112 |
#define VNSI_RECORDINGS_DELETED_GETLIST 182 |
| 113 |
#define VNSI_RECORDINGS_DELETED_DELETE 183 |
| 114 |
#define VNSI_RECORDINGS_DELETED_UNDELETE 184 |
| 115 |
#define VNSI_RECORDINGS_DELETED_DELETE_ALL 185 |
| 116 |
|
| 117 |
/** Stream packet types (server -> client) */ |
| 118 |
#define VNSI_STREAM_CHANGE 1 |
| 119 |
#define VNSI_STREAM_STATUS 2 |
| 120 |
#define VNSI_STREAM_QUEUESTATUS 3 |
| 121 |
#define VNSI_STREAM_MUXPKT 4 |
| 122 |
#define VNSI_STREAM_SIGNALINFO 5 |
| 123 |
#define VNSI_STREAM_CONTENTINFO 6 |
| 124 |
#define VNSI_STREAM_BUFFERSTATS 7 |
| 125 |
#define VNSI_STREAM_REFTIME 8 |
| 126 |
#define VNSI_STREAM_TIMES 9 |
| 127 |
|
| 128 |
/** Scan packet types (server -> client) */ |
| 129 |
#define VNSI_SCANNER_PERCENTAGE 1 |
| 130 |
#define VNSI_SCANNER_SIGNAL 2 |
| 131 |
#define VNSI_SCANNER_DEVICE 3 |
| 132 |
#define VNSI_SCANNER_TRANSPONDER 4 |
| 133 |
#define VNSI_SCANNER_NEWCHANNEL 5 |
| 134 |
#define VNSI_SCANNER_FINISHED 6 |
| 135 |
#define VNSI_SCANNER_STATUS 7 |
| 136 |
|
| 137 |
/** OSD packet types (server -> client) */ |
| 138 |
#define VNSI_OSD_MOVEWINDOW 1 |
| 139 |
#define VNSI_OSD_CLEAR 2 |
| 140 |
#define VNSI_OSD_OPEN 3 |
| 141 |
#define VNSI_OSD_CLOSE 4 |
| 142 |
#define VNSI_OSD_SETPALETTE 5 |
| 143 |
#define VNSI_OSD_SETBLOCK 6 |
| 144 |
|
| 145 |
/** Status packet types (server -> client) */ |
| 146 |
#define VNSI_STATUS_TIMERCHANGE 1 |
| 147 |
#define VNSI_STATUS_RECORDING 2 |
| 148 |
#define VNSI_STATUS_MESSAGE 3 |
| 149 |
#define VNSI_STATUS_CHANNELCHANGE 4 |
| 150 |
#define VNSI_STATUS_RECORDINGSCHANGE 5 |
| 151 |
#define VNSI_STATUS_EPGCHANGE 6 |
| 152 |
|
| 153 |
/** Timer */ |
| 154 |
#define VNSI_TIMER_TYPE_MAN 1 |
| 155 |
#define VNSI_TIMER_TYPE_MAN_REPEAT 2 |
| 156 |
#define VNSI_TIMER_TYPE_EPG 3 |
| 157 |
#define VNSI_TIMER_TYPE_VPS 4 |
| 158 |
#define VNSI_TIMER_TYPE_EPG_SEARCH 5 |
| 159 |
#define VNSI_TIMER_TYPE_MAN_REPEAT_CHILD 6 |
| 160 |
|
| 161 |
/** Packet return codes */ |
| 162 |
#define VNSI_RET_OK 0 |
| 163 |
#define VNSI_RET_RECRUNNING 1 |
| 164 |
#define VNSI_RET_NOTSUPPORTED 995 |
| 165 |
#define VNSI_RET_DATAUNKNOWN 996 |
| 166 |
#define VNSI_RET_DATALOCKED 997 |
| 167 |
#define VNSI_RET_DATAINVALID 998 |
| 168 |
#define VNSI_RET_ERROR 999 |