Solved

/dev/audio

Posted on 2001-07-18
6
534 Views
Last Modified: 2013-12-06
This is more of a survey than a question. I need to know how reliable it is to use /dev/audio to play sound on unix machines. The actual deal is that I need sound in a java JDK 1.1 compatible application, and there is no Java API in 1.1 to do that. What I think I will do is simply open /dev/audio as a file and write into it. The main question is what percentage of unix machines have this configured correctly. Please take the 30 seconds needed to check this and tell me if it works on your unix box. 5 points per answer, please don't lie :-)

The command to try is "cat somemusicfile.au > /dev/audio" (it's important for me that it's an 'au' file).

Thanks,
Sasha Maryanovsky.
0
Comment
Question by:Sasha_Mapa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 14

Accepted Solution

by:
chris_calabrese earned 50 total points
ID: 6296041
/dev/audio is a sun-ism.  Though it's been picked up by some other *x vendors, still other *x flavors do things differently (and hence the need to standardize things in the Java VM).

For example, in HP-UX you'd use
/opt/audio/bin/send_audio -au <filename>
0
 
LVL 7

Author Comment

by:Sasha_Mapa
ID: 6297075
Well, what's mostly important to me is the percentage - I'm not writing a professional application, and if 90% of the users will have a correct setting, I have no problem asking the remaining 10% to symlink /dev/audio to their actual audio device.

Sasha Maryanovsky.
0
 
LVL 14

Expert Comment

by:chris_calabrese
ID: 6298287
But, but, but, my point is that many Unix systems have no audio device.  HP-UX in particular does not, and it represents ~30% of Unix sales by revenue (so at least 10% of sales by volume).
0
Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

 
LVL 7

Author Comment

by:Sasha_Mapa
ID: 6298325
Forgive me if I'm saying stupid things here (I'm not a unix guy), but if HP-UX has no audio device, why'd you say I would use "/opt/audio/bin/send_audio -au <filename>" on an HP-UX?

Anyway, I don't really care about machines that have no audio device at all... it means they can't produce sound (right?), so my method which plays the sound will just fail - no problem.

Sasha Maryanovsky.
0
 
LVL 14

Expert Comment

by:chris_calabrese
ID: 6298388
It does have an audio capability, but it's not presented as a filesystem-based device as in Solaris.  Instead there are audio-specific system calls to talk to the audio device.
0
 
LVL 7

Author Comment

by:Sasha_Mapa
ID: 6857179
Sorry, it took so long.

Alexander Maryanovsky.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question