You are not logged in.

#1 2011-06-26 13:16:57

Belshirash
Member
Registered: 2011-06-26
Posts: 10

Logitech HD Webcam C270 - Chipmunk Sound

Hi!

2 Days ago i bought a Logitech HD Webcam C270. The video just works fine, but the built-in microphon makes some trouble. Sometimes it works as expected, but in the majority of cases my voice just sounds like a chipmunk. It also doesn't matter, what program i'm using... Skype, Mumble, Audio-Recorder... the result is always the same. In Audio Recorder i noticed, that when i record about 30 second, the time indication shows only about 10 seconds. On my other computer with Ubuntu 10.04the mic works fine.

At the moment i'm using ArchLinux with Gnome3.
Some systeminformation:

[belshi@ArchLinux ~]$ lspci | grep Audio
00:1b.0 Audio device: Intel Corporation 6 Series Chipset Family High Definition Audio Controller (rev 05)
01:00.1 Audio device: nVidia Corporation Device 0bee (rev a1)
[belshi@ArchLinux ~]$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 004 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 004 Device 003: ID 046a:0023 Cherry GmbH CyMotion Master Linux Keyboard
Bus 004 Device 004: ID 04fc:0801 Sunplus Technology Co., Ltd 
Bus 004 Device 005: ID 046d:0825 Logitech, Inc. Webcam C270
[belshi@ArchLinux ~]$ lsmod | grep snd
snd_usb_audio          90246  1 
snd_usbmidi_lib        18737  1 snd_usb_audio
snd_rawmidi            19466  1 snd_usbmidi_lib
snd_seq_device          5372  1 snd_rawmidi
snd_hda_codec_hdmi     22784  4 
snd_hda_codec_realtek   297871  1 
snd_hda_intel          22186  2 
snd_hda_codec          77703  3 snd_hda_codec_hdmi,snd_hda_codec_realtek,snd_hda_intel
snd_hwdep               6342  2 snd_usb_audio,snd_hda_codec
snd_pcm                73736  4 snd_usb_audio,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec
snd_timer              19488  1 snd_pcm
snd                    57384  17 snd_usb_audio,snd_usbmidi_lib,snd_rawmidi,snd_seq_device,snd_hda_codec_hdmi,snd_hda_codec_realtek,snd_hda_intel,snd_hda_codec,snd_hwdep,snd_pcm,snd_timer
soundcore               6178  1 snd
snd_page_alloc          7161  2 snd_hda_intel,snd_pcm
usbcore               141904  7 uvcvideo,snd_usb_audio,snd_usbmidi_lib,usbhid,xhci_hcd,ehci_hcd
[belshi@ArchLinux ~]$ dmesg | tail
...
[  147.423978] 5:3:4: cannot set freq 48000 to ep 0x86
[ 1283.683742] usb 4-1.6: USB disconnect, device number 5
[ 1286.426289] usb 4-1.6: new high speed USB device number 6 using ehci_hcd
[ 1286.729387] uvcvideo: Found UVC 1.00 device <unnamed> (046d:0825)
[ 1286.826185] input: UVC Camera (046d:0825) as /devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.6/4-1.6:1.0/input/input9
[ 1287.825518] 6:3:1: cannot set freq 16000 to ep 0x86

The message "cannot set freq..." is not always like this. Sometimes there's another number, sometimes no number and sometimes the message shows up multiple times.

Sample file: http://dl.dropbox.com/u/5749019/sample.mp3

PS: Sorry, if my english sucks smile

Last edited by Belshirash (2011-06-26 13:22:19)

Offline

#2 2011-06-26 19:25:15

jose1711
Member
Registered: 2006-07-08
Posts: 144

Re: Logitech HD Webcam C270 - Chipmunk Sound

same thing with my logitech c200 webcam w/ integrated microphone. i think the issue is there since ugprade to gnome3 so it may have something to do with pulseaudio. joe

edit:
voice seems to sound right when played at 0.35x of recorded speed.

edi2:
same sound distortion when using arecord -D .. seems like pulseaudio is innocent in this

Last edited by jose1711 (2011-06-26 22:20:52)

Offline

#3 2011-06-27 09:20:40

insecticider
Banned
Registered: 2011-06-16
Posts: 29

Re: Logitech HD Webcam C270 - Chipmunk Sound

same here with my Logitech Webcam Pro 9000. any solutions yet? regards.

Offline

#4 2011-06-27 09:25:43

jose1711
Member
Registered: 2006-07-08
Posts: 144

Re: Logitech HD Webcam C270 - Chipmunk Sound

