Community Forum

Wifibroadcast - low budget analog-like HD transmission with OSD

(Corrado Steri) #21

Really curious about procedure here too.

Thank you in advance



Wouldn’t this be a good idea to integrate wifi broadcast in the EMLID image provided?
As gstreamer already is installed, we only are one step away from having a “out of the box” solution for HD Streaming in flight with Navio 2 + RPi.

(Mikhail) #23

@Guiboy we have that planned :slight_smile: hope that it gets into the new image in a couple of months.


very good to read!
“Couple of months” means before the end of the year or after? I can’t wait to use it. I indeed could not go through the manual steps of the existing tutorial… I am hesistating between investing much time into understanding every bit of code or waiting for your marvelous disk image… :wink:

(Mikhail) #25

Marvelous disk image should be ready before the end of the year :slight_smile:

(Marcello) #26

No offense Rangarid but Emlid gave you a Navio 2, a $168 value, to make some good post and content. The clear intention of this was to help give their customers, us, a streamlined way to enhance the capability of their device, in this case with FPV from an RPi and RPi cam.

I am surprised that none of the staff have reached out to you asking or reminding you to keep up the work, and realized one person has recently asked you about you not posting. Though I feel you have an obligation to do what you were asked.

Personally, I am commenting because I was interested in setting up wifibroadcast and having an easy guide to follow on this forum, then noticing you blew this off. Many others, myself included, would have loved to take this opportunity for a device we had to pay $168 for and that without any accessories (which they may have also given you).

So id appreciate it if you finished your blog.


(Garrett Taves) #27

He already has a blog that has detailed instructions which worked for me. Yes, it should be posted better here, but it’s available if you just look.


Sorry mates, i was quite busy with family so i forgot to follow up. Actually i never had it running in the air, only on the ground, i was only flying for like 1h or so over the last 6 months. At that point i did not know, that i can not finish the detailed instruction in time. Sorry for that.

In the meantime i worked on buildroot support (which might be interesting if APM can be ported to buildroot as well, reduced boot time quite a bit):

Maybe someone can use it. Its still missing the autostart scripts, apart from that it works for buildroot.

Here’s a quick install instruction for more experienced people:

TX side (Navio Pi)

  1. sudo apt-get install mercurial libpcap-dev iw
  2. hg clone https://bitbucket.org/befi/wifibroadcast
  3. (optional if using AR9271 based dongles like TP-LINK TL-WN722N) sudo cp wifibroadcast/patches/AR9271/firmware/htc_9271.fw /lib/firmware
  4. cd wifibroadcast
  5. make

Then once everything is build you can manually run wifibroadcast like this:
sudo killall ifplugd #stop management of interface sudo ifconfig wlan0 down sudo iw dev wlan0 set monitor otherbss fcsfail sudo ifconfig wlan0 up sudo iwconfig wlan0 channel 13 raspivid -ih -t 0 -w 1280 -h 720 -fps 30 -b 4000000 -n -g 60 -pf high -o – | sudo ./tx -b 8 -r 4 -f 1024 wlan0
Replace channel number and raspivid parameters as you like.

sudo apt-get install mercurial libpcap-dev iw hg clone https://bitbucket.org/befi/wifibroadcast cd wifibroadcast make

Overwrite original hello_video with modified one:
cd $HOME hg clone https://bitbucket.org/befi/hello_video cp hello_video/video.c /opt/vc/src/hello_pi/hello_video cd /opt/vc/src/hello_pi/ ./rebuild.sh

Manually run application:
cd $HOME/wifibroadcast sudo killall ifplugd #stop management of interface sudo ifconfig wlan0 down sudo iw dev wlan0 set monitor otherbss fcsfail sudo ifconfig wlan0 up sudo iwconfig wlan0 channel 13 sudo ./rx -b 8 -r 4 -f 1024 wlan0 | /opt/vc/src/hello_pi/hello_video/hello_video.bin

the TX and RX parameters -b, -r, -f must be the same!

Automatic starting:

cd #go into home directory hg clone https://bitbucket.org/befi/wifibroadcast_fpv_scripts cd wifibroadcast_fpv_scripts sudo cp init.d/wbctxd /etc/init.d sudo update-rc.d wbctxd start

cd #go into home directory hg clone https://bitbucket.org/befi/wifibroadcast_fpv_scripts cd wifibroadcast_fpv_scripts sudo cp init.d/wbcrxd /etc/init.d sudo update-rc.d wbcrxd start

Cam must be connected to TX raspi, else it will not work.

OSD is still experimental, as there is a bug in the OpnVG core library. Until that is fixed i do not recommend to use my OSD.

For those that just want to try wifibroadcast without Navio here is a simple image that has everything setup for you:
It has a simple configs textfile where you can modify everything from windows.

NAVIO2 with EZ-Wifibroadcast
(David Posea) #29

I am working on this for the pxfmini, and it’s almost there. I get mavlink data sent to mission planner over a LAN link, now I just need to send it over the existing wifibroadcat link. I’ll post full instrctions and scripts on rcgroups when it’s all working (a few days at most) and post a link here. It’s really easy to get wifibroadcast working , OSD is a bit trickier.

(Yannis) #30

@mikhail.avkhimenia, that sounds great. Looking forward to the new image.

@Rangarid, thanks for posting the instructions here. I was wondering if the Atheros patch is the one that allows the use of channels outside the 2.4GHz range?

@voi9viper, great progress there. Looking forward to your results!


That patch does not include the 2.3G channels i think. It only includes better default settings. Will check for 2.3G fmw tomorrow.

(Yannis) #32

So it seems that in the website below (it is in French) they patched the 2.3 hambands to the EMLID PREEMPT-RT image… could be a good starting point…

EDIT: There is an english version as well:


