-
-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Raspberry PI Working as a TV Reciver (TBS6522) #57
Comments
There is already an official Pi DVB hat in the UK. Cannot recall exact compatibility elsewhere though. |
A DVBSky S952 v2 dual DVB-S2 tuner is certainly detected fine. TBS cards are pretty grim in that they have never contributed drivers to mainline, so you have to manually compile the modules. Hauppauge are generally better in that regard. See https://www.linuxtv.org/wiki/index.php/Category:DVB-S2_PCIe_Cards for general guidance on Linux support for DVB PCIe cards. |
The Pi TV HAT is DVB-T/T2 only and connects over SPI. There's no easy way to hook multiple of them up to the same Pi though. |
The Pi foundation talked about seeking the relevant licenses for other formats 3 years ago when this was launched. Shame they didn't manage for whatever reason. Would a USB solution work under Linux? |
It's not licences, it's finding a chip that does the relevant decode. I have never seen an ATSC SPI DVB demod chip.
Yes, works fine. |
DVBSky S952 is being awkward.
Rebooted and the card is misidentified
That's repeatable and needs a full powerdown to identify the card again properly, but then it dies with the It may be that it's just a PCIe setup issue, but I'm not going to investigate further. I had issues with this card disappearing on my x86 box so it may be that the card has partially died. |
@6by9 , Thanks for sharing all these info. |
Hi all, I am trying the same with a tbs6984! Unfortunatelly after days of trying various range settings and up to rpi-5.10-y i cannot get it to show in lspci. I tried the cm4+io board hardware with a intel NIC (NC110T) and the device is listed in lspci right away alongs side the bc pcie bridge. i even tried increasing the brcm_pcie_link_up(pcie) timeout in pcie-brcmstb.c but it keeps starting with "no link" in dmesg and 0 output in lspci. am i right that this is before any dvb-specific kernel modules are needed? in my test i did not compile the tbs driver each time but only check in dmesg/lspci for a life sign.... but nothing :( here the lspci -vv from a x64 ubuntu, can anybody tell me if the card is maybe using some mode the pi does not support and i should give up?
|
@stinger151 lspci should work even without the drivers.
DVB-S2 is going to need additional power connecting through the 6pin power connector on the TBS6984 for the LNB power. I'm keeping my eyes open on Ebay for TBS cards at silly prices, and will test if I find one. |
Ebay win for a TBS6981 dual DVB-S2 tuner.
Looking at the wiki it's a simple CX23885 / CX24132 / CX24117 device, all of which are supported in the mainline kernel. Enable
Ah, looking at the code, it's DMA woes. That would explain it. |
That address (0x0000000417cc0000) looks like a RAM address in PCIe space. Can you find out what phys and dma_addr are in dma_direct_map_page when it fails? |
Also dev->dma_mask and dev->bus_dma_limit. |
[ 584.259353] cx23885 0000:01:00.0: swiotlb addr 0x0000000417cc0000+16384 overflow (mask ffffffff, bus limit 4ffffffff). With extra logging in from
(Hit post too soon. Updated with the diff for the extra logging). |
I've kicked off a 64bit kernel build too to see if that changes things. |
It might. I think the problem is highlighted in the last line of dma_capable:
|
Where does the |
64bit build failed the same way :-(
So the question is where that mask gets set. |
I think I can answer my own question - https://github.com/raspberrypi/linux/blob/rpi-5.10.y/drivers/media/pci/cx23885/cx23885-core.c#L2150
|
Default value for the dma_mask is also 0xFFFFFFFF. Trying to increase that to 0xFFFFFFFFF or 0x7FFFFFFFF blows up
and ending with
from cx23885_buf_queue+0x3c/0x150, presumably as it is trying to queue a buffer that it failed to allocate. It needs someone who understands PCIe and DMA better than me to work this out. |
Is this device fully 64-bit capable? I see 64-bit registers and descriptors, but the upper 32-bits are written as zeroes. |
I would expect so as whilst the cx23885 has been around a while, the boards are relatively recent.
Trying my DVBsky S952 (same chipset):
I had hoped to win a TBS 6209 last night, but it went higher than I was prepared to pay. |
I'm going to try inverting the PCIe address map, putting RAM at zero and peripherals high. I've not found anything that explicitly disallows placing the outbound window above the 4GB mark, except that it would prevent 32-bit devices from working. Of course, putting RAM above 4GB would also do that, so for devices with 4GB+ of RAM it may be no worse... |
If you want to play with actual hardware then I can drop one of these into the office for/on Monday. I think they'll work well enough without an actual satellite signal to provoke this. |
Next attempt failed too. Hauppauge WinTV QuadHD. It shows up as a 1:2 PCI-e switch, and then two cx23885 decoders (https://www.linuxtv.org/wiki/index.php/Hauppauge_WinTV-quadHD_(DVB-T/T2/C) says they're actually CX23888).
Different failure - cx23885 fails to get an IRQ on trying to register the second half of the first adapter.
the second adapter then fails too
So it looks like it is the PCIe switch that has the issue, and not cx23885 specifically. (TBH The Pi works so nicely as a TV Receiver using USB tuners (I have 6 on my Pi4), so switching to these PCIe devices doesn't really add that much, but it has uses). |
I have just updated to 5.10.13, so it's possible something has changed since the 5.10.7 I was testing the other card with. |
Ah, it is switches that are the issue. Just to make sure I wasn't going crazy I tried my DVBSky S952. Initially connected via an ASMedia ASM1184e switch and it logged the same error as the QuadHD. |
Just linking this issue to this discussion: Test an HDTV tuner card... |
Wonder if this is related to the fact that the PCIE controller cannot perform 64 bit accesses |
Next attempt - DVBSky S952 v3 dual DVB-S2 tuner. It needs
|
Nice! What software do you use with it? I honestly haven't done much with tuners on Linux before; I used to use EyeTV from Elgato back in the day, but that was never ported to Linux AFAICT. |
A little more playing.
so largely the same as the WinTV QuadHD which has a built in PCIe switch (PericomPI7C9X2G304). TBS6284 quad DVB-T2 tuner works fine on the end of a single PCIe switch, but also fails in the chain. https://github.com/6by9/linux/tree/rpi-5.10.y-tbs/ rebased and updated to pull in drivers for TBS6984 (not arrived yet), and I've done the same with https://github.com/6by9/linux/tree/rpi-5.15.y-tbs/ |
I don't know if @geerlingguy wants to add these to his site, but the cards I have working are:
Believed working:
Ought to recheck: Unless any others pop up on Ebay at silly prices then I think I'm calling this done - yes you can use a CM4 system as a TV receiver. TBS cards are a pain as their drivers are out of tree and pretty ugly in coding style. I'm not even going to look at their FPGA based cards (although a TBS6909 would be tempting as an octa DVB-S2 card) Now to work out if I have sufficient feeds to run all the tuners I have at once (about 8 DVB-S2 and 10 DVB-T2! Shame there are only 8 DVB-T/T2 muxes in this area)..... |
@6by9 - I think I'd be happy adding those cards in the A/V section (https://pipci.jeffgeerling.com/#multimedia-av-and-sound-cards). |
Oh dear, a TBS6909 did just come up at a silly price. I guess I've got a little more work to do :-) And I'm now looking at satellite multiswitches to feed all these tuners! There was me thinking the octa LNB I installed would be sufficient for anything I cared to do - I guess I was wrong. |
TBS6909 turned out to be dead :-( At least I got a refund. Tried a combined rig with DVBSky S952 v3, TBS6985, and TBS6284 via a 4 way PCIe switch, alongside my 4 port SATA card (Marvell 9215). That did prompt me to try that rig out in my x86_64 machine. Ubuntu booted off a USB stick sees the above 3 tuners and the Hauppauge QuadHD I'd stuffed in there. No drivers for the TBS cards, but DVBSky and QuadHD show up. The QuadHD will actually tune though, and I can watch streams through VLC. So it's not dead, and I need to have a further look at why it's not happy on the CM4. |
It seems a lot of older cards (especially PCIe gen 1) require the tweak to work. Kind of annoying, but I think the solution is to either build specifically for the older card and sacrifice some newer gear (though there might be some SATA II card that works with it enabled), or give up the functionality from that older card. |
Whoops.
Not sure why it reports as a 4 tuner card as it's a TBS6909 octa DVB-S2 tuner. |
Er, it helps if you don't leave
The cx23885 in the Hauppauge card needs My TBS6284 (quad DVB-T2) and TBS6985 aren't being recognised in the PCIe switch. I'll have to see if they work direct, otherwise it may be that they're just dead. Now to sort out some form of storage around this device and see just how many channels I can record at once :-) |
Last update for now. |
Ah, I'd forgotten that the TBS 6284 and 6985 require the PCIe link to be forced to gen 1. You can do that for the brcmstb root controller, but there doesn't appear to be an easy solution for PCIe switches that I can see. Switching to my other PCIe switch (Pericom PI7C9X) didn't help. So 21 tuners is probably my limit for the time being. |
hi all, i think i made a step forward in including the tbs 6984 using an asm1184e raiser board it´s quite late here so i just give the quick version for now, also no stream test has been done just enumeration worked. first i added 2 scripts on the pi and installed setpci then i set all asmedia enum´s to linkspeed 1 maybe we can also just set that one port and keep the pi and the other ports on gen2 speed? and sure enough after that it appears to be alive! :) hope that helps and let me know how the testing goes br stinger1/stinger151/francesco |
@FrancescoRestelli Thank you! I'd started reading through the information about PCI configuration blocks, but had some real work to do and therefore dropped it. |
Hmm, some further tweaking required. Run it with just the 6284 and 6985 connected, only one card is detected at a time, but they don't initialise happily
|
Hi, I succesfully installed a TBS6902 on Raspberry Pi OS with 5.15.79-v7l+ compiled kernel but I'm facing a strange issue with this device. I can tune a satellite frequency however, no matter the application that I used, the signal doesn't get lock. There is no PCIe switch on my board. lsmod command output:
dmesg command output:
|
@ Kitoko86 Welcome to the fun world of working with out of tree drivers. Support needs to come from TBS, which means https://github.com/tbsdtv/linux_media/issues. They aren't always the most responsive, particularly when they find out you're running on a Pi. |
@Kitoko86 make sure you have set "dtoverlay=pcie-32bit-dma" in /boot/config.txt if i remember right this happend when the dma range is wrong and therefore no data can flow |
The card works flawlessly in an x86 computer. It seems that is linked to the tbsecp3 driver serie because I have the same symptoms with a TBS6909. I'm going to test a Digital Devices Octopus CI S2 and give a little feedback about it. I will contact the TBS support team to diagnose the issue.
Already tried that on 64 bit OS and no change. Thanks anyway for the advice. |
Can't tune with a Digital Devices Octopus CI S2. The dmesg throws me an error about the driver when I try to tune a frequency. There is only one device, the TBS6290, a DVB-C/-T/-T2 tuner based on the SAA716x that gives me good results. |
I got the smipcie module built and firmware installed. If I modprobe the module then it However, I've got a problem if the module is automatically loaded upon boot. If I disable the UI, I get console login regardless of whether the smipcie module is loaded or not. Any ideas? |
Hi,good day.I hawe DvbSky s950c pcie s2 and now not giwing me no more signal.Dont know is it becouse card not work anymore or is it new bios after i instaled or new chipset or its becouse windows new update .Please can you help me what i can check what isue is? |
This repo is about getting devices working with a Raspberry Pi running Linux. |
sry hard to find someone for that issue im not in linux hard for me i
tried long time ago
sri, 20. stu 2024. u 15:40 6by9 ***@***.***> napisao je:
… Hi,good day.I hawe DvbSky s950c pcie s2 and now not giwing me no more
signal.Dont know is it becouse card not work anymore or is it new bios
after i instaled or new chipset or its becouse windows new update .Please
can you help me what i can check what isue is?
This repo is about getting devices working with a Raspberry Pi running
Linux.
If you're using Windows, or an x86 processor (ie Intel or AMD), then this
is the wrong place to be asking.
—
Reply to this email directly, view it on GitHub
<#57 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/BNC6FEVY4IEHLEUMYTJXLAL2BSNNFAVCNFSM6AAAAABSEVMZRCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIOBYG43DEMBSGQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
I always had this idea of having a Raspberry PI Working as a Satellite/Terrestrial Reciver and Media Player.
This could finally be achieved if PCIe Tuners works.
Example of a Dual Tuner PCIe Card:
TBS6522 Dual Tuner PCIe Card DVB-S2X S2 S T2 T C2 C ISDB-T Multi Standard Digital TV Card Live TV/Window/Linux/HTPC/IPTV Server https://www.amazon.com/dp/B01MR28YAA/
Also This could be tested on a more specialized linux distro Like:
OSMC
LibreELEC
OpenPCTV
The text was updated successfully, but these errors were encountered: