Hi,
I am working a project on my internship and I am stuck! Please let me explain.
I am using a PCM1792a on my PC board and I am trying to test the DACs outputs with a sine wave on 1kHz. I mainly sending the sine wave with I2S and controlling the DAC with I2C with STM32f4 Discovery eval board.
I use 24-bit as bit rate and 90kHz as Fs. Stm32f4 is generating a master clock for i2s and its freq is 256fs as default. I did not change the DACs registers, it works as default. Actually, I don't get "playing with register" concept, unfortunately. Although, I am using a main file for generate sine wave with look-up table and importing a codec file actually written for CS43L22 DAC(is on the discovery board), PCM1792A looks like working properly( exept that triangular wave). There are some register definitions and I2C functions of stm32f4 in the codec file.I can see an output on both channels' - and + outputs but not a exact sine wave ( half - wave rectified sine). And the difference of - and + outputs looks like a triangular wave more than a sine.
Any idea why I faced this problem?
My first suspicion is that codec file. Because it is not for PCM1792a and register mapping is different. However, if the problem is that, how I can see half sine waves on the same frequency that I sending from stm32f4? May be I should create or find a codec file for pcm1792 but I am not sure wheather it is necessary. I am not an experienced engineer on field as a bechalor student and I am not good on assuming on codes. I would be appreciated any command.
Many thanks in advance!
Regards,
Burak