RPi + Runeaudio +Wifi as Accesspoint

Raspberry Pi related support

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby hondagx35 » 08 Sep 2016, 16:59

Hi dror,

what are they used for?


With the newest kernel all audio devices are disabled by default.
To get the old behavior you have to add "dtparam=audio=on"

The raspberry.conf file is not needed anymore and causes errors during boot, so we have to delete it.

Frank
User avatar
hondagx35
 
Posts: 3039
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby johnbanks » 11 Sep 2016, 00:27

Frank ...

I'm happy to report that I now have successfully got a Wireless AP working on an RPi2 and an RPi3 using the Edimax adapter and also using an adapter with a RaLink RT5370 chipset. I have also been successful using the RPi3 built-in wireless.

I followed the instructions you gave earlier in this thread plus 2 additions ...

1) I installed rng-tools because I got an error report about entropy. Did I do wrong?

2) I added 2 lines to /etc/hostapd/hostapd.conf based on advice I saw regarding the RPi3 built-in wireless. My generic hostapd.conf is ...

# interface and driver
interface=wlan0
driver=nl80211
ieee80211n=1
# Comment out following line if using a WIFI adapter with RT5370 chipset
ht_capab=[HT40][SHORT-GI-20][DSSS_CCK-40]

# WIFI-Config
ssid=Rune_AP
channel=11
hw_mode=g
wmm_enabled=1
macaddr_acl=0
auth_algs=1
max_num_sta=10

# WIFI authorization
wpa=2
wpa_key_mgmt=WPA-PSK
wpa_pairwise=TKIP CCMP
rsn_pairwise=CCMP
wpa_passphrase=guglielmo

I've spent many hours getting to this point. My earlier lack of success was a failure to realise the low transmitting power of nano adapters when used as an AP. I had inconsistent results with the RPi 9 metres (plus a brick wall) away from my controlling laptop. When I moved the the RPi to 3 metres away - instant success.

Many thanks for your Wireless AP solution.
johnbanks
 
Posts: 124
Joined: 11 Jun 2014, 00:16

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby hondagx35 » 11 Sep 2016, 12:42

Hi johnbanks,

1) I installed rng-tools because I got an error report about entropy. Did I do wrong?

No, nothing wrong.
In my post on page two i have used "haveged" instead, because it's the more universal way.
"rng-tools" is used when a hardware random generator is available.
But one of both is needed to get the AP working correctly.

2) I added 2 lines to /etc/hostapd/hostapd.conf based on advice I saw regarding the RPi3 built-in wireless.

Thanks for your testing, i will check this settings.

My earlier lack of success was a failure to realise the low transmitting power of nano adapters when used as an AP.

Interesting, i never tried the AP over longer distances.

Frank
User avatar
hondagx35
 
Posts: 3039
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby Joe90 » 11 Sep 2016, 20:06

Hi Frank

Trying to get this to work on an RPi B.

Followed your instructions so far:

Installed the nightly build
Did not update firmware or kernel
checked for iw, not installed so installed with "pacman -S iw"
ran "iw list" which returned nothing!


Decided to press on and followed your howto on page 2 of this thread

On final reboot:

wlan0 does not come up
The Edimax is there as evidenced by lsusb
and I can bring up the wireless interface with "ifconfig wlan0 up"
and run "iw list wlan0 scan" and get back the wireless networks around me

Running "/usr/bin/hostapd /etc/hostapd/hostapd.conf" returns (hand typed)

Code: Select all
nl80211: Driver does not support authentication/association or connect commands
nl80211: deinit ifname=wlan0 disabled_11b_rates=0
nl80211 driver initialization failed
wlan0: interface state UNINITIALIZED->DISABLED
wlan0: AP-DISABLED
hostapd_free_hapd_data: Interface wlan0 wasn't started



What else do I need to do, or what else do you need to know to help, or am I just wasting my time ;)
Joe90
 
Posts: 13
Joined: 11 Sep 2016, 19:42

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby johnbanks » 11 Sep 2016, 21:52

joe90 ...
Excuse me butting in with my 2 cents worth ...
You could try a wireless dongle with a RaLink RT5370 chipset.
They are very inexpensive ... but then I don't know your location
johnbanks
 
Posts: 124
Joined: 11 Jun 2014, 00:16

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby hondagx35 » 11 Sep 2016, 22:09

Hi Joe90,

ran "iw list" which returned nothing!

From my HowTo on page 2:
You can try this on all other platforms, but skip updating kernel and firmware.
The EDIMAX EW-7811UN will only work with latest kernel!

So will not work on a RP B!

johnbanks has the correct tip for you.
johnbanks wrote:You could try a wireless dongle with a RaLink RT5370 chipset.


Frank
User avatar
hondagx35
 
Posts: 3039
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby Joe90 » 12 Sep 2016, 17:44

Ah, OK, must have misread somewhere ;)

I have a few RPi B's so hoping I can get some success.

