{"id":505187,"date":"2026-11-28T00:37:57","date_gmt":"2026-11-27T21:37:57","guid":{"rendered":"https:\/\/savepearlharbor.com\/?p=505187"},"modified":"2026-11-28T00:37:57","modified_gmt":"2026-11-27T21:37:57","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=505187","title":{"rendered":"\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c UNO R4 (Cortex M4) \u0441 \u043c\u043e\u0434\u0435\u043b\u044c\u044e"},"content":{"rendered":"<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0441 \u043d\u0443\u043b\u044f \u0438 \u043f\u043e\u043b\u0435\u0437\u043d\u0443\u044e \u0443\u0442\u0438\u043b\u0438\u0442\u0443 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0435\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438. \u041a\u043b\u044e\u0447\u0435\u0432\u044b\u0435 \u0441\u043b\u043e\u0432\u0430: xPack, GDB, probe-rs, VSCode, Cortex Debug. <\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/00\/3b\/df\/003bdf140a554bc2b09b80762ec517a9.png\" width=\"1096\" height=\"685\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/00\/3b\/df\/003bdf140a554bc2b09b80762ec517a9.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/00\/3b\/df\/003bdf140a554bc2b09b80762ec517a9.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u041c\u043e\u0434\u0435\u043b\u044c: \u0434\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u043b\u044e\u0431\u0430\u044f &#8212; \u0410\u043b\u0438\u0441\u0430, \u0413\u0438\u0433\u0430 \u0427\u0430\u0442 \u0438 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435. SourceCraft \u0438\u043b\u0438 GigaCode \u043e\u0441\u0442\u0430\u0432\u0438\u043c \u043d\u0430\u043f\u043e\u0442\u043e\u043c.<\/p>\n<p>\u0422\u0430\u043a \u043a\u0430\u043a \u043b\u0435\u043d\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0438\u043c\u044f \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0441 \u0444\u043e\u0442\u043e -\u0441\u0440\u0430\u0437\u0443 \u0432\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u0435\u0433\u043e, \u043c\u0443\u043b\u044c\u0442\u0438\u043c\u043e\u0434\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c, \u043e\u0434\u043d\u0430\u043a\u043e. text R7FA4M1 AB3CFM 527A200 Use code with caution. \u042d\u0442\u043e 32-\u0440\u0430\u0437\u0440\u044f\u0434\u043d\u044b\u0439 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 Renesas RA4M1 (\u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430 Arm Cortex-M4, 48 \u041c\u0413\u0446), \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u043d\u0430 \u043f\u043b\u0430\u0442\u0435, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0439 \u0441 Arduino UNO R4 Minima.<\/p>\n<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 &#171;\u043a\u043b\u043e\u043d\u0430 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e JTAG-\u0430\u0434\u0430\u043f\u0442\u0435\u0440\u0430&#187; \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043f\u043e \u0441\u0445\u0435\u043c\u0435<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/5d\/19\/c9\/5d19c9bc9bdbc691eb3b25d232d125c1.png\" alt=\"\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 - \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u044b\u0432\u043e\u0434 UART \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 SWD, \u0447\u0442\u043e \u043f\u043e\u0442\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f\" title=\"\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 - \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u044b\u0432\u043e\u0434 UART \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 SWD, \u0447\u0442\u043e \u043f\u043e\u0442\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f\" width=\"633\" height=\"318\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/5d\/19\/c9\/5d19c9bc9bdbc691eb3b25d232d125c1.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/5d\/19\/c9\/5d19c9bc9bdbc691eb3b25d232d125c1.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/p>\n<div><figcaption>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 &#8212; \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u044b\u0432\u043e\u0434 UART \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 SWD, \u0447\u0442\u043e \u043f\u043e\u0442\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f<\/figcaption><\/div>\n<\/figure>\n<details class=\"spoiler\">\n<summary>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c lsusb:<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/d7\/41\/6f\/d7416f6eeb513dab8f489c33d55ff8e3.png\" width=\"751\" height=\"76\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/d7\/41\/6f\/d7416f6eeb513dab8f489c33d55ff8e3.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/d7\/41\/6f\/d7416f6eeb513dab8f489c33d55ff8e3.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u0412\u0438\u0434\u0438\u043c \u0447\u0442\u043e \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u0441 \u0430\u0434\u0440\u0435\u0441\u043e\u043c 0483:3748  <\/p>\n<p>\u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c st-util \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0432 sudo apt update &amp;&amp; sudo apt install stlink-tools<\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 <\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/85\/81\/bf\/8581bf15fa7e79ab7cbc3185286118b2.png\" width=\"852\" height=\"46\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/85\/81\/bf\/8581bf15fa7e79ab7cbc3185286118b2.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/85\/81\/bf\/8581bf15fa7e79ab7cbc3185286118b2.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u0421\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043e\u0441\u0446\u0438\u043b\u043b\u043e\u0433\u0440\u0430\u0444\u043e\u043c &#8212; \u0441\u0438\u0433\u043d\u0430\u043b ~RST \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0438\u043c\u043f\u0443\u043b\u044c\u0441\u043e\u043c \u0432 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u0439 \u043d\u043e\u043b\u044c \u043d\u0430 \u0442\u0430\u043a\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u0445<\/p>\n<p>\u041f\u0438\u0448\u0435\u043c \u0432\u0430\u0439\u0431 \u0441 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435\u043c (<strong>\u043a\u043e\u043f\u0438\u043f\u0430\u0441\u0442<\/strong>), \u0434\u0430\u043b\u0435\u0435 \u043f\u0438\u0448\u0435\u043c \u043f\u0440\u043e\u043c\u043f\u0442 <strong>different tools<\/strong>.<\/p>\n<details class=\"spoiler\">\n<summary>\u0412\u0430\u0440\u0438\u0430\u043d\u0442\u044b<\/summary>\n<div class=\"spoiler__content\">\n<p>1. \u0418\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u0434\u043b\u044f \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0438 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 \u043f\u043e SWD (\u0437\u0430\u043c\u0435\u043d\u0430 <code>st-util<\/code> \/ GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430)<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0435\u0441\u044c \u043a \u043f\u0438\u043d\u0430\u043c <code>SWDIO<\/code> \u0438 <code>SWCLK<\/code> (\u043d\u0430 \u0432\u0430\u0448\u0435\u0439 \u043f\u043b\u0430\u0442\u0435 \u044d\u0442\u043e 6-\u043f\u0438\u043d\u043e\u0432\u044b\u0439 \u0440\u0430\u0437\u044a\u0435\u043c <code>SWD<\/code> \/ <code>ICSP<\/code> \u0440\u044f\u0434\u043e\u043c \u0441 \u0447\u0438\u043f\u043e\u043c):<\/p>\n<ul>\n<li>\n<p><code><strong>probe-rs<\/strong><\/code> \u2014 \u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043d\u0430 Rust. \u041e\u043d\u0430 \u0443\u043c\u0435\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0441 \u043a\u043b\u043e\u043d\u0430\u043c\u0438 <strong>ST-Link V2<\/strong> (\u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b ST-Link \u0434\u043b\u044f \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0445 ARM Cortex-M \u0447\u0438\u043f\u043e\u0432) \u0438 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u0443\u044e \u0431\u0430\u0437\u0443 \u0442\u0430\u0440\u0433\u0435\u0442\u043e\u0432 \u0434\u043b\u044f <code>R7FA4M1AB<\/code>.<\/p>\n<ul>\n<li>\n<p><em>\u0417\u0430\u043f\u0443\u0441\u043a GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430:<\/em> <code>probe-rs gdb --chip R7FA4M1AB<\/code><\/p>\n<\/li>\n<li>\n<p><em>\u041f\u0440\u043e\u0448\u0438\u0432\u043a\u0430:<\/em> <code>probe-rs download --chip R7FA4M1AB firmware.elf<\/code><\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code><strong>pyOCD<\/strong><\/code> \u2014 \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043d\u0430 Python, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0449\u0430\u044f ST-Link V2, CMSIS-DAP \u0438 J-Link. \u0422\u0440\u0435\u0431\u0443\u0435\u0442 \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 CMSIS-\u043f\u0430\u043a\u0435\u0442\u0430 Renesas.<\/p>\n<ul>\n<li>\n<p><em>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 \u0447\u0438\u043f\u0430:<\/em> <code>pyocd pack install R7FA4M1AB<\/code><\/p>\n<\/li>\n<li>\n<p><em>\u0417\u0430\u043f\u0443\u0441\u043a GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430:<\/em> <code>pyocd gdbserver -t R7FA4M1AB<\/code><\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code><strong>OpenOCD<\/strong><\/code><strong> (\u0444\u043e\u0440\u043a \u043e\u0442 Renesas)<\/strong> \u2014 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a, \u043d\u043e \u0434\u043b\u044f RA4M1 \u043b\u0443\u0447\u0448\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u0435\u0442\u043a\u0443 OpenOCD \u043e\u0442 Renesas, \u0442\u0430\u043a \u043a\u0430\u043a \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0444\u043b\u0435\u0448-\u043f\u0430\u043c\u044f\u0442\u0438 \u0441\u0435\u0440\u0438\u0438 RA \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u043f\u043e\u043b\u043d\u043e\u0439. \u041f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b <code>cmsis-dap<\/code>, <code>jlink<\/code> \u0438 <code>stlink<\/code>.<\/p>\n<\/li>\n<li>\n<p><strong>SEGGER J-Link (<\/strong><code><strong>JLinkGDBServer<\/strong><\/code><strong>)<\/strong> \u2014 \u043f\u0440\u043e\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f \u043e\u0442\u043b\u0430\u0434\u043a\u0438 ARM. \u041e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0441 Renesas RA4M1 \u0438 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c \u0441 \u043b\u043e\u0433\u0438\u043a\u043e\u0439 \u043e\u0442 1.2 \u0412 \u0434\u043e 5 \u0412.<\/p>\n<\/li>\n<\/ul>\n<\/div>\n<\/details>\n<p>\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c <em>probe-rs<\/em>. \u041f\u0438\u0448\u0435\u043c <strong>probe-rs install<\/strong>, \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0431\u0443\u0434\u0435\u0442 \u0434\u0430\u043d \u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u0421\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u043e\u043d\u043b\u0430\u0439\u043d-\u043c\u043e\u0434\u0435\u043b\u0438 \u0434\u0430\u044e\u0442 \u0431\u0438\u0442\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430 \u0438 IP, \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u0441 \u0446\u0435\u043b\u044c\u044e \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438, \u043f\u043e\u044d\u0442\u043e\u043c\u0443, \u0430\u0434\u0440\u0435\u0441\u0430 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0432\u0432\u043e\u0434\u0438\u0442\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0438\u043b\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0447\u0442\u043e \u043d\u0435\u0442 \u043e\u0448\u0438\u0431\u043e\u043a:<\/p>\n<pre><code class=\"bash\">curl -LsSf https:\/\/github.com\/probe-rs\/probe-rs\/releases\/latest\/download\/probe-rs-tools-installer.sh | shsource $HOME\/.cargo\/env<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper\"><\/span><\/a><\/div><\/pre>\n<p>,\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c<\/p>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/de\/10\/ff\/de10ffc78f80796bdc5b996fb693a146.png\" width=\"332\" height=\"31\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/de\/10\/ff\/de10ffc78f80796bdc5b996fb693a146.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/de\/10\/ff\/de10ffc78f80796bdc5b996fb693a146.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442:<\/p>\n<details class=\"spoiler\">\n<summary>\u0421\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041e\u0442\u043b\u0438\u0447\u043d\u043e, \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0432\u0438\u0434\u0438\u0442 \u0432\u0430\u0448 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430\u0442\u043e\u0440 (<code>STLink V2 -- 0483:3748:29<\/code>). \u042d\u0442\u043e \u043a\u043b\u043e\u043d ST-Link V2, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 <code>probe-rs<\/code> \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442.<\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0448\u0430\u0433 \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0438 \u0441\u0432\u044f\u0437\u0438 \u0441 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u043c <strong>Renesas RA4M1<\/strong>:<\/p>\n<pre><code>probe-rs info --chip R7FA4M1AB<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<\/div>\n<\/details>\n<p>\u041f\u044b\u0442\u0430\u0435\u043c\u0441\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f: probe-rs info &#8212;chip R7FA4M1AB<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/09\/5a\/8f\/095a8f2988c026a9a00d33b372f700ab.png\" width=\"748\" height=\"141\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/09\/5a\/8f\/095a8f2988c026a9a00d33b372f700ab.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/09\/5a\/8f\/095a8f2988c026a9a00d33b372f700ab.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u041a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439, \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435:<\/p>\n<details class=\"spoiler\">\n<summary>\u041e\u0448\u0438\u0431\u043a\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f<\/summary>\n<div class=\"spoiler__content\">\n<p>Use code with caution.<\/p>\n<ul>\n<li>\n<p>\u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0441\u043d\u0438\u0437\u0438\u0442\u044c \u0447\u0430\u0441\u0442\u043e\u0442\u0443 \u0442\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f SWD \u0434\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u043e 100 \u043a\u0413\u0446):<\/p>\n<\/li>\n<\/ul>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u0438\u043d\u0430 <code><strong>GND<\/strong><\/code> \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043e\u0440\u043f\u0443\u0441\u0430 USB-C \u0438 \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c <code><strong>probe-rs info --speed 100<\/strong><\/code> \u0441 \u0437\u0430\u043c\u043a\u043d\u0443\u0442\u044b\u043c \u043d\u0430 \u0437\u0435\u043c\u043b\u044e \u043a\u043e\u043d\u0442\u0430\u043a\u0442\u043e\u043c <code><strong>BOOT<\/strong><\/code><strong> (Pin 1)<\/strong>. \u041d\u0430\u043f\u0438\u0448\u0438\u0442\u0435, \u043a\u0430\u043a\u043e\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u0435\u0440\u043d\u0435\u0442 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b.<\/p>\n<\/div>\n<\/details>\n<p>\u0417\u0430\u0431\u0435\u0433\u0430\u044f \u0432\u043f\u0435\u0440\u0451\u0434 \u043c\u043e\u0436\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u0447\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c. \u0414\u0430\u0451\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <code>probe-rs info --speed 100<strong> <\/strong><\/code>\u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c:<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/d3\/10\/11\/d31011b49dff2a671dd1abc43f8b17e6.png\" width=\"615\" height=\"33\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/d3\/10\/11\/d31011b49dff2a671dd1abc43f8b17e6.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/d3\/10\/11\/d31011b49dff2a671dd1abc43f8b17e6.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u041e\u0442\u043b\u0438\u0447\u043d\u043e. \u0422\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0441\u043e\u043e\u0431\u0449\u0438\u0442\u044c, \u0447\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c SWD. <strong>I have the SWD interface<\/strong>. \u0438 \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u044d\u0442\u0438\u043c \u0432\u044b\u0432\u043e\u0434 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u044b. <\/p>\n<\/div>\n<\/details>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c xpack \u0434\u043b\u044f ARM. \u0415\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u0437\u044f\u0442\u044c <a href=\"https:\/\/xpack-dev-tools.github.io\/arm-none-eabi-gcc-xpack\/\" rel=\"noopener nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.  <\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u0442\u0430\u0432\u0438\u043c NPM \u0437\u0430\u0442\u0435\u043c XPM \u043f\u043e\u0442\u043e\u043c \u0443\u0436\u0435 xPack (\u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e <br \/>xpm install &#8212;global @xpack-dev-tools\/arm-none-eabi-gcc@latest <br \/>\u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u043a\u043e\u043f\u0438\u043f\u0430\u0441\u0442\u043e\u043c \u0441 \u0441\u0430\u0439\u0442\u0430) <\/p>\n<pre><code class=\"bash\">sudo apt install npmsudo npm install --location=global xpm@latestxpm install @xpack-dev-tools\/arm-none-eabi-gcc@15.2.1-1.1.1 --verbose --location=global<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>\u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043f\u043e\u0438\u0441\u043a\u043e\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430, \u043b\u0443\u0447\u0448\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0430\u0439\u0431 \u043f\u043e \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u043c\u0443 \u043f\u043e\u0438\u0441\u043a\u0443 \u043f\u0443\u0442\u0435\u0439. \u041e\u043f\u0443\u0441\u043a\u0430\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0438\u0435 \u0432\u044b\u043a\u043b\u0430\u0434\u043a\u0438 \u0441\u0440\u0430\u0437\u0443 \u0441\u0430\u043c\u043c\u0430\u0440\u0438 \u043f\u043e \u043a\u043e\u0434\u0443. \u042d\u0442\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043d\u0430\u0439\u0442\u0438 \u043f\u0443\u0442\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0435 \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0432\u044b\u0437\u043e\u0432\u0430 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u043e\u0432, \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u043e\u0432 \u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a. \u0422\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0437\u0430\u0445\u0430\u0440\u0434\u043a\u043e\u0436\u0435\u043d\u043d\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438. \u0421\u043a\u0440\u0438\u043f\u0442 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043d\u0430\u0439\u0442\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f.<\/p>\n<details class=\"spoiler\">\n<summary>\u0423\u0442\u0438\u043b\u0438\u0442\u044b \u043f\u043e\u0438\u0441\u043a\u0430 xPack<\/summary>\n<div class=\"spoiler__content\">\n<details class=\"spoiler\">\n<summary>Shell-\u043e\u0431\u0432\u044f\u0437\u043a\u0430 (shell wrapper script)<\/summary>\n<div class=\"spoiler__content\">\n<p>\u042d\u0442\u043e\u0442 \u0441\u043a\u0440\u0438\u043f\u0442 \u2014 <strong>POSIX-\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u0430\u044f shell-\u043e\u0431\u0435\u0440\u0442\u043a\u0430 (<\/strong><code><strong>find_<\/strong><\/code><a href=\"http:\/\/xpack.sh\" rel=\"noopener nofollow\"><code><strong>xpack.sh<\/strong><\/code><\/a><strong>), \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 Python \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0435\u043c\u0443 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u043c\u0435\u0441\u0442\u0435 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 <\/strong><code><strong>find_xpack.py<\/strong><\/code>.<\/p>\n<p>\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u0438 \u043b\u043e\u0433\u0438\u043a\u0430 \u0440\u0430\u0431\u043e\u0442\u044b<\/p>\n<ol>\n<li>\n<p><strong>\u0421\u0442\u0440\u043e\u0433\u0438\u0439 \u0440\u0435\u0436\u0438\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f (<\/strong><code><strong>set -eu<\/strong><\/code><strong>)<\/strong><\/p>\n<ul>\n<li>\n<p>\u041f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u043f\u0440\u0438 \u043b\u044e\u0431\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b (<code>-e<\/code>) \u0438\u043b\u0438 \u043f\u0440\u0438 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0438 \u043a \u043d\u0435\u043e\u0431\u044a\u044f\u0432\u043b\u0435\u043d\u043d\u043e\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 (<code>-u<\/code>).<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/strong><\/p>\n<ul>\n<li>\n<p>\u0412\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u043f\u0430\u043f\u043a\u0435, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0441\u0430\u043c <code>find_<\/code><a href=\"http:\/\/xpack.sh\" rel=\"noopener nofollow\"><code>xpack.sh<\/code><\/a>, \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e \u043e\u0442 \u0442\u043e\u0433\u043e, \u0438\u0437 \u043a\u0430\u043a\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u043e\u043d \u0431\u044b\u043b \u0432\u044b\u0437\u0432\u0430\u043d. \u042d\u0442\u043e \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043b\u0435\u0436\u0430\u0449\u0438\u0439 \u0440\u044f\u0434\u043e\u043c <code>find_xpack.py<\/code> \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0439\u0434\u0435\u043d.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>\u041f\u043e\u0438\u0441\u043a \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0430 Python<\/strong><\/p>\n<ul>\n<li>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 <code>python3<\/code> \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 (<code>PATH<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 <code>python3<\/code> \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d, \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <code>python<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043e\u0431\u0430 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0442, \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0435 \u0432 <code>stderr<\/code> \u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u0435\u0442\u0441\u044f \u0441 \u043a\u043e\u0434\u043e\u043c <code>1<\/code>.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><strong>\u0414\u0435\u043b\u0435\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f (<\/strong><code><strong>exec<\/strong><\/code><strong>)<\/strong><\/p>\n<ul>\n<li>\n<p>\u0417\u0430\u043c\u0435\u043d\u044f\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 shell \u043d\u0430 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 Python (<code>exec<\/code>), \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u044f <code>find_xpack.py<\/code> \u0441 \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0435\u0439 \u0432\u0441\u0435\u0445 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 (<code>\"$@\"<\/code>), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <code>--project-dir<\/code>.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p>\u041a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f<\/p>\n<ul>\n<li>\n<p>\u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432 <code>$HOME\/.armscr\/find_<\/code><a href=\"http:\/\/xpack.sh\" rel=\"noopener nofollow\"><code>xpack.sh<\/code><\/a> \u043f\u0440\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f (<code>make toolchain-setup<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0438\u0437 <code>Makefile<\/code> \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 xPack \u0432 \u0440\u0430\u043c\u043a\u0430\u0445 \u0441\u0431\u043e\u0440\u043a\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 (\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u043f\u043e\u0434 ARM-\u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0443).<\/p>\n<\/li>\n<\/ul>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>\u041f\u0438\u0442\u043e\u043d-\u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u043e\u0438\u0441\u043a\u0430<\/summary>\n<div class=\"spoiler__content\">\n<p><strong>\u0421\u043a\u0440\u0438\u043f\u0442 <\/strong><code><strong>find_xpack.py<\/strong><\/code><strong> \u2014 \u044d\u0442\u043e \u0430\u0432\u0442\u043e\u043d\u043e\u043c\u043d\u0430\u044f \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430 xPack ARM GNU (<\/strong><code><strong>arm-none-eabi-gcc<\/strong><\/code><strong>) \u0438 \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0435\u0433\u043e \u043f\u0443\u0442\u0435\u0439 \u043c\u0435\u0436\u0434\u0443 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439 \u0441\u0431\u043e\u0440\u043a\u0438 (<\/strong><code><strong>Makefile<\/strong><\/code><strong>) \u0438 \u0441\u0440\u0435\u0434\u043e\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 (<\/strong><code><strong>VS Code<\/strong><\/code><strong>).<\/strong><\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u044b\u0439 \u0440\u0430\u0437\u0431\u043e\u0440 \u0432\u0441\u0435\u0445 \u043c\u043e\u0434\u0443\u043b\u0435\u0439 \u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0438\u0441\u043a\u043b\u044e\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u044d\u0442\u043e\u0433\u043e Python-\u0441\u043a\u0440\u0438\u043f\u0442\u0430.<\/p>\n<hr\/>\n<p>1. \u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u044b \u0438 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438<\/p>\n<p>\u0412 \u043d\u0430\u0447\u0430\u043b\u0435 \u0444\u0430\u0439\u043b\u0430 \u0437\u0430\u0434\u0430\u044e\u0442\u0441\u044f \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043f\u043e\u0438\u0441\u043a\u0430 \u0438 \u043c\u0430\u043f\u043f\u0438\u043d\u0433\u0430:<\/p>\n<ul>\n<li>\n<p><code>SCOPE<\/code> (<code>@xpack-dev-tools<\/code>), <code>PKG<\/code> (<code>arm-none-eabi-gcc<\/code>), <code>QEMU_PKG<\/code> (<code>qemu-arm<\/code>) \u2014 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0432 \u044d\u043a\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u0435 xPack.<\/p>\n<\/li>\n<li>\n<p><code>CACHE_FILENAME<\/code> (<code>.xpack_cache.txt<\/code>) \u2014 \u0438\u043c\u044f \u0444\u0430\u0439\u043b\u0430 \u043a\u044d\u0448\u0430, \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c\u043e\u0433\u043e \u0434\u043b\u044f <code>Makefile<\/code>.<\/p>\n<\/li>\n<li>\n<p><code>BARE_TOOL_KEYS<\/code> \u2014 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u044f \u043a\u043b\u044e\u0447\u0435\u0439 JSON (<code>gdbPath<\/code>, <code>compilerPath<\/code>, <code>objdumpPath<\/code>, <code>nmPath<\/code>) \u0438\u043c\u0435\u043d\u0430\u043c \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432 \u0434\u043b\u044f \u0441\u043b\u0443\u0447\u0430\u0435\u0432, \u043a\u043e\u0433\u0434\u0430 \u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0438\u043c\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0431\u0435\u0437 \u043f\u0443\u0442\u0438.<\/p>\n<\/li>\n<li>\n<p><code>VSCODE_FILES<\/code> \u2014 \u0446\u0435\u043b\u0435\u0432\u044b\u0435 \u0444\u0430\u0439\u043b\u044b \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a IDE (<code>.vscode\/launch.json<\/code> \u0438 <code>.vscode\/c_cpp_properties.json<\/code>).<\/p>\n<\/li>\n<\/ul>\n<hr\/>\n<p>2. \u041f\u043e\u0438\u0441\u043a \u0438 \u0432\u044b\u0431\u043e\u0440 \u0432\u0435\u0440\u0441\u0438\u0438 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430 (<code>Discovery<\/code>)<\/p>\n<p>\u041b\u043e\u0433\u0438\u043a\u0430 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0430 \u0432\u043e\u043a\u0440\u0443\u0433 \u0441\u0431\u043e\u0440\u0430 \u0432\u0441\u0435\u0445 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a \u0438 \u0432\u044b\u0431\u043e\u0440\u0430 \u0441\u0430\u043c\u043e\u0439 \u043d\u043e\u0432\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438:<\/p>\n<ul>\n<li>\n<p><code><strong>version_key(name)<\/strong><\/code>: \u0418\u0437\u0432\u043b\u0435\u043a\u0430\u0435\u0442 \u0432\u0441\u0435 \u0447\u0438\u0441\u043b\u0430 \u0438\u0437 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432\u0435\u0440\u0441\u0438\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>'15.2.1-1.1.1'<\/code>) \u0438 \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u0438\u0445 \u0432 \u043a\u043e\u0440\u0442\u0435\u0436 <code>(15, 2, 1, 1, 1)<\/code> \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0433\u043e \u0441\u0435\u043c\u0430\u043d\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0432\u0435\u0440\u0441\u0438\u0439.<\/p>\n<\/li>\n<li>\n<p><code><strong>global_prefixes()<\/strong><\/code>: \u0424\u043e\u0440\u043c\u0438\u0440\u0443\u0435\u0442 \u0441\u043f\u0438\u0441\u043e\u043a \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0445 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439 <code>xpm<\/code> \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u041e\u0421: \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f <code>$XPACKS_DIR<\/code>, <code>~\/.local\/xPacks<\/code> (\u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f Linux\/macOS), <code>~\/.config\/xPacks<\/code> (\u0443\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0438\u0439 \u043f\u0443\u0442\u044c) \u0438 <code>%APPDATA%\/xPacks<\/code> (Windows).<\/p>\n<\/li>\n<li>\n<p><code><strong>package_dirs(prefix)<\/strong><\/code>: \u0421\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0432\u0438\u0434\u0430 <code>&lt;prefix&gt;\/&lt;scope&gt;\/&lt;pkg&gt;\/&lt;version&gt;<\/code> (\u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044f \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443 \u043a\u0430\u043a \u0441\u043e \u0441\u043a\u043e\u0443\u043f\u043e\u043c <code>@xpack-dev-tools<\/code>, \u0442\u0430\u043a \u0438 \u0431\u0435\u0437 \u043d\u0435\u0433\u043e).<\/p>\n<\/li>\n<li>\n<p><code><strong>payload_dir(root)<\/strong><\/code><strong> \u0438 <\/strong><code><strong>is_toolchain(root)<\/strong><\/code>: \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0432\u0430\u043b\u0438\u0434\u043d\u043e\u0441\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u0423\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u043f\u0430\u043a\u0435\u0442\u043e\u0432 <code>xpm<\/code>, \u0433\u0434\u0435 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u0431\u0438\u043d\u0430\u0440\u043d\u0438\u043a\u0438 \u043b\u0435\u0436\u0430\u0442 \u0432 \u0441\u043a\u0440\u044b\u0442\u043e\u0439 \u043f\u043e\u0434\u043f\u0430\u043f\u043a\u0435 <code>.content\/bin\/arm-none-eabi-gcc<\/code>.<\/p>\n<\/li>\n<li>\n<p><code><strong>from_path()<\/strong><\/code>: \u0420\u0435\u0437\u0435\u0440\u0432\u043d\u044b\u0439 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u2014 \u0438\u0449\u0435\u0442 <code>arm-none-eabi-gcc<\/code> \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 <code>$PATH<\/code> \u0447\u0435\u0440\u0435\u0437 <code>shutil.which<\/code> \u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u043a\u043e\u0440\u043d\u0435\u0432\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430.<\/p>\n<\/li>\n<li>\n<p><code><strong>discover(args, project, verbose)<\/strong><\/code>: \u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043f\u043e\u0438\u0441\u043a\u0430. \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0438 \u043f\u043e \u043f\u0440\u0438\u043e\u0440\u0438\u0442\u0435\u0442\u0443:<\/p>\n<ol>\n<li>\n<p>\u042f\u0432\u043d\u044b\u0439 \u0444\u043b\u0430\u0433 <code>--toolchain<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f <code>$ARM_XPACK_TOOLCHAIN_PATH<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u041b\u043e\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u0430\u043f\u043a\u0430 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 <code>&lt;project&gt;\/xPacks<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u0413\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 <code>xpm<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u0421\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0439 <code>$PATH<\/code> (\u0435\u0441\u043b\u0438 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d\u043e \u0432 <code>xPacks<\/code>).<br \/><em>\u0418\u0437 \u0432\u0441\u0435\u0445 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u044b\u0445 \u0432 \u043f\u0430\u043f\u043a\u0430\u0445 <\/em><code><em>xPacks<\/em><\/code><em> \u043a\u0430\u043d\u0434\u0438\u0434\u0430\u0442\u043e\u0432 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u043e\u0439 \u043f\u043e <\/em><code><em>version_key<\/em><\/code><em> \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u0442\u0441\u044f \u0441\u0430\u043c\u0430\u044f \u0441\u0432\u0435\u0436\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f.<\/em><\/p>\n<\/li>\n<\/ol>\n<\/li>\n<\/ul>\n<p>3. \u0421\u0431\u043e\u0440 \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0445 \u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f \u043a\u044d\u0448\u0430 (<code>Path computation<\/code> &amp; <code>Cache<\/code>)<\/p>\n<p><em>(\u0427\u0430\u0441\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u043d\u043e\u043c \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u0435, \u043d\u043e \u0438\u0445 \u043b\u043e\u0433\u0438\u043a\u0430 \u043e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e \u043a\u043e\u0434\u0443 \u0438 \u0432\u044b\u0437\u043e\u0432\u0430\u043c \u0432 <\/em><code><em>main<\/em><\/code><em>)<\/em>:<\/p>\n<ul>\n<li>\n<p><code><strong>gcc_version(root)<\/strong><\/code>: \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442 <code>arm-none-eabi-gcc --version<\/code> \u0447\u0435\u0440\u0435\u0437 <a href=\"http:\/\/subprocess.run\" rel=\"noopener nofollow\"><code>subprocess.run<\/code><\/a> (\u0441 \u0442\u0430\u0439\u043c\u0430\u0443\u0442\u043e\u043c 15 \u0441\u0435\u043a) \u0438 \u043f\u0430\u0440\u0441\u0438\u0442 \u043d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438. \u041f\u0440\u0438 \u043e\u0448\u0438\u0431\u043a\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u0435\u0440\u0435\u0442 \u0432\u0435\u0440\u0441\u0438\u044e \u0438\u0437 \u0438\u043c\u0435\u043d\u0438 \u043f\u0430\u043f\u043a\u0438 \u043f\u0430\u043a\u0435\u0442\u0430.<\/p>\n<\/li>\n<li>\n<p><code><strong>first_dir<\/strong><\/code><strong> \/ <\/strong><code><strong>first_glob<\/strong><\/code>: \u0412\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u043f\u043e\u0434\u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0445 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u043e\u0432 <code>include<\/code> \u0438\u043b\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a <code>lib<\/code> \u0432\u043d\u0443\u0442\u0440\u0438 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430).<\/p>\n<\/li>\n<li>\n<p><code><strong>find_qemu(prefixes, verbose)<\/strong><\/code>: \u041f\u043e \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0438 \u0441 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u043e\u043c \u0438\u0449\u0435\u0442 \u0441\u0430\u043c\u0443\u044e \u0441\u0432\u0435\u0436\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u044d\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u0430 <code>qemu-system-arm<\/code> \u0432 \u043f\u0430\u043f\u043a\u0430\u0445 <code>xPacks<\/code> \u0438\u043b\u0438 \u0432 <code>$PATH<\/code>.<\/p>\n<\/li>\n<li>\n<p><code><strong>build_paths<\/strong><\/code><strong> \u0438 <\/strong><code><strong>write_cache<\/strong><\/code> <em>(\u0438\u0437 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u043d\u043e\u0439 \u0441\u0435\u0440\u0435\u0434\u0438\u043d\u044b)<\/em>: \u0421\u043e\u0431\u0438\u0440\u0430\u044e\u0442 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 <code>ARM_XPACK_*<\/code> (\u043f\u0443\u0442\u0438 \u043a <code>bin<\/code>, \u043a\u043e\u0440\u043d\u044e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430, \u0432\u0435\u0440\u0441\u0438\u0438 GCC, \u043f\u0443\u0442\u0438 \u043a QEMU) \u0438 \u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u044e\u0442 \u0438\u0445 \u0432 <code>&lt;project&gt;\/generated\/.xpack_cache.txt<\/code>. \u0417\u0430\u043f\u0438\u0441\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f <strong>\u0438\u0434\u0435\u043c\u043f\u043e\u0442\u0435\u043d\u0442\u043d\u043e<\/strong> \u2014 \u0444\u0430\u0439\u043b \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0438 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e.<\/p>\n<\/li>\n<\/ul>\n<p>4. \u0421\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0439 VS Code (<code>.vscode\/*.json<\/code>)<\/p>\n<p>\u042d\u0442\u043e\u0442 \u0431\u043b\u043e\u043a \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a \u0438 \u0430\u043d\u0430\u043b\u0438\u0437\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430 C\/C++ \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u0440\u043e\u0432\u043d\u043e \u0442\u043e\u0442 \u0436\u0435 \u0442\u0443\u043b\u0447\u0435\u0439\u043d, \u0447\u0442\u043e \u0438 \u0441\u0431\u043e\u0440\u0449\u0438\u043a:<\/p>\n<ul>\n<li>\n<p><code><strong>remap_xpack_path(value, root)<\/strong><\/code>:<\/p>\n<ul>\n<li>\n<p>\u0420\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u044b\u043c \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435\u043c \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0432 \u0441\u0442\u0440\u043e\u043a\u0435 \u043f\u0443\u0442\u0438 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442 <code>...\/xPacks\/...<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u041e\u0442\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u0441\u0442\u0430\u0440\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u043f\u0430\u043a\u0435\u0442\u0430 \u0438 \u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0435\u0442 \u043d\u043e\u0432\u044b\u0439 \u043a\u043e\u0440\u0435\u043d\u044c <code>root<\/code> \u0441 \u043e\u0441\u0442\u0430\u0432\u0448\u0438\u043c\u0441\u044f \u00ab\u0445\u0432\u043e\u0441\u0442\u043e\u043c\u00bb \u043f\u0443\u0442\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>\/.content\/bin\/arm-none-eabi-gdb<\/code>).<\/p>\n<\/li>\n<li>\n<p><strong>\u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u0442 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u043e\u043d\u0444\u0438\u0433\u043e\u0432:<\/strong> \u0415\u0441\u043b\u0438 \u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u043c JSON \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 <code>${env:HOME}<\/code> \u0438\u043b\u0438 <code>~<\/code>, \u0441\u043a\u0440\u0438\u043f\u0442 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u044d\u0442\u043e\u0442 \u043f\u0440\u0435\u0444\u0438\u043a\u0441 \u0432\u043c\u0435\u0441\u0442\u043e \u0437\u0430\u043f\u0438\u0441\u0438 \u0436\u0435\u0441\u0442\u043a\u043e\u0433\u043e \u043f\u0443\u0442\u0438 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u0439 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code><strong>walk_and_update(...)<\/strong><\/code>:<\/p>\n<ul>\n<li>\n<p>\u0420\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u043e\u0431\u0445\u043e\u0434\u0438\u0442 \u0432\u0441\u0435 \u0443\u0437\u043b\u044b (<code>dict<\/code> \u0438 <code>list<\/code>) \u0440\u0430\u0441\u043f\u0430\u0440\u0441\u0435\u043d\u043d\u043e\u0433\u043e JSON-\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430.<\/p>\n<\/li>\n<li>\n<p>\u041f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442 <code>remap_xpack_path<\/code> \u043a\u043e \u0432\u0441\u0435\u043c \u0441\u0442\u0440\u043e\u043a\u043e\u0432\u044b\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c.<\/p>\n<\/li>\n<li>\n<p>\u0414\u043b\u044f \u043a\u043b\u044e\u0447\u0435\u0439 \u0438\u0437 <code>BARE_TOOL_KEYS<\/code> (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>\"gdbPath\": \"arm-none-eabi-gdb\"<\/code>) \u0440\u0430\u0437\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u0442 \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u0438\u043c\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0432 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u043e\u0433\u043e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code><strong>update_json_file(...)<\/strong><\/code>:<\/p>\n<ul>\n<li>\n<p>\u0411\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e \u0447\u0438\u0442\u0430\u0435\u0442 JSON (\u043f\u0440\u0438 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0435 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u043f\u0440\u0435\u0434\u0443\u043f\u0440\u0435\u0436\u0434\u0435\u043d\u0438\u0435 \u0432 <code>stderr<\/code> \u0438 \u043f\u0440\u043e\u043f\u0443\u0441\u043a\u0430\u0435\u0442 \u0444\u0430\u0439\u043b, \u043d\u0435 \u043b\u043e\u043c\u0430\u044f \u0441\u0431\u043e\u0440\u043a\u0443).<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0444\u0430\u0439\u043b \u043d\u0430 \u0434\u0438\u0441\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 (\u0438 \u0435\u0441\u043b\u0438 \u043d\u0435 \u0432\u043a\u043b\u044e\u0447\u0435\u043d <code>--dry-run<\/code>), \u0432\u044b\u0432\u043e\u0434\u044f \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u044b\u0439 diff (<code>- \u0441\u0442\u0430\u0440\u044b\u0439 \u043f\u0443\u0442\u044c<\/code> \/ <code>+ \u043d\u043e\u0432\u044b\u0439 \u043f\u0443\u0442\u044c<\/code>).<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>5. \u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u043c (<code>main<\/code>)<\/p>\n<ul>\n<li>\n<p><code><strong>parse_args(argv)<\/strong><\/code>: \u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u0442 <code>argparse<\/code> \u0441 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u043e\u0439 \u0444\u043b\u0430\u0433\u043e\u0432:<\/p>\n<ul>\n<li>\n<p><code>--project-dir<\/code> \u2014 \u043f\u0443\u0442\u044c \u043a \u043a\u043e\u0440\u043d\u044e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 (\u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0442\u0435\u043a\u0443\u0449\u0430\u044f \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f);<\/p>\n<\/li>\n<li>\n<p><code>--toolchain<\/code> \u2014 \u043f\u0440\u0438\u043d\u0443\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0443;<\/p>\n<\/li>\n<li>\n<p><code>--dry-run<\/code> \u2014 \u0440\u0435\u0436\u0438\u043c \u043f\u0440\u0435\u0434\u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0430 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0431\u0435\u0437 \u0437\u0430\u043f\u0438\u0441\u0438 \u0444\u0430\u0439\u043b\u043e\u0432;<\/p>\n<\/li>\n<li>\n<p><code>--no-vscode<\/code> \u2014 \u043f\u0440\u043e\u043f\u0443\u0441\u043a \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f JSON-\u0444\u0430\u0439\u043b\u043e\u0432 IDE;<\/p>\n<\/li>\n<li>\n<p><code>--quiet<\/code> \u0438 <code>-v \/ --verbose<\/code> \u2014 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0443\u0440\u043e\u0432\u043d\u0435\u043c \u0434\u0435\u0442\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043b\u043e\u0433\u043e\u0432.<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code><strong>main(argv)<\/strong><\/code>: \u041a\u043e\u043e\u0440\u0434\u0438\u043d\u0438\u0440\u0443\u0435\u0442 \u0432\u0435\u0441\u044c \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u044b\u0439 \u0446\u0438\u043a\u043b:<\/p>\n<ol>\n<li>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u043d\u0438\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<\/p>\n<\/li>\n<li>\n<p>\u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442 <code>discover()<\/code> \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u0430. \u0415\u0441\u043b\u0438 \u043e\u043d \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d \u2014 \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442 \u0441\u043f\u0438\u0441\u043e\u043a \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0445 \u043f\u0443\u0442\u0435\u0439 \u0438 \u0433\u043e\u0442\u043e\u0432\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <code>xpm install --global ...<\/code> \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438, \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u044f\u0441\u044c \u0441 \u043a\u043e\u0434\u043e\u043c <code>1<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u0412\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u043f\u0443\u0442\u0438 (<code>build_paths<\/code>), \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u0442 \u043a\u044d\u0448 (<code>write_cache<\/code>) \u0438 \u043a\u043e\u043d\u0444\u0438\u0433\u0438 VS Code (<code>update_json_file<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u0445\u0432\u0430\u0442\u044b\u0432\u0430\u0435\u0442 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0435 \u043e\u0448\u0438\u0431\u043a\u0438 \u0432\u0432\u043e\u0434\u0430-\u0432\u044b\u0432\u043e\u0434\u0430 (<code>OSError<\/code>), \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u044f \u043a\u043e\u0434 <code>2<\/code> \u043f\u0440\u0438 \u0441\u0431\u043e\u044f\u0445 \u0438 <code>0<\/code> \u043f\u0440\u0438 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u043c \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u0438.<\/p>\n<\/li>\n<\/ol>\n<\/li>\n<\/ul>\n<\/div>\n<\/details>\n<\/div>\n<\/details>\n<p>\u0422\u0430\u043a\u0436\u0435, \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e json \u0434\u043b\u044f VSCode \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0437\u0430\u0448\u0438\u0442\u044b \u043f\u0443\u0442\u0438 \u043a \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u0443 \u0438 Cortex Debug. \u0422\u0430\u043c \u0435\u0441\u0442\u044c \u0441\u0432\u043e\u0438 \u043d\u044e\u0430\u043d\u0441\u044b \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u0441 \u0432\u044b\u0437\u043e\u0432\u043e\u043c nm-\u043e\u0431\u0451\u0440\u0442\u043e\u043a \u0434\u043b\u044f gdb. <\/p>\n<details class=\"spoiler\">\n<summary>\u0412\u0430\u0439\u0431 \u043f\u043e\u0447\u0435\u043c\u0443 \u0438 \u0447\u0442\u043e \u0442\u0430\u043c \u0441 Cortex Debug  \u0438 \u0441\u0443\u0444\u0444\u0438\u043a\u0441\u0430\u043c\u0438 -nm<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0412 \u0441\u0432\u044f\u0437\u043a\u0435 <strong>Python-\u0441\u043a\u0440\u0438\u043f\u0442\u0430 <\/strong><code><strong>find_xpack.py<\/strong><\/code><strong> + <\/strong><code><strong>nm<\/strong><\/code><strong> + <\/strong><code><strong>Cortex-Debug<\/strong><\/code> \u0433\u043b\u0430\u0432\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u0435 VS Code \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e \u043d\u0430\u0445\u043e\u0434\u0438\u043b\u043e \u0443\u0442\u0438\u043b\u0438\u0442\u0443 <code>arm-none-eabi-nm<\/code> (\u0438 \u0441\u043e\u043f\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 <code>objdump<\/code>\/<code>gdb<\/code>) \u0438\u0437 \u0438\u0437\u043e\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0430\u043a\u0435\u0442\u0430 xPack \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u043f\u0440\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0438\u0445 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0439 <code>$PATH<\/code>.<\/p>\n<p>\u041d\u0438\u0436\u0435 \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u043d\u043e, \u0437\u0430\u0447\u0435\u043c Cortex-Debug \u043d\u0443\u0436\u0435\u043d <code>nm<\/code>, \u043f\u043e\u0447\u0435\u043c\u0443 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0431\u0435\u0437 <code>find_xpack.py<\/code> \u0438 \u043a\u0430\u043a \u0438\u043c\u0435\u043d\u043d\u043e Python-\u0441\u043a\u0440\u0438\u043f\u0442 \u0435\u0451 \u0440\u0435\u0448\u0430\u0435\u0442.<\/p>\n<p>1. \u0417\u0430\u0447\u0435\u043c Cortex-Debug \u043d\u0443\u0436\u0435\u043d <code>nm<\/code> \u0438 \u043f\u043e\u0447\u0435\u043c\u0443 \u043e\u043d \u043f\u0430\u0434\u0430\u0435\u0442<\/p>\n<p>\u041f\u0440\u0438 \u043d\u0430\u0436\u0430\u0442\u0438\u0438 F5 (\u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u043e\u0442\u043b\u0430\u0434\u043a\u0438) \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u0435 <strong>Cortex-Debug<\/strong> \u0435\u0449\u0435 <strong>\u0434\u043e \u0441\u0442\u0430\u0440\u0442\u0430 GDB<\/strong> \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442 \u0438\u0437 Node.js \u0443\u0442\u0438\u043b\u0438\u0442\u0443 <code>arm-none-eabi-nm<\/code> (\u0432\u043c\u0435\u0441\u0442\u0435 \u0441 <code>arm-none-eabi-objdump<\/code>), \u0447\u0442\u043e\u0431\u044b \u0440\u0430\u0441\u043f\u0430\u0440\u0441\u0438\u0442\u044c <code>.elf<\/code>-\u0444\u0430\u0439\u043b:<\/p>\n<ul>\n<li>\n<p>\u0438\u0437\u0432\u043b\u0435\u0447\u044c \u0430\u0434\u0440\u0435\u0441\u0430 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0445 \u0438 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 (\u0434\u043b\u044f \u043f\u0430\u043d\u0435\u043b\u0438 <strong>Live Watch<\/strong> \u0438 <strong>Peripherals<\/strong>);<\/p>\n<\/li>\n<li>\n<p>\u043d\u0430\u0439\u0442\u0438 \u0430\u0434\u0440\u0435\u0441\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0438 \u0442\u043e\u0447\u043a\u0438 \u0432\u0445\u043e\u0434\u0430 (\u0434\u043b\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 <code>runToEntryPoint<\/code>, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <code>main<\/code> \u0438\u043b\u0438 <code>Reset_Handler<\/code>);<\/p>\n<\/li>\n<li>\n<p>\u043f\u043e\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043a\u0430\u0440\u0442\u0443 \u043f\u0430\u043c\u044f\u0442\u0438 \u0438 \u0441\u0435\u043a\u0446\u0438\u0439.<\/p>\n<\/li>\n<\/ul>\n<p><strong>\u0412 \u0447\u0435\u043c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0441 xPack:<\/strong>\u041c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u043a\u0435\u0442\u043e\u0432 <code>xpm<\/code> \u0441\u0442\u0430\u0432\u0438\u0442 \u0442\u0443\u043b\u0447\u0435\u0439\u043d \u0438\u0437\u043e\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e \u0432 <code>~\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/&lt;\u0432\u0435\u0440\u0441\u0438\u044f&gt;\/.content\/bin\/<\/code> \u0438 <strong>\u043d\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u044d\u0442\u0443 \u043f\u0430\u043f\u043a\u0443 \u0432 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 <\/strong><code><strong>$PATH<\/strong><\/code>. \u041a\u043e\u0433\u0434\u0430 Cortex-Debug \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c <code>arm-none-eabi-nm<\/code> \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, Node.js \u0432\u044b\u0434\u0430\u0435\u0442 \u043e\u0448\u0438\u0431\u043a\u0443 <code><strong>spawn arm-none-eabi-nm ENOENT<\/strong><\/code> \u2014 \u043e\u0442\u043b\u0430\u0434\u043a\u0430 \u0441\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0435\u0449\u0435 \u0434\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0443.<\/p>\n<p>2. \u041a\u0430\u043a <code>find_xpack.py<\/code> \u0440\u0435\u0448\u0430\u0435\u0442 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 <code>nm<\/code> \u0434\u043b\u044f Cortex-Debug<\/p>\n<p>\u0412 \u043a\u043e\u0434\u0435 <code>find_xpack.py<\/code> \u0434\u043b\u044f \u0441\u0432\u044f\u0437\u043a\u0438 \u0441 Cortex-Debug \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u044b \u0442\u0440\u0438 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0445 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u0430:<\/p>\n<p>\u0410. \u041c\u0430\u043f\u043f\u0438\u043d\u0433 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0445 \u0438\u043c\u0435\u043d (<code>BARE_TOOL_KEYS<\/code>)<\/p>\n<p>\u0412 \u043d\u0430\u0447\u0430\u043b\u0435 \u0441\u043a\u0440\u0438\u043f\u0442\u0430 \u0437\u0430\u0434\u0430\u043d \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u043a\u043b\u044e\u0447\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043d\u0438\u043c\u0430\u0435\u0442 Cortex-Debug \u0432 <code>.vscode\/launch.json<\/code>:<\/p>\n<p>python<\/p>\n<pre><code>BARE_TOOL_KEYS = {    \"gdbPath\": \"arm-none-eabi-gdb\",    \"compilerPath\": \"arm-none-eabi-gcc\",    \"objdumpPath\": \"arm-none-eabi-objdump\",    \"nmPath\": \"arm-none-eabi-nm\",}<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 <code>launch.json<\/code> \u0443\u043a\u0430\u0437\u0430\u043d\u043e <code>\"nmPath\": \"arm-none-eabi-nm\"<\/code>, \u0441\u043a\u0440\u0438\u043f\u0442 \u0432\u043e\u0441\u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u044d\u0442\u043e \u043a\u0430\u043a \u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 \u0430\u0432\u0442\u043e\u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0431\u0438\u043d\u0430\u0440\u043d\u0438\u043a\u0430 \u0438\u0437 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u043e\u0433\u043e xPack.<\/p>\n<p>\u0411. \u0420\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u043f\u0443\u0442\u0438 \u043f\u0440\u0438 \u043e\u0431\u0445\u043e\u0434\u0435 JSON (<code>walk_and_update<\/code>)<\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 <code>find_xpack.py<\/code> \u0447\u0438\u0442\u0430\u0435\u0442 <code>.vscode\/launch.json<\/code>, \u043e\u043d \u0440\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0432\u0441\u0435 \u043a\u043b\u044e\u0447\u0438:<\/p>\n<p>python<\/p>\n<pre><code>if new_value is None and key in BARE_TOOL_KEYS:    if value == BARE_TOOL_KEYS[key] and \"\/\" not in value:        candidate = bin_dir \/ value        if candidate.is_file():            new_value = str(candidate)<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<ol>\n<li>\n<p>\u041d\u0430\u0445\u043e\u0434\u0438\u0442 \u0441\u0430\u043c\u0443\u044e \u0441\u0432\u0435\u0436\u0443\u044e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e <code>arm-none-eabi-gcc<\/code> (\u0447\u0435\u0440\u0435\u0437 <code>discover()<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u0411\u0435\u0440\u0435\u0442 \u0435\u0451 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e <code>bin_dir<\/code> (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>~\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/15.2.1-1.1.1\/.content\/bin<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442, \u0447\u0442\u043e \u0444\u0430\u0439\u043b <code>arm-none-eabi-nm<\/code> \u0440\u0435\u0430\u043b\u044c\u043d\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 (<a href=\"http:\/\/candidate.is\" rel=\"noopener nofollow\"><code>candidate.is<\/code><\/a><code>_file()<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u0417\u0430\u043c\u0435\u043d\u044f\u0435\u0442 \u0432 <code>launch.json<\/code> \u043a\u043e\u0440\u043e\u0442\u043a\u0443\u044e \u0441\u0442\u0440\u043e\u043a\u0443 <code>\"arm-none-eabi-nm\"<\/code> \u043d\u0430 \u043f\u0440\u044f\u043c\u043e\u0439 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0431\u0438\u043d\u0430\u0440\u043d\u0438\u043a\u0443.<\/p>\n<\/li>\n<\/ol>\n<p>\u0412. \u0410\u0432\u0442\u043e\u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u0441\u043c\u0435\u043d\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430 (<code>remap_xpack_path<\/code>)<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432 <code>launch.json<\/code> \u0443\u0436\u0435 \u0431\u044b\u043b \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u043d \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043e\u0442 \u0441\u0442\u0430\u0440\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 xPack (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>14.2.1<\/code>), \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0432 <code>remap_xpack_path<\/code> \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0441\u0435\u0433\u043c\u0435\u043d\u0442 <code>...\/xPacks\/...<\/code>, \u043e\u0442\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u0441\u0442\u0430\u0440\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0438 \u043f\u043e\u0434\u043c\u0435\u043d\u044f\u0435\u0442 \u0435\u0451 \u043d\u0430 \u043d\u043e\u0432\u0443\u044e, \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u044f \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c\u044b\u0439 \u0444\u043e\u0440\u043c\u0430\u0442 <code>${env:HOME}<\/code> \u0438\u043b\u0438 <code>~<\/code>, \u0435\u0441\u043b\u0438 \u043e\u043d \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435.<\/p>\n<hr\/>\n<p>3. \u041f\u043e\u0447\u0435\u043c\u0443 \u043f\u0440\u044f\u043c\u043e\u0439 \u043f\u0443\u0442\u044c \u0432 <code>nmPath<\/code> \u043b\u0443\u0447\u0448\u0435, \u0447\u0435\u043c <a href=\"http:\/\/nm-wrapper.sh\" rel=\"noopener nofollow\"><code>nm-wrapper.sh<\/code><\/a><\/p>\n<p>\u0412 \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 <code>find_xpack.py<\/code> \u0434\u043b\u044f <code>nm<\/code> (\u0432 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 \u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u0430\u043c\u0438) \u043d\u0430\u043c\u0435\u0440\u0435\u043d\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f <strong>\u043f\u0440\u044f\u043c\u0430\u044f \u0438\u043d\u044a\u0435\u043a\u0446\u0438\u044f \u043f\u0443\u0442\u0438 \u0432 <\/strong><code><strong>launch.json<\/strong><\/code>, \u0430 \u043d\u0435 \u043f\u0440\u043e\u043c\u0435\u0436\u0443\u0442\u043e\u0447\u043d\u044b\u0439 shell-\u0441\u043a\u0440\u0438\u043f\u0442 <a href=\"http:\/\/nm-wrapper.sh\" rel=\"noopener nofollow\"><code>nm-wrapper.sh<\/code><\/a>:<\/p>\n<ul>\n<li>\n<p><strong>\u041e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u0435 \u043b\u0438\u0448\u043d\u0438\u0445 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0432:<\/strong> Cortex-Debug \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442 <code>nm<\/code> \u043f\u0440\u0438 \u043a\u0430\u0436\u0434\u043e\u043c \u0441\u0442\u0430\u0440\u0442\u0435 \u043e\u0442\u043b\u0430\u0434\u043a\u0438. \u041f\u0440\u044f\u043c\u043e\u0439 \u0432\u044b\u0437\u043e\u0432 \u0431\u0438\u043d\u0430\u0440\u043d\u0438\u043a\u0430 \u0438\u0437 <code>.content\/bin\/arm-none-eabi-nm<\/code> \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043c\u0433\u043d\u043e\u0432\u0435\u043d\u043d\u043e \u0431\u0435\u0437 \u043d\u0430\u043a\u043b\u0430\u0434\u043d\u044b\u0445 \u0440\u0430\u0441\u0445\u043e\u0434\u043e\u0432 \u043d\u0430 \u0437\u0430\u043f\u0443\u0441\u043a <code>\/bin\/sh<\/code>.<\/p>\n<\/li>\n<li>\n<p><strong>\u0417\u0430\u0449\u0438\u0442\u0430 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0445 \u043e\u0431\u0435\u0440\u0442\u043e\u043a:<\/strong> \u0415\u0441\u043b\u0438 \u043f\u043e \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u043f\u0440\u0438\u0447\u0438\u043d\u0435 \u0432 <code>launch.json<\/code> \u0432\u0441\u0451 \u0436\u0435 \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u043d \u0441\u0432\u043e\u0439 \u0441\u043a\u0440\u0438\u043f\u0442 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>\"nmPath\": \"${workspaceFolder}\/tools\/<\/code><a href=\"http:\/\/nm-wrapper.sh\" rel=\"noopener nofollow\"><code>nm-wrapper.sh<\/code><\/a><code>\"<\/code>), \u0443\u0441\u043b\u043e\u0432\u0438\u0435 <code>\"\/\" not in value<\/code> \u0438 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u0435 \u0441\u0435\u0433\u043c\u0435\u043d\u0442\u0430 <code>\/xPacks\/<\/code> \u0437\u0430\u0441\u0442\u0430\u0432\u0438\u0442 <code>find_xpack.py<\/code> <strong>\u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0442\u044c<\/strong> \u044d\u0442\u0443 \u0441\u0442\u0440\u043e\u043a\u0443. \u0421\u0430\u043c wrapper \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c <code>ARM_XPACK_BIN_PATH<\/code> \u0438\u0437 <code>generated\/.xpack_cache.txt<\/code>.<\/p>\n<\/li>\n<\/ul>\n<hr\/>\n<\/div>\n<\/details>\n<p>\u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0432 xPack \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0441\u0442\u0430\u0440\u0442\u0430\u043d\u0443\u0442\u044c \u043e\u0442\u043b\u0430\u0434\u043a\u0443: <strong>\u042f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043b xpm install &#8212;global <a class=\"mention\" href=\"\/users\/xpack-dev-tools\">@xpack-dev-tools<\/a>\/arm-none-eabi-gcc@latest \u043f\u0440\u043e\u0432\u0435\u0440\u044c xpack gdb. \u041d\u0430\u0439\u0434\u0438 \u0435\u0433\u043e \u0432\u043d\u0430\u0447\u0430\u043b\u0435 \u0432 \u043f\u0430\u043f\u043a\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438<\/strong>.<\/p>\n<p>\u0421\u0440\u0430\u0437\u0443 \u0431\u0435\u0440\u0451\u043c \u043d\u0443\u0436\u043d\u044b\u0439 \u0432\u044b\u0432\u043e\u0434<\/p>\n<pre><code class=\"bash\">find ~\/.local\/xPacks -name \"arm-none-eabi-gdb\" -type f 2&gt;\/dev\/null<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<br \/>\/home\/timur\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/15.2.1-1.1.1\/.content\/bin\/arm-none-eabi-gdb &#8212; \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u044d\u0442\u043e\u0442 \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c \u0441 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c \u043f\u0440\u043e\u043c\u043f\u0442\u043e\u043c: <strong>\u0434\u0430\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 swd \u0438 \u043e\u0442\u043b\u0430\u0434\u043a\u0438 gdb<\/strong>.<\/p>\n<details class=\"spoiler\">\n<summary>\u0412\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u043e\u0442\u043b\u0430\u0434\u043a\u0438<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041e\u0442\u043b\u0438\u0447\u043d\u043e, \u043f\u0443\u0442\u044c \u043a xPack GDB (<code>15.2.1-1.1.1<\/code>) \u043d\u0430\u0439\u0434\u0435\u043d. \u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u044b \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 SWD-\u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u0430 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0432\u0430\u0448\u0435\u0433\u043e \u043f\u043e\u043b\u043d\u043e\u0433\u043e \u043f\u0443\u0442\u0438.<\/p>\n<p>1. \u0417\u0430\u043f\u0443\u0441\u043a SWD GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430 (\u0422\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u21161)<\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 \u043f\u0435\u0440\u0432\u043e\u0435 \u043e\u043a\u043d\u043e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430 \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0435 <code>probe-rs<\/code> \u0432 \u0440\u0435\u0436\u0438\u043c\u0435 GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0430 \u043f\u043e\u0440\u0442\u0443 <code>1337<\/code>:<\/p>\n<p>bash<\/p>\n<pre><code>probe-rs gdb --chip R7FA4M1AB --speed 100<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<p><em>(\u041e\u0441\u0442\u0430\u0432\u044c\u0442\u0435 \u044d\u0442\u043e \u043e\u043a\u043d\u043e \u043e\u0442\u043a\u0440\u044b\u0442\u044b\u043c \u2014 \u043e\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0442\u0440\u0430\u043d\u0441\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b GDB \u0432 SWD \u0447\u0435\u0440\u0435\u0437 ST-Link).<\/em><\/p>\n<hr\/>\n<p>2. \u0417\u0430\u043f\u0443\u0441\u043a \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0432 xPack GDB (\u0422\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u21162)<\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 \u0432\u0442\u043e\u0440\u043e\u0435 \u043e\u043a\u043d\u043e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430 \u0438 \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u043d\u0443\u0436\u043d\u044b\u0439 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439:<\/p>\n<p>bash<\/p>\n<pre><code>\/home\/timur\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/15.2.1-1.1.1\/.content\/bin\/arm-none-eabi-gdb path\/to\/firmware.elf \\  -ex \"target extended-remote :1337\" \\  -ex \"load\" \\  -ex \"monitor reset halt\"<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<ul>\n<li>\n<p><strong>\u0412\u0430\u0440\u0438\u0430\u043d\u0442 \u0410: \u041e\u0442\u043b\u0430\u0434\u043a\u0430 \u0441 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u043e\u0439 \u0444\u0430\u0439\u043b\u0430 <\/strong><code><strong>.elf<\/strong><\/code><strong> (\u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c\u044b\u0439)<\/strong><br \/>\u0417\u0430\u043c\u0435\u043d\u0438\u0432 <code>path\/to\/firmware.elf<\/code> \u043d\u0430 \u043f\u0443\u0442\u044c \u043a \u0432\u0430\u0448\u0435\u043c\u0443 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u043c\u0443 \u0444\u0430\u0439\u043b\u0443:<\/p>\n<\/li>\n<li>\n<p><strong>\u0412\u0430\u0440\u0438\u0430\u043d\u0442 \u0411: \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a \u0443\u0436\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0435\u043c\u0443 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0443 (\u0431\u0435\u0437 <\/strong><code><strong>.elf<\/strong><\/code><strong> \u0444\u0430\u0439\u043b\u0430)<\/strong><\/p>\n<\/li>\n<\/ul>\n<p>bash<\/p>\n<pre><code>\/home\/timur\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/15.2.1-1.1.1\/.content\/bin\/arm-none-eabi-gdb \\  -ex \"target extended-remote :1337\"<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<hr\/>\n<p>3. \u0411\u0430\u0437\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 <code>(gdb)<\/code><\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0432\u044b \u043e\u043a\u0430\u0436\u0435\u0442\u0435\u0441\u044c \u0432 \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0439 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 <code>(gdb)<\/code>. \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0434\u043b\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0447\u0438\u043f\u043e\u043c:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th colspan=\"undefined\">\n<p align=\"left\">\u041a\u043e\u043c\u0430\u043d\u0434\u0430<\/p>\n<\/th>\n<th colspan=\"undefined\">\n<p align=\"left\">\u0414\u0435\u0439\u0441\u0442\u0432\u0438\u0435<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>monitor reset halt<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0410\u043f\u043f\u0430\u0440\u0430\u0442\u043d\u044b\u0439 \u0441\u0431\u0440\u043e\u0441 \u0447\u0438\u043f\u0430 \u0438 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043d\u0430 \u043f\u0435\u0440\u0432\u043e\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>load<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0417\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 (<code>.elf<\/code>) \u0432\u043e \u0444\u043b\u0435\u0448-\u043f\u0430\u043c\u044f\u0442\u044c RA4M1<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>b main<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0442\u043e\u0447\u043a\u0443 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0430 (breakpoint) \u043d\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>main<\/code><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>c<\/code> (<code>continue<\/code>)<\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \/ \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>n<\/code> (<code>next<\/code>)<\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0428\u0430\u0433 \u0441 \u043e\u0431\u0445\u043e\u0434\u043e\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u0439 (Step Over)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>s<\/code> (<code>step<\/code>)<\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0428\u0430\u0433 \u0441 \u0437\u0430\u0445\u043e\u0434\u043e\u043c \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e (Step Into)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>info reg<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u041f\u043e\u043a\u0430\u0437\u0430\u0442\u044c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u0430 (<code>r0<\/code>\u2013<code>r15<\/code>, <code>pc<\/code>, <code>sp<\/code>)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>x\/10wx 0x00000000<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u041f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c 10 \u0441\u043b\u043e\u0432 (\u043f\u043e 32 \u0431\u0438\u0442\u0430) \u0438\u0437 \u043d\u0430\u0447\u0430\u043b\u0430 \u0444\u043b\u0435\u0448-\u043f\u0430\u043c\u044f\u0442\u0438<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>Ctrl + C<\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u041f\u0440\u0438\u043d\u0443\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0439\u0441\u044f \u043a\u043e\u0434<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code>q<\/code> (<code>quit<\/code>)<\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0412\u044b\u0439\u0442\u0438 \u0438\u0437 GDB<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<\/details>\n<p>\u0412 \u043f\u0435\u0440\u0432\u043e\u043c \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0441\u0435\u0441\u0441\u0438\u044e &#171;\u0441\u0435\u0440\u0432\u0435\u0440\u0430&#187;, \u043d\u0430\u043f\u043e\u0434\u043e\u0431\u0438\u0435 st-util \u0438\u043b\u0438 OpenOCD.<\/p>\n<pre><code class=\"bash\">probe-rs gdb --chip R7FA4M1AB --speed 100<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/0f\/84\/df\/0f84dfdc252d843e6a44ab0295e35aa1.png\" alt=\"\u0412\u0441\u0451 \u0432 \u043f\u043e\u0440\u044f\u0434\u043a\u0435 - \u0441\u043e\u0435\u0434\u0438\u043d\u0438\u043b\u0438\u0441\u044c\" title=\"\u0412\u0441\u0451 \u0432 \u043f\u043e\u0440\u044f\u0434\u043a\u0435 - \u0441\u043e\u0435\u0434\u0438\u043d\u0438\u043b\u0438\u0441\u044c\" width=\"460\" height=\"22\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/0f\/84\/df\/0f84dfdc252d843e6a44ab0295e35aa1.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/0f\/84\/df\/0f84dfdc252d843e6a44ab0295e35aa1.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/p>\n<div><figcaption>\u0412\u0441\u0451 \u0432 \u043f\u043e\u0440\u044f\u0434\u043a\u0435 &#8212; \u0441\u043e\u0435\u0434\u0438\u043d\u0438\u043b\u0438\u0441\u044c<\/figcaption><\/div>\n<\/figure>\n<p>\u0412\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u043f\u044b\u0442\u0430\u0435\u043c\u0441\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u043e\u043c \u0431\u0435\u0437 elf-\u0444\u0430\u0439\u043b\u0430 (\u043f\u043e\u043a\u0430 \u0443 \u043d\u0430\u0441 \u043d\u0435\u0442 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438) <\/p>\n<pre><code class=\"bash\">\/home\/timur\/.local\/xPacks\/@xpack-dev-tools\/arm-none-eabi-gcc\/15.2.1-1.1.1\/.content\/bin\/arm-none-eabi-gdb \\  -ex \"target extended-remote :1337\"<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>\u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0432\u0438\u0434\u0438\u043c \u043a\u043e\u043d\u0441\u043e\u043b\u044c GDB<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/f3\/62\/64\/f362645950a640c05b0c8ce562c80bf2.png\" width=\"662\" height=\"339\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/f3\/62\/64\/f362645950a640c05b0c8ce562c80bf2.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/f3\/62\/64\/f362645950a640c05b0c8ce562c80bf2.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0438 \u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u043d\u043e \u043f\u0435\u0440\u0435\u0434 \u044d\u0442\u0438\u043c \u0441\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u044d\u0442\u043e\u0442 \u0432\u044b\u0432\u043e\u0434 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c. \u041f\u043e\u0442\u043e\u043c \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u0440\u043e\u043c\u043f\u0442: <strong>\u043e\u0442\u043b\u0430\u0434\u043a\u0430 \u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0438 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c<\/strong>.\u043f<\/p>\n<details class=\"spoiler\">\n<summary>\u0428\u043f\u0430\u0440\u0433\u0430\u043b\u043a\u0430 \u043e\u0442 \u043c\u043e\u0434\u0435\u043b\u0438<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0414\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0432 \u0440\u0435\u0436\u0438\u043c\u0435 <strong>\u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430<\/strong>, <strong>\u0437\u0430\u043f\u0443\u0441\u043a\u0430<\/strong> \u0438 <strong>\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438<\/strong> \u043a\u043e\u0434\u0430 \u0432 \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0439 \u0441\u0435\u0441\u0441\u0438\u0438 <code>(gdb)<\/code> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043d\u0430\u0431\u043e\u0440 \u043a\u043e\u043c\u0430\u043d\u0434.<\/p>\n<p>1. \u0412\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0443\u0434\u043e\u0431\u043d\u043e\u0433\u043e \u043e\u043a\u043d\u0430 \u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430 (TUI-\u0440\u0435\u0436\u0438\u043c)<\/p>\n<p>\u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 <code>(gdb)<\/code> \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<p>gdb<\/p>\n<pre><code>layout asm<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<ul>\n<li>\n<p>\u042d\u043a\u0440\u0430\u043d \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0441\u044f: \u0441\u0432\u0435\u0440\u0445\u0443 \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u044f\u0442\u0441\u044f \u043c\u0430\u0448\u0438\u043d\u043d\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 \u0441 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u0435\u043c <code>&gt;<\/code> \u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 (<code>$pc<\/code>), \u0441\u043d\u0438\u0437\u0443 \u043e\u0441\u0442\u0430\u043d\u0435\u0442\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430 <code>(gdb)<\/code>.<\/p>\n<\/li>\n<li>\n<p>\u0427\u0442\u043e\u0431\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043e\u043a\u043d\u043e \u0441 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u043c\u0438 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u0430 \u0441\u0432\u0435\u0440\u0445\u0443, \u0432\u0432\u0435\u0434\u0438\u0442\u0435:<\/p>\n<\/li>\n<\/ul>\n<p>gdb<\/p>\n<pre><code>layout regs<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<ul>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u044d\u043a\u0440\u0430\u043d\u0430 \u0441\u043e\u0431\u044c\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u0432\u043e\u0434\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0439, \u043d\u0430\u0436\u043c\u0438\u0442\u0435 <code><strong>Ctrl + L<\/strong><\/code> \u0434\u043b\u044f \u043f\u0435\u0440\u0435\u0440\u0438\u0441\u043e\u0432\u043a\u0438 \u0438\u043b\u0438 \u0432\u044b\u0439\u0434\u0438\u0442\u0435 \u0438\u0437 TUI \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <code>tui disable<\/code>.<\/p>\n<\/li>\n<\/ul>\n<p><em>(\u0410\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u0430 \u0431\u0435\u0437 \u043f\u0441\u0435\u0432\u0434\u043e\u0433\u0440\u0430\u0444\u0438\u043a\u0438 \u2014 \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 10 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c: <\/em><code><em>x\/10i $pc<\/em><\/code><em>).<\/em><\/p>\n<hr\/>\n<p>2. \u0417\u0430\u043f\u0443\u0441\u043a, \u043f\u0430\u0443\u0437\u0430 \u0438 \u0441\u0431\u0440\u043e\u0441 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th colspan=\"undefined\">\n<p align=\"left\">\u041a\u043e\u043c\u0430\u043d\u0434\u0430<\/p>\n<\/th>\n<th colspan=\"undefined\">\n<p align=\"left\">\u0427\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code><strong>c<\/strong><\/code> <em>(continue)<\/em><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\"><strong>\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442<\/strong> \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u043d\u0430 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0435.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code><strong>Ctrl + C<\/strong><\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\"><strong>\u041e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442<\/strong> (\u0441\u0442\u0430\u0432\u0438\u0442 \u043d\u0430 \u043f\u0430\u0443\u0437\u0443) \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0439\u0441\u044f \u043a\u043e\u0434 \u0432 \u043b\u044e\u0431\u043e\u0439 \u043c\u043e\u043c\u0435\u043d\u0442.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code><strong>monitor reset halt<\/strong><\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\"><strong>\u0421\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442<\/strong> \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0438 \u0441\u0440\u0430\u0437\u0443 \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0435\u0433\u043e \u043d\u0430 \u0441\u0430\u043c\u043e\u0439 \u043f\u0435\u0440\u0432\u043e\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 (\u0432\u0435\u043a\u0442\u043e\u0440 \u0441\u0431\u0440\u043e\u0441\u0430 <code>Reset_Handler<\/code>).<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td colspan=\"undefined\">\n<p align=\"left\"><code><strong>monitor reset<\/strong><\/code><\/p>\n<\/td>\n<td colspan=\"undefined\">\n<p align=\"left\">\u0421\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0438 \u0441\u0440\u0430\u0437\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<hr\/>\n<p>3. \u041f\u043e\u0448\u0430\u0433\u043e\u0432\u043e\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 (\u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430)<\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d (\u043d\u0430 \u043f\u0430\u0443\u0437\u0435):<\/p>\n<ul>\n<li>\n<p><code><strong>si<\/strong><\/code> <em>(stepi)<\/em> \u2014 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c <strong>\u043e\u0434\u043d\u0443 \u043c\u0430\u0448\u0438\u043d\u043d\u0443\u044e \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e<\/strong> \u0441 \u0437\u0430\u0445\u043e\u0434\u043e\u043c \u0432\u043d\u0443\u0442\u0440\u044c \u043f\u043e\u0434\u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c (<code>BL<\/code> \/ <code>BLX<\/code>).<\/p>\n<\/li>\n<li>\n<p><code><strong>ni<\/strong><\/code> <em>(nexti)<\/em> \u2014 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c <strong>\u043e\u0434\u043d\u0443 \u043c\u0430\u0448\u0438\u043d\u043d\u0443\u044e \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e<\/strong>, \u043f\u0435\u0440\u0435\u0448\u0430\u0433\u043d\u0443\u0432 \u0432\u044b\u0437\u043e\u0432 \u043f\u043e\u0434\u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0446\u0435\u043b\u0438\u043a\u043e\u043c.<\/p>\n<\/li>\n<li>\n<p><code><strong>b <em>0x00000630<\/em><\/strong><\/code><em> \u2014 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0430\u043f\u043f\u0430\u0440\u0430\u0442\u043d\u0443\u044e \u0442\u043e\u0447\u043a\u0443 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0430 (breakpoint) \u043d\u0430 \u0442\u043e\u0447\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u0432 \u043f\u0430\u043c\u044f\u0442\u0438 (\u0437\u0432\u0435\u0437\u0434\u043e\u0447\u043a\u0430 <\/em> \u043f\u0435\u0440\u0435\u0434 \u0430\u0434\u0440\u0435\u0441\u043e\u043c \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u0430).<\/p>\n<\/li>\n<li>\n<p><code><strong>info break<\/strong><\/code> \u2014 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0445 \u0442\u043e\u0447\u0435\u043a \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0430.<\/p>\n<\/li>\n<li>\n<p><code><strong>delete 1<\/strong><\/code> \u2014 \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0442\u043e\u0447\u043a\u0443 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0430 \u21161 (\u0438\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e <code>delete<\/code> \u0434\u043b\u044f \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0432\u0441\u0435\u0445).<\/p>\n<\/li>\n<\/ul>\n<hr\/>\n<p>4. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u0438 \u043f\u0430\u043c\u044f\u0442\u0438<\/p>\n<ul>\n<li>\n<p><code><strong>info reg<\/strong><\/code> \u2014 \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432\u0441\u0435\u0445 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u044f\u0434\u0440\u0430 Cortex-M4 (<code>r0<\/code>\u2013<code>r12<\/code>, <code>sp<\/code>, <code>lr<\/code>, <code>pc<\/code>, <code>xpsr<\/code>).<\/p>\n<\/li>\n<li>\n<p><code><strong>p\/x $r0<\/strong><\/code> \u2014 \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>r0<\/code>) \u0432 \u0448\u0435\u0441\u0442\u043d\u0430\u0434\u0446\u0430\u0442\u0435\u0440\u0438\u0447\u043d\u043e\u043c \u0444\u043e\u0440\u043c\u0430\u0442\u0435.<\/p>\n<\/li>\n<li>\n<p><code><strong>x\/16wx $sp<\/strong><\/code> \u2014 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c 16 \u0441\u043b\u043e\u0432 (\u043f\u043e 32 \u0431\u0438\u0442\u0430) \u0438\u0437 \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0432\u0435\u0440\u0448\u0438\u043d\u044b \u0441\u0442\u0435\u043a\u0430.<\/p>\n<\/li>\n<\/ul>\n<\/div>\n<\/details>\n<p>\u041f\u0438\u0448\u0435\u043c <em>layout asm<\/em>, \u0437\u0430\u0442\u0435\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <em>c<\/em>. \u0421\u043f\u0443\u0441\u0442\u044f \u043f\u0430\u0440\u0443 \u0441\u0435\u043a\u0443\u043d\u0434 \u0436\u043c\u0451\u043c Ctrl+C &#8212; \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c. \u0427\u0442\u043e \u043c\u044b \u0438 \u0432\u0438\u0434\u0438\u043c. \u0414\u0430\u043b\u0435\u0435 \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u044d\u0442\u043e\u0442 \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c<\/p>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/81\/6e\/77\/816e77534bd0018408ee4c80302a8a4b.png\" width=\"482\" height=\"602\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/81\/6e\/77\/816e77534bd0018408ee4c80302a8a4b.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/81\/6e\/77\/816e77534bd0018408ee4c80302a8a4b.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p>\u0412\u044b\u0432\u043e\u0434 \u043c\u043e\u0434\u0435\u043b\u0438 \u043f\u043e \u043b\u0438\u0441\u0442\u0438\u043d\u0433\u0443:<\/p>\n<details class=\"spoiler\">\n<summary>\u0418\u0433\u0440\u044b \u0441 \u043a\u043e\u043f\u0438\u043f\u0430\u0441\u0442\u043e\u043c \u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430<\/summary>\n<div class=\"spoiler__content\">\n<p><strong>\u041e\u0442\u043b\u0430\u0434\u043a\u0430 \u0432 \u0440\u0435\u0436\u0438\u043c\u0435 \u0434\u0438\u0437\u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e<\/strong> \u2014 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f (<code>c<\/code>), \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e \u043f\u0440\u0435\u0440\u044b\u0432\u0430\u043d\u0438\u044e (<code>Ctrl+C<\/code>), \u0430 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c \u043a\u043e\u043c\u0430\u043d\u0434 (<code>PC: 0x66c<\/code>) \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f \u0432 \u043e\u043a\u043d\u0435 \u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u0430.<\/p>\n<p>\u0427\u0442\u043e \u0441\u0435\u0439\u0447\u0430\u0441 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u0447\u0438\u043f\u0435<\/p>\n<ul>\n<li>\n<p><strong>\u0412\u044b \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0435\u0441\u044c \u0432\u043d\u0443\u0442\u0440\u0438 \u0437\u0430\u0432\u043e\u0434\u0441\u043a\u043e\u0433\u043e \u0437\u0430\u0433\u0440\u0443\u0437\u0447\u0438\u043a\u0430 (Bootloader) Arduino UNO R4 Minima<\/strong> (\u0430\u0434\u0440\u0435\u0441\u0430 \u0432 \u043d\u0430\u0447\u0430\u043b\u0435 \u0444\u043b\u0435\u0448-\u043f\u0430\u043c\u044f\u0442\u0438 <code>0x00000000<\/code> \u2013 <code>0x00003FFF<\/code>).<\/p>\n<\/li>\n<li>\n<p>\u041e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043d\u0430 \u043e\u0434\u043d\u043e\u0439 \u0438 \u0442\u043e\u0439 \u0436\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 (<code>0x66c<\/code>), \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0437\u0430\u0433\u0440\u0443\u0437\u0447\u0438\u043a \u043a\u0440\u0443\u0442\u0438\u0442\u0441\u044f \u0432 \u0431\u0435\u0441\u043a\u043e\u043d\u0435\u0447\u043d\u043e\u043c \u0446\u0438\u043a\u043b\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u043a\u043e\u043c\u0430\u043d\u0434 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 \u043f\u043e USB\/UART (\u043e\u0431\u044b\u0447\u043d\u043e \u044d\u0442\u043e \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442, \u0435\u0441\u043b\u0438 \u0432 \u043f\u0430\u043c\u044f\u0442\u0438 \u0435\u0449\u0435 \u043d\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0441\u043a\u0435\u0442\u0447\u0430 \u0438\u043b\u0438 \u043d\u0430\u0436\u0430\u0442\u0430 \u0434\u0432\u043e\u0439\u043d\u0430\u044f \u043a\u043d\u043e\u043f\u043a\u0430 \u0441\u0431\u0440\u043e\u0441\u0430).<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0438 \u0432\u0440\u043e\u0434\u0435 <code>0x67c lsls r0, r5, #22<\/code> \u0438\u043b\u0438 <code>0x68c lsrs r4, r1, #26<\/code> \u2014 \u044d\u0442\u043e \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438, \u0430 <strong>32-\u0431\u0438\u0442\u043d\u044b\u0435 \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u044b (\u0430\u0434\u0440\u0435\u0441\u0430 \u043f\u0435\u0440\u0438\u0444\u0435\u0440\u0438\u0439\u043d\u044b\u0445 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432)<\/strong> \u0432 \u043f\u0443\u043b\u0435 \u043b\u0438\u0442\u0435\u0440\u0430\u043b\u043e\u0432 (Literal Pool), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u044e\u0442\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438 <code>ldr r2, [pc, #12]<\/code> \u0438 <code>ldr r3, [pc, #8]<\/code>. \u0423\u0432\u0438\u0434\u0435\u0442\u044c \u0438\u0445 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <code>x\/wx 0x67c<\/code> (\u044d\u0442\u043e \u0431\u0443\u0434\u0443\u0442 \u0430\u0434\u0440\u0435\u0441\u0430 \u0438\u0437 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 SRAM <code>0x2000xxxx<\/code> \u0438\u043b\u0438 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 <code>0x400xxxxx<\/code>).<\/p>\n<\/li>\n<\/ul>\n<p>\u041f\u043e\u043b\u0435\u0437\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0434\u043b\u044f \u0430\u043d\u0430\u043b\u0438\u0437\u0430 \u043f\u0440\u044f\u043c\u043e \u0441\u0435\u0439\u0447\u0430\u0441<\/p>\n<ul>\n<li>\n<p><strong>\u041f\u043e\u0448\u0430\u0433\u043e\u0432\u043e \u043f\u0440\u043e\u0439\u0442\u0438 \u0446\u0438\u043a\u043b:<\/strong> \u0412\u0432\u0435\u0434\u0438\u0442\u0435 <code>si<\/code> \u0438 \u043d\u0430\u0436\u0438\u043c\u0430\u0439\u0442\u0435 <code>Enter<\/code> (\u043f\u0443\u0441\u0442\u043e\u0439 \u0432\u0432\u043e\u0434 \u0432 GDB \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u0442 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443), \u0447\u0442\u043e\u0431\u044b \u043d\u0430\u0431\u043b\u044e\u0434\u0430\u0442\u044c, \u043a\u0430\u043a \u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u044b \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b.<\/p>\n<\/li>\n<li>\n<p><strong>\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u0447\u0442\u043e \u043b\u0435\u0436\u0438\u0442 \u0432 \u043f\u0443\u043b\u0435 \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442 \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443 <\/strong><code><strong>0x67c<\/strong><\/code><strong>:<\/strong><\/p>\n<\/li>\n<\/ul>\n<p>gdb<\/p>\n<pre><code>x\/wx 0x67c<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>Use code with caution.<\/p>\n<p>gdb<\/p>\n<pre><code>layout regs<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<ul>\n<li>\n<p><strong>\u041f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043d\u0430 \u044d\u043a\u0440\u0430\u043d \u0441 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u043c\u0438 \u0438 \u0430\u0441\u0441\u0435\u043c\u0431\u043b\u0435\u0440\u043e\u043c \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e:<\/strong><\/p>\n<\/li>\n<\/ul>\n<\/div>\n<\/details>\n<p>\u0420\u0430\u0431\u043e\u0442\u043e\u0441\u043f\u043e\u0441\u043e\u0431\u043d\u043e\u0441\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u0430. \u0412 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u043d\u0443\u043b\u044f \u043f\u043e\u0434 \u044d\u0442\u043e\u0442 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440. <\/p>\n<\/div>\n<p>\u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/1113432\/\">https:\/\/habr.com\/ru\/articles\/1113432\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0441 \u043d\u0443\u043b\u044f \u0438 \u043f\u043e\u043b\u0435\u0437\u043d\u0443\u044e \u0443\u0442\u0438\u043b\u0438\u0442\u0443 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0435\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438. \u041a\u043b\u044e\u0447\u0435\u0432\u044b\u0435 \u0441\u043b\u043e\u0432\u0430: xPack, GDB, probe-rs, VSCode, Cortex Debug. \u041c\u043e\u0434\u0435\u043b\u044c: \u0434\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u043b\u044e\u0431\u0430\u044f &#8212; \u0410\u043b\u0438\u0441\u0430, \u0413\u0438\u0433\u0430 \u0427\u0430\u0442 \u0438 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435. SourceCraft \u0438\u043b\u0438 GigaCode \u043e\u0441\u0442\u0430\u0432\u0438\u043c \u043d\u0430\u043f\u043e\u0442\u043e\u043c.\u0422\u0430\u043a \u043a\u0430\u043a \u043b\u0435\u043d\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0438\u043c\u044f \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0441 \u0444\u043e\u0442\u043e -\u0441\u0440\u0430\u0437\u0443 \u0432\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u0435\u0433\u043e, \u043c\u0443\u043b\u044c\u0442\u0438\u043c\u043e\u0434\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c, \u043e\u0434\u043d\u0430\u043a\u043e. text R7FA4M1 AB3CFM 527A200 Use code with caution. \u042d\u0442\u043e 32-\u0440\u0430\u0437\u0440\u044f\u0434\u043d\u044b\u0439 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 Renesas RA4M1 (\u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430 Arm Cortex-M4, 48 \u041c\u0413\u0446), \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u043d\u0430 \u043f\u043b\u0430\u0442\u0435, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0439 \u0441 Arduino UNO R4 Minima.\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 &#171;\u043a\u043b\u043e\u043d\u0430 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e JTAG-\u0430\u0434\u0430\u043f\u0442\u0435\u0440\u0430&#187; \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043f\u043e \u0441\u0445\u0435\u043c\u0435\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 &#8212; \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u044b\u0432\u043e\u0434 UART \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 SWD, \u0447\u0442\u043e \u043f\u043e\u0442\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u041f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c lsusb:\u0412\u0438\u0434\u0438\u043c \u0447\u0442\u043e \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u0441 \u0430\u0434\u0440\u0435\u0441\u043e\u043c 0483:3748  \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c st-util \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0432 sudo apt update &amp;&amp; sudo apt install stlink-tools\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0421\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043e\u0441\u0446\u0438\u043b\u043b\u043e\u0433\u0440\u0430\u0444\u043e\u043c &#8212; \u0441\u0438\u0433\u043d\u0430\u043b ~RST \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0438\u043c\u043f\u0443\u043b\u044c\u0441\u043e\u043c \u0432 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u0439 \u043d\u043e\u043b\u044c \u043d\u0430 \u0442\u0430\u043a\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u0445\u041f\u0438\u0448\u0435\u043c \u0432\u0430\u0439\u0431 \u0441 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435\u043c (\u043a\u043e\u043f\u0438\u043f\u0430\u0441\u0442), \u0434\u0430\u043b\u0435\u0435 \u043f\u0438\u0448\u0435\u043c \u043f\u0440\u043e\u043c\u043f\u0442 different tools.\u0412\u0430\u0440\u0438\u0430\u043d\u0442\u044b1. \u0418\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u0434\u043b\u044f \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0438 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 \u043f\u043e SWD (\u0437\u0430\u043c\u0435\u043d\u0430 st-util \/ GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430)\u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0435\u0441\u044c \u043a \u043f\u0438\u043d\u0430\u043c SWDIO \u0438 SWCLK (\u043d\u0430 \u0432\u0430\u0448\u0435\u0439 \u043f\u043b\u0430\u0442\u0435 \u044d\u0442\u043e 6-\u043f\u0438\u043d\u043e\u0432\u044b\u0439 \u0440\u0430\u0437\u044a\u0435\u043c SWD \/ ICSP \u0440\u044f\u0434\u043e\u043c \u0441 \u0447\u0438\u043f\u043e\u043c):probe-rs \u2014 \u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043d\u0430 Rust. \u041e\u043d\u0430 \u0443\u043c\u0435\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0441 \u043a\u043b\u043e\u043d\u0430\u043c\u0438 ST-Link V2 (\u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b ST-Link \u0434\u043b\u044f \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0445 ARM Cortex-M \u0447\u0438\u043f\u043e\u0432) \u0438 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u0443\u044e \u0431\u0430\u0437\u0443 \u0442\u0430\u0440\u0433\u0435\u0442\u043e\u0432 \u0434\u043b\u044f R7FA4M1AB.\u0417\u0430\u043f\u0443\u0441\u043a GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430: probe-rs gdb &#8212;chip R7FA4M1AB\u041f\u0440\u043e\u0448\u0438\u0432\u043a\u0430: probe-rs download &#8212;chip R7FA4M1AB firmware.elfpyOCD \u2014 \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043d\u0430 Python, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0449\u0430\u044f ST-Link V2, CMSIS-DAP \u0438 J-Link. \u0422\u0440\u0435\u0431\u0443\u0435\u0442 \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 CMSIS-\u043f\u0430\u043a\u0435\u0442\u0430 Renesas.\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 \u0447\u0438\u043f\u0430: pyocd pack install R7FA4M1AB\u0417\u0430\u043f\u0443\u0441\u043a GDB-\u0441\u0435\u0440\u0432\u0435\u0440\u0430: pyocd gdbserver -t R7FA4M1ABOpenOCD (\u0444\u043e\u0440\u043a \u043e\u0442 Renesas) \u2014 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a, \u043d\u043e \u0434\u043b\u044f RA4M1 \u043b\u0443\u0447\u0448\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u0435\u0442\u043a\u0443 OpenOCD \u043e\u0442 Renesas, \u0442\u0430\u043a \u043a\u0430\u043a \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0444\u043b\u0435\u0448-\u043f\u0430\u043c\u044f\u0442\u0438 \u0441\u0435\u0440\u0438\u0438 RA \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u043f\u043e\u043b\u043d\u043e\u0439. \u041f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b cmsis-dap, jlink \u0438 stlink.SEGGER J-Link (JLinkGDBServer) \u2014 \u043f\u0440\u043e\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f \u043e\u0442\u043b\u0430\u0434\u043a\u0438 ARM. \u041e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0441 Renesas RA4M1 \u0438 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c \u0441 \u043b\u043e\u0433\u0438\u043a\u043e\u0439 \u043e\u0442 1.2 \u0412 \u0434\u043e 5 \u0412.\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c probe-rs. \u041f\u0438\u0448\u0435\u043c probe-rs install, \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0431\u0443\u0434\u0435\u0442 \u0434\u0430\u043d \u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u0421\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u043e\u043d\u043b\u0430\u0439\u043d-\u043c\u043e\u0434\u0435\u043b\u0438 \u0434\u0430\u044e\u0442 \u0431\u0438\u0442\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430 \u0438 IP, \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u0441 \u0446\u0435\u043b\u044c\u044e \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438, \u043f\u043e\u044d\u0442\u043e\u043c\u0443, \u0430\u0434\u0440\u0435\u0441\u0430 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0432\u0432\u043e\u0434\u0438\u0442\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0438\u043b\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0447\u0442\u043e \u043d\u0435\u0442 \u043e\u0448\u0438\u0431\u043e\u043a:curl -LsSf https:\/\/github.com\/probe-rs\/probe-rs\/releases\/latest\/download\/probe-rs-tools-installer.sh | shsource $HOME\/.cargo\/env,\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c\u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442:\u0421\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435\u041e\u0442\u043b\u0438\u0447\u043d\u043e, \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0432\u0438\u0434\u0438\u0442 \u0432\u0430\u0448 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430\u0442\u043e\u0440 (STLink V2 &#8212; 0483:3748:29). \u042d\u0442\u043e \u043a\u043b\u043e\u043d ST-Link V2, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 probe-rs \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442.\u0422\u0435\u043f\u0435\u0440\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0448\u0430\u0433 \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0438 \u0441\u0432\u044f\u0437\u0438 \u0441 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u043c Renesas RA4M1:probe-rs info &#8212;chip R7FA4M1AB\u041f\u044b\u0442\u0430\u0435\u043c\u0441\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f: probe-rs info &#8212;chip R7FA4M1AB\u041a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u044b\u0432\u043e\u0434 \u0432 \u043c\u043e\u0434\u0435\u043b\u044c \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439, \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435:\u041e\u0448\u0438\u0431\u043a\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044fUse code with caution.\u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0441\u043d\u0438\u0437\u0438\u0442\u044c \u0447\u0430\u0441\u0442\u043e\u0442\u0443 \u0442\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f SWD \u0434\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u043e 100 \u043a\u0413\u0446):\u041f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u0438\u043d\u0430 GND \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043e\u0440\u043f\u0443\u0441\u0430 USB-C \u0438 \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c probe-rs info &#8212;speed 100 \u0441 \u0437\u0430\u043c\u043a\u043d\u0443\u0442\u044b\u043c \u043d\u0430 \u0437\u0435\u043c\u043b\u044e \u043a\u043e\u043d\u0442\u0430\u043a\u0442\u043e\u043c BOOT (Pin 1). \u041d\u0430\u043f\u0438\u0448\u0438\u0442\u0435, \u043a\u0430\u043a\u043e\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u0435\u0440\u043d\u0435\u0442 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b.\u0417\u0430\u0431\u0435\u0433\u0430\u044f \u0432\u043f\u0435\u0440\u0451\u0434 \u043c\u043e\u0436\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u0447\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c. \u0414\u0430\u0451\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 probe-rs info &#8212;speed 100 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c:\u041e\u0442\u043b\u0438\u0447\u043d\u043e. \u0422\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0441\u043e\u043e\u0431\u0449\u0438\u0442\u044c, \u0447\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c SWD. I have the SWD interface. \u0438 \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u044d\u0442\u0438\u043c \u0432\u044b\u0432\u043e\u0434 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u044b. \u041f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c xpack \u0434\u043b\u044f ARM. \u0415\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u0437\u044f\u0442\u044c \u0437\u0434\u0435\u0441\u044c.  \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u0442\u0430\u0432\u0438\u043c NPM \u0437\u0430\u0442\u0435\u043c XPM \u043f\u043e\u0442\u043e\u043c \u0443\u0436\u0435 xPack (\u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e xpm install &#8212;global @xpack-dev-tools\/arm-none-eabi-gcc@latest \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u043a\u043e\u043f\u0438\u043f\u0430\u0441\u0442\u043e\u043c \u0441 \u0441\u0430\u0439\u0442\u0430) sudo apt install npmsudo npm install &#8212;location=global xpm@latestxpm install @xpack-dev-tools\/arm-none-eabi-gcc@15.2.1-1.1.1 &#8212;verbose &#8212;location=global\u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043f\u043e\u0438\u0441\u043a\u043e\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430, \u043b\u0443\u0447\u0448\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0430\u0439\u0431 \u043f\u043e \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u043c\u0443 \u043f\u043e\u0438\u0441\u043a\u0443 \u043f\u0443\u0442\u0435\u0439. \u041e\u043f\u0443\u0441\u043a\u0430\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0438\u0435 \u0432\u044b\u043a\u043b\u0430\u0434\u043a\u0438 \u0441\u0440\u0430\u0437\u0443 \u0441\u0430\u043c\u043c\u0430\u0440\u0438 \u043f\u043e \u043a\u043e\u0434\u0443. \u042d\u0442\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043d\u0430\u0439\u0442\u0438 \u043f\u0443\u0442\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0435 \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0432\u044b\u0437\u043e\u0432\u0430 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u043e\u0432, \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a\u043e\u0432 \u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a. \u0422\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0437\u0430\u0445\u0430\u0440\u0434\u043a\u043e\u0436\u0435\u043d\u043d\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438. \u0421\u043a\u0440\u0438\u043f\u0442 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043d\u0430\u0439\u0442\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f.\u0423\u0442\u0438\u043b\u0438\u0442\u044b \u043f\u043e\u0438\u0441\u043a\u0430 xPackShell-\u043e\u0431\u0432\u044f\u0437\u043a\u0430 (shell wrapper script)\u042d\u0442\u043e\u0442 \u0441\u043a\u0440\u0438\u043f\u0442 \u2014 POSIX-\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u0430\u044f shell-\u043e\u0431\u0435\u0440\u0442\u043a\u0430 (find_xpack.sh), \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 Python \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0435\u043c\u0443 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u043c\u0435\u0441\u0442\u0435 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 find_xpack.py.\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u0438 \u043b\u043e\u0433\u0438\u043a\u0430 \u0440\u0430\u0431\u043e\u0442\u044b\u0421\u0442\u0440\u043e\u0433\u0438\u0439 \u0440\u0435\u0436\u0438\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f (set -eu)\u041f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u043f\u0440\u0438 \u043b\u044e\u0431\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b (-e) \u0438\u043b\u0438 \u043f\u0440\u0438 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0438 \u043a \u043d\u0435\u043e\u0431\u044a\u044f\u0432\u043b\u0435\u043d\u043d\u043e\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 (-u).\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u0412\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u043f\u0430\u043f\u043a\u0435, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0441\u0430\u043c find_xpack.sh, \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e \u043e\u0442 \u0442\u043e\u0433\u043e, \u0438\u0437 \u043a\u0430\u043a\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u043e\u043d \u0431\u044b\u043b \u0432\u044b\u0437\u0432\u0430\u043d. \u042d\u0442\u043e \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043b\u0435\u0436\u0430\u0449\u0438\u0439 \u0440\u044f\u0434\u043e\u043c find_xpack.py \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0439\u0434\u0435\u043d.\u041f\u043e\u0438\u0441\u043a \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0430 Python\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 python3 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 (PATH).\u0415\u0441\u043b\u0438 python3 \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d, \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c python.\u0415\u0441\u043b\u0438 \u043e\u0431\u0430 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0442, \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0435 \u0432 stderr \u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u0435\u0442\u0441\u044f \u0441 \u043a\u043e\u0434\u043e\u043c 1.\u0414\u0435\u043b\u0435\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f (exec)\u0417\u0430\u043c\u0435\u043d\u044f\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 shell \u043d\u0430 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 Python (exec), \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u044f find_xpack.py \u0441 \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0435\u0439 \u0432\u0441\u0435\u0445 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 (&#171;$@&#187;), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#8212;project-dir.\u041a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f\u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432 $HOME\/.armscr\/find_xpack.sh \u043f\u0440\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f (make toolchain-setup).\u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0438\u0437 Makefile \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 xPack \u0432 \u0440\u0430\u043c\u043a\u0430\u0445 \u0441\u0431\u043e\u0440\u043a\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 (\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u043f\u043e\u0434 ARM-\u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0443).\u041f\u0438\u0442\u043e\u043d-\u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u043e\u0438\u0441\u043a\u0430\u0421\u043a\u0440\u0438\u043f\u0442 find_xpack.py \u2014 \u044d\u0442\u043e \u0430\u0432\u0442\u043e\u043d\u043e\u043c\u043d\u0430\u044f \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430 xPack ARM GNU (arm-none-eabi-gcc) \u0438 \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0435\u0433\u043e \u043f\u0443\u0442\u0435\u0439 \u043c\u0435\u0436\u0434\u0443 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439 \u0441\u0431\u043e\u0440\u043a\u0438 (Makefile) \u0438 \u0441\u0440\u0435\u0434\u043e\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 (VS Code).\u041d\u0438\u0436\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u044b\u0439 \u0440\u0430\u0437\u0431\u043e\u0440 \u0432\u0441\u0435\u0445 \u043c\u043e\u0434\u0443\u043b\u0435\u0439 \u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0438\u0441\u043a\u043b\u044e\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u044d\u0442\u043e\u0433\u043e Python-\u0441\u043a\u0440\u0438\u043f\u0442\u0430.1. \u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u044b \u0438 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438\u0412 \u043d\u0430\u0447\u0430\u043b\u0435 \u0444\u0430\u0439\u043b\u0430 \u0437\u0430\u0434\u0430\u044e\u0442\u0441\u044f \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043f\u043e\u0438\u0441\u043a\u0430 \u0438 \u043c\u0430\u043f\u043f\u0438\u043d\u0433\u0430:SCOPE (@xpack-dev-tools), PKG (arm-none-eabi-gcc), QEMU_PKG (qemu-arm) \u2014 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0432 \u044d\u043a\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u0435 xPack.CACHE_FILENAME (.xpack_cache.txt) \u2014 \u0438\u043c\u044f \u0444\u0430\u0439\u043b\u0430 \u043a\u044d\u0448\u0430, \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c\u043e\u0433\u043e \u0434\u043b\u044f Makefile.BARE_TOOL_KEYS \u2014 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u044f \u043a\u043b\u044e\u0447\u0435\u0439 JSON (gdbPath, compilerPath, objdumpPath, nmPath) \u0438\u043c\u0435\u043d\u0430\u043c \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432 \u0434\u043b\u044f \u0441\u043b\u0443\u0447\u0430\u0435\u0432, \u043a\u043e\u0433\u0434\u0430 \u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0438\u043c\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0431\u0435\u0437 \u043f\u0443\u0442\u0438.VSCODE_FILES \u2014 \u0446\u0435\u043b\u0435\u0432\u044b\u0435 \u0444\u0430\u0439\u043b\u044b \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a IDE (.vscode\/launch.json \u0438 .vscode\/c_cpp_properties.json).2. \u041f\u043e\u0438\u0441\u043a \u0438 \u0432\u044b\u0431\u043e\u0440 \u0432\u0435\u0440\u0441\u0438\u0438 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430 (Discovery)\u041b\u043e\u0433\u0438\u043a\u0430 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0430 \u0432\u043e\u043a\u0440\u0443\u0433 \u0441\u0431\u043e\u0440\u0430 \u0432\u0441\u0435\u0445 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a \u0438 \u0432\u044b\u0431\u043e\u0440\u0430 \u0441\u0430\u043c\u043e\u0439 \u043d\u043e\u0432\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438:version_key(name): \u0418\u0437\u0432\u043b\u0435\u043a\u0430\u0435\u0442 \u0432\u0441\u0435 \u0447\u0438\u0441\u043b\u0430 \u0438\u0437 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432\u0435\u0440\u0441\u0438\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, &#8216;15.2.1-1.1.1&#8217;) \u0438 \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u0438\u0445 \u0432 \u043a\u043e\u0440\u0442\u0435\u0436 (15, 2, 1, 1, 1) \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0433\u043e \u0441\u0435\u043c\u0430\u043d\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0432\u0435\u0440\u0441\u0438\u0439.global_prefixes(): \u0424\u043e\u0440\u043c\u0438\u0440\u0443\u0435\u0442 \u0441\u043f\u0438\u0441\u043e\u043a \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0445 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439 xpm \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u041e\u0421: \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f $XPACKS_DIR, ~\/.local\/xPacks (\u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f Linux\/macOS), ~\/.config\/xPacks (\u0443\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0438\u0439 \u043f\u0443\u0442\u044c) \u0438 %APPDATA%\/xPacks (Windows).package_dirs(prefix): \u0421\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0432\u0438\u0434\u0430 &lt;prefix&gt;\/&lt;scope&gt;\/&lt;pkg&gt;\/&lt;version&gt; (\u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044f \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443 \u043a\u0430\u043a \u0441\u043e \u0441\u043a\u043e\u0443\u043f\u043e\u043c @xpack-dev-tools, \u0442\u0430\u043a \u0438 \u0431\u0435\u0437 \u043d\u0435\u0433\u043e).payload_dir(root) \u0438 is_toolchain(root): \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0432\u0430\u043b\u0438\u0434\u043d\u043e\u0441\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u0423\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u043f\u0430\u043a\u0435\u0442\u043e\u0432 xpm, \u0433\u0434\u0435 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u0431\u0438\u043d\u0430\u0440\u043d\u0438\u043a\u0438 \u043b\u0435\u0436\u0430\u0442 \u0432 \u0441\u043a\u0440\u044b\u0442\u043e\u0439 \u043f\u043e\u0434\u043f\u0430\u043f\u043a\u0435 .content\/bin\/arm-none-eabi-gcc.from_path(): \u0420\u0435\u0437\u0435\u0440\u0432\u043d\u044b\u0439 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u2014 \u0438\u0449\u0435\u0442 arm-none-eabi-gcc \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 $PATH \u0447\u0435\u0440\u0435\u0437 shutil.which \u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u043a\u043e\u0440\u043d\u0435\u0432\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430.discover(args, project, verbose): \u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043f\u043e\u0438\u0441\u043a\u0430. \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0438 \u043f\u043e \u043f\u0440\u0438\u043e\u0440\u0438\u0442\u0435\u0442\u0443:\u042f\u0432\u043d\u044b\u0439 \u0444\u043b\u0430\u0433 &#8212;toolchain.\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f $ARM_XPACK_TOOLCHAIN_PATH.\u041b\u043e\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u0430\u043f\u043a\u0430 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 &lt;project&gt;\/xPacks.\u0413\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 xpm.\u0421\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0439 $PATH (\u0435\u0441\u043b\u0438 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d\u043e \u0432 xPacks).\u0418\u0437 \u0432\u0441\u0435\u0445 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u044b\u0445 \u0432 \u043f\u0430\u043f\u043a\u0430\u0445 xPacks \u043a\u0430\u043d\u0434\u0438\u0434\u0430\u0442\u043e\u0432 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u043e\u0439 \u043f\u043e version_key \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u0442\u0441\u044f \u0441\u0430\u043c\u0430\u044f \u0441\u0432\u0435\u0436\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f.3. \u0421\u0431\u043e\u0440 \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0445 \u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f \u043a\u044d\u0448\u0430 (Path computation &amp; Cache)(\u0427\u0430\u0441\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u043d\u043e\u043c \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u0435, \u043d\u043e \u0438\u0445 \u043b\u043e\u0433\u0438\u043a\u0430 \u043e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e \u043a\u043e\u0434\u0443 \u0438 \u0432\u044b\u0437\u043e\u0432\u0430\u043c \u0432 main):gcc_version(root): \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442 arm-none-eabi-gcc &#8212;version \u0447\u0435\u0440\u0435\u0437 subprocess.run (\u0441 \u0442\u0430\u0439\u043c\u0430\u0443\u0442\u043e\u043c 15 \u0441\u0435\u043a) \u0438 \u043f\u0430\u0440\u0441\u0438\u0442 \u043d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438. \u041f\u0440\u0438 \u043e\u0448\u0438\u0431\u043a\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u0435\u0440\u0435\u0442 \u0432\u0435\u0440\u0441\u0438\u044e \u0438\u0437 \u0438\u043c\u0435\u043d\u0438 \u043f\u0430\u043f\u043a\u0438 \u043f\u0430\u043a\u0435\u0442\u0430.first_dir \/ first_glob: \u0412\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u043f\u043e\u0434\u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0445 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u043e\u0432 include \u0438\u043b\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a lib \u0432\u043d\u0443\u0442\u0440\u0438 \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430).find_qemu(prefixes, verbose): \u041f\u043e \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0438 \u0441 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u043e\u043c \u0438\u0449\u0435\u0442 \u0441\u0430\u043c\u0443\u044e \u0441\u0432\u0435\u0436\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u044d\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u0430 qemu-system-arm \u0432 \u043f\u0430\u043f\u043a\u0430\u0445 xPacks \u0438\u043b\u0438 \u0432 $PATH.build_paths \u0438 write_cache (\u0438\u0437 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u043d\u043e\u0439 \u0441\u0435\u0440\u0435\u0434\u0438\u043d\u044b): \u0421\u043e\u0431\u0438\u0440\u0430\u044e\u0442 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 ARM_XPACK_* (\u043f\u0443\u0442\u0438 \u043a bin, \u043a\u043e\u0440\u043d\u044e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430, \u0432\u0435\u0440\u0441\u0438\u0438 GCC, \u043f\u0443\u0442\u0438 \u043a QEMU) \u0438 \u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u044e\u0442 \u0438\u0445 \u0432 &lt;project&gt;\/generated\/.xpack_cache.txt. \u0417\u0430\u043f\u0438\u0441\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0438\u0434\u0435\u043c\u043f\u043e\u0442\u0435\u043d\u0442\u043d\u043e \u2014 \u0444\u0430\u0439\u043b \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0438 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e.4. \u0421\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0439 VS Code (.vscode\/*.json)\u042d\u0442\u043e\u0442 \u0431\u043b\u043e\u043a \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043e\u0442\u043b\u0430\u0434\u0447\u0438\u043a \u0438 \u0430\u043d\u0430\u043b\u0438\u0437\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430 C\/C++ \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u0440\u043e\u0432\u043d\u043e \u0442\u043e\u0442 \u0436\u0435 \u0442\u0443\u043b\u0447\u0435\u0439\u043d, \u0447\u0442\u043e \u0438 \u0441\u0431\u043e\u0440\u0449\u0438\u043a:remap_xpack_path(value, root):\u0420\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u044b\u043c \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435\u043c \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0432 \u0441\u0442\u0440\u043e\u043a\u0435 \u043f\u0443\u0442\u0438 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442 &#8230;\/xPacks\/&#8230;.\u041e\u0442\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u0441\u0442\u0430\u0440\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u043f\u0430\u043a\u0435\u0442\u0430 \u0438 \u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0435\u0442 \u043d\u043e\u0432\u044b\u0439 \u043a\u043e\u0440\u0435\u043d\u044c root \u0441 \u043e\u0441\u0442\u0430\u0432\u0448\u0438\u043c\u0441\u044f \u00ab\u0445\u0432\u043e\u0441\u0442\u043e\u043c\u00bb \u043f\u0443\u0442\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \/.content\/bin\/arm-none-eabi-gdb).\u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u0442 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u043e\u043d\u0444\u0438\u0433\u043e\u0432: \u0415\u0441\u043b\u0438 \u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u043c JSON \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 ${env:HOME} \u0438\u043b\u0438 ~, \u0441\u043a\u0440\u0438\u043f\u0442 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u044d\u0442\u043e\u0442 \u043f\u0440\u0435\u0444\u0438\u043a\u0441 \u0432\u043c\u0435\u0441\u0442\u043e \u0437\u0430\u043f\u0438\u0441\u0438 \u0436\u0435\u0441\u0442\u043a\u043e\u0433\u043e \u043f\u0443\u0442\u0438 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u0439 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.walk_and_update(&#8230;):\u0420\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u043e\u0431\u0445\u043e\u0434\u0438\u0442 \u0432\u0441\u0435 \u0443\u0437\u043b\u044b (dict \u0438 list) \u0440\u0430\u0441\u043f\u0430\u0440\u0441\u0435\u043d\u043d\u043e\u0433\u043e JSON-\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430.\u041f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442 remap_xpack_path \u043a\u043e \u0432\u0441\u0435\u043c \u0441\u0442\u0440\u043e\u043a\u043e\u0432\u044b\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c.\u0414\u043b\u044f \u043a\u043b\u044e\u0447\u0435\u0439 \u0438\u0437 BARE_TOOL_KEYS (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, &#171;gdbPath&#187;: &#171;arm-none-eabi-gdb&#187;) \u0440\u0430\u0437\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u0442 \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u0438\u043c\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0432 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u043e\u0433\u043e \u0442\u0443\u043b\u0447\u0435\u0439\u043d\u0430.update_json_file(&#8230;):\u0411\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e \u0447\u0438\u0442\u0430\u0435\u0442 JSON (\u043f\u0440\u0438 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0435 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u043f\u0440\u0435\u0434\u0443\u043f\u0440\u0435\u0436\u0434\u0435\u043d\u0438\u0435 \u0432 stderr \u0438 \u043f\u0440\u043e\u043f\u0443\u0441\u043a\u0430\u0435\u0442 \u0444\u0430\u0439\u043b, \u043d\u0435 \u043b\u043e\u043c\u0430\u044f&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-505187","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/505187","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=505187"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/505187\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=505187"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=505187"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=505187"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}