Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

Synchronizing Music Players?

Cliff posted more than 7 years ago | from the all-at-once-now dept.

Music 64

orn asks: "Lots of people now have MP3 players in the living room. Some people have players in the kitchen, bedroom, garage, and so on. They are great when it comes to getting to your music from multiple places, but when you walk from room to room, it's almost impossible to get the music aligned. Are there software packages or techniques for synchronizing multiple networked music players? One thought is to use streaming software to stream to all players — but is there any streamer that will let you account for the different delays in different hardware to create a single synchronized whole?"

cancel ×


Sorry! There are no comments related to the filter you selected.

SlimServer (4, Informative)

jad4 (87988) | more than 7 years ago | (#18996811)

SlimServer works for me. []

Re:SlimServer (1)

Marauder2 (82448) | more than 7 years ago | (#19019631)

I second that. Open Source, Runs on any platform supported by Perl, can synchronize multiple squeezeboxes and softsuqeeze players. supports a boat load of formats, mp3, flac, aac, ogg, you name it. Plenty of plugins and modifications from an active user and developer community, and the CEO of Slimdevices has even been known to posts on the forums, answering user questions, on the weekends.

The Squeezebox is a solid piece of hardware and even when it's turned off it's useful for using it's VFD as an information display. (I have mine set up with a plugin that display weather information as the powered off screensaver, can also do stock quotes, sport scores, there are plugins that can interface with CallerID, etc.)

I love it and was running SlimServer even before I got my first squeezebox (and then second and...)

Simplify (5, Insightful)

pintpusher (854001) | more than 7 years ago | (#18996847)

So, I know this doesn't answer your question, and I'm all for technology, but why not just run a multi-output speaker control box. Then just pipe the same signal to all the rooms over plain old speaker wire. I'm sure you can get lovely remote control panels (or fab some up) to control the device too. Its just so much simpler, IMO.

Re:Simplify (2, Interesting)

i_should_be_working (720372) | more than 7 years ago | (#18996921)

Indeed. And if one really wants to have other additional computers in control of the music, they can just use vnc or some similar app to control the music server.

Re:Simplify (3, Interesting)

simcop2387 (703011) | more than 7 years ago | (#18997067)

similar in line with this you can get a low power FM transmitter off ebay, and use that and some radios, much simpler if you don't want to run that much wire. my parents do it like this.

Re:Simplify (5, Interesting)

blhack (921171) | more than 7 years ago | (#18997189)

I came here to suggest the same thing. We have a setup very similar to this in our house. There is a room with a rack that has 4 Amps on it. Each one is individually controllable as far as volume goes (remotely). So that i can be in my bedroom with the music on VERY low, and the kids can be out in pool with the music on very LOUD. With this setup, you can also run different sources to different amps too. Its pretty slick. I'm still at work so i can't look at who makes the stuff. If this is something like what you want, i'll go look at who makes everything for you when i get there. :)

BTW, everything is controlled either from little panels that look like light switches in each room, or from a wireless tablet.

Re:Simplify (3, Informative)

Jah-Wren Ryel (80510) | more than 7 years ago | (#18999623)

If you don't know who makes it (which means it wasn't a DIY project), and it has both a wireless tablet and on-the-wall controls, chances are it is Crestron and costs a boatload.

Re:Simplify (1)

blhack (921171) | more than 7 years ago | (#19002065)

The Controllers are intellinet, and the amps are knoll......if that helps at all. I would pull one of the panels off the wall, but i'm assuming they're just some basic serial devices.

Re:Simplify (2, Informative)

blhack (921171) | more than 7 years ago | (#19002083)

sorry about the double post, but this website shows pretty much all the stuff you would need to do a setup exactly like mine.

Click []

Re:Simplify (2, Interesting)

_Sharp'r_ (649297) | more than 7 years ago | (#18998883)

My favorite trick is that with the right adapter you can use the cable TV coax already throughout your house as digital coax. That will generally get digital audio piped from one source to any device in your house that accepts a surround sound input.

Pre-existing cables and a couple of $70 Theater in a boxes (for the amps inside and the multiple speakers to scatter about the house) with that solution gave me whole house audio sourced from the one expensive tuner (Denon 3806) that runs my real theater, which of course was already tied into my PC/MP3 storage.

It's nice to be able to play surround sound from your computer to anywhere in the house without having to run cables between floors or anything.

Re:Simplify (1)

FLEB (312391) | more than 7 years ago | (#18998955)

Can you still run your television cable on the same lines through some sort of filter, or is that disconnected?

Re:Simplify (1)

_Sharp'r_ (649297) | more than 7 years ago | (#18999045)

I didn't need to, because since my Theater equipment was already at the "hub" of the cable plant, but I'm pretty sure that with some careful planning and knowledge of what frequency ranges you needed for what you could feed it all through.

I say that because I do know that you can backfeed various combinations of cable/satellite/over the air broadcasts in different directions over the same RG6 cable as long as you pay attention to the frequency ranges they use and use the right combiners/filters.

The only issue I ran into is that I didn't have a digital coax output on my receiver that switched signals for me, so I had to buy a $20 fiber to digital coax converter box from

Speakers? (1)

hahafaha (844574) | more than 7 years ago | (#18996875)

I am not sure if this is quite what you want, but wouldn't it be easier to just add more speakers? That way, you'll only have one player to worry about.

Easy solution (4, Funny)

YrWrstNtmr (564987) | more than 7 years ago | (#18996897)

but when you walk from room to room, it's almost impossible to get the music aligned.

That's what the volume knob is for. I assume you have an '11' setting on it? Problem solved. You can hear it in all rooms simultaneously.

Re:Easy solution (3, Funny)

orkysoft (93727) | more than 7 years ago | (#18997111)

Another easy solution:

MP3 players are portable, are they not? Simply carry the one you're listening to with you, and the only delay you'll get is relativistic, which (1) is negligible at the velocities of typical slashdotters, and (2) nullified by carrying the player with you.

I believe Apple makes a suitable device for this purpose.

Simple. (5, Funny)

harrkev (623093) | more than 7 years ago | (#18996947)


First, figure out what your slowest player is. Then, delay the others to match. Note that a lot of cat-5 cable might be useful -- about a mile or two should do it.

Use an osiclloscope to compare two different devices, and figure out how much delay you need. Figure that eight inches of wire is about a nanosecond delay. Note that you might have trouble driving a mile or two of cat-5, so you might have to throw in a switch or hub along the way -- which will introduce additional delay. Simply measure the delay and use less cable.

See, simple!

Re:Simple. (1)

internewt (640704) | more than 7 years ago | (#18997637)

You sound like a knowledgable guy, so maybe you'll be able to confirm if this could help: We all know that sound travels slower than light and other forms of electromagnetic radiation, so the /. askee could do some clever positioning of wireless network receivers around his house from his AP to adjust the delay of the music over a wireless LAN!

Re:Simple. (1)

cskrat (921721) | more than 7 years ago | (#19000415)

Too much jitter. Wi-Fi latency is known to fluctuate every time a large organic mass with a high iron content moves across the room.

AirPort Express (4, Informative)

Anonymous Coward | more than 7 years ago | (#18997019)

Buy AirPort Expresses [] . iTunes will drive multiple units in perfect sync. If you don't like iTunes or need to play from some other source, the Mac version of Rogue Amoeba's Airfoil [] can also drive multiple units in sync using any application on your computer as the source.

Don't think DIY is going to do it (4, Informative)

Zadaz (950521) | more than 7 years ago | (#18997037)

Standard Network latency and timing is not precise enough to reliably sync audio between rooms in such a way that you won't hear an echo. At least that was what I found when I researched this a couple of years ago.

Buy a Sonos [] and forget about it. It's an amazing set of hardware that's worth twice the price.

Re:Don't think DIY is going to do it (-1)

Anonymous Coward | more than 7 years ago | (#18997697)

That's ridiculous. A standard unloaded ethernet connection has a latency of 1-3ms. Wifi is not much worse. The human ear can't distinguish between two sources of sound that are out of sync by under 50ms, and it takes 100ms before it becomes really noticeable. Doing this on a clean network is really simple. Making your stuff work reliably on a dirty network with packet loss and other traffic flying around is harder and requires buffering, but getting synchronization is still entirely possible, as proven by systems like the AirPort Express which actually do it.

Re:Don't think DIY is going to do it (1)

poopdeville (841677) | more than 7 years ago | (#18998669)

1-3 ms comes to constructive and destructive interference at 333Hz - 1kHz. You'll get flanging as the latency changes. Yey!

In any event, this sort of system is a bad idea. Sound travels at 343 m/s (as opposed to c within the network), so propagation delay introduces latencies that swamp the network's. Even if you synchronize, the system will only be synchronized for a particular spot. If you move from it, you'll get major flanging.

Re:Don't think DIY is going to do it (0)

Anonymous Coward | more than 7 years ago | (#19000743)

The network latency differences are easily solved with a 25ms buffer. Unless the sound is realtime, you can easily use a buffer that's multiple seconds long. Seriously, why would you send raw audio over the network for instant playback? It makes no sense.

As far as your speed-of-sound problems, you've just disproved the existence of rock concerts and movie theaters with surround sound speakers. I don't know how they get away with it, but the fact that they exist obviously shows that your objection can be overcome.

Re:Don't think DIY is going to do it (1)

poopdeville (841677) | more than 7 years ago | (#19005375)

As far as your speed-of-sound problems, you've just disproved the existence of rock concerts and movie theaters with surround sound speakers. I don't know how they get away with it, but the fact that they exist obviously shows that your objection can be overcome.

Yes, because movie theaters and rock bands have the same goals in mind as the Ask Slashdotter. He specifically said he wanted no "echo", not that he wanted to drown it out with loud music/sound effects.

Re:Don't think DIY is going to do it (0)

Anonymous Coward | more than 7 years ago | (#19000407)

This is wrong.

Most players cache the incoming data to account for network issues, not to mention most modern wireless networks can send more data than your player's playback speed of that data.

iow, you would only have to sync the start of a song or playlist.

Apple Airport Express (1)

dwater (72834) | more than 7 years ago | (#18997195)

Not particularly useful/applicable in this situation, but I thought I'd mention it as tech that can do what you want to do.

I don't know how it works, but it does...


Sonos (0)

Anonymous Coward | more than 7 years ago | (#18997209)

I've researched this a lot. The best thing it a whole house audio system hardwired together. This requires removing a few walls. This way you can have independent or simultaneous steams. The most cost effective and slickest alternative is to buy the sonos player. That's what I finna do when my house finally gets done.

Perfect (and simple!) solution (1)

VE3OGG (1034632) | more than 7 years ago | (#18997223)

Instead of trying to sync music across multiple rooms (which can be a hassle -- if not a near impossibility), why not simply wire the speakers to every room and install a motion sensor attached to the speaker line. The music is always broadcasting, but only if there is movement. The bonus to this method, is if someone is upstairs, and someone else is downstairs, both can listen to the music without worrying about latency. It also saves a bundle in hardware since all you need is a decent soundcard and some high-quality (if you want good sound) speakers.

Re:Perfect (and simple!) solution (0)

Anonymous Coward | more than 7 years ago | (#18997321)

Motion sensing is probably a very bad idea, why not just install a switch? If someone wants to take a nap(in a room in which music is sometimes listened to) and someone else wants to listen to music, and the size of the house is such that this should be possible, one shouldn't make it impossible merely for the novelty of not having to hit a switch.

Re:Perfect (and simple!) solution (2, Funny)

Jarjarthejedi (996957) | more than 7 years ago | (#18997383)

But...motion sensing is cool...and all...stop ruining my Star Trek dreams...keep them away, them and their normal ideas...I want my motion sensing radio with mood ring capabilities for music!

Re:Perfect (and simple!) solution (1)

Grishnakh (216268) | more than 7 years ago | (#19024615)

What's this stuff about "someone else" in the same house? We're talking about someone on Slashdot here.

Re:Perfect (and simple!) solution (0)

Anonymous Coward | more than 7 years ago | (#19040257)

Mom & Dad. You know, those people that live on the upper floors of the house.

Re:Perfect (and simple!) solution (-1, Flamebait)

Anonymous Coward | more than 7 years ago | (#18997331)

that's the stupidest fucking reply i've seen in a long time. thanks for the laughs you fucking moron.
how about you just go back to digg?

Re:Perfect (and simple!) solution (1)

merreborn (853723) | more than 7 years ago | (#18997401)

Most motion sensors wouldn't detect, say, someone sitting at a computer, reading slashdot.

Having the music cut out unless you wave your arms around every 5 minutes might be a touch obnoxious.

Re:Perfect (and simple!) solution (1)

UncleTogie (1004853) | more than 7 years ago | (#18997667)

Most motion sensors wouldn't detect, say, someone sitting at a computer, reading slashdot.

Use your webcam with motion-sensing software. A number of "security" apps will let you trigger an external program that could very well fire off an X10 [] signal upon a sense event [or lack thereof.]

I know most of us are mouse potatoes, but I'm also fairly sure a large percentage make some form of perceptible motion within 5 minutes time.

Re:Perfect (and simple!) solution (1)

FLEB (312391) | more than 7 years ago | (#18998987)

Use a light beam/sensor between the arms of the office chair. Or, for that matter, a pressure switch wired to the chair.

Re:Perfect (and simple!) solution (1)

wik (10258) | more than 7 years ago | (#19003619)

You must not have cats.

Re:Perfect (and simple!) solution (1)

Grishnakh (216268) | more than 7 years ago | (#19025617)

Your cats must be awfully fat if you're worried about them triggering a pressure switch set for human weight.

Re:Perfect (and simple!) solution (1)

mrchaotica (681592) | more than 7 years ago | (#18999353)

The music is always broadcasting, but only if there is movement.

And so when they sit down to listen, the music stops? Brilliant!

Three Techniques: (1)

Steve-o-192.168 (1096403) | more than 7 years ago | (#18997353)

1. Low Power FM Transmitter hooked to a central player, FM receivers elsewhere in the house. Check ebay for some cheap, stereo FM transmitters

2. Use a stream server on your network to "stream" your mp3's to the other players. This should be pretty close to real time synchronization.

3. Run speaker wire to each room from a central location

I've actually tried 1 & 3, they work great!

The answers are: Yes and I don't know. (1)

romland (192158) | more than 7 years ago | (#18997579)

pim6sd []

The things we have to struggle against (1, Funny)

exp(pi*sqrt(163)) (613870) | more than 7 years ago | (#18997887)

> it's almost impossible to get the music aligned

OMFG! Life is so hard!

Sync'ing movies between two households? (1)

KWTm (808824) | more than 7 years ago | (#18998003)

I have a related situation for which I'd love to hear you Slashdotters' input.

In these few months, I am going to be out-of-town for most days out of the month. My wife and I miss each other very much and we've gotten the old Unlimited-Talk-To-Each-Other-On-Your-Cellphone plan, etc. But one of our favourite activities is watching movies or TV shows together. We already know how to play them on the computer when we are at home together (got the ol' bigscreen and hi-fi hooked up to my Linux box), but it would be great if we could watch the show simultaneously even when I'm out of town.

I would have a computer with me, and my wife could play it on the home desktop. I envision a scheme where we would be on the phone with each other throughout the whole movie (who cares, it's an unlimited calling scheme). We wouldn't say much, but we'd be able to hear each other laugh, or gasp in surprise, etc. But the thing is, I want to be able to synchronize the movie. We enjoy watching thrillers where a delay of one second might spoil a plot surprise (e.g. my wife screams over the phone, "He's alive!"), so I hope to be able to make any delay unnoticeable.

How to do this?

The worst case would be that we both start the movie manually, and it will probably be out of sync by a few seconds (depending on how long it takes the player software to start up). The next step up might be to synchronize both computers to the same NTP server, and then set a cron job (or what's the one-time cron command called? "at", I think?) to start the movie at a specified time a few minutes into the future.

But is there some way to synchronize keypresses? So that, for example, if we have to pause the movie, both computers pause at the same point?

I thought of using VNC, but it tends to be slow outside the home LAN. If I wanted to pause a movie, I'd have to pause the local player, then switch to the VNC screen (and wait for it to redraw the remote screen), then hit the pause button (and wait for the remote computer to sense my keypress and stop). Reversing the order (pausing the remote player first, then the local) is slightly better but not by much.

This scenario is not quite the same as a the OP scenario, since the hookup spans different cities rather than just within the same home. It's also not the same as a streaming webcast, mainly because the bandwidth is not there for streaming video of this quality --nor is it necessary, since both computers already have the video content pre-loaded; it's just a matter of synchronizing the playback.

Any ideas?

Re:Sync'ing movies between two households? (0)

Anonymous Coward | more than 7 years ago | (#18998275)

Wife? You liar, you're just going to put a delay in so you can hear your own laughter and not feel so alone, aren't you?

Re:Sync'ing movies between two households? (1)

Digital_Quartz (75366) | more than 7 years ago | (#18998427)

You're going to run into a problem with latency in the handsets. There's a noticeable delay on most cellular networks even inside the same city (it's actually pretty remarkable how many times your voice signal is decompressed and re-compressed as it hops from node to node on the network, and each hop adds latency and lower quality). So, if both movies actually were started at exactly the same time, you would both hear each other's reactions anywhere from a 1/10th to 1/2 after the movie you were watching.

Re:Sync'ing movies between two households? (1)

netsharc (195805) | more than 7 years ago | (#19007069)

One way I'd solve this is, you can start the player and movie, and hit pause at a certain point, e.g. when the movie logo shows up. Then you can tell your wife to load it and hit pause when the logo shows up. This makes sure loading latencies don't affect anything. After you're both paused at the same place, you can just do a countdown and unpause at zero.

But as the other poster said, the cellphone network might have other ideas of latencies...

Re:Sync'ing movies between two households? (1)

Virgil Tibbs (999791) | more than 7 years ago | (#19024707)

I've done the same thing thing
but personally i still think there is no real answer
maybe go and find out what the real definition of VLC media player is about but i dont think that would help really
if you find an answer let us know...

Centralized unit (2, Interesting)

ZipR (584654) | more than 7 years ago | (#18998233)

I have a system from these guys ( in my house. Each room has its own set of built-in speakers, with a separate volume and source control too. I serve music via my computer (in the basement), and can skip from song to song in the living room (on the first floor) with an ATI remote wonder (works through walls.) I also have my main TV audio hooked into the system as well as the DVD/CD player. When the big game is on, I can turn it up in all the rooms.

Airport Express easily streams 2 multiple speakers (1)

mrfett (610302) | more than 7 years ago | (#18998269)

A few ppl have already mentioned it, but I actually use it and it works wonderfully. I have a set of speakers upstairs, in the living room, on the patio, and in the downstairs den. I can run iTunes from any machine in the house and send the stream to any of these Airport Express-connected speakers. It's a fantastic solution that really works. Of course, you need to consider your network layout, but these small basestations are able to extend existing networks, and can do B and/or G. They also do printer sharing. The audio output can be either stereo analog or digital mini. Given the small footprint/multiple uses/low cost of these units, I wouldn't consider anything else.

Re:Airport Express easily streams 2 multiple speak (1)

mrfett (610302) | more than 7 years ago | (#18998283)

just to clarify, I said "any" speaker, and should've said any/all. You can use as many speaker as you have hooked up, at the same time, in-sync.

Re:Airport Express easily streams 2 multiple speak (1)

nuxx (10153) | more than 7 years ago | (#18998491)

I'll chime in on this too. I use two Airport Expresses, one in the basement and one in the living room. I can (and regularly do) have music playing from my desktop machine (PowerMac G5), living room, and basement all at the same time, all in sync. It works great, and as picking the alternate outputs is done with dropdown in iTunes, it's wonderfully easy to switch around where the music comes from.

J. River Media Center (1)

stickynips (1088445) | more than 7 years ago | (#18998295)

I use J. River Media Center just for this. [] It's got a feature much like iTunes, where you can share your media library over a network. It also allows sorting and tagging of every sort of video file (iTunes is very limited with video files). Simply setting up a media server on one computer will allow you to access that same library on multiple computers.

Who are these people? (2, Insightful)

ArchieBunker (132337) | more than 7 years ago | (#18998331)

Not to sound like Jerry Seinfeld, but who are these people? Who needs music piped into every room of their house available constantly? Who needs an ipod to get through the day at work?

Jerry Seinfeld Would have said... (1)

mdboyd (969169) | more than 7 years ago | (#18998605)

And what is the deal with streaming music? You need music everywhere you go? Do you listen to music in the bathroom? etc. etc.

I always thought Kramer was the funniest anyway.

Re:Who are these people? (1)

Bill Walker (835082) | more than 7 years ago | (#19001059)

Who needs music piped into every room of their house available constantly?

Who needs music?

Who needs an ipod to get through the day at work?

I do. I work on a trading floor as a quantitative analyst. When I need to concentrate, music is a hell of a lot less distracting than the conversations I can hear otherwise.

Incidentally, this is what you get for asking rhetorical questions on Slashdot. Some nerd will always take you literally anyway.

wireless speakers (1)

TheSHAD0W (258774) | more than 7 years ago | (#18998881)

Get some sets of good wireless speakers. Use one transmitter and tune all the other speakers to it. Voila, you have the same music all through the house, no delays, no extra wiring, little expense.

It's Buffer Time... (1)

dthirteen (307585) | more than 7 years ago | (#18999503)

You're probably not using a Mac or you'd already have an airport extreme...

If you're linux compatible you should check out mpg123 as it can take a playlist on standard in, and it can buffer n bytes of music. In the man page they suggest that a one meg buffer is about six seconds of delay, so that's one way to give yourself some tuneable delay...

mpg123 will also let you send the output in pcm or wav to standard out... and then you could make your own software based buffer before handing the music off to the sound card...

If you're using Windows, I guess we don't have much to say to one another...

Use the ethernet cable for analog signals (1)

hankwang (413283) | more than 7 years ago | (#18999695)

Of course, if you don't want to run audio cables throughout your home, you could also consider sending the audio signal over the unused wire pairs that are in the ethernet cable. Unless you use gigabit ethernet, only two out of the four wire pairs in the UTP-cable are used. It's twisted pair, so it's reasonably immune to interference.

vlc (1)

m_frankie_h (240122) | more than 7 years ago | (#19000049)

vlc ( has a network sync feature, allowing you to synchronise playback on several computers.

Re:vlc (1)

Not Public (257178) | more than 7 years ago | (#19001979)

I have to second the VLC reccomendation.

best of all, its handles multiple OSs

it handles varying latencies pretty well, i've had it sync two desktops over a 10/100 local and a 802.11b and a 802.11g laptop at opposite ends of the house... and it sounded pretty decent.

anything more is excessively costly, complicated and a pain in the ass.

Hate to point out the obvious but... (4, Informative)

cybereal (621599) | more than 7 years ago | (#19000397)

Apple's iPod + iTunes + Airport Express covers all of your needs.

One iTunes installation streaming to several AirPort Express base stations (connectable via wifi or ethernet) provides just what you need, including synchronized output. I was really surprised when I discovered the output was synchronized, despite being streamed as data and decoded at the express device itself.

Furthermore, if you have several iPods it's trivial to synchronize them all with the same iTunes installation, in fact, it's kind of the entire point and reason behind the iPod's success isn't it?

It's not like the iPod is that great of a player, and people can quit pretending the scroll wheel was a good idea because it's not (my sore thumb joint...) but the software to manage the things, that's the golden feature right there.

I'm sorry to be the one that pimps Apple on this, but son... they've got you pegged.

PulseAudio (1)

sirfunk (667309) | more than 7 years ago | (#19001485)

PulseAudio, which is a cross-platform audio server/proxy. Is supposed to have very good synchronization across different' sound cards and across the network. I havn't gotten to play with it much, but it might be the solution you are looking for. []

Obvious (2, Funny)

triso (67491) | more than 7 years ago | (#19014245)

Put a MP3 player in your pocket, with the tunes you want, put some headphones on and the music will follow you around, magically, without phase or synchronization problems.

Squeezeboxes and slimserver (1)

Xenna (37238) | more than 7 years ago | (#19032847)

I have 4 Squeezebox III players all over the house. They can be synchronized. In fact the living room and kitchen players are permanently synchronized. Whenever I turn on the kitchen SB it starts playing what the living room SB is playing.

Check for New Comments
Slashdot Login

Need an Account?

Forgot your password?

Submission Text Formatting Tips

We support a small subset of HTML, namely these tags:

  • b
  • i
  • p
  • br
  • a
  • ol
  • ul
  • li
  • dl
  • dt
  • dd
  • em
  • strong
  • tt
  • blockquote
  • div
  • quote
  • ecode

"ecode" can be used for code snippets, for example:

<ecode>    while(1) { do_something(); } </ecode>