Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Внимания я всё делал от root "sudo su"
- Для начала проверим наличее DVB-карт
- #lspci
- SS2- Network controller: Techsan Electronics Co Ltd B2C2 FlexCopII DVB chip / Technisat SkyStar2 DVB card (rev 02)
- SS3- Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
- Сами устройства находятся тут /dev/dvb/
- Ставим драйвера v4l http://linuxtv.org/
- для них потребуются:
- #apt-get install linux-source linux-headers linux-image libncurses5-dev
- придётся некоторые компанетны выбрать вручную
- устанавливаем v4l:
- #make all
- #make install
- Процес долгий можете налить чаю Smiley
- из пойманых мною глюкав оказалось нестаится с неправельной датой, make install выполнял из папки v4l и с флэшки неставился.
- Можети попить чаю процес долгий.
- Перезагружаем машыну...
- проверяем транспортеры. для этого создаём фаил с содержымым:
- S частота поляризация скорость fec
- например S 11044000 V 44950000 3/4
- scan я нашол в комплекте dvb-utils
- # apt-get install dvb-utils
- выполняем:
- scan -a устройство фаил
- например #scan -a 1 53
- если паказал станции и их пиды то всё нормально
- ставим getstream
- #apt-get install getstream но я советую ставить с исходников если будите патчить Smiley
- http://silicon-verl.de/home/flo/projects/streaming/
- Для сборки потребуется:
- #apt-get install libevent-dev libglib2.0-dev
- Если собераетесь пропатчеть для того чтоб играло радио в винампе(внимаение перестаёт вещать видео и играть радио в WMP я ставил 2 getstream`a):
- http://tipok.org.ua/downloads/iptv/DVB/ ... ps-es.diff Патчь
- #patch -p1 < filter-ps-es.diff
- Собераем getstream:
- #make
- #cp getstream /usr/local/bin
- Дальше создаём фаил где описываем каналы такого типа:
- http{
- port 8000;
- };
- adapter 0 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000; #Нижний предел
- lof2 10600000; #Верхний предел
- slof 11700000; #Частота переключения
- };
- transponder { #описываем транспондер
- frequency 11671000; #Частота приема
- polarisation v; #поляризация
- symbol-rate 18200000; #символьная скорость
- };
- };
- #начало описания потока
- stream {
- name "Serebryany Dozhd"; #имя потока
- #входные данные потока
- input {
- pnr 2100; #pid пакета на спутнике
- };
- #выходные данные для потока
- output-http {
- url /serebryany_dozhd; #URL адрес, на который будет вещаение
- };
- };
- для пропатченого:
- output-http {
- filter {
- es;
- };
- url /serebryany_dozhd; #URL адрес, на который будет вещаение
- };
- запускаем так
- getsream -c имя фаила -d
- -с обязателен
- имя фаила с натроенными каналами
- -d показывать статистику
- -dd ещё больше статистики
- в моём случии
- screen -d -m /usr/local/bin/getstream -c /home/radio/video-53+60+75+80+90
- а для пользователя создаём плайлист:
- #EXTM3U
- #EXTINF:-131,Серебрянный дождь
- http://Имя сервера/serebryany_dozhd
- мои фаилы:
- Цитата
- http{
- port 8001;
- };
- adapter 4 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000;
- lof2 10600000;
- slof 11700000;
- };
- transponder {
- frequency 11606000;
- polarisation v;
- symbol-rate 44950000;
- };
- };
- stream {
- name "1Rock";
- input {
- pnr 30;
- };
- output-http {
- url /1Rock;
- };
- };
- };
- adapter 0 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000;
- lof2 10600000;
- slof 11700000;
- };
- transponder {
- frequency 11044000;
- polarisation v;
- symbol-rate 44950000;
- };
- };
- stream {
- name "MuzTV";
- input {
- pnr 5;
- };
- output-http {
- url /MuzTV;
- };
- };
- stream {
- name "1Muz";
- input {
- pnr 1;
- };
- output-http {
- url /1Muz;
- };
- };
- stream {
- name "TV7";
- input {
- pnr 2;
- };
- output-http {
- url /TV7;
- };
- };
- stream {
- name "Expert";
- input {
- pnr 9;
- };
- output-http {
- url /Expert;
- };
- };
- stream {
- name "Grozny";
- input {
- pnr 10;
- };
- output-http {
- url /Grozny;
- };
- };
- stream {
- name "1TVRUS";
- input {
- pnr 11;
- };
- output-http {
- url /1TVRUS;
- };
- };
- };
- adapter 3 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000;
- lof2 10600000;
- slof 11700000;
- };
- transponder {
- frequency 11092000;
- polarisation v;
- symbol-rate 26470000;
- };
- };
- stream {
- name "RenTV";
- input {
- pnr 3600;
- };
- output-http {
- url /RenTV;
- };
- };
- stream {
- name "Vesti";
- input {
- pnr 3900;
- };
- output-http {
- url /Vesti;
- };
- };
- stream {
- name "Bibigon";
- input {
- pnr 4000;
- };
- output-http {
- url /Bibigon;
- };
- };
- };
- adapter 2 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000;
- lof2 10600000;
- slof 11700000;
- };
- transponder {
- frequency 12670000;
- polarisation v;
- symbol-rate 22000000;
- };
- };
- stream {
- name "2x2";
- input {
- pnr 200;
- };
- output-http {
- url /2x2;
- };
- };
- stream {
- name "LUXE_TV";
- input {
- pnr 100;
- };
- output-http {
- url /LUXE_TV;
- };
- };
- stream {
- name "TVclub";
- input {
- pnr 600;
- };
- output-http {
- url /TVclub;
- };
- };
- };
- adapter 1 {
- packet-buffer 50;
- stat-interval 120;
- dvb-s {
- lnb {
- lof1 9750000;
- lof2 10600000;
- slof 11700000;
- };
- transponder {
- frequency 12579000;
- polarisation v;
- symbol-rate 22000000;
- };
- };
- stream {
- name "A-ONE";
- input {
- pnr 1300;
- };
- output-http {
- url /A-ONE;
- };
- };
- stream {
- name "TV-Sale";
- input {
- pnr 1400;
- };
- output-http {
- url /TV-Sale;
- };
- };
- stream {
- name "Topshop";
- input {
- pnr 1500;
- };
- output-http {
- url /Topshop;
- };
- };
- };
- плайлист
- Цитата
- #EXTM3U
- #EXTINF:-1,1Rock
- http://192.168.32.10:8001/1Rock
- #EXTINF:-1,A-ONE
- http://192.168.32.10:8001/A-ONE
- #EXTINF:-1,2x2
- http://192.168.32.10:8001/2x2
- #EXTINF:-1,МузТВ
- http://192.168.32.10:8001/MuzTV
- #EXTINF:-1,1Музыкальный
- http://192.168.32.10:8001/1Mus
- #EXTINF:-1,7 ТВ
- http://192.168.32.10:8001/TV7
- #EXTINF:-1,Эксперт
- http://192.168.32.10:8001/Expert
- #EXTINF:-1,Грозный
- http://192.168.32.10:8001/Grozny
- #EXTINF:-1,Первый канал
- http://192.168.32.10:8001/1TVRUS
- #EXTINF:-1,REN TV
- http://192.168.32.10:8001/RenTV
- #EXTINF:-1,Вести 24
- http://192.168.32.10:8001/Vesti
- #EXTINF:-1,Бибигон
- http://192.168.32.10:8001/Bibigon
- #EXTINF:-1,Luxe TV
- http://192.168.32.10:8001/LUXE_TV
- #EXTINF:-1,TV Club
- http://192.168.32.10:8001/TVclub
- #EXTINF:-1,TV Sale
- http://192.168.32.10:8001/TV-Sale
- #EXTINF:-1,Top Shop
- http://192.168.32.10:8001/Topshop
- а такде я к munin приделал 2 скрипта:
- Для статистики сигналов с DVB-карт Tuner=№ вашей DVB-карты
- Цитата
- Tuner=0
- case $1 in
- autoconf|detect)
- if [ -e /dev/dvb/adapter$Tuner/ ] ; then
- echo yes
- exit 0
- else
- echo "no (dvb tuner $Tuner not found)"
- exit 1
- fi;;
- config)
- echo 'graph_title DVB-0'
- echo 'graph_args --base 1000 -l 0'
- echo 'graph_vlabel Signal Strength % / Errors in 000s'
- echo 'graph_category mythtv'
- echo 'graph_scale no'
- echo "signal.label Signal strength"
- echo "signal.draw LINE1"
- echo "signal.min 0"
- echo "snr.label Signal to noise"
- echo "snr.draw LINE1"
- echo "snr.min 0"
- echo "ber.label Bit error rate (in millions)"
- echo "ber.draw LINE1"
- echo "ber.min 0"
- echo "unc.label Uncorrectable errors (in thousands)"
- echo "unc.draw LINE1"
- echo "unc.min 0"
- exit 0;;
- esac
- if [ -e /dev/dvb/adapter$Tuner/ ] ; then
- check=`femon -H -c 1 -a $Tuner | grep signal `
- echo $check | awk '{printf "signal.value %.0f\nsnr.value %.0f\nber.value %.2f\nunc.value %.2f\n\n",$5,$8,$11/1000,$14/1000000}'
- else
- echo "snr.value 0"
- echo "unc.value 0"
- echo "ber.value 0"
- echo "signal.value 0"
- fi
- exit 0
- И для статистика смотрящих TV
- Цитата
- if [ "$1" = "config" ]; then
- echo 'graph_title See TV'
- echo 'graph_args --base 1000 -l 0'
- echo 'graph_vlabel shtuck'
- echo 'graph_category Network'
- echo 'graph_scale no'
- echo "tcp.label see TV"
- echo "tcp.draw LINE1"
- echo "tcp.min 0"
- exit 0
- fi
- echo -n "tcp.value "
- echo `/bin/netstat -p tcp -n | grep 8001 | grep ESTABLISHED | wc -l`
- Всё рабочее остальное зависит от ваших рук Cool
- http://forum.ubuntu.ru/index.php?topic=84821.0
- https://bitbucket.org/a84/getstream/iss ... ent-338062 getstream a84
- https://bitbucket.org/a84/getstream/issues
- Код: Выделить всё
- trafshow -ni eth2 port 1234
- Код: Выделить всё
- dmesg | grep vmalloc
- [ 0.000000] vmalloc : 0xf83fe000 - 0xffbfe000 ( 120 MB)
- проверка памяти
- Код: Выделить всё
- cat /proc/meminfo
- Код: Выделить всё
- в oscam.pids откроешь, если карта стоит в картридере (52 или Belka, у меня 52)
- 4AE0/15 # 3K (52)
- #4AE0/0 # 3K (Belka)
- 4AE1/11 # 3K (13)
- У меня на Е2 AFF эта сборка oscam как клиент на Платформе работала в режиме dvbapi.
- http://forum.sat-expert.com/ipbox-99x-e ... ika-7.html
- http://www.sat-expert.com/Dreambox/p2_articleid/1359
- /usr/src/s2-liplianin/linux/drivers/media/dvb/dvb-core/dmxdev.h
- Код: Выделить всё
- #define DVR_BUFFER_SIZE (10*188*1024*4)
- пересборка дров
- Код: Выделить всё
- make clean
- make distslean
- make rminstall
- make -i
- make install
- http://blog.brovary-fun.com/?p=380
- freedom
- Сообщения: 147
- Зарегистрирован: 25 фев 2009, 19:09
- Вернуться к началу
- Re: Getstream
- freedom » 14 фев 2011, 00:21
- Femon - в процентах
- Код: Выделить всё
- /* femon -- monitor frontend status
- *
- * Copyright (C) 2003 convergence GmbH
- * Johannes Stezenbach <[email protected]>
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
- #include <stdio.h>
- #include <stdlib.h>
- #include <limits.h>
- #include <string.h>
- #include <errno.h>
- #include <sys/ioctl.h>
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <sys/poll.h>
- #include <fcntl.h>
- #include <time.h>
- #include <unistd.h>
- #include <stdint.h>
- #include <sys/time.h>
- #include <linux/dvb/frontend.h>
- #ifndef TRUE
- #define TRUE (1==1)
- #endif
- #ifndef FALSE
- #define FALSE (1==0)
- #endif
- #define FRONTENDDEVICE "/dev/dvb/adapter%d/frontend%d"
- static char *usage_str =
- "\nusage: femon [options]\n"
- " -a number : use given adapter (default 0)\n"
- " -f number : use given frontend (default 0)\n"
- " -o number : use format out in hex(0)/%(1) (default 0)\n\n";
- static void usage(void)
- {
- fprintf(stderr, usage_str);
- exit(1);
- }
- static
- int check_frontend (int fe_fd, unsigned int formout)
- {
- fe_status_t status;
- uint16_t snr, signal;
- uint32_t ber, uncorrected_blocks;
- do {
- ioctl(fe_fd, FE_READ_STATUS, &status);
- ioctl(fe_fd, FE_READ_SIGNAL_STRENGTH, &signal);
- ioctl(fe_fd, FE_READ_SNR, &snr);
- ioctl(fe_fd, FE_READ_BER, &ber);
- ioctl(fe_fd, FE_READ_UNCORRECTED_BLOCKS, &uncorrected_blocks);
- if (formout==0) {
- printf ("status %02x | signal %04x | snr %04x | ber %08x | unc %08x | ",
- status, signal, snr, ber, uncorrected_blocks);
- } else {
- printf ("status %02x | signal %3.2f%% | snr %3.2f%% | ber %08x | unc %08x | ",
- status, (double)(signal/655.35), (double)snr/655.35, ber, uncorrected_blocks);
- }
- if (status & FE_HAS_LOCK)
- printf("FE_HAS_LOCK");
- printf("\n");
- usleep(1000000);
- } while (1);
- return 0;
- }
- static
- int do_mon(unsigned int adapter, unsigned int frontend, unsigned int formout)
- {
- char fedev[128];
- int fefd;
- int result;
- struct dvb_frontend_info fe_info;
- snprintf(fedev, sizeof(fedev), FRONTENDDEVICE, adapter, frontend);
- printf("using '%s'\n", fedev);
- if ((fefd = open(fedev, O_RDONLY | O_NONBLOCK)) < 0) {
- perror("opening frontend failed");
- return FALSE;
- }
- result = ioctl(fefd, FE_GET_INFO, &fe_info);
- if (result < 0) {
- perror("ioctl FE_GET_INFO failed");
- close(fefd);
- return FALSE;
- }
- printf("FE: %s (%s)\n", fe_info.name, fe_info.type == FE_QPSK ? "SAT" :
- fe_info.type == FE_QAM ? "CABLE": "TERRESTRIAL");
- check_frontend (fefd, formout);
- close(fefd);
- return result;
- }
- int main(int argc, char *argv[])
- {
- unsigned int adapter = 0, frontend = 0, formout = 0;
- int opt;
- while ((opt = getopt(argc, argv, "hlrn:a:f:d:o:")) != -1) {
- switch (opt)
- {
- case '?':
- case 'h':
- default:
- usage();
- case 'a':
- adapter = strtoul(optarg, NULL, 0);
- break;
- case 'f':
- frontend = strtoul(optarg, NULL, 0);
- case 'o':
- formout = strtoul(optarg, NULL, 0);
- }
- }
- do_mon(adapter, frontend, formout);
- return FALSE;
- }
- Собрать gcc femon.c -o femon
- Запускать ./femon -o 1
- http://viaccessfree.biz/forum/showthrea ... 932&page=2
- запуск femon
- Код: Выделить всё
- femon -H -a 3
- 3 - это номер адаптера
- freedom
- Сообщения: 147
- Зарегистрирован: 25 фев 2009, 19:09
- Вернуться к началу
- Re: Getstream
- freedom » 10 май 2011, 20:33
- Ман по getstream a84
- https://cesbo.com/projects/iptv/wiki/Ge ... version=16
- https://bitbucket.org/a84/gs_public/iss ... tatus=open
- freedom
- Сообщения: 147
- Зарегистрирован: 25 фев 2009, 19:09
- Вернуться к началу
- Re: Getstream
- freedom » 10 май 2011, 21:08
- Код: Выделить всё
- newcamd 1 {
- hostname "127.0.0.1";
- port 5005;
- username "fantom";
- password "111";
- cfgkey "0102030405060708091011121314";
- prov-ident "000015";
- disable-emm 0;
- fifo-size 256;
- delay 0;
- };
- adapter 2 { packet-buffer 7; stat-interval 50; stuck-interval 200; budget-mode 0;
- dvb-s2 {
- lnb { lof1 10700000; lof2 10600000; slof 11700000; };
- transponder { frequency 12380000; polarisation v; symbol-rate 26400000; }; };
- stream { name "Sport 1"; input { pnr 120; newcamd 1;}; output-udp {remote-address 239.172.20.212; remote-port 1234;};};
- stream { name "Nathional Geographic HD"; input { pnr 40; newcamd 1;}; output-udp {remote-address 239.172.20.211; remote-port 1234;};};
- stream { name "Nat Geo Wild HD"; input { pnr 50; newcamd 1;}; output-udp {remote-address 239.172.20.213; remote-port 1234;};};
- stream { name "HD Sport"; input { pnr 20; newcamd 1;}; output-udp {remote-address 239.172.20.214; remote-port 1234;};};
- };
- трик
- Код: Выделить всё
- http{
- port 8000;
- };
- newcamd 1 {
- hostname "10.10.10.23";
- port "10000";
- username "baton";
- password "baton";
- cfgkey "0102030405060708091011121314";
- prov-ident "000011";
- disable-emm 0;
- fifo-size 256;
- delay 0;
- };
- adapter 0 {
- budget-mode 0;
- packet-buffer 7;
- stat-interval 50;
- stuck-interval 200;
- dvb-s {
- lnb-sharing no;
- lnb {
- lof1 10750000;
- lof2 10750000;
- slof 10750000;
- };
- transponder {
- frequency 12303000;
- polarisation h;
- symbol-rate 27500000;
- };
- };
- stream {
- name "Bridge TV";
- input {
- pnr 410;
- newcamd 1;
- epg 1;
- };
- output-http {
- url /1;
- };
- };
- };
- Триколор 1226 L DVB-S SR 27500 FEC 3/4
- Код: Выделить всё
- newcamd 1 {
- hostname "127.0.0.1";
- port 10000;
- username "user";
- password "user";
- cfgkey "0102030405060708091011121314";
- prov-ident "000011";
- disable-emm 0;
- fifo-size 256;
- delay 0;
- };
- adapter 0 {
- packet-buffer 63; # обязательно должно быть кратно 7
- budget-mode 0;
- stat-interval 120;
- stuck-interval 200;
- dvb-s {
- lnb {
- lof1 10750000;
- lof2 10750000;
- slof 10750000;
- };
- transponder {
- frequency 12226000;
- polarisation h;
- symbol-rate 27500000;
- };
- lnb-sharing no;
- };
- stream {
- name "Perviy kanal";
- input {
- pnr 27005;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.13;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Rossiya 1";
- input {
- pnr 27010;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.1;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "NTV";
- input {
- pnr 27015;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.2;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Rossiya K";
- input {
- pnr 27020;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.3;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "TNT";
- input {
- pnr 27025;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.4;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Rossiya 2";
- input {
- pnr 27030;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.5;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Rossiya 24";
- input {
- pnr 27040;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.6;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "5 Kanal";
- input {
- pnr 27050;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.7;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "DTV";
- input {
- pnr 27060;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.8;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "REN TV";
- input {
- pnr 27070;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.9;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Karusel";
- input {
- pnr 27090;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.10;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "TV Centr";
- input {
- pnr 27100;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.11;
- remote-port 1234;
- ttl 4;
- };
- };
- stream {
- name "Ru TV";
- input {
- pnr 27110;
- ecm-group 0x11;
- epg 1;
- newcamd 1;
- };
- output-udp {
- remote-address
- 239.100.1.12;
- remote-port 1234;
- ttl 4;
- };
- };
- };
- Tricolor 12303 L DVB-S SR 27500 FEC 3/4
- Код: Выделить всё
- newcamd 1 {
- hostname "127.0.0.1";
- port 10000;
- username "user";
- password "user";
- cfgkey "0102030405060708091011121314";
- prov-ident "000011";
- disable-emm 0;
- fifo-size 256;
- delay 0;
- };
- adapter 0 {
Advertisement
Add Comment
Please, Sign In to add comment