Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2008

Tip: Looking for answers? Try searching our database.

Can Java read TOC cd?

Thread view: 
Maarten - 16 Mar 2008 22:04 GMT
Hi,

Currently I am exploring the what I need to know to for creating a
program that can read the TOC of a audio/data cd and connect through
telnet or http to the Freedb cd database on the internet and get the
available information and after processing putting it in an MySQL
database. Java seems to be an interesting language to perform this job
as it is multi-platform. However, before I go learn this language only
to find out this might not the best language to write it in, I would
like to hear some opinions on this.

Thanks in advance, Maarten
GArlington - 17 Mar 2008 11:31 GMT
On Mar 16, 9:04 pm, Maarten <"maarten at custodis dot cistron dot nl">
wrote:
> Hi,
>
[quoted text clipped - 8 lines]
>
> Thanks in advance, Maarten

ANY server side (scripting) language can do that for you...
So, you will have to decide if you are interested in learning Java,
instead of trying to compare it's ability to do this VERY simple task
to other languages.
Logan Shaw - 19 Mar 2008 03:11 GMT
> On Mar 16, 9:04 pm, Maarten <"maarten at custodis dot cistron dot nl">
> wrote:

>> Currently I am exploring the what I need to know to for creating a
>> program that can read the TOC of a audio/data cd and connect through
[quoted text clipped - 4 lines]
>> to find out this might not the best language to write it in, I would
>> like to hear some opinions on this.

> ANY server side (scripting) language can do that for you...

Huh?  I took the question to mean that the original poster has
a CD-ROM drive, they want to insert an audio CD, and they want to
gather information about the audio tracks on the CD.  This is a
pretty low-level function.  It has to depend on the device driver
for the CD-ROM drive, and it may have to have some very specific
knowledge about the CD audio format (which is different than the
CD-ROM format; only the latter has a filesystem, for one thing).

Think of a TOC as sort of like a partition table, except that it
divides up a continuous series of audio frames into conceptual
tracks, and I think it uses seconds (rather than frames or
blocks or bytes) as its unit.

As I understand it, the usual way to do all this on a PC is to
speak ATAPI to the hardware.  I don't know of a way to do this
directly from Java, although it could be possible.

Also, it sounds to me like this would all be done on the client
side, not the server side.  The client needs to look at the low-level
info on the physical disc, then it needs to contact some service
on the network to gather more information about that disc, then
store that into a database somewhere.  Java sounds great for the
second two of those, but the first one is another question.

  - Logan
Maarten - 19 Mar 2008 17:34 GMT
> Think of a TOC as sort of like a partition table, except that it
> divides up a continuous series of audio frames into conceptual
> tracks, and I think it uses seconds (rather than frames or
> blocks or bytes) as its unit.

I have never seen the TOC of an audio-cd but since freedb/cddb both
display the start of each audio track as a frame-offset I guess it is
set in frames.

The TOC can set the track offset (the frame at which a track begins; 1
second is 75 frames), index point (subdivisions of a track), cd and
track information and whatever one would like to put in there.

> As I understand it, the usual way to do all this on a PC is to
> speak ATAPI to the hardware.  I don't know of a way to do this
> directly from Java, although it could be possible.

Most programs I've seen that copy cd's and convert them to wave or mp3
require an ASPI driver (ASPI stands for Advanced SCSI Programming
Interface. Originally developed by Adaptec. It is a software layer that
enables programs to communicate with SCSI (and ATAPI) devices.)

> Also, it sounds to me like this would all be done on the client
> side, not the server side.  The client needs to look at the low-level
> info on the physical disc, then it needs to contact some service
> on the network to gather more information about that disc, then
> store that into a database somewhere.  Java sounds great for the
> second two of those, but the first one is another question.

And that was indeed my question to begin with, though maybe not too
clear. I have never seen a Java program to copy audio CD's or do
something else with it and since I only have experience with PHP and
Javascript it requires me quite a bit to learn which is all right as
long as it leads to something.

Maarten
Tris Orendorff - 22 Mar 2008 16:22 GMT
> Hi,
>
[quoted text clipped - 6 lines]
> to find out this might not the best language to write it in, I would
> like to hear some opinions on this.

Here's something from 2002:
http://forum.java.sun.com/thread.jspa?threadID=210561&messageID=1251678

Signature

Tris Orendorff
[ Anyone naming their child should spend a few minutes checking rhyming slang and dodgy
sounding names. Brad and Angelina failed to do this when naming their kid Shiloh Pitt. At some
point, someone at school is going to spoonerise her name.
Craig Stark ]



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.