Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


Solved: SiriusXM support?
#11
@jmperagine

Sorry, I’m out most of the day. Will get back to you tonight or tomorrow morning.

Regards,
Kent
Reply
#12
@jmperagine

So, first I lightly edited your post #10 to put command-line output into code blocks so it could be read more easily.

Your output #1 and #2 look ok.  The output  #3, however, doesn't indicate if you also see what I described, namely the screen clearing and then showing sxm-player initialization lines with the last one ending something like "INFO SXM Client started. 412 channels available".

The reason I flag #3 is that #4 does not mention sxm-player at all so I do not expect it to be running when all is said and done. Are you invoking the same rc.local shown in #2?

Finally, moodeutl with no leading forward slash is the name of the command.

Regards,
Kent
Reply
#13
(10-24-2021, 07:51 PM)TheOldPresbyope Wrote: @jmperagine

So, first I lightly edited your post #10 to put command-line output into code blocks so it could be read more easily.

Your output #1 and #2 look ok.  The output  #3, however, doesn't indicate if you also see what I described, namely the screen clearing and then showing sxm-player initialization lines with the last one ending something like "INFO SXM Client started. 412 channels available".

The reason I flag #3 is that #4 does not mention sxm-player at all so I do not expect it to be running when all is said and done. Are you invoking the same rc.local shown in #2?

Finally, moodeutl with no leading forward slash is the name of the command.

Regards,
Kent


Attached Files Thumbnail(s)
   
Reply
#14
(10-24-2021, 09:04 PM)jmperagine Wrote:
(10-24-2021, 07:51 PM)TheOldPresbyope Wrote: @jmperagine

So, first I lightly edited your post #10 to put command-line output into code blocks so it could be read more easily.

Your output #1 and #2 look ok.  The output  #3, however, doesn't indicate if you also see what I described, namely the screen clearing and then showing sxm-player initialization lines with the last one ending something like "INFO SXM Client started. 412 channels available".

The reason I flag #3 is that #4 does not mention sxm-player at all so I do not expect it to be running when all is said and done. Are you invoking the same rc.local shown in #2?

Finally, moodeutl with no leading forward slash is the name of the command.

Regards,
Kent
As the attached pic shows, the system hangs on boot up if I include the line
# start the SiriusXM proxy

/usr/local/bin/sxm-player -U <my sxm username> -P <my sxm password> &   (using my credentials of course)

in rc.local.

Also this:
pi@moode:~ $ moodeutl -i
Import moOde autoconfig settings
no file "/boot/moodecfg.ini" to import

All this and I found sxm v 0.2.8 here: https://sxm-client.readthedocs.io/en/latest/readme.html

with v0.2.8 installed, the system will boot, it's just that sxm does not load.
Reply
#15
@jmperagine

I'm sorry, I've been trying to do too many things online and in real life at the same time and making unforced errors as a result.

Mistake 1: I didn't look carefully enough at your post #10. It turns out there is a leading comment character on the line which is supposed to start the proxy. 
Mistake 2: I should have explained my notation. The entire string <my sxm username> should be replaced by your sxm username (without angle brackets); similarly the entire string <my sxm password> should be replaced by your sxm password (without angle brackets). Sorry I made this unclear. I was assuming you'd already be familiar with the syntax of the sxm-player options, having started it successfully early on, and recognize my notation for what it was.
Related, the line should not end with the string '(using my credentials of course)'. I shouldn't have attempted to throw in a comment without ensuring it wouldn't be copied literally as I see it appear in your most recent post. 

In summary, the line in question in rc.local should read

Code:
/usr/local/bin/sxm-player -U uuuuu -P ppppp &

where uuuuu is to be replaced by your sxm username and ppppp by your sxm password.

The presence of the comment character in your file explains why I didn't see output in your post #10 relating to sxm-player. It never got invoked.

As for the "&" error in your most recent post, if I replace the line in question in rc.local with this [incorrect] line literally

Code:
/usr/local/bin/sxm-player -U <my sxm username> -P <my sxm password> &   (using my credentials of course)

