A small Walkman-style device called the Rio - available in Britain for less than pounds 200 - enables tracks and albums to be downloaded from the Internet as files called MP3s.
The near-CD quality files can then be transferred to the Rio and played in the same way as a cassette player.
The music industry fears that the gadgets and the software that makes them work will allow people to circumvent copyright law and lead to a slump in music sales.
Many artists are already recording their music as MP3s and putting them online.
In a test case, the court ruled that Diamond Multimedia could continue to ship its Rio PMP300 player. The court said the Rio did not fall within the definition of a "digital recording device" used in the Audio Home Recording Act, which requires manufacturers to prevent serial re-recordings of copyrighted music.
The act refers to digital audio tapes or CDs, not recordings made from computers, the judge decided.
Though the legality of the Rio has not yet been tested in British courts, the ruling will be a huge boost to Diamond and several other companies which make or plan to make the devices in this country.
The case was brought by the Recording Industry Association of America, an industry group worried that businesses and artists will lose revenue if the trend spreads.
"The court appears to have concluded that, despite congressional intent, the Audio Home Recording Act has limited application in a world of convergent technologies," the association said. "We filed this lawsuit because unchecked piracy on the Internet threatens the development of a legitimate marketplace for on-line music, a marketplace that consumers want."
The computer industry says the devices are the equivalent of video cassette recorders. "It's not possible to stop this revolution," said Hock Leow, vice-president of the multimedia division of Creative Labs, which plans to ship its own device later this month.
Worried by a potential slump in sales, the world's five largest record companies - Sony, Warner, Universal, EMI and Bertelsmann - have launched the Secure Digital Music Initiative, which aims to make it more difficult to distribute pirated music over the Internet.