PageSourceSearch

https://napiworld.ru/assets/js/fa5ce909.cc8669ff.js

js napiworld.ru collected 2026-10-04 00:00:25 UTC 14,206 bytes, 1 lines download raw bytes

1"use strict";(globalThis.webpackChunknapi_www||=[]).push([[1619],{67626(n,i,e){e.r(i),e.d(i,{default:()=>c,metadata:()=>r});var r=e(99005),p=e(74848),o=e(28453);const t={authorsImageUrls:[void 0]};function s(n){const i={code:"code",h2:"h2",h3:"h3",p:"p",pre:"pre",...(0,o.R)(),...n.components};return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(i.h2,{id:"\u0434\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430-\u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438-gpio",children:"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO"}),"\n",(0,p.jsx)(i.p,{children:"\u0412 Linux \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0447\u0435\u043c \u0437\u0430\u043d\u044f\u0442\u044b \u0432\u0441\u0435 GPIO:"}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"cat /sys/kernel/debug/pinctrl/pinctrl-rockchip-pinctrl/pinmux-pins\n"})}),"\n",(0,p.jsx)(i.h3,{id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0432\u044b\u0432\u043e\u0434\u0430-\u043d\u0430-napi-c",children:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0432\u043e\u0434\u0430 \u043d\u0430 NAPI-C"}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{children:"root@rockpi-s:~# cat /sys/kernel/debug/pinctrl/pinctrl-rockchip-pinctrl/pinmux-pins\nPinmux settings per pin\nFormat: pin (name): mux_owner gpio_owner hog?\npin 0 (gpio0-0): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 1 (gpio0-1): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 2 (gpio0-2): sdio-pwrseq gpio0:2 function sdio-pwrseq group wifi-enable-h\npin 3 (gpio0-3): ff480000.mmc (GPIO UNCLAIMED) function sdmmc group sdmmc-det\npin 4 (gpio0-4): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 5 (gpio0-5): leds gpio0:5 function leds group heartbeat-led\npin 6 (gpio0-6): leds gpio0:6 function leds group green-led\npin 7 (gpio0-7): stmmac-0:01 gpio0:7 function gmac group mac-rst\npin 8 (gpio0-8): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 9 (gpio0-9): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 10 (gpio0-10): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 11 (gpio0-11): ff050000.i2c (GPIO UNCLAIMED) function i2c1 group i2c1-xfer\npin 12 (gpio0-12): ff050000.i2c (GPIO UNCLAIMED) function i2c1 group i2c1-xfer\npin 13 (gpio0-13): ff180000.pwm (GPIO UNCLAIMED) function pwm0 group pwm0-pin-pull-down\npin 14 (gpio0-14): (MUX UNCLAIMED) (GPIO UNCLAIMED)\npin 15 (gpio0-15): (MUX UNCLAIMED) (GPIO UNCLAIMED)\n"})}),"\n",(0,p.jsx)(i.h3,{id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0437\u0430\u043d\u044f\u0442\u043e\u0433\u043e-gpio",children:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0437\u0430\u043d\u044f\u0442\u043e\u0433\u043e GPIO"}),"\n",(0,p.jsxs)(i.p,{children:["\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, ",(0,p.jsx)(i.code,{children:"GPIO0-A5"}),' \u0437\u0430\u043d\u044f\u0442 \u0438 \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043a\u0430\u043a DE \u0434\u043b\u044f UART \u0431\u0435\u0437 \u043b\u0438\u0448\u043d\u0438\u0445 "\u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440" \u043f\u043e \u0435\u0433\u043e \u043e\u0441\u0432\u043e\u0431\u043e\u0436\u0434\u0435\u043d\u0438\u044e:']}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# cat /sys/kernel/debug/pinctrl/pinctrl-rockchip-pinctrl/pinmux-pins | grep gpio0-5\npin 5 (gpio0-5): leds gpio0:5 function leds group heartbeat-led\nroot@rockpi-s:~/S4-GPIO2_A5#\n"})}),"\n",(0,p.jsx)(i.h3,{id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u0433\u043e-gpio",children:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u0433\u043e GPIO"}),"\n",(0,p.jsxs)(i.p,{children:["\u0410 \u0432\u043e\u0442 ",(0,p.jsx)(i.code,{children:"GPIO2-B4"})," \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043a\u0430\u043a \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u044b\u0439:"]}
1),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# cat /sys/kernel/debug/pinctrl/pinctrl-rockchip-pinctrl/pinmux-pins | grep gpio2-12\npin 76 (gpio2-12): (MUX UNCLAIMED) (GPIO UNCLAIMED)\n"})}),"\n",(0,p.jsx)(i.p,{children:'\u0418 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0435\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e "\u0434\u0435\u0440\u0433\u0430\u0442\u044c":'}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# gpioset gpiochip2 12=1\nroot@rockpi-s:~/S4-GPIO2_A5# gpioset gpiochip2 12=0\nroot@rockpi-s:~/S4-GPIO2_A5#\n"})}),"\n",(0,p.jsx)(i.h3,{id:"\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435-gpio-\u0432-dts",children:"\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 GPIO \u0432 DTS"}),"\n",(0,p.jsxs)(i.p,{children:['\u0410 \u0442\u0435\u043f\u0435\u0440\u044c "\u0437\u0430\u0445\u0432\u0430\u0442\u0438\u043c" \u043f\u0438\u043d ',(0,p.jsx)(i.code,{children:"GPIO2_A5"})," \u0434\u043b\u044f DE \u0432 UART1 \u0442\u0430\u043a\u0438\u043c DTS:"]}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-dts",children:' /dts-v1/;\n/plugin/;\n\n/ {\n  compatible = "rockchip,rk3308";\n\n  fragment@0 {\n    target = <&uart1>;\n    __overlay__ {\n      status = "okay";\n\n      pinctrl-names = "default";\n      pinctrl-0 = <&uart1_xfer>;\n\n      linux,rs485-enabled-at-boot-time;\n      rs485-rts-active-high;\n      rs485-rts-delay = <0 0>;\n      rts-gpios = <&gpio2 5 0>;\n    };\n  };\n};\n'})}),"\n",(0,p.jsx)(i.h3,{id:"\u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430-\u0437\u0430\u0445\u0432\u0430\u0442\u0430-gpio",children:"\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0437\u0430\u0445\u0432\u0430\u0442\u0430 GPIO"}),"\n",(0,p.jsx)(i.p,{children:"\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u0430\u043a \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0438\u043d:"}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# cat /sys/kernel/debug/pinctrl/pinctrl-rockchip-pinctrl/pinmux-pins | grep gpio2-5\npin 69 (gpio2-5): (MUX UNCLAIMED) gpio2:69\nroot@rockpi-s:~/S4-GPIO2_A5#\n"})}),"\n",(0,p.jsx)(i.p,{children:'\u0422\u0443\u0442 \u043d\u0435 \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u043f\u043e\u043d\u044f\u0442\u043d\u043e \u0437\u0430\u0445\u0432\u0430\u0442\u0438\u043b\u0441\u044f \u043e\u043d \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u043e\u043c RS485 \u0438\u043b\u0438 \u043d\u0435\u0442. \u041d\u043e \u0447\u0442\u043e \u0432\u0430\u0436\u043d\u043e, Linux \u043d\u0435 \u0434\u0430\u0441\u0442 \u0431\u043e\u043b\u044c\u0448\u0435 \u0438\u043c "\u043c\u0438\u0433\u0430\u0442\u044c", \u0435\u0441\u043b\u0438 \u043e\u043d \u0437\u0430\u043d\u044f\u0442 \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u043e\u043c \u044f\u0434\u0440\u0430:'}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# gpioset gpiochip2 5=0\ngpioset: error setting the GPIO line values: Device or resource busy\nroot@rockpi-s:~/S4-GPIO2_A5# gpioset gpiochip2 5=1\ngpioset: error setting the GPIO line values: Device or resource busy\nroot@rockpi-s:~/S4-GPIO2_A5#\n"})}),"\n",(0,p.jsx)(i.h3,{id:"\u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435-uart1",children:"\u0422\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 UART1"}),"\n",(0,p.jsx)(i.p,{children:"\u041e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0447\u0435\u0440\u0435\u0437 UART1:"}),"\n",(0,p.jsx)(i.pre,{children:(0,p.jsx)(i.code,{className:"language-bash",children:"root@rockpi-s:~/S4-GPIO2_A5# mbpoll -m rtu -P none -b 115200 -a 125 -r 1 -c 4 -t4   /dev/ttyS1\nmbpoll 1.0-0 - FieldTalk(tm) Modbus(R) Master Simulator\nCopyright \xa9 2015-2019 Pascal JEAN, https://github.com/epsilonrt/mbpoll\nThis program comes with ABSOLUTELY NO WARRANTY.\nThis is free software, and you are welcome to redistribute it\nunder certain conditions; type 'mbpoll -w' for details.\n\nProtocol configuration: Modbus RTU\nSlave configuration...: address = [125]\n                        start reference = 1, count = 4\nCommunication.........: /dev/ttyS1,     115200-8N1\n                        t/o 1.00 s, poll rate 1000 ms\nData type.............: 16-bit register, output (holding) register table\n\n-- Polling slave 125... Ctrl-C to stop)\n[1]:   125\n[2]:   1\n[3]:   851\n[4]:   772\n\n"})})]})}function c(n={}){const{wrapper:i}={...(0,o.R)(),...n.components};return i?(0,p.jsx)(i,{...n,children:(0,p.jsx)(s,{...n})}):s(n)}e.d(i,["assets",0,t,"contentTitle",0,void 0,"frontMatter",0,{slug:"gpio-pinmux-debug",title:"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0432 Linux",authors:"dmn",tags:["gpio","pinmux","debug","rockchip","pinctrl"],telegram_id:30,description:"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 /sys/kernel/debug/pinctrl \u0438 pinmux-pins \u0432 Linux \u043d\u0430 Rockchip.",keywords:["gpio","pinmux","\u043e\u0442\u043b\u0430\u0434\u043a\u0430","rockchip","pinctrl","linux","rk3308","napi-c"]},"toc",0,[{value:"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO",id:"\u0434\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430-\u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438-gpio",level:2},{value:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0432\u043e\u0434\u0430 \u043d\u0430 NAPI-C",id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0432\u044b\u0432\u043e\u0434\u0430-\u043d\u0430-napi-c",level:3},{value:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0437\u0430\u043d\u044f\u0442\u043e\u0433\u043e GPIO",id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0437\u0430\u043d\u044f\u0442\u043e\u0433\u043e-gpio",level:3},{value:"\u041f\u0440\u0438\u043c\u0435\u0440 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u0433\u043e GPIO",id:"\u043f\u0440\u0438\u043c\u0435\u0440-\u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u0433\u043e-gpio",level:3},{value:"\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 GPIO \u0432 DTS",id:"\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435-gpio-\u0432-dts",level:3},{value:"\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0437\u0430\u0445\u0432\u0430\u0442\u0430 GPIO",id:"\u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430-\u0437\u0430\u0445\u0432\u0430\u0442\u0430-gpio",level:3},{value:"\u0422\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 UART1",id:"\u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435-uart1",level:3}]])},28453(n,i,e){e.d(i,{R:()=>t,x:()=>s});var r=e(96540);const p={},o=r.createContext(p);function t(n){const i=r.useContext(o);return r.useMemo(function(){return"function"==typeof n?n(i):{...i,...n}},[i,n])}function s(n){let i;return i=n.disableParentContext?"function"==typeof n.components?n.components(p):n.components||p:t(n.components),r.createElement(o.Provider,{value:i},n.children)}},99005(n){n.exports=JSON.parse('{"permalink":"/recipes/gpio-pinmux-debug","source":"@site/techblog/2025-12-01-gpio-pinmux-debug/index.md","title":"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0432 Linux","description":"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 /sys/kernel/debug/pinctrl \u0438 pinmux-pins \u0432 Linux \u043d\u0430 Rockchip.","date":"2025-12-01T00:00:00.000Z","tags":[{"inline":true,"label":"gpio","permalink":"/recipes/tags/gpio"},{"inline":true,"label":"pinmux","permalink":"/recipes/tags/pinmux"},{"inline":true,"label":"debug","permalink":"/recipes/tags/debug"},{"inline":true,"label":"rockchip","permalink":"/recipes/tags/rockchip"},{"inline":true,"label":"pinctrl","permalink":"/recipes/tags/pinctrl"}],"readingTime":3.19,"hasTruncateMarker":false,"authors":[{"name":"dmn","title":"maintainer","url":"https://github.com/dmnovikov","imageURL":"https://avatars.githubusercontent.com/u/17533288?v=4","key":"dmn","page":null}],"frontMatter":{"slug":"gpio-pinmux-debug","title":"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0432 Linux","authors":"dmn","tags":["gpio","pinmux","debug","rockchip","pinctrl"],"telegram_id":30,"description":"\u0414\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0430 \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u0438 GPIO \u043f\u0438\u043d\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 /sys/kernel/debug/pinctrl \u0438 pinmux-pins \u0432 Linux \u043d\u0430 Rockchip.","keywords":["gpio","pinmux","\u043e\u0442\u043b\u0430\u0434\u043a\u0430","rockchip","pinctrl","linux","rk3308","napi-c"]},"unlisted":false,"prevItem":{"title":"\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u043e\u0440\u0442\u0430 \u0432 Linux","permalink":"/recipes/serial-port-configuration"},"nextItem":{"title":"Overlay \u0434\u043b\u044f RS485 \u043d\u0430 UART1 \u0441 GPIO \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f","permalink":"/recipes/rs485-uart1-overlay"}}')}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.