Forum Replies Created
-
Posted in: Allo USB Bundle
-
23. Februar 2016 at 19:27 #18678
Hi Maximilian:
To summarize and help you see, what I think the problem is. Look at the file:
/etc/init.d/dhcpcd
and specifically the lines:if grep -q "^[[:space:]]*iface[[:space:]]*.*[[:space:]]*inet[[:space:]]*dhcp" \ $INTERFACES; then log_failure_msg "Not running $NAME because $INTERFACES" log_failure_msg "defines some interfaces that will use a" \ "DHCP client" exit 6 fi
If I read this correctly, it scans the /etc/network/interfaces file and aborts the script if it finds any interface that is set to request dhcp setup. I know that this is not max2play code, but it seems wrong to me, because I see no reason why a server with multiple interfaces cannot be both a DHCP server and a DHCP client. Perhaps the best fix is to comment out this test.
The fix I had implemented was NOT this, I simply modified the interfaces file to satisfy the test by assigning static IP addresses. That fix is not undone by „access point removal“ causing the issue that gapmedia refers to. So an alternate fix of commenting out the check is better, I think.I read that your tests with an alternate dongle works. Does the /etc/init.d/dhcpcd file on the test system contain the code above? If it does then, I have no idea why it works, as DHCPD should fail to start, with the max2play standard interfaces file.
21. Januar 2016 at 16:48 #18045Based on your code I wrote this (in perl) it works.
https://www.dropbox.com/s/fznkbe3xin6h5mk/kodi_hdmi.pl
#!/usr/bin/perl $| = 1; $debug = 1; if ($debug == 0) { open(STDERR, ">/dev/null")} # This will start kodi on startup if a device is on hdmi # or will stop kodi processes if no device is on hdmi $oldstat="X"; # force a change on startup while(1) { $stat=<code>/opt/vc/bin/tvservice -n</code>; # if there is something plugged in and there was a change then Start KODI if (($stat ne "") && ($stat ne $oldstat)) { print "starting Kodi\n"; #Turn on HDMI system("/opt/vc/bin/tvservice -p"); #Turn on Kodi system("sudo -u pi -H -s /opt/max2play/start_xbmc.sh >> /dev/null 2>&1 &"); $oldstat=$stat; next; } # if there is nothing plugged in and there was a change then Stop KODI if (($stat eq "") && ($stat ne $oldstat)) { print "stopping Kodi\n"; #Turn off Kodi system("pkill -9 -f \"kodi.*standalone\""); #Turn off HDMI system("/opt/vc/bin/tvservice -o"); $oldstat=$stat; next; } sleep 10; }
20. Januar 2016 at 19:03 #18027Disclaimer: I’ve not tried this myself:
With shell access:
You can edit the file
/var/www/max2play/application/config/plugins.xml
and look for this section<plugin> <name>Settings / Reboot</name> <navigation> <translate>Settings / Reboot</translate> </navigation> <path>/plugins/max2play_settings/controller/Basic.php</path> <updateurl></updateurl> <lastupdate></lastupdate> <active>1</active> <pos>2</pos> </plugin>
If you see a „0“ in <active> change it to a „1“ and save the file
Good Luck
20. Januar 2016 at 17:49 #18020Alex:
I used one of those cheap USB sound dongles too. I found it much better than the raw audio output on the PI.
Not super but good enough for my purposes so far. I have zero experience with the hifiberry or wolfson cards.
I have also been using KODI and playing music through the HDMI to my amplifier, the sound is great.17. Januar 2016 at 5:40 #17964Hello Heiner:
Thank you for trying it. Please feel free to proceed as you wish. The dropbox link above can be used, as I have no other place to host it. As far as a description how about?
Plugin Run Command Allows you to run a single command on the hosting computer from the web interface. You can run the command with or without "root" privilege.
17. Januar 2016 at 2:18 #17963It is a flaw in M2P, and something they should address in the next update.
I did not see the problem because my base release is older started with 2.16?
It didn’t have the dhcpd check that the newer versions have.I found the problem by loading the new release and trying to get my dongle to work.
You’re very very welcome, my reward is your reaction when it worked ROFL
It’s been a long haul but it ended in success.
17. Januar 2016 at 1:17 #17958The issue or at least the latest issue turned out to be that the DHCP Daemon (DHCPD) was not starting.The DHCPD provides IP addresses to clients when they connect to the access point.
The latest init.d script to start DHCPD, scans the /etc/network/interfaces file and exits if it finds an interface set to DHCP.
The default file from M2P has such an entry so DHCPD never starts, causing the connect problem. In the file I had you download with „wget“
I replaced the dhcp entry with a static entry for eth0, and removed the dhcp setting for wlan0 as well.
BTW you will find M2P through the ethernet/wired interface at: 192.168.1.250 with the current setting.16. Januar 2016 at 23:52 #17949Hi Alex:
I think I found the answer, please try the following:
cd /tmp wget https://www.dropbox.com/s/we0d928vfddovia/interfaces.192.168.1.0 sudo cp /etc/network/interfaces /etc/network/interfaces.orig sudo cp interfaces.192.168.1.0 /etc/network/interfaces sudo chown root:root /etc/network/interfaces sudo chmod 666 /etc/network/interfaces
Then reboot. If it works I’ll follow with an explanation.
16. Januar 2016 at 17:29 #17937Alex:
Does the maz2play accesspoint page debug info say something like this?
Just making sure that with this new dongle these remain running.#### DNSMASQ Running #### 5 S 110 2444 1 0 80 0 - 1612 poll_s ? 00:00:00 dnsmasq #### HOSTAPD Running #### 5 S 0 2519 1 0 80 0 - 1294 poll_s ? 00:00:00 hostapd
out of interest please run:
lsusb
to see what info is returned for the new dongle.16. Januar 2016 at 15:51 #17933I’m amazed at the problems we are having…
Regarding not seeing any network info for max2play, You are correct you will not see that until you successfully connect.
From the info you provided…wlan0 is NOT running in master mode, but it is trying to assign the address 192.168.189.1, but it gets withdrawn:
Withdrawing address record for 192.168.189.1 on wlan0
.please provide more from the syslog:
sudo tail -75 /var/log/syslog
16. Januar 2016 at 6:10 #17928I have two ideas
- 1 To be absolutely sure it’s not a that your device is capitalizing the first character, change the password and make the first letter a capital.
- 2 Hook up a display and keyboard, OR login via the ethernet port using putty. login and type the command
sudo iwconfig
to check the status of wlan0. Thensudo ifconfig
to confirm that wlan0 is up and has an ip address (should be 192.168.189.1) thensudo tail -f /var/log/syslog
. This will monitor the end of the syslog file. With this running try to connect. look for new messages related to the connection attempt. You can terminate the command with Crtl-c
- This reply was modified 8 years, 10 months ago by noop.
-