Rpanion rollover to AP wireless mode from STA mode

@stephendade I wish to use Rpanion not as a companion computer (although I do also use it for that purpose with Pi-Connect boards), rather I want a use self powered Pi Zero 2 W to plug into any of my aircraft after a flight and download logs and write them to my NAS (a Pironman 5 in my basement with a Public Key). Ideally I want to do this using the Flight Controller USB port and my PI can then power the FC.

It would be very useful to have the ability to set up a rollover to AP mode with first default being STA mode, and be able to enter the SSID and Password on the Network options without having to select the network. Is this a feature you think would be worth adding? If you did it would be great to have two SSIDs options (home wifi and cellphone hotspot) and if neither can be found then rollover to AP mode – ie the ‘rpanion’ SSID.

Right now I guess I will have to configure a USB port on the PI as a USB gadget so that I can set up the wlan0 – which I obviously can’t do when I am connected by SSH to the rpanion WAP.

It has been one of my goals for a long time to more easily capture all of my logs easily on my NAS and review them later. I did look at cloud options but I don’t want an AWS account.

It should already do that. When booted, Rpanion-server will look for any available Wi-Fi networks to connect to. If it doesn’t find any, it will switch to AP mode.

Are you not seeing this behavior?

The issue is a RP Zero 2W has one wireless interface in AP mode and I am connected to that to configure it. The configuration of SSIDs for STA mode relies upon the adaptor being in STA mode so it can see networks – I cannot enter SSIDs and Passwords. Thus I need to connect via USB. Am I right?

I will check with my ZeroW2 and confirm in a few days …

Ok, I’ve confirmed the issue and created a fix: Wifiscan by stephendade · Pull Request #263 · stephendade/Rpanion-server · GitHub. See if that works for you.

Fantastic. I will try out your fix in the next day or so and report back.

Stephen, sorry only getting to this – so clone the repo on a fresh install of RPi OS and run the install scripts with:
cd ./deploy && ./RasPi2-3-4-5-deploy.sh

That installs master? Or do I have to build it from Master? Sorry but I have only used your images previously – I have no issues if I have to build it, I just did not see a wiki section on that.

Yes that’ll install latest master.

Otherwise, there’s an upgrade script (GitHub - stephendade/Rpanion-server: Web-based configurator for companion computers of MAVLink vehicles) that’ll pull latest master and re-build.

1 Like

Stephen the changes work well. In addition, installing it starting from the RP OS essentially means I started out connecting through my home network so I essentially avoided the catch22 situation I had encountered when using a pro-configured image.

1 Like

I used the 64 bit Lite PiOS, not the full desktop version and for whatever reason I cannot seem to get the rpanion service set up using:

sudo cp rpanion.service /etc/systemd/system
sudo systemctl enable rpanion.service

The above run without error and this is what I see when I check what services are setup. Is there some dependancy with the Lite version I am missing – I did have to install git, for example, but that was the only extra step I could see.

marcdornan@rpanion:~/Rpanion-server $ sudo service --status-all
[ - ] alsa-utils
[ - ] apparmor
[ + ] bluetooth
[ - ] console-setup.sh
[ + ] cron
[ + ] dbus
[ - ] dnsmasq
[ + ] dphys-swapfile
[ + ] fake-hwclock
[ - ] hwclock.sh
[ - ] keyboard-setup.sh
[ + ] kmod
[ - ] nfs-common
[ + ] procps
[ + ] resolvconf
[ - ] rpcbind
[ - ] rsync
[ + ] ssh
[ - ] sudo
[ + ] triggerhappy
[ + ] udev
[ - ] x11-common
[ + ] zerotier-one

You’ll also need:

sudo systemctl daemon-reload
sudo systemctl start rpanion.service

If it’s still not running, post the output of sudo systemctl status rpanion.service

Still not starting up. Here is the result of: sudo systemctl status rpanion.service

I guess I can just use the full version of 64 bit PiOS if the Lite is going to be problematic.


rpanion.service - Rpanion Server Service

Loaded: loaded (/etc/systemd/system/rpanion.service; enabled; preset: enabled)

Active: failed (Result: exit-code) since Mon 2024-12-16 12:54:53 CST; 2min 6s ago

Duration: 3ms

Process: 531 ExecStart=/usr/bin/npm run service (code=exited, status=217/USER)

Main PID: 531 (code=exited, status=217/USER)

CPU: 0

Dec 16 12:54:53 rpanion systemd[1]: rpanion.service: Scheduled restart job, restart counter is at 5.

Dec 16 12:54:53 rpanion systemd[1]: Stopped rpanion.service - Rpanion Server Service.

Dec 16 12:54:53 rpanion systemd[1]: rpanion.service: Start request repeated too quickly.

Dec 16 12:54:53 rpanion systemd[1]: rpanion.service: Failed with result ‘exit-code’.

Dec 16 12:54:53 rpanion systemd[1]: Failed to start rpanion.service - Rpanion Server Service.

I use 64-bit RasPiOS Lite for development, so it should definitely work there.

Looks like there’s some issue starting the service.

Can you try running Rpanion-server manually:

sudo systemctl stop rpanion.service
export PORT=3000
cd /home/pi/Rpanion-server
/usr/bin/npm run service