and reboot or invoke sudo /etc/rc.local then I get the same sort of error that you report.

Mistake 3: that option for moodeutl should be -l (as in log), not -i (as in import). Try the --help option to see all the possibilities.

- - - 

Regarding versions of software, the distributed image of moOde 7.4.1 includes python3.7. On a freshly flashed moOde I installed sxm-player from the Python Package Index using pip3

Code:
pi@rpi3a:~ $ sudo pip3 install sxm-player
...lots of output...

When the install was done, I asked pip3 to list all installed packages and grep'ed the list for the string sxm to see what just got installed

Code:
pi@rpi3a:~ $ pip3 list | grep sxm
sxm                0.2.8    
sxm-player         0.2.5  

Python 3.7 and these versions of the sxm-related packages are working fine on my moOde 7.4.1 player.

Regards,
Kent
Reply
#16
This is a new clean build of Moode 7.4.1
After booting, I changed the default python to 3.7, updated anyio to 3.3.4, installed sxm-player0.2.5 and sxm0.2.8

CODE:
pi@moode:/ $ pip3 list | grep sxm
sxm                0.2.8
sxm-player         0.2.5



For some reason, sxm keeps getting installed in a hidden directory.

CODE:
pi@moode:~/.local/bin $ ls
coloredlogs  dotenv  httpx  humanfriendly  iptest  iptest3  ipython  ipython3  normalizer  pygmentize  sxm  sxm-player



CODE:
pi@moode:/ $ which sxm-player
/home/pi/.local/bin/sxm-player



end lines of rc.local
CODE:
# moOde startup and job processor daemon 
/var/www/command/worker.php > /dev/null 2>&1

#Start the SXM Proxy
/home/pi/.local/bin/sxm-player -U MyUsername -P MyPassword
exit 0

(If I use your path /usr/local/bin/sxm-player the system hangs at boot)

I added a bunch of directories to the path hopping that was it.
CODE:
pi@moode:/etc $ echo $PATH
/home/pi/.local/bin:/home/pi/.local/lib/python3.7/site-packages:/home/pi/.local/bin:/etc:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games


