Firefly Open Source Community

   Login   |   Register   |
New_Topic

I2S MCLK on Core-3399-JD4

7

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
7
Posted at 9/5/2019 17:38:15     
Last edited by alex.mamonov In 9/5/2019 18:13 Editor

Hi!

I'm trying to use I2S1 on Firefly Core-3399-JD4 with TLV320AIC3100 codec. This is how I describe it in the dts:
  1. / {
  2.   tlv320aic31xx-sound {
  3.     compatible = "simple-audio-card";
  4.     status = "okay";
  5.     simple-audio-card,format = "i2s";
  6.     simple-audio-card,name = "rockchip,tlv320aic31xx-codec";
  7.     simple-audio-card,widgets =
  8.                             "Microphone", "Mic Jack",
  9.     "Headphone", "Headphone Jack";
  10.     simple-audio-card,routing =
  11.     "Mic Jack", "MICBIAS1",
  12.     "IN1P", "Mic Jack",
  13.     "Headphone Jack", "HPOL",
  14.     "Headphone Jack", "HPOR";
  15.   
  16.     simple-audio-card,cpu {
  17.       sound-dai = <&i2s1>;
  18.       format = "i2s";
  19.     };
  20.     simple-audio-card,codec {
  21.       sound-dai = <&tlv320aic3100>;
  22.       format = "i2s";
  23.     };
  24.   };
  25. };
  26. &i2c1 {
  27.   tlv320aic3100: tlv320aic3100@18 {
  28.     #sound-dai-cells = <0>;
  29.     compatible = "ti,tlv320aic3100";
  30.     reg = <0x18>;
  31.     status = "okay";

  32.     HPVDD-supply = <&vcc3v3_sys>;
  33.     SPRVDD-supply = <&vcc5v0_host>;
  34.     SPLVDD-supply = <&vcc5v0_host>;
  35.     AVDD-supply = <&vcc3v3_sys>;
  36.     IOVDD-supply = <&vcca1v8_codec>;
  37.     DVDD-supply = <&vcca1v8_codec>;
  38.   };
  39. };
Copy the code
The drivers starts without errors and I can see audio device in aplay -l output, but there is no sound and I can't see the clocks on MCLK pin. How can I get MCLK on?


Reply

Use props Report

1201

Credits

0

Prestige

0

Contribution

vip

Rank: 6Rank: 6

Credits
1201
Posted at 9/18/2019 10:56:36     
You need to specify `clock`, take rt5640 as an example:

  1. &i2c1 {
  2.         status = "okay";
  3.         i2c-scl-rising-time-ns = <300>;
  4.         i2c-scl-falling-time-ns = <15>;

  5.         rt5640: rt5640@1c {
  6.                 #sound-dai-cells = <0>;
  7.                 compatible = "realtek,rt5640";
  8.                 reg = <0x1c>;
  9.                 clocks = <&cru SCLK_I2S_8CH_OUT>;
  10.                 clock-names = "mclk";
  11.                 realtek,in1-differential;
  12.                 pinctrl-names = "default";
  13.                 pinctrl-0 = <&rt5640_hpcon &i2s_8ch_mclk>;
  14.                 hp-con-gpio = <&gpio4 21 GPIO_ACTIVE_HIGH>;
  15.                 //hp-det-gpio = <&gpio4 28 GPIO_ACTIVE_LOW>;
  16.                 io-channels = <&saradc 4>;
  17.                 hp-det-adc-value = <500>;
  18.         };
  19. }
Copy the code
Reply

Use props Report

You need to log in before you can reply Login | Register

This forum Credits Rules

Quick Reply Back to top Back to list