# Using a raspberry pi pivpn to tunnel for communication

Source: https://forum.modalai.com/topic/813/using-a-raspberry-pi-pivpn-to-tunnel-for-communication
Category: ESCs, Sensors and Accessories (https://forum.modalai.com/category/15/escs-sensors-and-accessories)
Tags: cellular
Posted: 2022-03-21 20:06:23 UTC by David Smyth
Replies: 4 · Views: 1730

## David Smyth · 2022-03-21 20:06:23 UTC

In case anyone wants to connect without having to use a cloud service, it's possible to run pivpn to run openvpn on a raspberry pi (or other linux machine) to create the tunnel, while only needing to download the corresponding ovpn file on the voxl. Convenient for testing purposes at least. When using with a mobile network you'll need to take a look at the following: https://github.com/pivpn/pivpn/issues/54.

## Reply by Chad Sweet (ModalAI staff) · 2022-03-21 20:10:31 UTC

Great feedback, thanks!

## Reply by David Smyth · 2022-03-21 20:43:17 UTC

No problem. I also created a corresponding .service systemd file so that on start up the voxl will connect using the LTE module and then start the vpn client. A second .service file starts the video stream which can be viewed over QGroundControl connected to the same vpn. Seems like this would be a common workflow whenever flying. Might be worth taking a look at using Wireguard instead of openvpn in the future to reduce the vpn overhead.

## Reply by Eric Katzfey (ModalAI staff) · 2022-03-22 16:08:56 UTC (in reply to David Smyth)

@David-Smyth Once again, thanks! WireGuard does indeed look like a nice alternative to openVPN.

## Reply by pthomason · 2024-09-06 17:39:22 UTC (in reply to David Smyth)

@David-Smyth Would you be willing to share the .service files you created?
