Allow loading firmware files on boot

Yes, please have a look there:

The installation and setup was easy, but it is of no use to me, because nobody at HA seems to be interested to solve the problem with the firmware files for DVB-T2 USB sticks, or I haven’t understood how to solve it myself. :pensive:

What driver are you seeking?

It’s about these 3 files:

Under which path the files are to be stored, I don’t mind, as long as they survive a system reboot and are correctly loaded on system boot and used by the tvheadend add-on. It would be really great if this worked! :hugs:

@nickrout
Has my reply answered your question?

Yes, and agners has answered your question.

Put the files in /share/firmware

Change the cmdline as shown in the github issue.

Reboot.

Check the commandline with cat /proc/cmdline

Sorry, but where? I’ve seen so many different advices - depending on how HA is set up etc. - that I’ve lost track.

E.g., do I need to follow instructions for developers to access /root via ssh port 22222, or is it also possible via the Advanced SSH Terminal add-on with save mode disabled?

Some posts were about /mnt/boot/firmware/, now I read about /share/firmware/, not to speak about the correct syntax in the boot parameter.

I appreciate your patience and help very much. Thank you! :+1:

Probably because you keep starting new threads, and not answering his questions. How to use firmware search path? (e.g. `/mnt/data/supervisor/share/firmware`) - #5 by agners

Have you seen my reply there?

I followed the the Raspberry Pi guide to install Home Assistant Operating System and both /mnt/ and /share/ are empty in my HA installation.

/config is where your configuration.yaml resides. Go 1 directory up (…/config) and you will find /share

1 Like

Yes, as I say (and as Agners stated later in the thread) you didn’t answer his question.

If you mean this:

It’s not a question, so I’m not sure if you really meant this. I’m using the “recommended” installation (Raspberry Pi 4) and do not want to change it.

I appreciate it very much if you kindly pointed me to that question you refer to. Thank you. :smiling_face:

PS:
The other advice in that thread was this:

As I wrote there in response, my problem is that this folder structure does not exist, and when I create it, it is gone again after a reboot. I asked further questions about it, but either my questions were irrelevant or misunderstood, or I missed the whole point and ridiculed myself. :face_with_open_eyes_and_hand_over_mouth:

He asked a question. You clearly missed the question despite this

And now you don’t do any of this

@nickrout @agners
I simply wanted to have 3 firmware files (which I clearly stated over at GitHub) (*) permanently stored and correctly loaded with HA. I replied that I do not want to use another HA installation than the “recommended” one:

follow the Raspberry Pi guide to install Home Assistant Operating System

If placing firmware files in HA (installed the “recommended” way) is (still) not possible or not easy for normal users (i.e. without following “developer-only guides”), then please kindly say so.

If I still missed the point in your opinion, I appreciated it very much if you were so decent to tell me where exactly I failed. Thanks for your efforts.

PS (*) footnote for above - I answered the question:

So yes, I did answer the question, or didn’t I?

https://github.com/OpenELEC/dvb-firmware/raw/master/firmware/dvb-usb-it9303-01.fw
https://github.com/OpenELEC/dvb-firmware/raw/master/firmware/dvb-demod-si2168-02.fw
https://github.com/OpenELEC/dvb-firmware/raw/master/firmware/dvb-demod-si2168-b40-01.fw

I am not sure, but just trying to help.

Not in the thread where Agners asked.

Anway I asked you to post some debugging, and gave you the command.

Also dmesg is a good kernel boot tool.

This does not lead to anything. Over at GitHub I asked this:

@agners @HahnBenjamin I don’t have this path: /mnt/data/supervisor/share/firmware/

There’s /mnt but it’s empty. What have I missed?

PS: I have asked also in the HA community: How to use firmware search path? (e.g. `/mnt/data/supervisor/share/firmware`)

I go this answer from @agners at GitHub:

This is an issue tracker and not a support forum. I’ve responded to your community post.

Then in the community forum, I got this reply from @agners

/mnt/data/supervisor/share is mapped to /share in typical addons. E.g. you can use the Samba add-on to access that location. You would need to add firmware directory in the share folder, and store firmwares in there.

What firmware are you missing?

I provided the direct link (back to the GitHub issue!) where I provided the firmware files.

And still, my question about the empty /mnt/ path remains unanswered.

I understand that you guys do all this in your free time and unpaid, and I appreciate it. But I also wonder where I took the wrong turn that my question led to this dead-end. Maybe we simply misunderstood each other (and it’s very likely my fault, so I beg your pardon).

By the way, I also tried to store the firmware files under /lib/firmware/ (as I mentioned in the GitHub issue), but that path also is empty after a reboot.

What does “exposed to the supervisor” mean? (quoted from an answer in the GitHub issue):

I my case I placed the firmware files in the /share folder exposed to the supervisor, specifically /share/firmware

I really don’t understand these details, and maybe that’s my problem (and therefore I asked).