Will you have a solution for avoiding to use 2 RPis ?
I would like to use RPi3+Navio2+RaspiCam on my quad and hopefully using Tower RPi video stream feature on an Android device for my GCS.
It works perfectly currently with “normal wifi” but the range is quite limited on top of the major issue of having stalled images when connection is poor…

(David Posea) #34

I bought a Navio2 and I’m really close to releasing an image. The new kernel with firmware changes will help. I am also modifying the ath9k_fw to allow setting the bitrate by passing a new header type that is ignored if not there. This eliminates any changes needed to the kernel. Also I\ve already updated tx to accept a bitrate parameter to eliminate having multiple copies of tx like tx.18, tx.24, tx,36 etc. Mavproxy and socat work great. There is also support for a two way link, or at the least a separate uplink , although you may need another tx card. Have not tested receiving on the same card as transmitting, but using another wifi card on a different channel certainly works. I’m having a problem getting battery data from the arduplane program by default. It sends a lot of the useful data for an OSD, position, speed, attitude, etc. but battery data is missing. I’m trying to figure this out tonight. Right now everything is sent at 48 mbits/sec on AR9271 cards, not sure if ralink cards work without kernel changes yet, but I think they do. I have a pair of each type for testing. There is a new EZ-wifibroadcast 1.3 beta image but the changes are made for an end user to have an easy time. It complicates development. I’ll be glad to make an image for Navio2 that has the changes I made to speed up development, if anyone wants one. The new beta relies on connecting with HDMI and a keyboard, with different functions on each virtual terminal , i.e. ALT-F1, ALT-F2, … For me to use ssh I changed the scripts to accept a tty port number as a parameter, so you can start as many copies as you wish by opening a new terminal and running the same command with different tty ports. Fixing the battery issue, eliminating kernel patches, and getting an uplink going are my big priority items. I got slowed down by a rather large hurricane that left me powerless for a while.

(David Posea) #35

I’m recommending the Navio2 s the preferred flight controller for Wifibroadcast from now on. This is due to EMLID being open source to a large extent, making kernel images available, as well as source. I’lm adding all the wifibroadcast patches and building a kernel now, and i’ll package that with the lastest wifibroadcast beta image. I’ll include socat and MAVProxy for telemetry along with Rangarid’s OSD. Someone else will need to add the android support. Way to go emlid support, it’s nice to have a company that is willing to work with a open source project like this one. And the price is a lot better then a pixhawk, with very little weight gain. Full flight control with HD video for under $300 US is going to be very hard to beat.Bit rate control will be available for Atheros and Ralink cards, and we can investigate others if firmware becomes available that can be controlled. If anyone has suggestion on what they want included please let me know. I should have a working beta image done in a week or less, unless we have another hurricane or the weather off the florida coast improves. Then I’ll be out in the gulf stream chasing mahi mahi and sailfish. They are coming closer to shore due to the annual mullet run, and the seas are too rough to go out right now :frowning:

(David Posea) #36

I know befi (the originator of wifibroadcast has been working on an android port, and the new EZ-WBC image has support for Android. I don’t know id IOS will ever be an option, which is too bad cause I have mini ipads, but no android ones.

(Corrado Steri) #37

Hello, this is great news.

Will it be possible to use wifibroadcast only with raspberry cam or we will be able to use ip cameras or webcams?

It would be great if ip cameras could be routed trough wifibroadcast.


(David Posea) #38

I know integrating an IP camera is pretty easy, but the latency went way way up , so everyone I know stopped trying to use them. There are a lot of cheap PI cams available, I have a wide angle one with adjustable focus that is the best I’ve seen without any image adjustment except focus. I can look at IP cameras again once I clean up a few other issues, mostly adjustable bitrate for AR9271 based cards. I’m build a fully patched kernel tonight.

(Corrado Steri) #39

Actually for our application latency is not that important. We are using a Sony Block 7500 camera with 30x optical zoom.

What do you mean by way way up? If it is lower than 1 second i think it could still be great for some applications.


p.s. Please let us know if you need us to make some tests on our ip camera if needed.

(David Posea) #40

I think the latency was more like 1500 ms. I encourage every one to check the RC Groups thread:


it has more details on other configurations. i will look into IP cameras for you. I have a few laying around. I’m so mad right now I built the wrong kernel defconfig, and the build just finished and is running again with bcm2709_defconfig. I used bcmrpi_defconfig :frowning: A complete image is only a day or two away. I want to contact emlid to see if they have suggestions that should be added. I found the battery voltage problem, and of course it was a completely dead lipo, but the only one I had with the yellow connectors. I soldered in deans and now have lots of battery choices, and I’m looking at requesting SV2 and SV3 by default, or any othter parameter you with, all on the tx side. Two way communication will be added, but it also very easy with an rpi 3 to use the on board wifi as an AP. Connect to it on the ground, tune the APM or add a mission, disconnect and go fly. Two ways coms have shorter range. We are aending data at lower bitrates to improve range, so right now 720p at 48hz id the best image.I hope to have a full flight test plane set up very soon to test range, clarity, and mission planning. There are several other people on RC Groups working very hard to make this easy to install, and very very functional. We want to concentrate on a couple of flight controllers first, and of course navio2 is one of those. Cleanflight is the other. I think the pixhawk derivatives will just work as well. If anyone has specific requests ask away here or on rc groups and we will try to include them as soon as we can. And of course any input from Emlid will be a great help. I have another project I need to work on, this one for cash, so I need to finish wifibroadcast as soon as possible. Can anyone help with a patent search? I want my new, non-rc idea to make money for me, and I do not think it’s ever been done the way I want go with it. sorry for the secrecy, but thiefs are out that and will patent a leaked idea just on speculation.