From 14e7306992c36e26448586a4bf5c11384f5a037b Mon Sep 17 00:00:00 2001 From: Vasily Evseenko Date: Mon, 23 Jan 2017 19:08:28 +0300 Subject: [PATCH] Add README --- LICENSE | 2 +- README.md | 26 ++++++++++++++++++++++++++ rx.sh | 6 +++--- 3 files changed, 30 insertions(+), 4 deletions(-) create mode 100644 README.md diff --git a/LICENSE b/LICENSE index f85606e..d51fd40 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ wifibroadcast and its FEC code are free software - you can redistribute wifibroadcast core functionality and/or + you can redistribute wifibroadcast core functionality and/or it them under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License. diff --git a/README.md b/README.md new file mode 100644 index 0000000..d8d19e7 --- /dev/null +++ b/README.md @@ -0,0 +1,26 @@ +This is a completely rewrited from scratch version of https://befinitiv.wordpress.com/wifibroadcast-analog-like-transmission-of-live-video-data/ +The main modification is how to data are encapsulated into ieee80211 frames. The original wifibroadcast/wifibroadcast-ez accepts stream +of bytes and split them into packets don't related to x264 stream structure. This can emit up to 100ms latencies. In my case wifibroadcast accepts +UDP stream (for example x264 encapsulated into RTP packets). This provides low latency streaming. + +Sample usage chain: +``` +Camera -> gstreamer --[RTP stream (UDP)]--> wifibroadcast_tx --//--[ RADIO ]\ + --//--> wifibroadcast_rx --[RTP stream (UDP)]--> gstreamer --> Display +``` + +For encode logitech c920 camera: +``` +gst-launch-1.0 uvch264src device=/dev/video0 initial-bitrate=6000000 average-bitrate=6000000 iframe-period=1000 name=src auto-start=true \ + src.vidsrc ! queue ! video/x-h264,width=1920,height=1080,framerate=30/1 ! h264parse ! rtph264pay ! udpsink host=localhost port=5600 +``` + +To decode: +``` + gst-launch-1.0 udpsrc port=5600 caps='application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264' \ + ! rtph264depay ! avdec_h264 ! clockoverlay valignment=bottom ! autovideosink fps-update-interval=1000 sync=false +``` + + +Supported WiFi hardware: Ralink RT2800. Was tested with ALPHA AWUS05NH v2 in 5GHz mode. To disable ieee80211 autospeed and maximize output power you +need to apply kernel patches from ``patches`` directory. See https://github.com/bortek/EZ-WifiBroadcast/wiki for details. \ No newline at end of file diff --git a/rx.sh b/rx.sh index 2f71e6b..4831db7 100755 --- a/rx.sh +++ b/rx.sh @@ -1,8 +1,8 @@ #!/bin/bash WLANS=$@ -CHANNEL5G="6" -#CHANNEL5G="149" +#CHANNEL5G="6" +CHANNEL5G="149" for WLAN in $WLANS do @@ -14,5 +14,5 @@ ifconfig $WLAN up iwconfig $WLAN channel $CHANNEL5G done -./rx -u 5601 $WLANS +./rx -u 5600 $WLANS #tcpdump -i $WLAN 'ether[0x0a:4]==0x13223344'