[HOW TO] Geniatech HDStar V3 Dvb-S2 install

[I would like to place this topic in the how-to’s, but I do not have rights to write there. So, here is the info]:

Geniatech HDStar V3 Dvb-S2 had been a real headache to install in raspberry pi 3.
I was almost to give up, but knowing that in the past some users were able to do it, keep me in the track.
This is my Solution.


CRAZYCAT’s v4l media-tree for Raspberry Pi 3 in OSMC
Update media drivers

The following lines resumes the steps needed to compile an update version of the drivers.
If you only want to download the drivers goto to the end of the post.

================================================================================

How to compile kernel multimedia drivers for the installed OSMC kernel version.

This was made to get compatibility for Geniatech HDSTAR dvb-s2 version 3.X,
but will be useful for many other multimedia devices .
I’ve choose Crazycat’s v4l branch, as being the one that solved Geniatech issues
as of today (January 2019).
The approach used will be able to compile and update the drivers for
the currently installed kernel version, thinking on OSMC running in a raspberry pi 3.
For other configurations, you’ll have to surely adapt some things.


The following instructions were adapted from the fantastic summary already available
for some time here at osmc forums :slight_smile:

[HowTo] Compile DVB Media Build drivers on RPi 3


In my system I have a development space, that seats in a disk image in an external hdd,
but you can place everything in your sd-card.
A previous backup of your sd-card is strongly advised.
The following commands could be included in a script, but I strongly recommend the execute one by one.


1. Download build essentials:

sudo apt-get install git bzip2 make gcc patch patchutils libproc-processtable-perl libncurses-dev -y


2. Download kernel sources,
(downloads, uncompresses and removes .deb file to save space)
Repeat this step every time the kernel is updated:

sudo apt-get install rbp2-source-$(uname -r) -y
sudo tar -xjvf /usr/src/rbp2-source-$(uname -r).tar.bz2
sudo apt-get remove rbp2-source-$(uname -r)

sudo rm -rf /lib/modules/$(uname -r)/build
sudo ln -s $(pwd)/rbp2-source-$(uname -r) /lib/modules/$(uname -r)/build

sudo cp /boot/config-$(uname -r) /lib/modules/$(uname -r)/build/.config
pushd /lib/modules/$(uname -r)/build
sudo make oldconfig && sudo make prepare
popd


3. Download crazycat’s sources

git clone https://bitbucket.org/CrazyCat/media_build.git
cd media_build

update sources

git pull


4. Build
Use only 1st time, or to clean binaries after a kernel upgrade.
It cleans everything, pulls additionally needed files,
applies patches, enables everything and compiles:

./build

If you get errors in this phase or want to recompile after changing some files, go to next step


5 Re-select items to compile

I suggest to enable EVERYTHING in the menu EXCEPT:

  • HDMI CEC;
    This way you will update every driver available except the ones that
    are giving compilation errors, and it is not in the scope of this thread to solve.

sudo make menuconfig


6 Compile

make -j 4


7 Install drivers
( you should previously backup your current drivers and firmware - see bellow)

sudo make install


8 Backup & restore // media drivers and firmware

backup media drivers & firmware:
tar -cvzPf backup-drivers-media.tgz /lib/modules/$(uname -r)/kernel/drivers/media/
tar -cvzPf backup-firmware.tgz /lib/firmware

restore media drivers & firmware:
sudo tar -xPf backup-drivers-media.tgz
sudo tar -xPf backup-firmware.tgz


9 TESTING

Did everything went ok ?
Reboot your system.

Then, list your dvb devices:

ls -R /dev/dvb

Your dvb adapter, should be listed with:
at least 1 of each:
demux, dvr, frontend, net.

If geniatech was not propely detected, the frontend will no be loaded :frowning:
This is working just great for me.
Now, assuming you want ot use tvheadend, unfortunalley geniatech is taking around 60 seconds to load.
So tvheadend will only detect it after a:

service tvheadend restart

To avoid doing this at every reboot, you can edit tvheadend.service file to wait for all frontends to be loaded before tvheadend starts:

a) Edit the file:
/lib/systemd/system/tvheadend.service
b) Before ExecStart, add the line:
ExecStartPre=/bin/bash -c "sleep 10; for adapter in /dev/dvb/*; do COUNT=60; echo tvheadend testing $adapter; while [[ $COUNT -gt 0 ]]; do [[ -e $adapter/frontend0 ]] && COUNT=1; ((COUNT--)); sleep 1; done; done
c) Save
d) reload services:
sudo systemctl daemon-reload
e) reboot

That’s IT !
Good Luck !!!


Download pre-compiled drivers

If you want to directly try and installed my compiled version, just download from the following link:
Unzip the zip file to a directory in your sd-card.
execute with root privileges:
sudo ./install.sh

It will backup your current media drivers and firmware, and then install (overwrite) the new ones.

Please note: No warranties given!

Compiled drivers and firmware are here:
(compiled 23/1/2019 12:00)
https://www.sendspace.com/file/nj2lk6

Restore previous drivers and firmware

If you have any issues you can revert drivers and firmware by untaring them:

sudo tar -xPf firmware-backup-filename.tgz
sudo tar -xPf drivers-media-backup-filename.tgz

just remember to use the proper filenames that were created when running the install script

1 Like

I’ve just updated the tvheadend.service changes to properly wait for the dvb frontends to be loaded.