Firefly开源社区

打印 上一主题 下一主题

[Linux] ROC-RK3308B-CC-PLUS DTS文件配置I2S1或者I2S0 MCLK无波形输出

23

积分

0

威望

0

贡献

技术小白

积分
23

ROC-RK3308B-CC-PLUS DTS文件配置I2S1或者I2S0 MCLK无波形输出

发表于 2023-8-14 16:32:19      浏览:3299 | 回复:0        打印      只看该作者   [复制链接] 楼主
  • 固件类型: 自行编译的固件
  • SDK包名称: rk3308_linux_release_v1.5.0a_20221212
  • SDK更新到哪个COMMIT: 0000-00-00 00:00:00
  • SDK修改内容: 在sound/soc/codecs 下增加驱动文件并配置Kconfig和Makefile,在对应DTS中增加新声卡
  • Log日志: log.rar
问题描述及复现步骤:
[    1.643153] es7210_modinit enter
[    1.643488] begin->>>>>>>>>>es7210_i2c_probe!
[    1.643513] i2c info: i2c flags = 0 i2c addr=40 i2c name=MicArray_0
[    1.643523] i2c info:device id = MicArray_0
[    1.643542] es7210 3-0040: codec register 3-0040
[    1.643573] es7210 3-0040: ASoC: dai register 3-0040 #1
[    1.643588] es7210 3-0040: ASoC: Registered DAI 'ES7210 4CH ADC 0'
[    1.643604] es7210 3-0040: ASoC: Registered codec 'es7210.3-0040'
[    1.644042] asoc-simple-card es7210_sound: New simple-card: everest,es7210-codec
[    1.644081] asoc-simple-card es7210_sound: Revert to legacy daifmt parsing
[    1.644232] asoc-simple-card es7210_sound:   name : ff300000.i2s-ES7210 4CH ADC 0
[    1.644248] asoc-simple-card es7210_sound:   format : 4001
[    1.644263] asoc-simple-card es7210_sound:   cpu : ff300000.i2s / 50176000
[    1.644277] asoc-simple-card es7210_sound:   codec : ES7210 4CH ADC 0 / 50176000
[    1.644293] of_get_named_gpiod_flags: can't parse 'simple-audio-card,hp-det-gpio' property of node '/es7210_sound[0]'
[    1.644306] of_get_named_gpiod_flags: can't parse 'simple-audio-card,mic-det-gpio' property of node '/es7210_sound[0]'
[    1.644330] asoc-simple-card es7210_sound: ASoC: binding ff300000.i2s-ES7210 4CH ADC 0 at idx 0
[    1.644345] asoc-simple-card es7210_sound: platform_name: (null)
[    1.644360] asoc-simple-card es7210_sound: platform_name: (null) platform->component.name:ff310000.i2s
[    1.644375] asoc-simple-card es7210_sound: platform_name: (null) platform->component.name:ff300000.i2s
[    1.644389] asoc-simple-card es7210_sound: platform_name: (null) platform->component.name:snd-soc-dummy
[    1.644588] begin->>>>>>>>>>es7210_probe!
[    1.644733] vcc_sd: disabling
[    1.644762] vccio_sd: disabling
[    1.790982] usb 2-1: new high-speed USB device number 2 using ehci-platform
[    1.908022] hub 2-1:1.0: USB hub found
[    1.908332] hub 2-1:1.0: 4 ports detected
[    1.987219] asoc-simple-card es7210_sound: ASoC: probe everest,es7210-codec dai link 0 late -2
[    1.987266] asoc-simple-card es7210_sound: ASoC: probe everest,es7210-codec dai link 0 late -1
[    1.987297] asoc-simple-card es7210_sound: ASoC: probe everest,es7210-codec dai link 0 late 0
[    1.987330] asoc-simple-card es7210_sound: ASoC: probe everest,es7210-codec dai link 0 late 1
[    1.987359] asoc-simple-card es7210_sound: ASoC: probe everest,es7210-codec dai link 0 late 2
[    1.987395] rockchip-i2s-tdm ff300000.i2s: The target mclk_tx freq is: 50176000
[    1.988438] asoc-simple-card es7210_sound: ES7210 4CH ADC 0 <-> ff300000.i2s mapping ok
[    2.015839] dwmmc_rockchip ff490000.dwmmc: Successfully tuned phase to 25
[    2.016145] mmc0: new HS200 MMC card at address 0001
[    2.017516] mmcblk0: mmc0:0001 4FTE4R 3.64 GiB
[    2.018252] mmcblk0boot0: mmc0:0001 4FTE4R partition 1 4.00 MiB
[    2.019031] mmcblk0boot1: mmc0:0001 4FTE4R partition 2 4.00 MiB
[    2.019677] mmcblk0rpmb: mmc0:0001 4FTE4R partition 3 512 KiB
[    2.025677]  mmcblk0: p1 p2 p3 p4 p5 p6 p7 p8
[    2.146255] vendor storage:20160801 ret = 0
[    2.172983] usb 2-1.3: new high-speed USB device number 3 using ehci-platform
[    2.257372] bFWReady == _FALSE call reset 8051...
[    2.286286] [WLAN_RFKILL]: rockchip_wifi_mac_addr: enter.
[    2.286345] [WLAN_RFKILL]: get_wifi_addr_vendor: rk_vendor_read wifi mac address failed (-1)
[    2.356967] usb 2-1.4: new high-speed USB device number 4 using ehci-platform
[    2.503024] usb 2-1.4: reset high-speed USB device number 4 using ehci-platform
[    2.607649] r8152 2-1.4:1.0 (unnamed net_device) (uninitialized): Invalid ether addr 00:00:00:00:00:00
[    2.607848] r8152 2-1.4:1.0 (unnamed net_device) (uninitialized): Create an ether addr [b8:2f:3c:62:77:c] from system serial number
[    2.607917] r8152 2-1.4:1.0 (unnamed net_device) (uninitialized): Random ether addr b8:2f:3c:62:77:0c
[    2.652501] ret 1024
[    2.653652] ALSA device list:
[    2.653703]   #0: everest,es7210-codec
[    2.653723]   #7: Loopback 1
[    2.654476] Freeing unused kernel memory: 384K
[    2.663394] r8152 2-1.4:1.0 eth0: v2.16.1 (2022/04/12)
[    2.663464] r8152 2-1.4:1.0 eth0: This product is covered by one or more of the following patents:
[    2.663464]          US6,570,884, US6,115,776, and US6,327,625.
[    2.663464]
[    3.049157] r8152 2-1.4:1.0 eth1: renamed from eth0
[    5.101096] EXT4-fs (mmcblk0p6): mounted filesystem without journal. Opts: (null)
[    5.284214] EXT4-fs (mmcblk0p8): warning: mounting unchecked fs, running e2fsck is recommended
[    5.286773] EXT4-fs (mmcblk0p8): mounted filesystem without journal. Opts: (null)
[    6.591778] udevd[372]: starting version 3.2.5
[    6.637768] udevd[373]: starting eudev-3.2.5
[    7.399564] EXT4-fs (mmcblk0p7): couldn't mount as ext3 due to feature incompatibilities
[    7.401681] EXT4-fs (mmcblk0p7): mounted filesystem without journal. Opts: (null)
[    7.915220] IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
[    8.035793] rockchip-i2s-tdm ff300000.i2s: The target mclk_tx freq is: 11289600
[    8.035880] Enter into es7210_pcm_hw_params()
[    8.126856] enter into pcm_pop_work_events
[    8.126913] enter into es7210_unmute
[    8.294110] rockchip-i2s-tdm ff300000.i2s: The target mclk_tx freq is: 11289600
[    8.294151] Enter into es7210_pcm_hw_params()
[    8.520601] rockchip-i2s-tdm ff300000.i2s: The target mclk_tx freq is: 11289600