I also have some RaLink MT7601U chipset nano usb dongles. These aren't plug and play but I have found a howto, installed and succeeded on Raspbian, but do not know if they are AP capable. Worth a try ?

I'll be off shopping for a RaLink RT5370 dongle now. Will take a few days before I can report back on progress.

Thanks for the tips
Joe90
 
Posts: 13
Joined: 11 Sep 2016, 19:42

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby hondagx35 » 12 Sep 2016, 20:21

Hi Joe90,

but do not know if they are AP capable. Worth a try ?

From my post on page 2 (is the same on Raspbian):
* install and check your WIFI dongle
Code: Select all
iw list

should show something like this
Code: Select all
Wiphy phy0
        max # scan SSIDs: 9
        max scan IEs length: 2304 bytes
        max # sched scan SSIDs: 0
        max # match sets: 0
        Retry short limit: 7
        Retry long limit: 4
        Coverage class: 0 (up to 0m)
        Supported Ciphers:
                * WEP40 (00-0f-ac:1)
                * WEP104 (00-0f-ac:5)
                * TKIP (00-0f-ac:2)
                * CCMP (00-0f-ac:4)
        Available Antennas: TX 0 RX 0
        Supported interface modes:
                 * IBSS
                 * managed
                 * AP
                 * monitor
                 * P2P-client
                 * P2P-GO
        Band 1:
                Capabilities: 0x1862
                        HT20/HT40
                        Static SM Power Save
                        RX HT20 SGI
                        RX HT40 SGI
                        No RX STBC
                        Max AMSDU length: 7935 bytes
                        DSSS/CCK HT40
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT Max RX data rate: 150 Mbps
                HT TX/RX MCS rate indexes supported: 0-7, 32
                Bitrates (non-HT):
                        * 1.0 Mbps
                        * 2.0 Mbps
                        * 5.5 Mbps
                        * 11.0 Mbps
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
                Frequencies:
                        * 2412 MHz [1] (20.0 dBm)
                        * 2417 MHz [2] (20.0 dBm)
                        * 2422 MHz [3] (20.0 dBm)
                        * 2427 MHz [4] (20.0 dBm)
                        * 2432 MHz [5] (20.0 dBm)
                        * 2437 MHz [6] (20.0 dBm)
                        * 2442 MHz [7] (20.0 dBm)
                        * 2447 MHz [8] (20.0 dBm)
                        * 2452 MHz [9] (20.0 dBm)
                        * 2457 MHz [10] (20.0 dBm)
                        * 2462 MHz [11] (20.0 dBm)
                        * 2467 MHz [12] (20.0 dBm)
                        * 2472 MHz [13] (20.0 dBm)
                        * 2484 MHz [14] (disabled)
        Band 2:
                Capabilities: 0x1862
                        HT20/HT40
                        Static SM Power Save
                        RX HT20 SGI
                        RX HT40 SGI
                        No RX STBC
                        Max AMSDU length: 7935 bytes
                        DSSS/CCK HT40
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT Max RX data rate: 150 Mbps
                HT TX/RX MCS rate indexes supported: 0-7, 32
                Bitrates (non-HT):
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
                Frequencies:
                        * 5170 MHz [34] (20.0 dBm)
                        * 5180 MHz [36] (20.0 dBm)
                        * 5190 MHz [38] (20.0 dBm)
                        * 5200 MHz [40] (20.0 dBm)
                        * 5210 MHz [42] (20.0 dBm)
                        * 5220 MHz [44] (20.0 dBm)
                        * 5230 MHz [46] (20.0 dBm)
                        * 5240 MHz [48] (20.0 dBm)
                        * 5260 MHz [52] (20.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5280 MHz [56] (20.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5300 MHz [60] (20.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5320 MHz [64] (20.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5500 MHz [100] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5520 MHz [104] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5540 MHz [108] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5560 MHz [112] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5580 MHz [116] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5600 MHz [120] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5620 MHz [124] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5640 MHz [128] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5660 MHz [132] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5680 MHz [136] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5700 MHz [140] (26.0 dBm) (radar detection)
                          DFS state: usable (for 40621 sec)
                          DFS CAC time: 60000 ms
                        * 5745 MHz [149] (disabled)
                        * 5765 MHz [153] (disabled)
                        * 5785 MHz [157] (disabled)
                        * 5805 MHz [161] (disabled)
                        * 5825 MHz [165] (disabled)
                        * 5920 MHz [184] (disabled)
                        * 5940 MHz [188] (disabled)
                        * 5960 MHz [192] (disabled)
                        * 5980 MHz [196] (disabled)
                        * 6000 MHz [200] (disabled)
                        * 6020 MHz [204] (disabled)
                        * 6040 MHz [208] (disabled)
                        * 6060 MHz [212] (disabled)
                        * 6080 MHz [216] (disabled)
        Supported commands:
                 * new_interface
                 * set_interface
                 * new_key
                 * start_ap
                 * new_station
                 * set_bss
                 * join_ibss
                 * set_pmksa
                 * del_pmksa
                 * flush_pmksa
                 * remain_on_channel
                 * frame
                 * set_channel
                 * connect
                 * disconnect
        Supported TX frame types:
                 * IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
        Supported RX frame types:
                 * IBSS: 0xd0
                 * managed: 0x40 0xd0
                 * AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                 * AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                 * P2P-client: 0x40 0xd0
                 * P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
        software interface modes (can always be added):
                 * monitor
        interface combinations are not supported
        Device supports scan flush.

The interesting part is:
Code: Select all
Supported interface modes:
                 * IBSS
                 * managed
                 * AP
                 * monitor
                 * P2P-client
                 * P2P-GO

We are looking for AP mode.

Frank
User avatar
hondagx35
 
Posts: 3039
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby Arnoedi » 14 Sep 2016, 08:43

Hi there,

Not sure if I sould reply here or create another thread, but since Franck asked for reports on Runeaudio AP, here we go.

I'm using Runeaudio on my RPi2 with great success so far.

Like many people here I'm currently trying to set up an AP on my RPi. What I want to do is to have my Pi connected to the Network by Ethernet and then using it as a small WiFi router to connect my phone and my laptop (it spare me the cost of a real router among other things).

So far I was able to do exactly that with the create_ap script using this command :
Code: Select all
create_ap -d --dhcp-dns 8.8.8.8  wlan0 eth0 SSID passphrase

If you remember to activate IP forwarding on your device this enable you to go NATed quite easily. The only tweak for me was to plug the WiFi Dongle (a Ralink RT5370) after the Pi boot, I had some error otherwise.

Since I let my Runeaudio RPi on at all time it isn't really bothering me, and I haven't tried to launch the AP automatically at boot.

At this point I have what my initial objective was :
- A WiFi network with Internet access powered by the Pi
- Access to the runeaudio UI from both the wireless network and the wired network (with my desktop)

But now I'm trying to get the UPnP/DLNA working and I didn't get it.

When on the WiFi created by the Pi my Android pnone with BubbleUPnp is unable to see any DLNA renderer on the network.
On the wired network, I'm using pulseaudio-dlna on Debian Sid and it isn't detecting the renderer when I'm using the auto-detection mode.

I've tried to look at the upmpdcli.log and found this line :
Code: Select all
libupnpp/upnpplib.cxx:153::LibUPnP: Using IP 10.171.29.73 port 49152

So I've tried to tell explicitly to pulseaudio-dlna where to look for the renderer :
Code: Select all
pulseaudio-dlna --debug --port 8081 --renderer-urls=http://10.171.29.73:49152

and got this in the log :
Code: Select all
09-14 09:23:15 requests.packages.urllib3.connectionpool       INFO     Starting new HTTP connection (1): 10.171.29.73
09-14 09:23:15 requests.packages.urllib3.connectionpool       DEBUG    "GET / HTTP/1.1" 500 60
09-14 09:23:15 pulseaudio_dlna.holder                         DEBUG    Response from device (http://10.171.29.73:49152)
<html><body><h1>500 Internal Server Error</h1></body></html>

So I think the problem steam from the Pi configuration.

I have thus two questions :
1) How can I get my UPnP/DLNA renderer to work on my wired network (the 10.171.23.0/24 network), or where can I look for more debug infos ?
2) How can I specify to upmpdcli to work on the wlan0 interface too ?

Here is the pastebin of the debug info of the RPI, the upmpdcli.log and the output of my pulseaudio-dlna command :

RuneAudio debug Info : http://pastebin.com/raw/XvSNTDNM
upmdcli.log : http://pastebin.com/raw/7Ce2TnUE
pulseaudio-dlna output : http://pastebin.com/raw/REFef2Mm

Hardware : RaspberryPi2 (08), Ralink RT5370
Active kernel : Linux version 4.4.17-1-ARCH (builduser@leming) (gcc version 6.1.1 20160707 (GCC) ) #1 SMP Fri Aug 12 20:05:37 MDT 2016


Thank you for your input !
Arnoedi
 
Posts: 4
Joined: 14 Sep 2016, 07:55

Re: RPi + Runeaudio +Wifi as Accesspoint

Postby dror » 14 Sep 2016, 12:27

Hi,
I think we have a very similar setup. (I have a PC over the eth0 network side)
Have you setup the Rpi as an AP as Frank explained? (page 2 of this discussion)
While on your Android and connected to the AP:
Can you see the Runeaudio UPNP renderer? the Rune Airplay renderer? (using Airstream or Airaudio or equivalents)

While on your eth0:
Can you see the Rune UPNP renderer if you search for it?

Dror
dror
 
Posts: 122
Joined: 03 Dec 2015, 10:14

support RuneAudio Donate with PayPal

PreviousNext

Return to Raspberry Pi

Who is online

Users browsing this forum: cmh714 and 21 guests