导航

    全志在线开发者论坛

    • 注册
    • 登录
    • 搜索
    • 版块
    • 话题
    • 在线文档
    • 社区主页

    Tina Linux UART flow control

    MR Series
    2
    5
    2157
    正在加载更多帖子
    • 从旧到新
    • 从新到旧
    • 最多赞同
    回复
    • 在新帖中回复
    登录后回复
    此主题已被删除。只有拥有主题管理权限的用户可以查看。
    • L
      lecndav LV 5 最后由 lecndav 编辑

      Hi, I suspect that UART flow control (RTS, CTS) does not work on the sipeed lichee rv dock (D1 chip) board with Tina linux. I came to the assumption after testing bluetooth (RTL8723DS). In general BT works, but if the CPU is very busy, I get "Bluetooth: Out-of-order packet arrived (6 != 7)" from the kernel. The device tree is configured as followed:

      uart1_pins_a: uart1_pins@0 {
      		pins = "PG6", "PG7", "PG8", "PG9";
      		function = "uart1";
      		drive-strength = <10>;
      		bias-pull-up;
      };
      
      uart1_pins_b: uart1_pins {
      		pins = "PG6", "PG7", "PG8", "PG9";
      		function = "gpio_in";
      };
      
      &uart1 {
      	uart-has-rtscts;
      	pinctrl-names = "default";
      	pinctrl-0 = <&uart1_pins_a>;
      	pinctrl-1 = <&uart1_pins_b>;
      	status = "okay";
      };
      

      I assume something is wrong in the device tree and CTS RTS is not activated. Is there something else to activate flow controls?

      whycan 1 条回复 最后回复 回复 引用 分享 0
      • whycan
        whycan晕哥 LV 9 @lecndav 最后由 编辑

        @lecndav

        用逻辑分析仪或者示波器接上 PG6 ~ PG9

        Connect PG6 ~ PG9 with logic analyzer or oscilloscope

        L 1 条回复 最后回复 回复 引用 分享 0
        • L
          lecndav LV 5 @whycan 最后由 编辑

          @whycan Yes, I connected RX TX RTS CTS to an oscilloscope yesterday. I observed that the Realtek chip is using his RTS line, but I saw nothing on the other line.

          whycan 1 条回复 最后回复 回复 引用 分享 0
          • whycan
            whycan晕哥 LV 9 @lecndav 最后由 whycan 编辑

            @lecndav 在 Tina Linux UART flow control 中说:

            Yes, I connected RX TX RTS CTS to an oscilloscope yesterday. I observed that the Realtek chip is using his RTS line, but I saw nothing on the other line

            1e5e8214-3b08-40b4-ac93-570dba4cd3ba-image.png

            yes, only 3-wire for rtl8723ds

            L 1 条回复 最后回复 回复 引用 分享 0
            • L
              lecndav LV 5 @whycan 最后由 编辑

              @whycan Ah I see. The problem only occurs on many I/O interrupts. So for example when executing "find /" on the console or via SSH. I could maybe workaround this problem on software side. Do you recommend another WIFI + BT chip which has 4 wire UART and is compatible with D1 without a lot of driver adaptions?

              1 条回复 最后回复 回复 引用 分享 0
              • 1 / 1
              • First post
                Last post

              Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号

              行为准则 | 用户协议 | 隐私权政策