Opened 16 years ago

Closed 5 years ago

#146 closed defect (too-old)

No sound in Virtual PC

Reported by: mikeforester Owned by:
Priority: normal Milestone:
Component: UNIAUD16 Version: 1.9.8
Severity: normal Keywords:
Cc:

Description

I know that they said, back when VPC was still a live project, that the only supported audio driver was Sander's sbliveos2. But earlier versions of Uniaud did work. Now that I've finally got Uniaud working again with 1.9.8, I was disappointed that I got no sound. That's kind of a deal-breaker for me, because I need VPC for all the things I can't do in OS/2 (e.g. most Flash).

Other comments on 1.9.8: It supports this fairly new Intel HDA chip, and I'm truly impressed by that. The only problem I have apart from VPC is that I get a small hiccup on system sounds -- like a stutter: it repeats about a half-second of the wav file that just finished, like a stinger.

Attachments (3)

uni.txt (7.0 KB ) - added by abwillis 13 years ago.
Log after launching VPC
uni1.txt (6.3 KB ) - added by abwillis 13 years ago.
Log without launching VPC
vpc2.diff (769 bytes ) - added by abwillis 12 years ago.
Update file, had to increase minsize for Alsa 1.0.24

Download all attachments as: .zip

Change History (16)

comment:1 by mikeforester, 16 years ago

Interesting update: Sound works in VPC when Uniaud 1.9.8 is used with an SBLive card -- just not when it's used with onboard HD audio. The stutter/sound repetition problem is the same with both audio devices, however.

Also, using Uniaud with SBLive conflicts with GenMac and the onboard Marvell LAN chip, for some reason. They don't share an IRQ or any address space, and there's no problem with the onboard HDA and onboard LAN. Odd.

comment:2 by losepete, 14 years ago

Just to add my 2 pence worth:

I also find that my WindowsXP guest can no longer play audio if I use recent/current builds of uniaud.

The last version that works for me is uniaud32-1.9.2 with uniaud16.sys from the 114RC6 release.

Is there any specific reason why recent/current builds of uniaud do not play audio from a VirtualPC/2 guest?

comment:3 by SigurdWarp, 14 years ago

Is this issue being worked on? Still good no sound in Virtual PC with the latest UNIAUD (195-1924). Hardware is onboard HDA (Lenovo X200T) Thanks for information.

comment:4 by abwillis, 13 years ago

I can confirm that I have sound with uniaud32.sys 1.9.2 but it works with uniaud16.sys 1.9.5 in my Z81m with HDA. So it is definitely in uniaud32.sys and related to HDA audio as the newer versions work fine with VPC in my T42 that doesn't have HDA.

Version 0, edited 13 years ago by abwillis (next)

comment:5 by abwillis, 13 years ago

Further testing shows that 1.9.6 was the last one that worked and 1.9.8 did not (have not gone version by version above that yet but the few I have tried above 1.9.8 do not work).

by abwillis, 13 years ago

Attachment: uni.txt added

Log after launching VPC

by abwillis, 13 years ago

Attachment: uni1.txt added

Log without launching VPC

comment:6 by abwillis, 13 years ago

Attached log files, shows: Period size min=b0 max=b0 Error -22 second time.. Bailing U16: StartStream: ConfigDev failed!! channels: 2, period size: 2c0 channels selected: 2 HWP: SR rate 44100, BPS 16, CH 2, PRSZ b0, periods 20 hda_codec_cleanup_stream: NID=0x3

Period size min=b0 max=b0 Error -22 second time.. Bailing U16: StartStream: ConfigDev failed!!

\lib32\sound.c for the error -22 second time bailing message The ConfigDev is in uniaud16. As uniaud16 works with older uniaud32 on HDA and with current uniaud32 on non-HDA I think it is caused by getting the error -22.

comment:7 by abwillis, 13 years ago

This gets me sound in VPC with the trunk uniaud32.sys (latest uniaud16 release being used):

Index: lib32/sound.c
===================================================================
--- lib32/sound.c	(revision 563)
+++ lib32/sound.c	(working copy)
@@ -965,16 +965,19 @@
 	_snd_pcm_hw_params_any(&params);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_ACCESS,
 						   SNDRV_PCM_ACCESS_RW_INTERLEAVED, 0);
+#if 0
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_SAMPLE_BITS,
 						  pHwParams->ulBitsPerSample, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_FRAME_BITS,
 						   pHwParams->ulBitsPerSample*pHwParams->ulNumChannels, 0);
+#endif
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_FORMAT,
 						   OSSToALSADataType[pHwParams->ulDataType], 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_CHANNELS,
 						   pHwParams->ulNumChannels, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_RATE,
 						   pHwParams->ulSampleRate, 0);
+#if 0
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_SIZE,
 						   periodsize, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_BYTES,
@@ -985,6 +988,7 @@
 						   periodsize*nrperiods, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_BUFFER_BYTES,
 						   periodbytes*nrperiods, 0);
+#endif
 
 
 	dprintf(("HWP: SR rate %ld, BPS %ld, CH %ld, PRSZ %lx, periods %lx",

comment:8 by abwillis, 13 years ago

See also ticket #215 pmixWrite() failed if a buffer size is too small

comment:9 by abwillis, 13 years ago

With this information from #215 and the buffer size I was able to narrow it down a bit more and the following is all that I needed and not the first section of the last diff:

Index: sound.c
===================================================================
--- sound.c	(revision 563)
+++ sound.c	(working copy)
@@ -975,6 +975,7 @@
 						   pHwParams->ulNumChannels, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_RATE,
 						   pHwParams->ulSampleRate, 0);
+#if 0
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_SIZE,
 						   periodsize, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_BYTES,
@@ -985,6 +986,7 @@
 						   periodsize*nrperiods, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_BUFFER_BYTES,
 						   periodbytes*nrperiods, 0);
+#endif
 
 
 	dprintf(("HWP: SR rate %ld, BPS %ld, CH %ld, PRSZ %lx, periods %lx",

comment:10 by abwillis, 12 years ago

A better workaround and gives a bit more information:

Index: sound.c
===================================================================
--- sound.c	(revision 563)
+++ sound.c	(working copy)
@@ -975,6 +975,7 @@
 						   pHwParams->ulNumChannels, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_RATE,
 						   pHwParams->ulSampleRate, 0);
+if (periodsize > 6 * minperiodsize) {
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_SIZE,
 						   periodsize, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_PERIOD_BYTES,
@@ -985,6 +986,7 @@
 						   periodsize*nrperiods, 0);
 	_snd_pcm_hw_param_set(&params, SNDRV_PCM_HW_PARAM_BUFFER_BYTES,
 						   periodbytes*nrperiods, 0);
+}
 
 
 	dprintf(("HWP: SR rate %ld, BPS %ld, CH %ld, PRSZ %lx, periods %lx",

5 times the minperiodsize was not enough... I did not try fractions. Mplayer will run into problems when I had it in a #if 0 block but works with this.

by abwillis, 12 years ago

Attachment: vpc2.diff added

Update file, had to increase minsize for Alsa 1.0.24

comment:11 by abwillis, 12 years ago

The only difference in the new patch is that I had to increase the minimum periodsize as such: if (periodsize > 6 * minperiodsize) { if (periodsize > 16 * minperiodsize) {

comment:12 by martini, 5 years ago

Hi

This ticket is too old. Please test the issue with the latest version of Uniaud and if the problem persist please re-open the ticket.

Regards

comment:13 by martini, 5 years ago

Resolution: too-old
Status: newclosed
Note: See TracTickets for help on using tickets.