PATCH - ESI Juli driver
Hi Takashi,
Juli support required some changes to ice1724.c/ice1712.h. Since Juli uses different clock scheme than most other ice1712/24 cards, I had to move all clock-specific code to card-specific routines. Most of them are redefined in juli.c.
The driver is tested, only analog-in and digital-in monitors are not working. I have coded according to manufacturer's documentation, the same procedure is in OSS Juli driver. I described the issue in detail in the code, perhaps someone will do more research.
The card itself has no HW master volume control. It would have to be implemented as a virtual control manipulating internal values of PCM and monitor volume controls. I will take a look at it later. For now, perhaps we could rename the PCM Volume to Master Volume, as most people will not need the monitoring anyway. I will leave it to your decision.
* moving all clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
* missing - master volume control, will have to be implemented as virtual, no HW support.
Thanks,
Pavel.
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
At Sun, 16 Mar 2008 13:57:24 +0100,
Quoted 7 lines · Pavel Hofman
Hi Takashi,
Juli support required some changes to
ice1724.c/ice1712.h. Since Juli uses different clock scheme than most other ice1712/24 cards, I had to move all clock-specific code to card-specific routines. Most of them are redefined injuli.c.
I feel there are too many additional callbacks in your patch. Since we don't need too subtle tuning, can we simplify this?
Regarding the separate rate setting for each stream, we should consider about Maya44 support, too.
Quoted 11 lines
The driver is tested, only analog-in and digital-in monitors are not working. I have coded according to manufacturer's documentation, the same procedure is in OSS Juli driver. I described the issue in detail in the code, perhaps someone will do more research.
The card itself has no HW master volume control. It would have to be implemented as a virtual control manipulating internal values of PCM and monitor volume controls. I will take a look at it later. For now, perhaps we could rename the PCM Volume to Master Volume, as most people will not need the monitoring anyway. I will leave it to your decision.
Quoted 7 lines
Signed-off-by Pavel Hofman <[email protected]>* moving all clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
* missing - master volume control, will have to be implemented as virtual, no HW support.
vmaster can be used for this now. It was moved to core directory after 1.0.16 release.
thanks,
Takashi
Quoted 6 lines · Takashi Iwai
At Sun, 16 Mar 2008 13:57:24 +0100,
Quoted 1 line · Pavel Hofman
Hi Takashi,
I feel there are too many additional callbacks in your patch. Since we don't need too subtle tuning, can we simplify this?
There are only two callbacks which Juli does not redefine. These could be removed. Though I felt it was cleaner to have all the clock-specific stuff potentially redefinable for other cards.
I did not want to copy/paste any algorithmical code from ice1724.c to juli.c as it complicates future maintenance. Now, the vt1724 code in ice1724.c is pretty much about general algorhitms, specific routines are in stdclock_... I tested the original clock with Prodigy192 which provided testing analog/SPDIF signals. There are no functional changes.
Quoted 3 lines
Regarding the separate rate setting for each stream, we should consider about Maya44 support, too.
I have been following the discussion. Unfortunately, I did not get to see any patch of ice1724.c, iirc the last patch included the whole modified ice1724.c copied to alsa-driver.
Rainer, what are the changes?
Now each card can specify its own stream parameters. E.g. Juli has a modified list of available frequencies for analog streams.
Quoted 14 lines
Quoted 14 lines
The driver is tested, only analog-in and digital-in monitors are not working. I have coded according to manufacturer's documentation, the same procedure is in OSS Juli driver. I described the issue in detail in the code, perhaps someone will do more research.
The card itself has no HW master volume control. It would have to be implemented as a virtual control manipulating internal values of PCM and monitor volume controls. I will take a look at it later. For now, perhaps we could rename the PCM Volume to Master Volume, as most people will not need the monitoring anyway. I will leave it to your decision.
Signed-off-by Pavel Hofman <[email protected]>
Quoted 8 lines
Quoted 5 lines
* moving all clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
* missing - master volume control, will have to be implemented as virtual, no HW support.vmaster can be used for this now. It was moved to core directory after 1.0.16 release.
Thanks, I did not know about vmaster. I will try to implement it tonight.
The Juli support is one of the very called-for features, I guess it would be a pitty to keep a functional patch out of repository.
Thanks,
Pavel.
At Mon, 17 Mar 2008 09:57:49 +0100,
Quoted 13 lines · Pavel Hofman
Quoted 6 lines · Takashi Iwai
At Sun, 16 Mar 2008 13:57:24 +0100,
Quoted 1 line · Pavel Hofman
Hi Takashi,
I feel there are too many additional callbacks in your patch. Since we don't need too subtle tuning, can we simplify this?
There are only two callbacks which Juli does not redefine. These could be removed. Though I felt it was cleaner to have all the clock-specific stuff potentially redefinable for other cards.
Quoted 5 lines
I did not want to copy/paste any algorithmical code from
ice1724.ctojuli.cas it complicates future maintenance. Now, the vt1724 code inice1724.cis pretty much about general algorhitms, specific routines are instdclock_... I tested the original clock with Prodigy192 which provided testing analog/SPDIF signals. There are no functional changes.
I see the point that you want to make it generic. But, too many callbacks, in other words, too many tuning parameters make the code difficult to follow. It's a question of balance.
Takashi
Quoted 10 lines
Quoted 6 lines
I did not want to copy/paste any algorithmical code from
ice1724.ctojuli.cas it complicates future maintenance. Now, the vt1724 code inice1724.cis pretty much about general algorhitms, specific routines are instdclock_... I tested the original clock with Prodigy192 which provided testing analog/SPDIF signals. There are no functional changes.I see the point that you want to make it generic. But, too many callbacks, in other words, too many tuning parameters make the code difficult to follow. It's a question of balance.
Takashi, I understand your concern. On the other hand, if the callbacks are well documented, it actually makes the code easier to follow, as it separates general algorithms from detailed HW implementation. I can certainly add more comments to the callback functions.
Honestly, I do not know which callbacks to remove (apart of those two not redefined in Juli). Otherwise I will have to copy/paste serious portions of code to juli.c which I would really want to avoid.
As I see it, the clocking code in ice1724 was written for one specific implementation. There was no need to do so in a general way and I completely understand that. Nevertheless, juli uses a different clock implementation and I believe the time has come to make the code in ice1724 more general. Unfortunately, I do not know of any other technology but callbacks.
What would you recommend?
Thanks,
Pavel.
Quoted 7 lines
Takashi
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Signature · 16 lines
----------------- inSITE, s.r.o. Rubesova 29, 326 00 Plzen Tel., fax: +420 - 37 - 74 493 58 GSM: +420 - 603 - 163 973 Email: [email protected] www.educity.cz, www.insite.cz www.meetings.cz, www.hrzive.cz www.comben.cz, www.hr-online.cz ------------------------------- Navstivte www.educity.cz, server s nejvetsi nabidkou profesniho vzdelavani na ceskem internetu.
At Mon, 17 Mar 2008 10:37:22 +0100,
Quoted 21 lines · Pavel Hofman
Quoted 11 lines
Quoted 7 lines
I did not want to copy/paste any algorithmical code from
ice1724.ctojuli.cas it complicates future maintenance. Now, the vt1724 code inice1724.cis pretty much about general algorhitms, specific routines are instdclock_... I tested the original clock with Prodigy192 which provided testing analog/SPDIF signals. There are no functional changes.I see the point that you want to make it generic. But, too many callbacks, in other words, too many tuning parameters make the code difficult to follow. It's a question of balance.
Takashi, I understand your concern. On the other hand, if the callbacks are well documented, it actually makes the code easier to follow, as it separates general algorithms from detailed HW implementation. I can certainly add more comments to the callback functions.
Honestly, I do not know which callbacks to remove (apart of those two not redefined in Juli). Otherwise I will have to copy/paste serious portions of code to
juli.cwhich I would really want to avoid.
Quoted 8 lines
As I see it, the clocking code in ice1724 was written for one specific implementation. There was no need to do so in a general way and I completely understand that. Nevertheless, juli uses a different clock implementation and I believe the time has come to make the code in ice1724 more general. Unfortunately, I do not know of any other technology but callbacks.
What would you recommend?
IMO, rate_code can be avoided. Instead of exposing the encoded value, better to use the raw rate value as parameters.
And, the texts inf rates_info can be generated dynamically.
So, what we need primarily are callbacks to get and set the current rate setting. Suppose rate=0 as SPDIF-in, we can pass the raw rate value. Then snd_vt1724_pro_internal_clock_get() would just a function to get the current rate and compares it with the given rate_info[] value, returns the index.
How to set stream-specific hw_params is another question. But surely we can cut off a bit more.
thanks,
Takashi
Quoted 8 lines · Takashi Iwai
At Mon, 17 Mar 2008 10:37:22 +0100,
Quoted 2 lines · Pavel Hofman
What would you recommend?
IMO,
rate_codecan be avoided. Instead of exposing the encoded value, better to use the raw rate value as parameters.
No problem. I just wanted to avoid the repeated conversion from the numerical rate to the card specific representation which is input information for all the rate-related code. ice1724 cards utilize MT_RATE, juli makes use of GPIO.
If you are OK with the repeated conversion, I will remove this. I tried to keep the methods inline if possible.
Quoted 1 line
And, the texts inf
rates_infocan be generated dynamically.
For obvious reasons I tried changing ice1724 as little as possible. That is why I kept the original code, only rearranged it.
I can change the way texts in rates_info are generated. Still there will have to be some callback as juli has a different list of rates.
Quoted 6 lines
So, what we need primarily are callbacks to get and set the current rate setting. Suppose rate=0 as SPDIF-in, we can pass the raw rate value. Then
snd_vt1724_pro_internal_clock_get()would just a function to get the current rate and compares it with the given rate_info[] value, returns the index.
I am afraid I do not understand what to change in snd_vt1724_pro_internal_clock_get(). It seems fairly logical, I made only minor changes - is_spdif_master used in other parts of the code, get_rate_index with a simple meaning.
Quoted 3 lines
How to set stream-specific
hw_paramsis another question. But surely we can cut off a bit more.
We probably can, by rewriting portions of the original well-tested ice1724 code. I really wanted to avoid that and changed by callbacks only the card-specific portions.
OK, I will remove the rate_code conversions, the new overhead will be low and one abstraction will be removed.
For the rest, please state you objectives. Either cutting a few of the callbacks by non-trivial rewrite of the original ice1724 code, or keeping the remaining callbacks and the well-tested code.
Thanks a lot,
Pavel.
Quoted 5 lines
thanks,
Takashi
Signature · 16 lines
----------------- inSITE, s.r.o. Rubesova 29, 326 00 Plzen Tel., fax: +420 - 37 - 74 493 58 GSM: +420 - 603 - 163 973 Email: [email protected] www.educity.cz, www.insite.cz www.meetings.cz, www.hrzive.cz www.comben.cz, www.hr-online.cz ------------------------------- Navstivte www.educity.cz, server s nejvetsi nabidkou profesniho vzdelavani na ceskem internetu.
At Mon, 17 Mar 2008 15:08:48 +0100,
Quoted 11 lines · Pavel Hofman
Quoted 8 lines · Takashi Iwai
At Mon, 17 Mar 2008 10:37:22 +0100,
Quoted 2 lines · Pavel Hofman
What would you recommend?
IMO,
rate_codecan be avoided. Instead of exposing the encoded value, better to use the raw rate value as parameters.
Quoted 7 lines
No problem. I just wanted to avoid the repeated conversion from the numerical rate to the card specific representation which is input information for all the rate-related code. ice1724 cards utilize
MT_RATE, juli makes use of GPIO.If you are OK with the repeated conversion, I will remove this. I tried to keep the methods inline if possible.
Usually you don't have to specify inline expclitily unless it's really the time-critical code path. And the code path of the rate setting is certainly no such a thing.
Quoted 14 lines
Quoted 1 line
And, the texts inf
rates_infocan be generated dynamically.For obvious reasons I tried changing ice1724 as little as possible. That is why I kept the original code, only rearranged it.
I can change the way texts in
rates_infoare generated. Still there will have to be some callback as juli has a different list of rates.Quoted 5 lines
So, what we need primarily are callbacks to get and set the current rate setting. Suppose rate=0 as SPDIF-in, we can pass the raw rate value. Then
snd_vt1724_pro_internal_clock_get()would just a function to get the current rate and compares it with the given rate_info[] value, returns the index.
Quoted 4 lines
I am afraid I do not understand what to change in
snd_vt1724_pro_internal_clock_get(). It seems fairly logical, I made only minor changes -is_spdif_masterused in other parts of the code,get_rate_indexwith a simple meaning.
Yeah, your change is logical -- simply convert some code snippets to callbacks. But, this isn't really good for maintenance for a long term. I prefer a bit more straight way if we really change something. And, indeed we do need to change the stuff for rate settings.
Quoted 7 lines
Quoted 2 lines
How to set stream-specific
hw_paramsis another question. But surely we can cut off a bit more.We probably can, by rewriting portions of the original well-tested ice1724 code. I really wanted to avoid that and changed by callbacks only the card-specific portions.
Quoted 6 lines
OK, I will remove the
rate_codeconversions, the new overhead will be low and one abstraction will be removed.For the rest, please state you objectives. Either cutting a few of the callbacks by non-trivial rewrite of the original ice1724 code, or keeping the remaining callbacks and the well-tested code.
Don't be too nervous about changing the ice1724 code right now :) We would need the rewrite of core codes anyway because of other problems in Maya44. And, I believe we can fix more than we might break by such a restructuring in the end. The current ice1724.c is way too complex due to its history, derived from ice1712.c.
Thanks,
Takashi
Quoted 10 lines · Takashi Iwai
Quoted 4 lines
I am afraid I do not understand what to change in
snd_vt1724_pro_internal_clock_get(). It seems fairly logical, I made only minor changes -is_spdif_masterused in other parts of the code,get_rate_indexwith a simple meaning.Yeah, your change is logical -- simply convert some code snippets to callbacks. But, this isn't really good for maintenance for a long term. I prefer a bit more straight way if we really change something. And, indeed we do need to change the stuff for rate settings.
I am afraid I do not have the insight of what needs to be changed. The code as is seems fairly OK to me, just a bit underdocumented.
Quoted 9 lines
Quoted 8 lines
OK, I will remove the
rate_codeconversions, the new overhead will be low and one abstraction will be removed.For the rest, please state you objectives. Either cutting a few of the callbacks by non-trivial rewrite of the original ice1724 code, or keeping the remaining callbacks and the well-tested code.
Quoted 5 lines
Don't be too nervous about changing the ice1724 code right now :) We would need the rewrite of core codes anyway because of other problems in Maya44. And, I believe we can fix more than we might break by such a restructuring in the end. The current
ice1724.cis way too complex due to its history, derived fromice1712.c.
Well, to tell the truth, I do not feel knowledgeable enough of the alsa infrastructure to implement major changes in ice1724 code.
Actually, what is the deal with maya44? Its detailed image shows it has standard clocking scheme (no FPGA, PLL etc.), just a couple of Wolfson codecs, connection to MI/ODI/O card (fully supported e.g. by Prodigy192), switched I2S input between SPDIF-IN/Analog-IN. I just do not see a reason to rewrite ice1724 because of maya44 support.
The limitation of capture rate to 96kHz is present in most other ice1724 cards (including Juli) and nobody has made a big deal of it. It could be perhaps tackled in a similar manner we solved the single SPDIF-input rate.
Plus I will have to return the borrowed Juli soon, and will not be able to do some qualified testing.
I have another ice1724 card on the way (SndScape Odeum SPDIF interface) and really would love to finish Juli soon.
Thanks a lot,
Pavel.
At Mon, 17 Mar 2008 16:50:39 +0100,
Quoted 40 lines · Pavel Hofman
Quoted 10 lines · Takashi Iwai
Quoted 4 lines
I am afraid I do not understand what to change in
snd_vt1724_pro_internal_clock_get(). It seems fairly logical, I made only minor changes -is_spdif_masterused in other parts of the code,get_rate_indexwith a simple meaning.Yeah, your change is logical -- simply convert some code snippets to callbacks. But, this isn't really good for maintenance for a long term. I prefer a bit more straight way if we really change something. And, indeed we do need to change the stuff for rate settings.
I am afraid I do not have the insight of what needs to be changed. The code as is seems fairly OK to me, just a bit underdocumented.
Quoted 9 lines
Quoted 8 lines
OK, I will remove the
rate_codeconversions, the new overhead will be low and one abstraction will be removed.For the rest, please state you objectives. Either cutting a few of the callbacks by non-trivial rewrite of the original ice1724 code, or keeping the remaining callbacks and the well-tested code.
Quoted 5 lines
Don't be too nervous about changing the ice1724 code right now :) We would need the rewrite of core codes anyway because of other problems in Maya44. And, I believe we can fix more than we might break by such a restructuring in the end. The current
ice1724.cis way too complex due to its history, derived fromice1712.c.Well, to tell the truth, I do not feel knowledgeable enough of the alsa infrastructure to implement major changes in ice1724 code.
Actually, what is the deal with maya44? Its detailed image shows it has standard clocking scheme (no FPGA, PLL etc.), just a couple of Wolfson codecs, connection to MI/ODI/O card (fully supported e.g. by Prodigy192), switched I2S input between SPDIF-IN/Analog-IN. I just do not see a reason to rewrite ice1724 because of maya44 support.
Quoted 3 lines
The limitation of capture rate to 96kHz is present in most other ice1724 cards (including Juli) and nobody has made a big deal of it. It could be perhaps tackled in a similar manner we solved the single SPDIF-input rate.
Exactly. That's why I suggested here.
Quoted 5 lines
Plus I will have to return the borrowed Juli soon, and will not be able to do some qualified testing.
I have another ice1724 card on the way (SndScape Odeum SPDIF interface) and really would love to finish Juli soon.
Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
thanks,
Takashi
Quoted 11 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Quoted 1 line · Pavel Hofman
Takashi Iwai wrote:
Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Thanks, I will send the patch tonight.
Pavel.
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
Here is the patch. I removed several callbacks and changed _rate_code callbacks to _rate ones. You were right, the change did clean the code a little bit. The vmaster surprisingly works too :)
The compilation writes
In file included from /home/pavel/projects/alsa/alsa-driver/pci/ice1712/juli.c:3:/home/pavel/projects/alsa/alsa-driver/pci/ice1712/../../alsa-kernel/pci/ice1712/juli.c:139: warning: function declaration isn’t a prototype
Routine juli_init_gpio_rates() without any parameter starts on that line. I do not know how to fix the warning, could you do so, please?
Thanks a lot.
Pavel.
* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Re: PATCH - ESI Juli driver - removed debugs
In reply to Takashi IwaiQuoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Pavel.
* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Re: PATCH - ESI Juli driver - removed debugs
At Tue, 18 Mar 2008 07:56:11 +0100,
Quoted 18 lines · Pavel Hofman
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Quoted 8 lines
Pavel.
Signed-off-by Pavel Hofman <dustin at seznam.cz>* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputs
Thanks. Now I checked the patch and found it much better now. However, I still think the get_rate_index can be omitted by checking the index from the rate list dynamically. This looks inefficent but improves the readability and reduces the code size better. Moreover, the snd_pcm_hw's aren't needed to be prepared for each type.
Below is my revised patch. With this patch, ice->hw_rates must be non-NULL and this is referred in many places. It cleans up *_internal_clock*() nicely.
Takashi
---
pci/ice1712/ice1712.h +9 -0
@@ -367,6 +367,15 @@ struct snd_ice1712 {/* other board-specific data */ void *spec; + +/* VT172x specific */ +int pro_rate_default; +int (*is_spdif_master)(struct snd_ice1712 *ice); +unsigned int (*get_rate)(struct snd_ice1712 *ice); +void (*set_rate)(struct snd_ice1712 *ice,unsigned int rate); +unsigned char (*set_mclk)(struct snd_ice1712 *ice,unsigned int rate); +void (*set_spdif_clock)(struct snd_ice1712 *ice); + };
pci/ice1712/ice1724.c +156 -171
452 lines not on this page · raw message
pci/ice1712/juli.c +440 -31
585 lines not on this page · raw message
Re: PATCH - ESI Juli driver - removed debugs
Takashi Iwai napsal(a):
Quoted 34 lines
At Tue, 18 Mar 2008 07:56:11 +0100,
Quoted 17 lines · Pavel Hofman
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Quoted 8 lines
Pavel.
Signed-off-by Pavel Hofman <dustin at seznam.cz>* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputsThanks. Now I checked the patch and found it much better now. However, I still think the
get_rate_indexcan be omitted by checking the index from the rate list dynamically. This looks inefficent but improves the readability and reduces the code size better. Moreover, the snd_pcm_hw's aren't needed to be prepared for each type.
Quoted 4 lines
Below is my revised patch. With this patch,
ice->hw_ratesmust be non-NULL and this is referred in many places. It cleans up *_internal_clock*() nicely.
Takashi, thanks a lot. I will test the patch tonight and let you know.
Pavel.
Re: PATCH - ESI Juli driver - works OK
In reply to Takashi IwaiQuoted 34 lines · Takashi Iwai
At Tue, 18 Mar 2008 07:56:11 +0100,
Quoted 17 lines · Pavel Hofman
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Quoted 8 lines
Pavel.
Signed-off-by Pavel Hofman <dustin at seznam.cz>* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputsThanks. Now I checked the patch and found it much better now. However, I still think the
get_rate_indexcan be omitted by checking the index from the rate list dynamically. This looks inefficent but improves the readability and reduces the code size better. Moreover, the snd_pcm_hw's aren't needed to be prepared for each type.
Quoted 4 lines
Below is my revised patch. With this patch,
ice->hw_ratesmust be non-NULL and this is referred in many places. It cleans up *_internal_clock*() nicely.
Well Takashi, you are the real master here, your patch tells. I especially like the smart way you replaced the ugly switch/case structures in juli.c
The patch works fine, both standard clock as well as Juli.
Thanks a lot for your major help. Now time to move on to another audiobeast.
Pavel.
Re: PATCH - ESI Juli driver - works OK
At Tue, 18 Mar 2008 20:24:40 +0100,
Quoted 41 lines · Pavel Hofman
Quoted 34 lines · Takashi Iwai
At Tue, 18 Mar 2008 07:56:11 +0100,
Quoted 17 lines · Pavel Hofman
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Quoted 8 lines
Pavel.
Signed-off-by Pavel Hofman <dustin at seznam.cz>* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputsThanks. Now I checked the patch and found it much better now. However, I still think the
get_rate_indexcan be omitted by checking the index from the rate list dynamically. This looks inefficent but improves the readability and reduces the code size better. Moreover, the snd_pcm_hw's aren't needed to be prepared for each type.Quoted 4 lines
Below is my revised patch. With this patch,
ice->hw_ratesmust be non-NULL and this is referred in many places. It cleans up *_internal_clock*() nicely.
Quoted 5 lines
Well Takashi, you are the real master here, your patch tells. I especially like the smart way you replaced the ugly switch/case structures in
juli.cThe patch works fine, both standard clock as well as Juli.
Thanks for confirming. I applied the patch to HG tree now.
Takashi
Re: PATCH - ESI Juli driver - removed debugs
In reply to Pavel HofmanQuoted 40 lines
Takashi Iwai napsal(a):
Quoted 37 lines
At Tue, 18 Mar 2008 07:56:11 +0100,
Quoted 17 lines · Pavel Hofman
Quoted 9 lines · Takashi Iwai
At Mon, 17 Mar 2008 16:50:39 +0100,
Pavel Hofman wrote:Well, then we'll need to find some point to compromise. Could you repost the patch after reducing the callbacks again?
I'll have also no time from the next week at all -- will be on vacation for three weeks. So, let's kick it out soonish :)
Hi,
I am sorry, the previous patch had some debugs enabled. Here is a fixed patch.
Thanks a lot.
Quoted 8 lines
Pavel.
Signed-off-by Pavel Hofman <dustin at seznam.cz>* moving most of clock-specific code to card-specific routines
* support for ESI Juli
* to-be-researched - monitoring of analog/digital inputsThanks. Now I checked the patch and found it much better now. However, I still think the
get_rate_indexcan be omitted by checking the index from the rate list dynamically. This looks inefficent but improves the readability and reduces the code size better. Moreover, the snd_pcm_hw's aren't needed to be prepared for each type.Below is my revised patch. With this patch,
ice->hw_ratesmust be non-NULL and this is referred in many places. It cleans up *_internal_clock*() nicely.
Takashi, thanks for commiting the patch. I just noticed the final patch does not change the native rates flags in snd_vt1724_playback_pro for juli, keeping the unsupported values 8000 - 12000 in the flags. I guess if 8kHz rate is played via plughw, plughw will not resample and juli will switch to gpios = 0, corresponding to 32kHz.
I can test in the evening, but this is very likely.
Pavel.
Re: PATCH - ESI Juli driver - OK
Quoted 9 lines · Pavel Hofman
Takashi, thanks for commiting the patch. I just noticed the final patch does not change the native rates flags in
snd_vt1724_playback_profor juli, keeping the unsupported values 8000 - 12000 in the flags. I guess if 8kHz rate is played via plughw, plughw will not resample and juli will switch to gpios = 0, corresponding to 32kHz.I can test in the evening, but this is very likely.
The test proved the current version of the driver works correctly. plughw correctly oversampled input 8kHz signal to 16kHz on Juli, and played 8kHz directly on Prodigy192.
Thanks for the clean work :)
Pavel.