DTS配置:
                es7210_sound {
                        status = "okay";
                        compatible = "simple-audio-card";
                                simple-audio-card,format = "i2s";
                                simple-audio-card,name = "everest,es7210-codec";
                                simple-audio-card,mclk-fs = <256>;
                                simple-audio-card,cpu{
                                                sound-dai = <&i2s_8ch_1>;
                                                dai-tdm-slot-num = <4>;
                                                dai-tdm-slot-width = <16>;
                                                };
                                simple-audio-card,codec {
                                                sound-dai = <&es7210>;
                                        };
                                };


&i2s_8ch_0 {
        status = "okay";
        #sound-dai-cells = <0>;
        pinctrl-names = "default";
        rockchip,clk-trcm = <1>;
        rockchip,bclk-fs = <64>;
       
};

&i2s_8ch_1 {
        status = "okay";
        #sound-dai-cells = <0>;
        pinctrl-names = "default";
        rockchip,clk-trcm = <1>;
        rockchip,bclk-fs = <64>;
    pinctrl-0 = <&i2s_8ch_1_m0_mclk
                            &i2s_8ch_1_m0_sclktx
                            &i2s_8ch_1_m0_lrcktx
                            &i2s_8ch_1_m0_lrckrx
                            &i2s_8ch_1_m0_sdi0
                            &i2s_8ch_1_m0_sdo3_sdi1
                            &i2s_8ch_1_m0_sdo2_sdi2
                            &i2s_8ch_1_m0_sdo1_sdi3
                            &i2s_8ch_1_m0_sdo0>;
};

&i2c3 {
                clock-frequency = <100000>;
        status = "okay";

        es7210: es7210@10 {
        status = "okay";
                #sound-dai-cells = <0>;
        compatible = "MicArray_0";
        reg = <0x40>;
                clocks = <&cru SCLK_I2S1_8CH_TX_OUT>;
                clock-names = "mclk";
                pinctrl-0 = <&i2s_8ch_1_m0_mclk>;
                pdn-gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>;
                reset-gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_LOW>;

        };
};


系统启动后能正常挂载声卡,用示波器测量MCLK时钟无输出,LRCK和SCLK有时钟输出


log.rar

9.66 KB, 下载次数: 0, 下载积分: 灯泡 -1 , 经验 -1

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

友情链接 : 爱板网 电子发烧友论坛 云汉电子社区 粤ICP备14022046号-2
快速回复 返回顶部 返回列表