Navigation

    全志在线开发者论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • 在线文档
    • 社区主页

    全志引脚计算器 AllwinnerPin 小工具发布

    其它全志芯片讨论区
    6
    7
    2873
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • YuzukiTsuru
      柚木 鉉 LV 9 last edited by YuzukiTsuru

      是不是厌倦了翻数据手册?是不是厌烦了cat pinmux?

      AllwinnerPin来帮你。

      67bc5b3e-6f8f-48e1-ad34-24c6df706588-image.png

      下载:AllwinnerPin.zip
      开源地址:https://github.com/YuzukiHD/AllwinnerPin

      支持操作系统:

      • Windows 10 x64, x86, ARM64
      • Windows 11 x64, x86, ARM64

      依赖 .Net Desktop Runtime 6.0,如果出现启动错误请安装 .Net Desktop Runtime 6.0的运行环境

      https://dotnet.microsoft.com/en-us/download/dotnet/6.0

      在这里选一个你的系统安装。

      5b6fde25-c36b-417c-a155-7ea3d47a4cf7-image.png

      79c691d1-ef96-475e-9d32-fd5b16032752-image.png

      可以转过去

      6d8a6c0d-7b17-408a-af4c-8eb7b082e1de-image.png

      还能转回来

      410fb2af-4885-4362-9aee-fc27530b822d-image.png

      别想搞事情

      b4a2eeaa-e571-4abc-ac83-c1fa45958631-image.png

      1 Reply Last reply Reply Quote Share 0
      • tigger
        tigger LV 7 last edited by

        有趣,再来个shell版本。

        1 Reply Last reply Reply Quote Share 0
        • mangogeek
          mangogeek LV 8 last edited by

          期待shell版本

          1 Reply Last reply Reply Quote Share 0
          • M
            mstempin LV 4 last edited by

            Here is a Shell version, no dependency:
            这是一个 Shell 版本,没有依赖关系:

            #!/bin/bash
            
            # Convert argument to uppercase
            arg=${1^^}
            
            if [[ "$arg" =~ ^[0-9]+$ ]]; then
            
                # Argument is numeric, each port is 32-bit wide
                let port_base=$arg/32
            
                # Convert port number to ASCII code ('A' is 65)
                let port=$port_base+65
                let bit=$arg%32
                printf "P%b%d\n" $(printf '\x%x\n' $port 2>/dev/null) $bit
            elif [[ "$arg" =~ ^P[A-Z][0-9]+$ ]]; then
            
                # Argument is a pin name, convert port name to number ('A' is 65)
                let port=$(printf "%d" "'${arg:1:1}")-65
            
                # Each port is 32-bit wide
                let port_base=$port*32
                let gpio=port_base+${arg:2}
                echo $gpio
            else
                >&2 echo "wrong argument"
            fi
            
            
            M 1 Reply Last reply Reply Quote Share 2
            • M
              miaoguoqiang LV 2 @mstempin last edited by

              @mstempin
              $ ./pincalc.sh 9876999
              PK5f17

              M 1 Reply Last reply Reply Quote Share 0
              • M
                mstempin LV 4 @miaoguoqiang last edited by

                @miaoguoqiang 垃圾进垃圾出 ;-)
                很难检查边界,因为它们依赖于 SoC。

                1 Reply Last reply Reply Quote Share 0
                • J
                  jmhh247 LV 6 last edited by

                  输入引脚号,点回车没反应,楼主考虑支持一下回车键计算

                  1 Reply Last reply Reply Quote Share 0
                  • Referenced by  YuzukiTsuru YuzukiTsuru 
                  • Referenced by  YuzukiTsuru YuzukiTsuru 
                  • Referenced by  T The_Qiang 
                  • 1 / 1
                  • First post
                    Last post

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

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