<div dir="ltr"><div dir="ltr">On Thu, Jul 15, 2021 at 3:45 PM Klaas de Waal <<a href="mailto:klaas.de.waal@gmail.com">klaas.de.waal@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 14 Jul 2021 at 22:24, Klaas de Waal <<a href="mailto:klaas.de.waal@gmail.com" target="_blank">klaas.de.waal@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, 13 Jul 2021 at 19:49, John P Poet <<a href="mailto:jppoet@gmail.com" target="_blank">jppoet@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr">On Tue, Jul 13, 2021 at 11:36 AM Klaas de Waal <<a href="mailto:klaas.de.waal@gmail.com" target="_blank">klaas.de.waal@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, 10 Jul 2021 at 17:44, John P Poet <<a href="mailto:jppoet@gmail.com" target="_blank">jppoet@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr">On Sat, Jul 10, 2021 at 7:30 AM Klaas de Waal <<a href="mailto:klaas.de.waal@gmail.com" target="_blank">klaas.de.waal@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, 10 Jul 2021 at 10:32, Klaas de Waal <<a href="mailto:klaas.de.waal@gmail.com" target="_blank">klaas.de.waal@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, 9 Jul 2021 at 22:57, John P Poet <<a href="mailto:jppoet@gmail.com" target="_blank">jppoet@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Hi Klaas,</div><div><br></div><div>I am setting up a new development machine to do some work. In the process I noticed that when scanning ATSC channels, no default channel number is given and the user must manually choose one for every single channel. This is when the user chooses to manually pick which channels get inserted into the DB.</div><div><br></div><div>For example, the message I am getting is:</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>You chose to manually insert channel 7_1 (KOAT-DT). Please enter a unique channel channel number. Default value is</div></blockquote><div><br></div><div>If I just click on OK, it just redraws the same dialog box. Instead I have to select Edit and type in 7_1. I could have sworn this was more automatic the last time I did this. Any chance you can have it pick a good default?</div><div><br></div></div></blockquote><div>Hi John,</div><div><br></div><div>This definitely should be automatic so there is something really wrong.</div><div>The correct behavior is to use the received channel number without asking and when there is a conflict the suggestion channel number is with a letter added.</div><div>There should also be the option in the dialog for "OK for all"  so that it is never asked again.</div><div>It could be a coincidence but there are also threads in the forum about ATSC cable scanning not working at all or crashing once the scan is complete. And that is with v31. I assume you are using master.</div><div>At least you still get the correct channel numbers and names, which the ATSC cable scans do not even do anymore.</div><div>What makes this a puzzle is that I have not changed anything significant in the scanning code for a long time now. </div><div>On the other hand, maybe people do not do channel scans that often....</div><div>The scanning does work correctly with DVB-T2/C/S2 as you might have guessed.</div><div>I will have a look at the code this weekend and possibly try to do a simple ATSC scan with a captured ATSC transport stream. Have done that in the past so I should be able to do that again....</div><div>In the meantime, if you have an idea what is wrong be welcome to explore and fix it!</div><div><br></div></div></div></blockquote><div>Hi John,</div><div><br></div><div>Can you please send me a complete backup of your database after you have done one or more scans?</div><div>Rationale:</div><div>In master the "Scan type"  "Import Existing Scan" allows playing back again a scan previously done. I expect the bug to be in the channel importer where the options such as "Complete scan data required" etc are processed and this can be replayed from an existing scan. Which then hopefully enables me to debug the channel numbering code with your ATSC scan. </div><div><br></div><div>Thanks,</div><div>Klaas.</div></div></div></blockquote><div><br></div><div>Yes, I can do that. I will replicate what I did when I saw the problem, which was to do a scan on an initial setup, i.e. brand new database.</div><div><br></div><div><br></div></div></div></blockquote><div>Hi John,</div><div><br></div><div>I've resurrected the capability to scan from a single transport stream, according to your description in </div><div><a href="https://github.com/MythTV/mythtv/commit/8828cc5e4698f72e25fcfc31782c42fda5079717#diff-09ba904030e3795f57e6332cba578167" target="_blank">https://github.com/MythTV/mythtv/commit/8828cc5e4698f72e25fcfc31782c42fda5079717#diff-09ba904030e3795f57e6332cba578167</a></div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"">"Add the ability to scan for the programs in a MPTS stream from an IPTV <span style="font-family:ui-monospace,SFMono-Regular,"SF Mono",Consolas,"Liberation Mono",Menlo,monospace;white-space:pre-wrap">source."</span></div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji""><span style="font-family:ui-monospace,SFMono-Regular,"SF Mono",Consolas,"Liberation Mono",Menlo,monospace;white-space:pre-wrap">I needed a small fix in channelscan_sm.cpp to make this work but that is another story.</span></div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"">The good news is that I should now be able to reproduce and debug the channel importer issue.</div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji""><br></div><div style="box-sizing:border-box;color:rgb(36,41,46)"><font face="ui-monospace, SFMono-Regular, SF Mono, Consolas, Liberation Mono, Menlo, monospace"><span style="white-space:pre-wrap">Question: can you send me a full MPTS that does not scan correctly?</span></font></div><div style="box-sizing:border-box;color:rgb(36,41,46)"><font face="ui-monospace, SFMono-Regular, SF Mono, Consolas, Liberation Mono, Menlo, monospace"><span style="white-space:pre-wrap"><br></span></font></div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji""><span style="font-family:ui-monospace,SFMono-Regular,"SF Mono",Consolas,"Liberation Mono",Menlo,monospace;white-space:pre-wrap">Thanks,</span></div><div style="box-sizing:border-box;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji""><span style="font-family:ui-monospace,SFMono-Regular,"SF Mono",Consolas,"Liberation Mono",Menlo,monospace;white-space:pre-wrap">Klaas.</span></div></div></div></blockquote><div><br></div><div>Hi Klaas,</div><div><br></div><div>Yes, I can do that. It may take me a couple of days, but I will get it to you by the end of this week.</div><div><br></div><div><br></div></div></div></blockquote><div>Hi John,</div><div><br></div><div>It looks like I can reproduce the problem. I found a transport stream from the beginning of 2020 which I think I actually got from you.</div><div>When I scan this with the IPTV UDP method I do get wrong results.</div><div></div><div>It has e.g.  <span style="color:rgb(0,0,0);font-family:"Droid Sans Mono",monospace,monospace,"Droid Sans Fallback";font-size:14px;white-space:pre-wrap">KWBQ-TV </span><span style="color:rgb(0,0,0);font-family:"Droid Sans Mono",monospace,monospace,"Droid Sans Fallback";font-size:14px;white-space:pre-wrap">which then gets channel number 5001-3, the 5001 being the UDP port number.</span></div><div><span style="color:rgb(0,0,0);font-family:"Droid Sans Mono",monospace,monospace,"Droid Sans Fallback";font-size:14px;white-space:pre-wrap">However, in the scan log it looks like KWBQ-TV should be 19-1 and the other channels 19-2, 19-3 and 19-4.</span></div><div><span style="color:rgb(0,0,0);font-family:"Droid Sans Mono",monospace,monospace,"Droid Sans Fallback";font-size:14px;white-space:pre-wrap">This is the VCT:</span></div><div><div style="color:rgb(0,0,0);font-family:"Droid Sans Mono",monospace,monospace,"Droid Sans Fallback";font-size:14px;line-height:19px;white-space:pre-wrap"><div>(HandleVCT) - ChannelScanSM[<span style="color:rgb(0,0,255)">7</span>]: Got a Virtual Channel Table for <span style="color:rgb(0,0,255)">0</span></div><div>(LogLines) - Terrestrial Virtual Channel Section</div><div>(LogLines) -   PSIP tableID(0xc8) length(<span style="color:rgb(0,0,255)">215</span>) extension(0x817)</div><div>(LogLines) -        version(<span style="color:rgb(0,0,255)">0</span>) current(<span style="color:rgb(0,0,255)">1</span>) section(<span style="color:rgb(0,0,255)">0</span>) last_section(<span style="color:rgb(0,0,255)">0</span>)</div><div>(LogLines) -        atsc_protocol_version(<span style="color:rgb(0,0,255)">0</span>)</div><div>(LogLines) -       channel_count(<span style="color:rgb(0,0,255)">4</span>) tsid(0x0817)</div><div>(LogLines) -   Channel #<span style="color:rgb(0,0,255)">0</span> name(KWBQ-TV) <span style="color:rgb(0,0,255)">19</span>-<span style="color:rgb(0,0,255)">1</span> mod(ATSC <span style="color:rgb(0,0,255)">8</span>-VSB) cTSID(0x0817)</div><div>(LogLines) -     pnum(<span style="color:rgb(0,0,255)">3</span>) ETM_loc(<span style="color:rgb(0,0,255)">1</span>) access_ctrl(<span style="color:rgb(0,0,255)">0</span>) hidden(<span style="color:rgb(0,0,255)">0</span>) hide_guide(<span style="color:rgb(0,0,255)">0</span>) service_type(ATSC TV)</div><div>(LogLines) -     source_id(<span style="color:rgb(0,0,255)">1</span>)</div><div>(LogLines) -     descriptors length(<span style="color:rgb(0,0,255)">23</span>) count:<span style="color:rgb(0,0,255)">1</span></div><div>(LogLines) -     Service Location Descriptor tag(0xa1) length(<span style="color:rgb(0,0,255)">21</span>) Dumping</div><div>(LogLines) -       <span style="color:rgb(0,0,255)">000</span>  e0 <span style="color:rgb(0,0,255)">31</span> <span style="color:rgb(0,0,255)">03</span> <span style="color:rgb(0,0,255)">02</span> e0 <span style="color:rgb(0,0,255)">31</span> <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">00</span>  <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">81</span> e0 <span style="color:rgb(0,0,255)">34</span> <span style="color:rgb(0,0,255)">65</span> 6e <span style="color:rgb(0,0,255)">67</span> <span style="color:rgb(0,0,255)">81</span>  |.<span style="color:rgb(0,0,255)">1</span>...<span style="color:rgb(0,0,255)">1</span>.....4eng.|</div><div>(LogLines) -       <span style="color:rgb(0,0,255)">010</span>  e0 <span style="color:rgb(0,0,255)">35</span> <span style="color:rgb(0,0,255)">73</span> <span style="color:rgb(0,0,255)">70</span> <span style="color:rgb(0,0,255)">61</span>                                    |.5spa|</div><div>(LogLines) -   Channel #<span style="color:rgb(0,0,255)">1</span> name(Grit) <span style="color:rgb(0,0,255)">19</span>-<span style="color:rgb(0,0,255)">2</span> mod(ATSC <span style="color:rgb(0,0,255)">8</span>-VSB) cTSID(0x0817)</div><div>(LogLines) -     pnum(<span style="color:rgb(0,0,255)">4</span>) ETM_loc(<span style="color:rgb(0,0,255)">1</span>) access_ctrl(<span style="color:rgb(0,0,255)">0</span>) hidden(<span style="color:rgb(0,0,255)">0</span>) hide_guide(<span style="color:rgb(0,0,255)">0</span>) service_type(ATSC TV)</div><div>(LogLines) -     source_id(<span style="color:rgb(0,0,255)">2</span>)</div><div>(LogLines) -     descriptors length(<span style="color:rgb(0,0,255)">17</span>) count:<span style="color:rgb(0,0,255)">1</span></div><div>(LogLines) -     Service Location Descriptor tag(0xa1) length(<span style="color:rgb(0,0,255)">15</span>) Dumping</div><div>(LogLines) -       <span style="color:rgb(0,0,255)">000</span>  e0 <span style="color:rgb(0,0,255)">41</span> <span style="color:rgb(0,0,255)">02</span> <span style="color:rgb(0,0,255)">02</span> e0 <span style="color:rgb(0,0,255)">41</span> <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">00</span>  <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">81</span> e0 <span style="color:rgb(0,0,255)">44</span> <span style="color:rgb(0,0,255)">65</span> 6e <span style="color:rgb(0,0,255)">67</span>     |.A...A.....Deng|</div><div>(LogLines) -   Channel #<span style="color:rgb(0,0,255)">2</span> name(Laff) <span style="color:rgb(0,0,255)">19</span>-<span style="color:rgb(0,0,255)">3</span> mod(ATSC <span style="color:rgb(0,0,255)">8</span>-VSB) cTSID(0x0817)</div><div>(LogLines) -     pnum(<span style="color:rgb(0,0,255)">5</span>) ETM_loc(<span style="color:rgb(0,0,255)">1</span>) access_ctrl(<span style="color:rgb(0,0,255)">0</span>) hidden(<span style="color:rgb(0,0,255)">0</span>) hide_guide(<span style="color:rgb(0,0,255)">0</span>) service_type(ATSC TV)</div><div>(LogLines) -     source_id(<span style="color:rgb(0,0,255)">3</span>)</div><div>(LogLines) -     descriptors length(<span style="color:rgb(0,0,255)">17</span>) count:<span style="color:rgb(0,0,255)">1</span></div><div>(LogLines) -     Service Location Descriptor tag(0xa1) length(<span style="color:rgb(0,0,255)">15</span>) Dumping</div><div>(LogLines) -       <span style="color:rgb(0,0,255)">000</span>  e0 <span style="color:rgb(0,0,255)">51</span> <span style="color:rgb(0,0,255)">02</span> <span style="color:rgb(0,0,255)">02</span> e0 <span style="color:rgb(0,0,255)">51</span> <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">00</span>  <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">81</span> e0 <span style="color:rgb(0,0,255)">54</span> <span style="color:rgb(0,0,255)">65</span> 6e <span style="color:rgb(0,0,255)">67</span>     |.Q...Q.....Teng|</div><div>(LogLines) -   Channel #<span style="color:rgb(0,0,255)">3</span> name(Ion) <span style="color:rgb(0,0,255)">19</span>-<span style="color:rgb(0,0,255)">4</span> mod(ATSC <span style="color:rgb(0,0,255)">8</span>-VSB) cTSID(0x0817)</div><div>(LogLines) -     pnum(<span style="color:rgb(0,0,255)">6</span>) ETM_loc(<span style="color:rgb(0,0,255)">0</span>) access_ctrl(<span style="color:rgb(0,0,255)">0</span>) hidden(<span style="color:rgb(0,0,255)">0</span>) hide_guide(<span style="color:rgb(0,0,255)">0</span>) service_type(ATSC TV)</div><div>(LogLines) -     source_id(<span style="color:rgb(0,0,255)">4</span>)</div><div>(LogLines) -     descriptors length(<span style="color:rgb(0,0,255)">17</span>) count:<span style="color:rgb(0,0,255)">1</span></div><div>(LogLines) -     Service Location Descriptor tag(0xa1) length(<span style="color:rgb(0,0,255)">15</span>) Dumping</div><div>(LogLines) -       <span style="color:rgb(0,0,255)">000</span>  e0 <span style="color:rgb(0,0,255)">61</span> <span style="color:rgb(0,0,255)">02</span> <span style="color:rgb(0,0,255)">02</span> e0 <span style="color:rgb(0,0,255)">61</span> <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">00</span>  <span style="color:rgb(0,0,255)">00</span> <span style="color:rgb(0,0,255)">81</span> e0 <span style="color:rgb(0,0,255)">64</span> <span style="color:rgb(0,0,255)">65</span> 6e <span style="color:rgb(0,0,255)">67</span>     |.a...a.....deng|</div><div><br></div><div>I think that this is the problem so I will start looking into this.</div><div><br></div></div></div></div></div></blockquote><div>The channel numbers like 5001-3 are generated because they are scanned as IPTV channels.</div><div>This is done in channelscan_sm.cpp lines 1712-1714.</div><div>When I select a manual install then the channel numbers lik 5001-3 are suggested as default. Pressing OK accepts this. Which is correct.</div><div>It would be possible to use ATSC major-minor as default channel number also for IPTV channels but that is then new functionality, not a bug fix.</div><div>I have not yet been able to find the path in the code that generates an empty default channel number when using the manual install.</div><div>It would be nice to have an "OK all" option when manual install is selected, to accept the default for all following channels.</div><div>Question: do you use IPTV or HDHomeRun or /dev/dvb tuners?</div><div><br></div><div>To be continued!</div><div>Klaas.</div></div></div></blockquote><div><br></div><div>Hi Klass,</div><div><br></div><div>My scan was done using a DVB tuner.</div><div>Sorry, I have not gotten you the DB/logs you asked for. I still hope to get that done this week.</div><div><br></div><div>Thanks,</div><div><br></div><div>John<br></div></div></div>