maybe someone brave will want to downgrade kernel and check if it helps. btw sample.mp3 from the original post sounds like "eins, zwei, drei, vier, fuenf" :-)

Offline

#5 2011-06-27 10:30:20

Belshirash
Member
Registered: 2011-06-26
Posts: 10

Re: Logitech HD Webcam C270 - Chipmunk Sound

jose1711 wrote:

voice seems to sound right when played at 0.35x of recorded speed.

jose1711 wrote:

maybe someone brave will want to downgrade kernel and check if it helps. btw sample.mp3 from the original post sounds like "eins, zwei, drei, vier, fuenf" :-)

Right :-) I recorded this sample for the german ArchLinux board.
I still have no solution. Just suppose, it's an issue with snd_usb_audio module.

Offline

#6 2011-06-27 14:23:25

GogglesGuy
Member
From: Rocket City
Registered: 2005-03-29
Posts: 610
Website

Re: Logitech HD Webcam C270 - Chipmunk Sound

Same with my new Logitech C310 webcam. My logitech headset does work though (also usb).

Possibly related:

https://bugs.launchpad.net/ubuntu/+sour … bug/459445

Last edited by GogglesGuy (2011-06-27 14:29:21)

Offline

#7 2011-06-30 16:43:00

totsilence
Member
Registered: 2010-02-01
Posts: 20

Re: Logitech HD Webcam C270 - Chipmunk Sound

Hey,

I have the same problem with this webcam (from lsusb):
Bus 001 Device 004: ID 046d:0807 Logitech, Inc. Webcam B500

I sound like a chipmunk most of the time, but trying very often sometimes fixes it.

EDIT: I tried with kernel26-lts which is of the 2.6.32 series and it works there.
I should also add that I never had any problems until like a month or at most two ago...

Last edited by totsilence (2011-06-30 17:30:18)

Offline

#8 2011-07-04 12:07:33

Belshirash
Member
Registered: 2011-06-26
Posts: 10

Re: Logitech HD Webcam C270 - Chipmunk Sound

totsilence wrote:

EDIT: I tried with kernel26-lts which is of the 2.6.32 series and it works there.
I should also add that I never had any problems until like a month or at most two ago...

Ok...that would explain why it works on my Ubuntu System for it has also an older kernel version. Maybe we should make a new bug report. I probably could make one later this evening.

Offline

#9 2011-07-04 17:57:07

totsilence
Member
Registered: 2010-02-01
Posts: 20

Re: Logitech HD Webcam C270 - Chipmunk Sound

