Nope, not sure that the channel number is that relevant - it could just be a sequence. If I look at a specific channel (randomly, it's channel file number 120, internally identified as channel_number 834 and named CH NINE UK) and try and trace that, neither of those channel numbers seem to appear elsewhere. However, I can find the channelname:
$ find . | xargs grep NINE
./channels/120: "name": "CH NINE UK",
./dvbtransports/_dev_dvb_adapter1_NXP_TDA1007112560000_H/_dev_dvb_adapter1_NXP_TDA1007112560000_H_d335: "servicename": "CH NINE UK",
./dvbtransports/_dev_dvb_adapter1_NXP_TDA1007112560000_H/_dev_dvb_adapter1_NXP_TDA1007112560000_H_d335: "channelname": "CH NINE UK",
... and those are the only references.
$ more ./dvbtransports/_dev_dvb_adapter1_NXP_TDA1007112560000_H/_dev_dvb_adapter1_NXP_TDA1007112560000_H_d335
{
"service_id": 54069,
"pmt": 259,
"stype": 1,
"scrambled": 0,
"channel": 0,
"provider": "BSkyB",
"servicename": "CH NINE UK",
"channelname": "CH NINE UK",
"mapped": 1,
"dvb_eit_enable": 1,
"pcr": 2352,
"disabled": 0,
"stream": {
"pid": 2352,
"type": "MPEG2VIDEO",
"position": 0
},
"stream": {
"pid": 2353,
"type": "MPEG2AUDIO",
"position": 1,
"language": "eng"
}
}
So it looks like service is mapped to channel based on the string value of the name. However, how you'd go about generating all the numeric values here is anyone's guess - but you may have all of those because you said that you were now discovering services.