Page 1 of 1

ISS -HAMTV Transport Stream has a bug

PostPosted: Wed 12 Feb 2014 06:32
by F6DZP
Some explanation about DVB transport stream

When we transmit using a DVB standard we modulate a carrier to transmit digital data.
Data are organized in different parts : information for the receiver to tell it where to find different multiplexed channels, where are video, audio in different languages sometimes, how they are coded, and data that can be other things that video or audio. We could use DVB just to transmit files, very more faster than packet radio....

So when a signal is demodulated, we receive data organized by packets (of 188 bytes). but packets are all mixed, data, info, teletext, audio, video....
Each packet has a number to recognize it : PID = Packet IDentification.
TS from my minimod SR1300_packet viewer.jpg
we can see different packets: Grey packets are "Null packets", they content nothing usable, white packets PID $101=257 are Audio packets, blue packets PID $100=256 are video packets and other colors show PAT, PMT... packets
TS from my minimod SR1300_packet viewer.jpg (140.16 KiB) Viewed 34001 times

To be able to reorganize data to put video data together, audio data together and decode them, we must know where they are (their PID) and at which channel they belong.
So all start with the "mother" of all packets : packet with PID 0 : PAT = Program Allocation Table. This PID=0 is always for PAT. It is known before we receive anything.
In this packet PAT we will find how much programs or channels we have in the multiplexed stream. and we will know the value of PID that give us info about these channels. These are PMT Program Map Table.
If you have 2 services ( channel TV) the PAT will tell you that you have 2 PMT, first PMT at PID 258 and second PMT at PID 270.
So the decoder will search to find packets having PID 258 (first channel), and when it receives them, it find inside these packets that there are 3 elementary streams : video PID 256 audio PID 257 (in English) and audio PID 260 (in French)
So the receiver/decoder will know that if you want to look at first channel it will assemble together all packets "PID=256" that represent video data and send them to the mpeg2 video decoder, if you want the English audio it will take all packets "PID=257" that arrive in the stream and send them to the Mpeg1-layer2 audio decoder.
PAT from my minimod SR1300_packet analizer.jpg
We can see that this PAT tell us that there are 2 PMT, Program_number 0 with PID16 and Program_number 1 with PID 258
PAT from my minimod SR1300_packet analizer.jpg (142.32 KiB) Viewed 34001 times

So to be able to show us a video and audio, any DVB receiver must know the video PID and audio PID it must decode. ( and many other things more complex to explain in only several lines)
So when you scan a frequency with a decoder, it search the PAT, when it get it, it knows how to find PMT and when it get one PMT it knows the audio PID and video PID corresponding, so if you want to watch this channel, it could take all packets for video that are arriving and all packets for audio that are arriving.

So in a DVB Transport Stream we have always a PAT, and one or several PMT.
some specific packets as SDT or NIT allow to give other info like the name of provider, name of network...

TS reader normal SR1300.jpg
This TS show a PAT that content only one PMT that describe 2 ES ( elementary streams) video PID $3e9=1000 and audio PID $3ea=1001. For this Transport stream coming from a SR1300 kS/s fec 1/2 we have a total of 1 198 kbps, 1 040 kbps is used for video, 84 kbps is used for audio, 41 kbps for Null Packets, and 15 kbps for PAT and PMT
TS reader normal SR1300.jpg (119.77 KiB) Viewed 34001 times

In HAMTV DVB multiplexer, there is a bug in the firmware, so there are absolutely no packets describing tables: no PAT, no PMT, no NIT, no SDT..
So any professional DVB decoder or any receiver that want to observe strict DVB standard will not accept this transport stream that is not DVB compliant. Nothing to see, nothing to hear..

Tsreader HamTV not corrected .jpg
HAMTV transport stream for SR1300, fec 1/2 => total data rate 1 198 kbps Too much data rate for Null packets! and also too much data rate for audio! so video data rate is only about 350 kbps
No PAT, No PMT. so we just see data at PID 256 and 257 but don't know what it is
Tsreader HamTV not corrected .jpg (96.74 KiB) Viewed 34001 times