CODE:
pi@moode:/ $ moodeutl -l
20211026 211306 worker: -- Start
20211026 211306 worker: Successfully daemonized
20211026 211306 worker: Integrity check (passed)
20211026 211307 worker: File check (OK)
20211026 211307 worker: Session vacuumed
20211026 211307 worker: Session loaded
20211026 211307 worker: Debug logging (OFF)
20211026 211307 worker: -- Audio debug
20211026 211307 worker: ALSA cards: (0:Headphones | 1:empty | 2:empty | 3:empty
20211026 211307 worker: MPD config: (0Tonguei Headphone jack | mixerSadHeadphone) | card:0)
20211026 211307 worker: ALSA mixer actual (Headphone)
20211026 211307 worker: ALSA Headphone volume set to (0%)
20211026 211307 worker: -- System
20211026 211308 worker: Host     (moode)
20211026 211309 worker: moOde    (7.4.1 2021-10-02)
20211026 211309 worker: RaspiOS  (10.6)
20211026 211309 worker: Kernel   (5.4.77-v7l+ #1371)
20211026 211309 worker: Platform (Pi-4B 1.4 4GB)
20211026 211309 worker: ARM arch (armv7l, 32-bit kernel)
20211026 211309 worker: MPD ver  (0.22.11_p0x3)
20211026 211309 worker: CPU gov  (ondemand)
20211026 211309 worker: USB boot not available
20211026 211309 worker: File system not expanded yet
20211026 211309 worker: HDMI port off
20211026 211309 worker: -- Network
20211026 211309 worker: eth0 exists
20211026 211309 worker: eth0 address not assigned
20211026 211309 worker: wlan0 exists
20211026 211309 worker: wifi country (US)
20211026 211309 worker: wlan0 trying SSID (ENZO)
20211026 211309 worker: IP addr (192.168.1.209)
20211026 211309 worker: Netmask (255.255.255.0)
20211026 211309 worker: Gateway (192.168.1.1)
20211026 211309 worker: Pri DNS (192.168.1.1)
20211026 211309 worker: Domain  (myfiosgateway.com)
20211026 211309 worker: Pi integrated wlan0 power save disabled
20211026 211309 worker: -- Audio config
20211026 211309 worker: MPD conf update skipped (USB device)
20211026 211309 worker: ALSA card number (0)
20211026 211309 worker: MPD audio output (Pi Headphone jack)
20211026 211309 worker: Audio formats (U8, S16_LE)
20211026 211309 worker: ALSA mixer name (Headphone)
20211026 211309 worker: MPD mixer type (software)
20211026 211309 worker: Hdwr volume controller exists
20211026 211309 worker: Max ALSA volume (100%)
20211026 211309 worker: ALSA output mode (Default: plughw)
20211026 211309 worker: ALSA loopback (Off)
20211026 211309 worker: Reset renderer active flags
20211026 211309 worker: CamillaDSP (off)
20211026 211309 worker: -- MPD startup
20211026 211309 worker: MPD started
20211026 211310 worker: MPD accepting connections
20211026 211310 worker: MPD output 1 ALSA Default (on)
20211026 211310 worker: MPD output 2 ALSA Bluetooth (off)
20211026 211310 worker: MPD output 3 HTTP Server (off)
20211026 211310 worker: MPD crossfade (off)
20211026 211310 worker: MPD ignore CUE files (yes)
20211026 211310 worker: -- Feature availability
20211026 211310 worker: Source select (available)
20211026 211310 worker: Source select (source: MPD)
20211026 211310 worker: Source select (output: Pi Headphone jack)
20211026 211310 worker: Bluetooth (available)
20211026 211310 worker: Airplay renderer (available)
20211026 211310 worker: Spotify renderer (available)
20211026 211310 worker: Squeezelite (available)
20211026 211310 worker: RoonBridge renderer (not installed)
20211026 211310 worker: Multiroom sender (available)
20211026 211310 worker: Multiroom receiver (available)
20211026 211310 worker: UPnP renderer (available)
20211026 211310 worker: DLNA server (available)
20211026 211310 worker: UPnP browser (available)
20211026 211310 worker: GPIO button handler (available: started)
20211026 211310 worker: Stream recorder (n/a)
20211026 211310 worker: -- Music sources
20211026 211310 worker: USB sources (none attached)
20211026 211310 worker: NAS and UPnP sources (none configured)
20211026 211310 worker: -- Other
20211026 211310 worker: USB volume knob (Off)
20211026 211310 worker: LCD updater engine started
20211026 211310 worker: Shellinabox SSH started
20211026 211310 worker: USB auto-mounter (udisks-glue)
20211026 211310 worker: LED0 (On)
20211026 211310 worker: LED1 (On)
20211026 211310 worker: Saved MPD vol level (0)
20211026 211310 worker: Preamp volume level (0)
20211026 211310 worker: MPD volume level (34) restored
20211026 211310 worker: ALSA Headphone volume (100%)
20211026 211310 worker: Auto-play (Off)
20211026 211311 worker: LocalUI started
20211026 211311 worker: Maintenance interval (3 hours)
20211026 211311 worker: Screen saver activation (Never)
20211026 211311 worker: Session permissions (OK)
20211026 211311 worker: Watchdog started
20211026 211311 worker: Ready
pi@moode:/ $



still can't get it to load, the system no longer hangs on boot, but and error does scroll by.

CODE:
[  OK  ] Started /etc/rc.local Compatibillity.
22.126407] rc.local[524]:  /etc/rc.local: 32: /etc/rc.local: /home/pi/.local/bin/sxm-player: not
found
[  OK  ] Started Getty on tty1.


Is there another way to load sxm post boot?
Possibly a shell script that gets run after all the other boot processes run?
Reply
#17
(10-27-2021, 02:01 AM)jmperagine Wrote: This is a new clean build of Moode 7.4.1
After booting, I changed the default python to 3.7, updated anyio to 3.3.4, installed sxm-player0.2.5 and sxm0.2.8