Ok, only months later I understand that the paths described obviously meant the underlying system, whereas I logged into HA and placed them there. Well, at least I think that was my problem. I’ve now managed to get access to the underlying system with ssh via port 22222 and public/private keys and will see if that helps me further.

I hope that I am now in the right place:

# ls -al /mnt/data/supervisor/share/firmware
total 24
drwxr-xr-x    2 root     root          4096 Nov  6 11:28 .
drwxr-xr-x    3 root     root          4096 Nov  6 11:28 ..
-rw-r--r--    1 root     root          2728 Nov  6 11:28 dvb-demod-si2168-02.fw
-rw-r--r--    1 root     root          6919 Nov  6 11:28 dvb-demod-si2168-b40-01.fw
-rw-r--r--    1 root     root          2169 Nov  6 11:28 dvb-usb-it9303-01.fw
#

.
In case other users are interested in this, here’s what I did on a Windows 11 PC (PowerShell) to ssh into the underlying system):

> ssh-keygen -t rsa -b 4096
> cat ~/.ssh/id_rsa.pub > D:\authorized_keys

In my case, the USB stick has the “D” as volume letter. Replace it by yours’ and make sure that the file content is ANSI encoded (not UTF-8) and with with Linux (LF), not Windows (CR LF) line ends. You can do this with e.g. Notepad++.

Then I unplugged the USB stick from my PC, plugged it into my Raspberry Pi 4 with HA, and restarted the system (not only HA). Then I was able to log in like this:

ssh -i ~/.ssh/id_rsa  root@<IP address of my Raspberry Pi 4> -p 22222

Put your device’s IP address there. Voilà:

Welcome to Home Assistant OS.

Use `ha` to access the Home Assistant CLI.
#
# ls -al
total 2
drwx------    4 root     root            42 Oct 26 11:20 .
drwxr-xr-x   13 root     root           222 Oct 26 15:04 ..
drwxr-xr-x    2 root     root          1024 Apr  4  2023 .docker
drwxr-xr-x    2 root     root          1024 Apr  4  2023 .ssh
#
# ls -al /
total 4
drwxr-xr-x   13 root     root           222 Oct 26 15:04 .
drwxr-xr-x   13 root     root           222 Oct 26 15:04 ..
lrwxrwxrwx    1 root     root             7 Oct 26 11:54 bin -> usr/bin
drwxr-xr-x   17 root     root          4060 Apr  4  2023 dev
drwxr-xr-x   28 root     root          1080 Oct 26 15:04 etc
drwxr-xr-x    2 root     root             3 Oct 26 11:54 home
lrwxrwxrwx    1 root     root             7 Oct 26 11:54 lib -> usr/lib
lrwxrwxrwx    1 root     root             3 Oct 26 11:54 lib64 -> lib
drwxr-xr-x    6 root     root            68 Oct 26 11:20 mnt
dr-xr-xr-x  356 root     root             0 Jan  1  1970 proc
drwx------    4 root     root            42 Oct 26 11:20 root
drwxr-xr-x   21 root     root           620 Nov  6 17:47 run
lrwxrwxrwx    1 root     root             8 Oct 26 11:54 sbin -> usr/sbin
dr-xr-xr-x   12 root     root             0 Jan  1  1970 sys
drwxrwxrwt    7 root     root          4096 Nov  6 18:05 tmp
drwxr-xr-x    7 root     root           126 Oct 26 15:04 usr
drwxr-xr-x    8 root     root           200 Apr  4  2023 var
#
# ls -al /mnt
total 21
drwxr-xr-x    6 root     root            68 Oct 26 11:20 .
drwxr-xr-x   13 root     root           222 Oct 26 15:04 ..
drwxr-xr-x    5 root     root         16384 Jan  1  1970 boot
drwxr-xr-x    2 root     root             3 Oct 26 11:20 config
drwxr-xr-x    6 root     root          4096 Oct 30 10:14 data
drwxr-xr-x    6 root     root          1024 Apr  4  2023 overlay
#

Hi, is your tuner work after putting the filles in “/mnt/data/supervisor/share/firmware” ? I put my firmware in the path and try many ways to make the kernel search path point to the folder. How did you make this persistent?
Even when I succeed to get the firmware uploaded I can’t get tvheadend to see my tuner. At the tvheadend boot I see “Tuner is busy. Error - 16” maybe this is my issue…
Any ideas?

Yes, it works. I set up Kodi on my PC, pointing to the RPi4 that runs HA and the tvheadend add-on. Regarding your problem, please have a look there:

And there (same thread but further below):

Hopefully, this helps!

Thank you very much! I progress a little since I write in the post. Did you have to unplug and replug after a reboot? I have a weard issue, but I think I will post it on the other topic.
Thank you!

I remember that I had to unplug it once, and @agners mentioned problems in this context, too. But overall, so far it works. I wish we did not have to install 2 tvheadend add-ons but the original one has the known bugs. Since I’m no programmer, I could not offer a PR.