Opened 3 years ago

Last modified 3 years ago

#16639 new bug

Can't play wav file correctly when using es1370 driver

Reported by: danboid Owned by: nobody
Priority: normal Milestone: Unscheduled
Component: Drivers/Audio/es1370 Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description (last modified by diver)

When running haiku-master-hrev54756-x86_gcc2h-anyboot under qemu 4.2.1 running under Ubuntu 20.04 using qemus es1370 soundhw option, the following wav file sounds like its being played at half speed when played with MediaPlayer:

https://freewavesamples.com/files/Ensoniq-ZR-76-03-Dope-85.wav

$ mediainfo Ensoniq-ZR-76-03-Dope-85.wav 
General
Complete name                            : Ensoniq-ZR-76-03-Dope-85.wav
Format                                   : Wave
File size                                : 486 KiB
Duration                                 : 2 s 821 ms
Overall bit rate mode                    : Constant
Overall bit rate                         : 1 412 kb/s
Performer                                : freewavesamples.com
Director                                 : freewavesamples.com

Audio
Format                                   : PCM
Format settings                          : Little / Signed
Codec ID                                 : 1
Duration                                 : 2 s 821 ms
Bit rate mode                            : Constant
Bit rate                                 : 1 411.2 kb/s
Channel(s)                               : 2 channels
Sampling rate                            : 44.1 kHz
Bit depth                                : 16 bits
Stream size                              : 486 KiB (100%)

If I play the same wav file under MediaPlayer with exactly the same config but using qemu's AC97 soundhw driver instead the file plays back correctly.

Change History (2)

comment:1 by danboid, 3 years ago

I thought it would also be worth mentioning that I have got the same wav file to play OK under the same version of qemu using the es1370 soundhw driver but running NetBSD 9.1 in a guest VM. By the looks of it, OpenBSD should work too but I've not tried.

$ qemu-img create netbsd-disk.img 20G
$ qemu-system-i386 -enable-kvm -m 2048M -drive file=netbsd-disk.img,if=virtio -cdrom \
             ./Downloads/NetBSD-9.1-i386.iso -display curses -boot d \
             -nic user,model=virtio-net-pci
# Install NetBSD then quit the installer and `poweroff`
$ qemu-system-i386 -enable-kvm -m 2048M -drive file=netbsd-disk.img,if=virtio -display curses -boot d -net nic -net user -soundhw es1370

# After booting into NetBSD:
$/etc/rc.d/dhcpcd onestart
$ ftp https://freewavesamples.com/files/Ensoniq-ZR-76-03-Dope-85.wav
$ audioplay Ensoniq-ZR-76-03-Dope-85.wav
Last edited 3 years ago by danboid (previous) (diff)

comment:2 by diver, 3 years ago

Component: DriversDrivers/Audio/es1370
Description: modified (diff)
Keywords: es1370 qemu audio driver removed
Note: See TracTickets for help on using tickets.