View Single Post
Old 10-05-2013, 09:12 AM   #14
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299993
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
Okay for the next poor soul:

me@dev /usr/local/src $ nasd -aa &

Quote:
Network Audio System Release 1.9.3
Error binding unix socket: /var/run/nasd/audio0
: Address already in use

Fatal server error:
Cannot establish unix listening socket
if we STRACE that we note that the ordinary user account DOES NOT HAVE PERMS to create the socket..

run it as sudo

(To kill it you will have to sudo killall -9 nasd, from another term, sigh)

also we have to check the devices

Quote:
The alsa drivers have native sound-devices in the /dev/snd/ directory. If you have one card you might see the following devices:

/dev/snd/pcmC0D0 - the raw audio device for the card
/dev/snd/mixerC0D0 - the mixer for card 0
/dev/snd/controlC0D0 - the control device for card 0
The first number means the number of the soundcard, the second number (if any) is the number of the device. A sound card with two PCM devices would have a pcmC0D0 and pcmC0D1 device. Please note: the ALSA devices have changed between the previous version. Older ALSA drivers use /dev/snd/pcm00 (first number is the card, second number is the device).
so:
(REF: http://www.tldp.org/HOWTO/Alsa-sound-6.html)
me@dev $ ls /dev/snd/
by-id by-path controlC1 pcmC1D0c pcmC1D0p seq timer

c = capture
p = playback (I finally figured out)


I tweaked the config to give us some debug

EDIT: noted in docs you can put "" in mixer section - this is honoured despite only being documented as for voxware... That gets rid of the mixer errors:

me@dev $ sudo nasd -aa -config ./nasd.conf
Quote:
config: Maxfrags set to 3
config: Minfrags set to 2
config: Fragsize set to 256
config: Maxfrags set to 3
config: Minfrags set to 2
config: Fragsize set to 256
Network Audio System Release 1.9.3
Network Audio System Release 1.9.3
AuInitPhysicalDevices();
Init: will close device when finished with stream.
Init: will keep mixer device open.
Init: Leaving the mixer device options alone at startup.
Init: openDevice OUT /dev/snd/pcmC1D0p mode 1
Init: openDevice(1) IN /dev/snd/pcmC1D0c mode 0
setupSoundcard(...);
++ Setting up Output device (/dev/snd/pcmC1D0p)
+++ requesting wordsize of 16, got 8
+++ requesting 2 channel(s), got 1 channel(s)
+++ Requesting minimum sample rate of 5000, got 5000
+++ Requesting maximum sample rate of 44100, got 44100
setupSoundcard(...);
++ Setting up Input device (/dev/snd/pcmC1D0c)
+++ requesting wordsize of 8, got 8
+++ requesting 2 channel(s), got 1 channel(s)
+++ Requesting minimum sample rate of 4000, got 4000
+++ Requesting maximum sample rate of 44100, got 44100
initMixer: no output mixer device specified
initMixer: no input mixer device specified
Init: initMixer was successful
createServerComponents(...);
closeDevice: out
closeDevice OUT /dev/snd/pcmC1D0p mode 1
closeDevice: in
closeDevice IN /dev/snd/pcmC1D0c mode 0
closeDevice: mixer
closeDevice: leaving mixer device(s) open

hmmm... dodgy.

hmm. a bit better.



next up we maybe? need to open up our X tcp sockets ( no listen tcp is a standard these days)
me@dev /usr/local/src $ socat TCP-LISTEN:8000 UNIX-CONNECT:/tmp/.X11-unix/X0

and nerf our access control
me@dev /usr/local/src $ xhost +
Quote:
access control disabled, clients can connect from any host
(REF: http://osr507doc.sco.com/en/GECG/X_D...essByHost.html)
(REF2: http://smorgasbord.gavagai.nl/2010/0...cket-over-tcp/)


(REF: http://mplayerhq.hu/pipermail/mplaye...er/037748.html)

Let's try running nmap on the kindle...

[root@kindle bin]# LD_LIBRARY_PATH=../lib:$LD_LIBRARY_PATH ./nmap 192.168.1.69
Quote:
Starting Nmap 6.00 ( http://nmap.org ) at 2013-10-05 13:06 UTC
Nmap scan report for dev (192.168.1.69)
Cannot find nmap-mac-prefixes: Ethernet vendor correlation will not be performed
Host is up (0.024s latency).
rDNS record for 192.168.1.69: dev.home
Not shown: 1060 closed ports
PORT STATE SERVICE
22/tcp open ssh
80/tcp open www
111/tcp open sunrpc
139/tcp open netbios-ssn
445/tcp open unknown
2049/tcp open nfsd
MAC Address: 00:02:72:3C:60:47 (Unknown)
Nmap done: 1 IP address (1 host up) scanned in 4.42 seconds

humph STILL no port 8000...


on the kindle:

[root@kindle root]# AUDIOSERVER=192.168.1.69:0 /mnt/us/extensions/alsaplayer/alsaplayer -o nas
Quote:
audiolib: warning, client is protocol rev 2.2 server is 11.0!
audiolib: connection to "tcp/192.168.1.69:8000" refused by server
audiolib: Protocol version mismatch
NAS server not available
Failed to initialize plugin!
Failed to register plugin: /mnt/us/extensions/alsaplayer/lib/alsaplayer/output/libnas_out.so
Failed to load output plugin "nas". Trying defaults.
but at least that is one step closer...


working on it...


EDIT:

okay so let's run

me@dev /usr/local/src $ auinfo
Quote:
Audio Server: tcp/localhost:8000
Version Number: 2.2
Vendor: Network Audio System Release 1.9.3 - VoxWare
Vendor Release: 1
Min Sample Rate: 5000
Max Sample Rate: 44100
Max Tracks: 32
Number of Formats: 7
Formats: ULAW8 LinearUnsigned8 LinearSigned8
LinearSigned16MSB LinearUnsigned16MSB
LinearSigned16LSB LinearUnsigned16LSB
Number of Elem Types: 12
Element Types: ImportClient ImportDevice ImportBucket
ImportWaveForm Bundle MultiplyConstant AddConstant
Sum ExportClient ExportDevice ExportBucket
ExportMonitor
Number of Wave Forms: 2
Wave Forms: Square Sine
Number of Actions: 3
Actions: ChangeState SendNotify Noop
Number of Devices: 3
Device 0:
Changable: Gain LineMode
ID: 0x23
Kind: PhysicalInput
Use: Import
Format: LinearUnsigned8
Num Tracks: 1
Access: Import List
Description: "Mono Channel Input"
Min Rate: 5000
Max Rate: 44100
Location: Left Right External
Gain Percent: 50
Num Children: 0
Device 1:
Changable: Gain
ID: 0x22
Kind: PhysicalOutput
Use: Export
Format: LinearUnsigned8
Num Tracks: 2
Access: Export List
Description: "Stereo Channel Output"
Min Rate: 5000
Max Rate: 44100
Location: Center Internal
Gain Percent: 50
Num Children: 1
Children: 0x21
Device 2:
Changable: Gain
ID: 0x21
Kind: PhysicalOutput
Use: Export
Format: LinearUnsigned8
Num Tracks: 1
Access: Export List
Description: "Mono Channel Output"
Min Rate: 5000
Max Rate: 44100
Location: Center Internal
Gain Percent: 50
Num Children: 0
Number of Buckets: 0
bonus. That is working at least now.

Last edited by twobob; 10-05-2013 at 10:05 AM.
twobob is offline   Reply With Quote