There's no need to change the default python so long as you use pip3. Don't know what updating anyio buys you. My working installation is using anyio 3.3.3.

Quote:For some reason, sxm keeps getting installed in a hidden directory.

CODE:
pi@moode:~/.local/bin $ ls
coloredlogs  dotenv  httpx  humanfriendly  iptest  iptest3  ipython  ipython3  normalizer  pygmentize  sxm  sxm-player



CODE:
pi@moode:/ $ which sxm-player
/home/pi/.local/bin/sxm-player

This is because you did not execute pip3 install as root, e.g., sudo pip3 install sxm-player 

As a result sxm-player is installed in the .local directory of normal user pi instead of being installed in a system directory available to all users. This changes its accessibility to other parts of the system and can cause weird and wonderful problems.

Regards,
Kent
Reply
#18
(10-27-2021, 03:03 AM)TheOldPresbyope Wrote:
(10-27-2021, 02:01 AM)jmperagine Wrote: This is a new clean build of Moode 7.4.1
After booting, I changed the default python to 3.7, updated anyio to 3.3.4, installed sxm-player0.2.5 and sxm0.2.8

There's no need to change the default python so long as you use pip3. Don't know what updating anyio buys you. My working installation is using anyio 3.3.3.

Quote:For some reason, sxm keeps getting installed in a hidden directory.

CODE:
pi@moode:~/.local/bin $ ls
coloredlogs  dotenv  httpx  humanfriendly  iptest  iptest3  ipython  ipython3  normalizer  pygmentize  sxm  sxm-player



CODE:
pi@moode:/ $ which sxm-player
/home/pi/.local/bin/sxm-player

This is because you did not execute pip3 install as root, e.g., sudo pip3 install sxm-player 

As a result sxm-player is installed in the .local directory of normal user pi instead of being installed in a system directory available to all users. This changes its accessibility to other parts of the system and can cause weird and wonderful problems.

Regards,
Kent

All good! Thank you!
Reply
#19
Hi Kent,
Hope all is well. Going back 2 years? Wow, so, the SXM client is not loading on bootup. I went back and looked at all your help, looks like putting the credentials in rc.local is no longer an option because it's trying to load them too soon? 

Where can I insert the login code line: 

/usr/local/bin/sxm-player -U myusername -P mypassword &  

so it gets executed upon bootup.

Thank you in advance.

btw, if you need SXM credentials I can provide them for you.
Reply
#20
(12-01-2023, 08:47 PM)jmperagine Wrote: Hi Kent,
Hope all is well. Going back 2 years? Wow, so, the SXM client is not loading on bootup. I went back and looked at all your help, looks like putting the credentials in rc.local is no longer an option because it's trying to load them too soon? 

Where can I insert the login code line: 

/usr/local/bin/sxm-player -U myusername -P mypassword &  

so it gets executed upon bootup.

Thank you in advance.

btw, if you need SXM credentials I can provide them for you.

Oh, my, did I really do that? The older I get the smarter I used to be.

Off the top of my head, I'm not sure what happened here. What is your evidence that the sxm client "isn't loading"?

How about doing the following:

Step 1. Try starting sxm-player from the command line and post the results. E.g.,


Code:
/usr/local/bin/sxm-player -U myusername -P mypassword

If this succeeds, then ensure the line is correct in /etc/rc.local and go to step 2., else stop. My guess is that if this step fails, then you're using incorrect credentials, but there could be bit rot in the 2-year old sxm-player code.

Step 2. Reboot, run the following from the command line, and post the results

Code:
grep -i sxm /var/log/syslog

[Above edited to fix typo}

You should see roughly the same messages as in step 1. I don't (yet) have a guess why step 1 might succeed and step 2 fail.

Be sure to obscure your actual SXM username and password when you post results.


Regards,
Kent
Reply


Forum Jump: