Details

This patch adds pseudo stereo output to the TinySID sid codec by splitting the three sid voices to the right and left audio channels.
Sid playback sounds much better then, especially with headphones. Famous sid players (e.g. sidplay2/w) also do that to enhance sid sound.
Note: this is not an implementation of a stereo sid because that needs a complete emulation of a 2nd sid chip. I think any further efforts should concentrate on porting the sidplay engine to rockbox.

The function synth_render() computes the sid internal voices and maps them to the pcm buffer for a given count of pcm samples. I extended the function arguments by one more pcm buffer pointer for the second channel. Voice 1 and 3 are then written to the right and voice 2 to the left channel (I assume it is not standardized which voice goes to which channel). I also mixed 1/16th of every channel to the respectively other channel because this will give a more natural sound compared with the very hard panning if the voices are completely seperated.
Overflow of the variables outf and outo should not happen because before they carried three voices, now only max. 2.0625. And please have a look at the additional 2k memory for the second pcm buffer, imho no problem, at least it compiles :)

I can imagine you get a nice stereo effect by using psycho-acoustics a bit, for example put one channel in one ear and a slightly delayed and low-pass filtered version of this channel in the other ear. The delay represents the delay between your ears, say 20 cm, or about 600 us, or about 26 samples at 44100 Hz. The low-pass filter represents the shadowing effect of your head: the close ear hears the full-range sound, the far ear hears the sound with the high-frequencies attenuated, similar to what we do with crossfeed.

I just built a version with this patch. It sure is nice having stereo imaging, but even with crossfeed it sounds a bit 'irritating', since bass frequencies are also hard-panned to one side. It would be great if frequencies below, say, 200-300 Hz could be kept fully in the center, for a more natural feeling.