I think the problem is in kernel module snd-usb-audio, not 100% sure though.
What I'm pretty sure of is that it has something to do with the frequency not being set up correctly:
I.e. The kernel module is recording in 16.000 Hz (but thinks its actually recording in either 44100 or 48000, don't know exactly).
When you play it back, you do so in 44100/48000 and hence the speedup.

Offline

#10 2011-07-05 00:10:51

Belshirash
Member
Registered: 2011-06-26
Posts: 10

Re: Logitech HD Webcam C270 - Chipmunk Sound

Just had a look at the source of the alsa driver (1.0.24) and found the following function in line 195 of sound/usb/clock.c

static int set_sample_rate_v1(struct snd_usb_audio *chip, int iface,
                  struct usb_host_interface *alts,
                  struct audioformat *fmt, int rate)
{
    struct usb_device *dev = chip->dev;
    unsigned int ep;
    unsigned char data[3];
    int err, crate;

    ep = get_endpoint(alts, 0)->bEndpointAddress;

    /* if endpoint doesn't have sampling rate control, bail out */
    if (!(fmt->attributes & UAC_EP_CS_ATTR_SAMPLE_RATE))
        return 0;

    data[0] = rate;
    data[1] = rate >> 8;
    data[2] = rate >> 16;
    if ((err = snd_usb_ctl_msg(dev, usb_sndctrlpipe(dev, 0), UAC_SET_CUR,
                   USB_TYPE_CLASS | USB_RECIP_ENDPOINT | USB_DIR_OUT,
                   UAC_EP_CS_ATTR_SAMPLE_RATE << 8, ep,
                   data, sizeof(data), 1000)) < 0) {
        snd_printk(KERN_ERR "%d:%d:%d: cannot set freq %d to ep %#x\n",
               dev->devnum, iface, fmt->altsetting, rate, ep);
        return err;
    }

    if ((err = snd_usb_ctl_msg(dev, usb_rcvctrlpipe(dev, 0), UAC_GET_CUR,
                   USB_TYPE_CLASS | USB_RECIP_ENDPOINT | USB_DIR_IN,
                   UAC_EP_CS_ATTR_SAMPLE_RATE << 8, ep,
                   data, sizeof(data), 1000)) < 0) {
        snd_printk(KERN_WARNING "%d:%d:%d: cannot get freq at ep %#x\n",
               dev->devnum, iface, fmt->altsetting, ep);
        return 0; /* some devices don't support reading */
    }

    crate = data[0] | (data[1] << 8) | (data[2] << 16);
    if (crate != rate) {
        snd_printd(KERN_WARNING "current rate %d is different from the runtime rate %d\n", crate, rate);
        // runtime->rate = crate;
    }

    return 0;
}

As you can see, the "cannot set freq" error is fired in this function. Maybe this helps someone who is more familiar with C than me.

Offline

#11 2011-07-05 00:15:39

sand_man
Member
From: Australia
Registered: 2008-06-10
Posts: 2,164

Re: Logitech HD Webcam C270 - Chipmunk Sound

I'm happy I'm not the only one with this problem. I've been booting into another unnamed OS to use Skype lately because of this.


neutral

Offline

#12 2011-07-22 16:19:52

dgbaley27
Member
Registered: 2011-07-22
Posts: 47

Re: Logitech HD Webcam C270 - Chipmunk Sound

I downgraded to the last 2.6.38 package and my problem was solved. However, I still see these "cannot get freq" messages.

This is the only commit in recent history on that file: http://git.kernel.org/?p=linux/kernel/g … 7847950668

However, there are a few things on the whole sound/usb directory. I'll try to do a git bisect on the kernel if I have time.

Last edited by dgbaley27 (2011-07-22 16:24:56)

Offline

#13 2011-07-24 21:23:24

dgbaley27
Member
Registered: 2011-07-22
Posts: 47

Re: Logitech HD Webcam C270 - Chipmunk Sound

I'm not having any luck with the bisect. I was hoping I could bisect just the snd-usb-audio module but it doesn't look like that'll be happening. I'm going to have to modify the kernel PKGBUILD to use a git tree with an ongoing bisect. Meanwhile, the issue is *not* fixed in linux-3.0

Offline

#14 2011-07-24 21:47:59

jose1711
Member
Registered: 2006-07-08
Posts: 144

Re: Logitech HD Webcam C270 - Chipmunk Sound

thank you for keeping us in the loop

Offline

#15 2011-07-29 16:10:28

GogglesGuy
Member
From: Rocket City
Registered: 2005-03-29
Posts: 610
Website

Re: Logitech HD Webcam C270 - Chipmunk Sound

Did somebody already file a bug report somewhere (alsa or kernel bugzilla)?

Offline

#16 2011-07-30 02:36:21

hyperflexed
Member
Registered: 2010-10-16
Posts: 10

Re: Logitech HD Webcam C270 - Chipmunk Sound

Having the same problem with the same hardware as OP.

Is there a simple way to downgrade the kernel to 2.6.38 in the meantime?

I tried grabbing the package and all the dependencies from the ARM, but pacman was giving me a hassle when I tried to downgrade nvidia and nvidia-utils to match the kernel. It seems Ubuntu is keeping a pile of kernels around for when these things happen while arch is just keeping the latest kernel. Maybe I have to configure things differently to get Arch to keep "backup" kernels. I'm new to this.

Last edited by hyperflexed (2011-07-30 02:38:47)

Offline

#17 2011-07-30 09:15:16

xamaco
Member
From: Corsica, France
Registered: 2010-04-05
Posts: 87

Re: Logitech HD Webcam C270 - Chipmunk Sound

You could try to use kernel26-lts (2.6.23) with the nvidia-lts.

Offline

#18 2011-07-31 03:56:27

dgbaley27
Member
Registered: 2011-07-22
Posts: 47

Re: Logitech HD Webcam C270 - Chipmunk Sound

hyperflexed wrote:

Having the same problem with the same hardware as OP.

Is there a simple way to downgrade the kernel to 2.6.38 in the meantime?

I tried grabbing the package and all the dependencies from the ARM, but pacman was giving me a hassle when I tried to downgrade nvidia and nvidia-utils to match the kernel. It seems Ubuntu is keeping a pile of kernels around for when these things happen while arch is just keeping the latest kernel. Maybe I have to configure things differently to get Arch to keep "backup" kernels. I'm new to this.

Check out the -d flag. Skip dependency checking while you're downgrading.

Offline

#19 2011-07-31 09:51:15

Belshirash
Member
Registered: 2011-06-26
Posts: 10

Re: Logitech HD Webcam C270 - Chipmunk Sound

@GogglesGuy Sorry, didn't have enough time in the last few weeks to create a bug report, because of a project I'm working on. Maybe someone who's english is better and who has more time can create one smile

Offline

#20 2011-08-03 23:07:25

ras0ir
Member
From: Ankara/Turkey
Registered: 2008-06-20
Posts: 65
Website

Re: Logitech HD Webcam C270 - Chipmunk Sound

See https://bugzilla.kernel.org/show_bug.cgi?id=35922
I'm going to try the patch available on https://bugzilla.kernel.org/attachment.cgi?id=64722 , I'll post if it succeeds.

Yeah, the following patch fixed the problem:

--- a/drivers/usb/core/quirks.c.orig    2011-08-04 02:21:36.807543038 +0300
+++ b/drivers/usb/core/quirks.c 2011-08-04 02:22:26.814211036 +0300
@@ -41,6 +41,9 @@
        /* Logitech Harmony 700-series */
        { USB_DEVICE(0x046d, 0xc122), .driver_info = USB_QUIRK_DELAY_INIT },
 
+    /* Logitech Webcam C270 */
+    { USB_DEVICE(0x046d, 0x0825), .driver_info = USB_QUIRK_RESET_RESUME },
+
        /* Philips PSC805 audio device */
        { USB_DEVICE(0x0471, 0x0155), .driver_info = USB_QUIRK_RESET_RESUME },

Last edited by ras0ir (2011-08-04 00:20:18)

Offline

#21 2011-08-07 23:08:08

smart2128
Member
Registered: 2010-04-09
Posts: 14

Re: Logitech HD Webcam C270 - Chipmunk Sound

I can confirm that the patch fix the issue also for Logitech C310.
Patch applied on a 3.0.1 vanilla and it works like a charm.

--- linux-3.0.1/drivers/usb/core/quirks.c    2011-08-05 06:59:21.000000000 +0200
+++ linux-3.0.1/drivers/usb/core/quirks_c310.c    2011-08-07 19:17:28.673002728 +0200
@@ -41,6 +41,9 @@
     /* Logitech Harmony 700-series */
     { USB_DEVICE(0x046d, 0xc122), .driver_info = USB_QUIRK_DELAY_INIT },
 
+    /* Logitech Webcam C310 */
+    { USB_DEVICE(0x046d, 0x081b), .driver_info = USB_QUIRK_RESET_RESUME },
+
     /* Philips PSC805 audio device */
     { USB_DEVICE(0x0471, 0x0155), .driver_info = USB_QUIRK_RESET_RESUME },

Thanks a lot.

Offline

#22 2011-08-07 23:36:42

dgbaley27
Member
Registered: 2011-07-22
Posts: 47

Re: Logitech HD Webcam C270 - Chipmunk Sound

Hmm, I'll have to try this for my Hercules Dualpix Exchange

Offline

#23 2011-08-08 20:17:49

dgbaley27
Member
Registered: 2011-07-22
Posts: 47

Re: Logitech HD Webcam C270 - Chipmunk Sound

That patched fixed my webcam (06f8:3005 Guillemot Corp. Hercules Dualpix Exchange). I wonder if it's more of a general issue than a quirk because it seems like so many people need this.

Offline

#24 2011-08-09 02:45:32

GSF1200S
Member
Registered: 2008-12-24
Posts: 474

Re: Logitech HD Webcam C270 - Chipmunk Sound

Logitech Webcam Pro 9000

Applied the patch (modifying to values given by lsusb) and this issue is resolved. Thanks for the link to the patch..

**EDIT** Late edit just to throw up my patch file in case anyone wants to take a look:

---
 drivers/usb/core/quirks.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index 81ce6a8..6c593f9 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -41,6 +41,9 @@ static const struct usb_device_id usb_quirk_list[] = {
     /* Logitech Harmony 700-series */
     { USB_DEVICE(0x046d, 0xc122), .driver_info = USB_QUIRK_DELAY_INIT },
 
+    /* Logitech Webcam Pro 9000 */
+    { USB_DEVICE(0x046d, 0x0809), .driver_info = USB_QUIRK_RESET_RESUME },
+
     /* Philips PSC805 audio device */
     { USB_DEVICE(0x0471, 0x0155), .driver_info = USB_QUIRK_RESET_RESUME },
 
-- 
1.7.1

Last edited by GSF1200S (2011-08-09 04:44:40)

Offline

#25 2011-08-12 01:10:13

Durden
Member
Registered: 2011-06-19
Posts: 261

Re: Logitech HD Webcam C270 - Chipmunk Sound

Could someone point me to instructions on how to apply this patch? Something int he wiki maybe? I can't seem to find out how.

Offline

Board footer

Powered by FluxBB