Wenn ich in der forward.c in get_adapter folgendes ändere, dann zeigt er ein reales Devices an "sasc-ng -i"
0: Sundtek DVB-C
forward.c:
int get_adapters(struct t_adaptermap **adaptermap)
{
int count = 0;
//struct dirent **adptrlist;
int i, n, fd, adapter;
char frontend[30];
struct dvb_frontend_info fe;
n = 1;
*adaptermap = (struct t_adaptermap *)malloc(n * sizeof(struct t_adaptermap));
for(i = 0; i < n; i++) {
if(1 == sscanf("adapter0", "adapter%d", &adapter)) {
snprintf(frontend, 30, "/dev/dvb/adapter%d/frontend0", adapter);
fd = open(frontend, O_RDONLY);
if(fd >= 0) {
if(ioctl(fd, FE_GET_INFO, &fe) >=0) {
//printf("%s\n",fe.name);
(*adaptermap)[count].adapter = adapter;
snprintf((*adaptermap)[count].name, 128, "%s", fe.name);
(*adaptermap)[count].used = 0;
count++;
}
close(fd);
}
}
//free(adptrlist);
}
//free(adptrlist);
if(count == 0)
free(*adaptermap);
return count;
}
Das Problem ist aber glaube ich, dass er keine neuen devices unter adapter1 anlegen kann?(Ist das so?)
In init_parser ist das Problem dann hier:
stat(realdev, &st) != 0
Und deswegen ist in main bei init_parser dann wieder Schluss:
init_parser(&pc_all, &common);
if(! pc_all.frontend || ! pc_all.demux || ! pc_all.dvr) {
dprintf("Could not connect to loopback device %d\n", virt_adapt);
dprintf("Are you sure you have loaded the dvbloopback module\n");
dprintf("properly and/or used the correct values to the '-j' switch\n");
return(-1);
}