Tag Archives: digital

HiFiBerry Digi pre-order started

hifiberrydigiOur new digital output board for the Raspberry Pi – the HiFiBerry Digi. can be pre-ordered now for our a special introductory price. We expect to ship the first units about mid of February.

The HiFiBerry Digi adds an optical and a fully isolated electrical output to your Raspberry Pi. Samples rates up to 192kHz/24bit are supported on both outputs.

Linux driver development has been finished already, production samples were tested. Everything works very well.

Pre-order it now!

HiFiBerry DSP Light: Prototyping started

hifiberry-dsp-debuggingOur DSP project for the Raspberry Pi has reached the next milestone: hardware prototyping. The digital part of the circuits is working. There was still a minor bug (wrong pinout of a transistor) that was easy to correct by soldering the transistor on its back. The rest of the circuit worked well. As you can see on the picture, the analog part is not assembled yet. First I want to be able to upload the software to the chip.

Unfortunately, the simple approach to upload the program did not work. The chip simply did not acknowledge any I2S requests. Soldering some cables and connecting the I2S bus to the logic analyzer showed some unexpected behavior. While I2C read requests did not work, there was no problem with write requests. What happened? I had a look at the datasheet again and I think, I found the problem. Before every read request, the chip expects a write request with the address to read. However, both requests have to be in the same I2C transaction. The chip expects multiple start bits. Unfortunately, the Python I2C library that I wanted to use does not support multiple starts. It seems that I have to use the lower-level device driver of the operating system to upload the software to the chip.

HiFiBerry Mini and RaspyFi – the 192kHz/24bit FLAC solution

hifberry-mini-raspberryToday I did some tests with the HiFiBerry Mini and RaspyFi. I replaced the kernel by the HiFiBerry enabled kernel – and it worked perfectly.  The music was played from a cheap USB-Stick. But the most interesting part was the test with 192kHz/24bit FLAC files. And yes – it works! I think, this is the smallest Raspberry-based setup that is able to play 192kHz FLAC music.

It is also nice to see, that RaspyFi also plays MP3 files in 24bit resolution, which means potentially less distortions.

You can order it now on our HiFiBerry web site.

Tracking down noise sources on a Raspberry Pi

I did some measurements of the HiFiBerry DAC for the Raspberry Pi. Compared to the DAC in standalone mode, there was noticeable more noise when I connected the DAC to the Raspberry Pi. Ok, that was expected. There is a lot of digital switching on the Raspberry, this is not good for audio circuits. But then I noticed an interesting fact: Even if the Raspberry Pi was powered off, there was still some noise.

rpi-noise-with-ethernetWhere did it come from? The only cable that was still connected was the network cable. Hmm, what happens if I remove this cable?


Wow! Silence! The 750Hz peak was a problem in our measurement setup.

But where does this noise come from? When you connect the Raspberry Pi do an ethernet network, the data connection is galvanically decoupled using a transformer. However, if you use shielded Ethernet patch cables (STP), the ground of the Raspberry Pi (and your audio equipment) is connected to the Ethernet network. This is where all the noise comes from. The solution is simple: You should use unshielded twisted pair cables (UTP) to connect your Raspberry Pi to en Ethernet network or use WLAN.


Connecting a Raspberry Pi and an ADAU1701 DSP

It looks like a simple task – connect the Raspberry Pi with an external ADAU1701 DSP chip. Both features an I2S interface – just connect it. However, it is not that easy. The ADAU1701 can only work as a slave device on the I2S input. Why not just using the Raspberry Pi as the master? This also won’t work, because the Raspberry Pi can create the BCLK and LRCLK signal, but not a 256xFs master clock signal that is needed by the ADAU1701. Using a local master clock on the ADAU1701 and the I2S clock from the Raspberry Pi will also not work, because both clocks have to be synchronous. Looks like a bit more complexity is needed.

We use the following setup: An external frequency generator creates the 12.288 MHz master clock and a synchronous 3.072 MHz BCLK signal. This BCLK signal will be the master clock for the I2S output of the Raspberry Pi. From this clock signal, the Raspberry Pi creates the 48 kHz LRCLK signal. Why are we not creating this clock externally? Because we have only a 2 channel signal generator available in the lab. This needs some tweaking in the sound card driver.

The ingredients of this test setup are

  • Rigol DG4062 signal generator
  • Raspberry Pi
  • MiniDSP (our own DSP board is not ready yet)
  • Lab power supply

For measurements I use a Rigol DS2072 DSO and a Intronix Logicport Logic analyzer. That’s a lot of equipment to connect two simple devices:


I had serious trouble to get this setup running. The reason for this was a simple mistake: I switched BCLK and LRCLK. But during debugging I had another idea. The output of the ADAU1701 is an I2S master. That means it can be used also as the master clock for the input. With this setup – output BCLK and LRCLK connected to input BCLK and LRCLK, there is no need for an external clock source. The ADAU1701 can create all the necessary clocks with the onboard resonator. This will simplify our DSP project a lot.

Finally when everything worked, it looked like this on the oscilloscope: a nice analog output from the ADAU1701.

Quad Volume Control PCB now available in our shop

QuadVol 1.1Finally, the Quad volume control has passed the final tests. It is now available in our shop. The documentation will be updated in the next days. There are some minor differences from our prototype:

  • Control connection can be a 4- or 5- pin molex connector or a 2×3 or 2×5 pin connector.
  • The control connection now has a common anode connection. With this connection you need only 4 cables for the connection of a microcontroller board and this circuit. The common anode will be connected to +5V/+3.3V (depending on the voltage of your microcontroller board).
  • With the new common anode, the signals will not be inverted anymore.
  • The audio connectors were moved a bit.

Note that most documentation on our site still show the old version. This will be corrected in the next days. Also expect more pictures of the finished circuit in a nice acrylic case!

A digital controllable phono input stage

When connecting a MC or MM system with a phono stage, the most important things to consider are input capacitance (for MM systems) and input resistance (for MC systems). Usually this is done be DIP switches or external connected capacitors. That means you cannot do this from your listing position and it is not easy to hear the differences between different settings. This the following input stage, all switching is done by low-resistance analog switches. These switches can be controlled by a digital circuit (e.g. a microcontroller). That makes it easy to implement a switching of capacitance and resistance using a remote control.

The selected analog switch is the ADG1411 from ADI. It features 4 independent switches, can run at +/-15V 8 and has an Ron of only 1.5Ω.