Support and General Use > Hardware
Modifying Rockbox to control an external digital potentiometer via iPod 5.5g
axismundi:
Hi everyone,
I recently purchased an iPod 5.5g for which I plan to build a separate headphone amp stage. I am currently testing some prototypes and I am quite happy about the improvements I can hear and measure.
Taking the input signal from line out rather than headphone out results in a better sound (no surprises here) and using Rockbox partially helps in that it allows software control over the line out volume. However, the lack of hardware control over the line out means that the lower the listening levels, the worse the signal-to-noise ratio.
The solution I am contemplating is to use a digital potentiometer controlled by the processor in iPod. This will allow an overall "hardware" adjustment of the line out volume, maintaining the signal-to-noise ratio relatively constant regardless of the volume.
There are quite many I2C controlled digital potentiometers available (such as Maxim MAX5387http://www.maxim-ic.com/datasheet/index.mvp/id/6412, Maxim DS1881 http://www.maxim-ic.com/datasheet/index.mvp/id/4661/t/al, Analog Devices AD5243 http://www.analog.com/en/digital-to-analog-converters/digital-potentiometers/ad5243/products/product.html etc.). The good part is that the Wolfson DAC in the iPod has an integrated digital potentiometer controlled via an I2C interface so in theory one should be able to use this. The bad part that I foresee is related to the fact that I do not expect the I2C instructions used to control the DAC to coincide with the ones required by the third party digital potentiometers, so this is why this post.
The limitations I am facing are that I am not that familiar with digital electronics and I2C protocol, not to mention that I have limited programming knowledge. Is there anyone fairly familiar with the subject that could let me know if my assumptions/plan are reasonable? If so, how difficult it would be to use such a potentiometer and having it controlled by Rockbox via the iPod? Any feedback, advice, help/tutorials would be greatly appreciated.
LE: There is of course the alternative of using a traditional potentiometer, but due to the project restrictions this is not a solution.
Thanks!
saratoga:
--- Quote from: axismundi on March 08, 2011, 06:28:33 PM ---Taking the input signal from line out rather than headphone out results in a better sound (no surprises here) and using Rockbox partially helps in that it allows software control over the line out volume. However, the lack of hardware control over the line out means that the lower the listening levels, the worse the signal-to-noise ratio.
--- End quote ---
The line out has hardware volume control IIRC. Have you tried just using that?
Edit: This looks like the commit you want:
http://svn.rockbox.org/viewvc.cgi?view=rev&revision=9181
The wmcodec_set_lineout_vol function should let you adjust the volume.
axismundi:
Thanks for the quick reply, saratoga!
I had the impression that only the HO out in WM8758 has hardware volume control... I will check again the datasheet and google about this. I really hope you're right, it would be the best solution.
I assume the "commit" linked is something which is not implemented in the standard build (bear with me, I am a very happy user of Rockbox but not much more), so I have to learn how to apply it. Anyway, it looks like I have some homework to do. Thanks again!
saratoga:
--- Quote from: axismundi on March 08, 2011, 07:31:37 PM ---I had the impression that only the HO out in WM8758 has hardware volume control... I will check again the datasheet and google about this. I really hope you're right, it would be the best solution.
--- End quote ---
I didn't think there was a datasheet for the WM8758.
--- Quote from: axismundi on March 08, 2011, 07:31:37 PM ---I assume the "commit" linked is something which is not implemented in the standard build (bear with me, I am a very happy user of Rockbox but not much more), so I have to learn how to apply it. Anyway, it looks like I have some homework to do. Thanks again!
--- End quote ---
Commits are changes to the rockbox source code. If you click that link, you can see that it was committed on Mar 22, 2006 as well as a description of what it does (prevents the line out volume from changing when you adjust the volume). Should be easily enough for you to change back.
saratoga:
--- Quote from: saratoga on March 08, 2011, 07:35:46 PM ---
--- Quote from: axismundi on March 08, 2011, 07:31:37 PM ---I had the impression that only the HO out in WM8758 has hardware volume control... I will check again the datasheet and google about this. I really hope you're right, it would be the best solution.
--- End quote ---
I didn't think there was a datasheet for the WM8758.
--- Quote from: axismundi on March 08, 2011, 07:31:37 PM ---I assume the "commit" linked is something which is not implemented in the standard build (bear with me, I am a very happy user of Rockbox but not much more), so I have to learn how to apply it. Anyway, it looks like I have some homework to do. Thanks again!
--- End quote ---
Commits are changes to the rockbox source code. If you click that link, you can see that it was committed on Mar 22, 2006 as well as a description of what it does (prevents the line out volume from changing when you adjust the volume). Should be easily enough for you to change back.
--- End quote ---
Just so this shows up . . .
Navigation
[0] Message Index
[#] Next page
Go to full version