But if you use a very simple SetTopBox at very low price, a basic hardware that don't take care of strict DVB characteristics, it will be able to decode if you give it, by yourself, the audio PID value(257) and the Video PID value(256).

If you use a very good SetTopBox that use table, that use PCR and PTS values inside packets to synchronize strictly audio and video, these equipment will not work for HAMTV decoding.

Using a computer and a software like Tutioune will allow us to receive the BAD transport stream coming from HAMTV and to add in real time the tables that are not present.
So the Transport Stream recorded or sent via UDP to VLC, TSreader will have all tables.

HamTV TS corrected using TSreader.jpg
HAMTV transport stream has bee corrected in real time by Tutioune : we can find all tables. But we cannot change poor data rate given to video!
HamTV TS corrected using TSreader.jpg (136.34 KiB) Viewed 34001 times

VLC gives some info about the stream :
HamTV TS corrected using VLC.jpg
audio bitrate is too much :256 kbps! we don't need that for just a voice in a microphone, 32 kbps or 64 kbps is enough. and 44100 Hz is a sample rate that is never used in DVB broadcasting, we must always use 48 kHz!
HamTV TS corrected using VLC.jpg (121.05 KiB) Viewed 33999 times

The last thing to do is to explore if there are no other bugs ...
I'm working on that. I need more time for test. I'm writing a long document about all of that.

Sorry, my English is not very good, DVB technology is not very simple, I hope you will understand these explanations, I have tried to simplify the most I could.

Best regards


Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Wed 12 Feb 2014 07:43
by F6DZP
Here you can download specific beta version of Tutioune that has a button "ISS" that you must check when you receive HAMTV. This will add DVB tables that are not present in the transport stream.
( Tutioune does not decode for the moment with this beta version , but can record the corrected TS to Hard disk, or send it to VLC or TSreader using UDP).

For Technotrend TT S2-1600 ==> There is a new version, see following discussion

For Technotrend TT S2-3200: ==> There is a new version, see following discussion

If you want to test not corrected HAMTV transport stream without tables, here is an example at SR 2000:
(5.5 MiB) Downloaded 1536 times

I have transmitted this transport stream using my professional DVB modulator (Dektec DTA107) and received/corrected/ recorded with Tutioune1600_ISS and that gave me this TS corrected:
(3.17 MiB) Downloaded 1536 times

Jean Pierre F6DZP

Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Wed 5 Mar 2014 18:23
by zg3409
ISS Button
ISSButton.jpg (120.18 KiB) Viewed 33786 times

Above is the extra ISS button. Thanks to F6DZP for this.

Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Thu 6 Mar 2014 15:07
by F6DZP
Ok, sorry for that. I have made the modification.

These 2 new versions allow to receive HamTv with Tutioune, decoding video and audio if you want.
but as HamTV audio is not set as it would do ( 44100 kHz is not used in DVB format, the Microsoft Audio decoder can do some click)

If you send via UDP to VLC and not use Tutioune for decoding ( just by NOT giving it the video and audio PIDS), VLC will decode audio with its own decoder and audio is better.

New version for TT S2-3200:
(887.14 KiB) Downloaded 1734 times

New version for TT S2-1600:

Jean Pierre F6DZP

Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Wed 12 Mar 2014 20:37
by G4KLB
Do you have instructions on how to use UDP with VLC?

Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Thu 13 Mar 2014 09:05
by F6DZP

Answer is here :

Jean Pierre F6DZP

Re: ISS -HAMTV Transport Stream has a bug

PostPosted: Thu 13 Mar 2014 11:38
by G4KLB
Thank you Jean Pierre,

VLC and TSReader are working perfectly thanks to your instructions.

Both VLC and TSReader remember the settings so is very easy to use now.

Colin G4KLB