The MP3car.com Store  

Welcome to the MP3Car.com forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. Registering will also remove advertisements. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Go Back   MP3Car.com > Mp3Car Technical > Linux

Reply
 
Thread Tools Display Modes
Old 10-17-2007, 10:24 AM   #46
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Finally got ALSA working with the *right* audio driver, installing many of the gstreamer plugins, and replacing EDS with PulseAudio.
At first I had ALSA working from the command line, but getting MP3 sound from Gnome was much less clear.
Now I'll get back to the HQCT driver and demo software. Hope I haven't broken anything in Gentoo Linux during my thrashing about.
waltersaegir is offline   Reply With Quote
Sponsored Links
Old 10-20-2007, 07:18 PM   #47
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Everythingworks after compilation/make, copying to the '/lib/modules/2.6.22-gentoo-r5/kernel/drivers/usb/misc' directory and doing a 'insmod HQCT.ko'.

I do a 'dmesg | tail' and see "Driver Initialized" and "AlignFr = {87500, 90900, 94300, 97700, 101200, 104600, 108000}"
and "DAAs = {79, 77, 75, 73, 72, 72, 74}.
I can see the hqct0 device in the /lib/dev directory.

I can run the test software that accesses the attached HQCT device.

After rebuilding the kernel and doing a 'make modules_install',
the hqct.ko file is no longer in '/lib/modules/2.6.22-gentoo-r5/kernel/drivers/usb/misc' directory,
and the /dev/hqct0 device is gone.

I found 'blacklist' in '/lib/modules/2.6.22-gentoo-r5/kernel/drivers/hid/usbhid/hidquirks.c' and added following two lines
to the bottom of the list:

#define USB_VENDER_ID_NEW 0x04d8
#define USB_DEVICE_ID_NEW 0x000a

After rebuilding the kernel (make clean && make && make modules_install), I experience the same problem *and* I see no trace of a hid-quirks.o. Which says to me that the kernel rebuild did not notice the change to hid-quirks.c.

I expect that my unfamilurity with Gentoo and Portage is biting me and I've posted on the Gentoo Forum to see what those guys think.
waltersaegir is offline   Reply With Quote
Old 10-27-2007, 06:19 PM   #48
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Replaced insmod with depmod and modprobe and now /dev/hqct0 stays around between reboots.

Getting spirious results. Sometimes works. Seems that it might be timing related.

Currently hqct_init is failing at ioctl. Seems to think that there is an invalid parameter i.e. errno ==22

I did comment-out the #include <linux/config.h> in hqct.c to get it to compile. What is that file and where else might it be located?

That could be the key. Ugh, apparently not: "The file include/linux/config.h has been removed from 2.6.19 kernel."http://www.linuxquestions.org/questions/linux-kernel-70/removal-of-includelinuxconfig.h-file-in-2.6.19-kernel-506363/

Last edited by waltersaegir : 10-27-2007 at 09:22 PM.
waltersaegir is offline   Reply With Quote
Old 11-11-2007, 08:39 AM   #49
Newbie
 
Join Date: Aug 2006
Posts: 7
My Photos: (0)
rds support...

