Loading Raspberry Pi 3 wifi kernel module outside of a service

raspberrypi3
wifi

#1

We have a Raspberry Pi 3 compute card, which doesn’t have a dedicated wifi module. We have a custom wifi chip connected via SDIO and we need to load a kernel module at runtime to enable wifi communication. We load the kernel module after application start, and everything works wonderfully.

The problem we’re having is that if we switch applications and a reboot happens (e.g. changing service variables or restarting the device), the old application will not be re-launched and the new application isn’t finished downloading. Since we only have wifi while an application is running, we won’t have wifi access to continue downloading the new application, so we’d need manual intervention to reconnect the device to ethernet, which is a very difficult process.

Is there a decent way to load kernel modules when the host OS starts instead of when the application starts? Ideally in a way that wouldn’t require forking either the resin supervisor or resin OS, but I can’t see a way around that. Any other solution I might be missing?


#4

Currently we do not have a way for inserting kernel modules from within the host OS. We have plans for this, but it will take time to get there.


#5

Sounds like we’re going to have to run a custom build. Thanks for the info! I’ve upvoted the HostApp Trello card on the public roadmap, assuming that’s the solution in the works.


#6

Yes, host OS apps is what will enable this.