Hi TheLlama and everybody else,
Last week I climbed back up from the edge of earth... I unearthed my hqct module and started coding. Now I've got a working RDS implementation based on TheLlama's driver from last year in combination with rdsd, which is part of the video4linux stuff (which i think we should use as there's already some stuff for radios and to have any chance of making it into the kernel tree (wishful)).
The code implements part of the v4l interface to radios, for now just enough to make rdsd happy, but a complete implementation of a radio tuner device should be nice.

Do we have a SVN repository or anything? It would be nice to get some coordination in the coding effort.

Also does anyone have a specification of the messages the HQCT throws over the USB bus?

greetz Daniel
p.s. I'm just testing it a bit more and when we have an SVN I'll upload.
djwlindenaar is offline   Reply With Quote
Old 11-11-2007, 12:07 PM   #50
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Djwlindenaar, good to see activity and progress.

I've been testing the driver under Gentoo.

I'm getting a sperious hang condition in hqct_seek_up.

It looks to be at the read(hh->fd, 0, 0);

I have added many printf and printk, but that shouldn't be the cause.

I suspect that the radio is hung for some reason and the 'read' is just waiting.

Anyone seen this problem?

I'll trial some changes to see what happens:

-temporarily eliminating the 'read'
-replacing the read with something like 'select'
waltersaegir is offline   Reply With Quote
Sponsored Links
Old 11-11-2007, 01:10 PM   #51
Newbie
 
Join Date: Aug 2006
Posts: 7
My Photos: (0)
hanging read()

I'd guess that the driver doesn't put out any data during seeking... but my driver only uses read() to output RDS data groups, so it's hard for me to check it out.

Daniel
djwlindenaar is offline   Reply With Quote
Old 11-19-2007, 11:07 AM   #52
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Made some changes to demo.c to drive the tune-seek-volume-etc functions from a case statement inside a while loop menu.

Seek seems to need more sensitivity. I should be able to find something in the code to change this.

I can tune directly to any FM station, but seek never finds them. I get no AM stations except 910 seems to give some sound.

Maybe I need something different for an antenna. I'm currently using a XM antenna at the end of a 6 ft. wire. I'll boot back to windows 2000 for comparison on AM.
waltersaegir is offline   Reply With Quote
Old 11-19-2007, 02:23 PM   #53
Newbie
 
Join Date: Aug 2006
Posts: 7
My Photos: (0)
seek sensitivity

Seek senitivity can be set using the "HQCTIOC_SET_MIN_LEVEL" ioctl.

greetz Daniel
djwlindenaar is offline   Reply With Quote
Old 11-20-2007, 07:20 PM   #54
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
The AM tuning seems to have a problem both Seeking and direct Tuning. The Pas Code under windoze works for direct Tuning, but doesn't seem to Seek. *Maybe* that's a clue for the C code problem.

I've compared the C code to the Pas code and even tried some trial-error (all error) testing of changing parameters by a factor of 10.
The C code
"PLL = (( ( ((freq/10) + interm_fr) * AM_VCO)) / AM_ref_fr);"
with AM_ref_fr == 1 why divide by one?
looks a little different from
the Pas code
"PLL := (Gewenste_Freq + IntermFreq_AM)* VCO_div_AM div RefFreq_AM;"
with RefFreq_AM == 10 (the same as FM)

I'll try some variants that I might have missed:

maybe "freq/10" SB "freq/100" or maybe "AM_ref_fr = 1" SB "AM_ref_fr = 10" or both.

Obviously I have zero frame-of-reference for the Phase-locked loop algorithm and variables.
waltersaegir is offline   Reply With Quote
Old 12-02-2007, 03:36 PM   #55
FLAC
 
TheLlama's Avatar
 
Join Date: Jul 2004
Location: All over the world
Vehicle: 2001 Paper Airplane Standard Edition
Posts: 984
My Photos: (0)
Hey everyone. I haven't been on the forums in a while since the mp3car community, for the most part, isn't the same set of folks it was when I first started. Regardless, I'm glad people are finally getting some use out of my driver. It looks like it is time to finish it.

As far as the read error on seeking. Perhaps it isn't finding any stations? so it is continuously looping? I can make it so it will stop seeking once it's gone full-circle, or maybe after a certain time.

The seeking may have a bug or two. But, if you change code in there, please pay attention to how the code functions. Two packets need to be sent to tune the radio. We set status=HQCT_STATUS_SEEKING_UP1, then send the first packet. The send_callback fires. If status==HQCT_STATUS_SEEKING_UP1, which it does, then we set status=HQCT_STATUS_SEEKING_UP2 and send the second packet.

Now, the radio will send a report back. In recv_callback, if status==HQCT_STATUS_SEEKING_UP2, then we check the signal strength and possibly call hqct_tune again.

It needs to be asynchronous like this, or else the radio driver will freeze the whole system while seeking. But, there may still be a bug in variable locking, the completion vars, whatever.
TheLlama is offline   Reply With Quote
Old 12-02-2007, 05:26 PM   #56
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
Currently I'm not getting any AM station to tune. I've tried several strong local stations and get nothing but static. Rebooting the same PC hardware to Windows 2000, allows me to tune AM. FM tunes perfectly.

The PLL calculation appears quite different for AM than the PLL calculation for FM and I wonder if there might be a bug, yet I do not see a logical (or otherwise) alternative to the existing values.

Does your testing of AM result in successful tuning?
waltersaegir is offline   Reply With Quote
Old 12-19-2007, 09:33 AM   #57
Newbie
miatacarpc's CarPC Specs
 
Join Date: Nov 2007
Vehicle: 2000 Mazda Miata SE
Posts: 22
My Photos: (0)
compatibility with other radios?

This might be a bit OT, but I'm curious if you think there's any chance that this driver will work with the Brando FM USB receiver?

in this post, it seems the Centrafuse HQCT-specific module "just works", so I'm curious if you have any idea whether the linux kernel driver might work also.

I know it's a naive question, and probably too much to hope for. Otherwise I might have to dust off my programming hat and try to figure out how to write an HID driver for this specific radio. For information, it's a Silabs radio chipset and USB microcontroller.
miatacarpc is offline   Reply With Quote
Old 01-29-2008, 03:10 PM   #58
FLAC
 
TheLlama's Avatar
 
Join Date: Jul 2004
Location: All over the world
Vehicle: 2001 Paper Airplane Standard Edition
Posts: 984
My Photos: (0)
Quote: Originally Posted by waltersaegir View Post
Currently I'm not getting any AM station to tune. I've tried several strong local stations and get nothing but static. Rebooting the same PC hardware to Windows 2000, allows me to tune AM. FM tunes perfectly.

The PLL calculation appears quite different for AM than the PLL calculation for FM and I wonder if there might be a bug, yet I do not see a logical (or otherwise) alternative to the existing values.

Does your testing of AM result in successful tuning?

Walter, how is the AM tuning working? Any news updates? I plan on doing some testing to see if I ever truly had AM working in the first place.

-Paul
TheLlama is offline   Reply With Quote
Old 01-31-2008, 02:52 PM   #59
Newbie
 
Join Date: May 2006
Posts: 35
My Photos: (0)
AM still not working. Sorry to say that I've done little with the radio since late December. Hopefully I will see enought daylight to revisit HQCT things before the end of Feb. Keep us posted, if you see something new. - Walter
waltersaegir is offline   Reply With Quote
Old 04-17-2008, 01:13 PM   #60
Newbie
 
Join Date: Apr 2008
Posts: 2
My Photos: (0)
Hi djwlindenaar,

If you have a working driver that supports RDS and uses V4L, can you please upload the driver with the quick upload link?
cecolong is offline   Reply With Quote
Sponsored Links
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Line Driver Selection? And Audio advice Philly#1 Lex Car Audio 6 04-24-2006 11:10 AM
Line Driver Vs. Amp Sensitivity Adjustment 3onDubs Car Audio 5 11-28-2005 07:37 PM
XM Driver Install Problem MikeH MacCar 5 04-24-2005 11:22 AM
MS S&T 2005 GPS receiver driver install problem... rdc_3200 GPS 4 01-01-2005 04:19 PM
USB Sound Card with ASIO driver and volume control tbdombrosky General Hardware Discussion 0 02-03-2003 11:00 PM


All times are GMT -5. The time now is 01:14 AM.


Sponsored Links
The MP3car.com Store

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0
Copyright © 1999 - 2008 Mp3Car.com Inc.
Ad Management by RedTyger
Message Board Statistics