{"id":82112,"date":"2020-08-02T19:18:19","date_gmt":"2020-08-02T13:18:19","guid":{"rendered":"http:\/\/rcl-radio.ru\/?p=82112"},"modified":"2022-01-08T17:08:54","modified_gmt":"2022-01-08T11:08:54","slug":"%d1%80%d0%b5%d0%b3%d0%b8%d1%81%d1%82%d1%80%d1%8b-%d0%bf%d0%be%d1%80%d1%82%d0%be%d0%b2-stm32f103c8t6-arduino-ide","status":"publish","type":"post","link":"http:\/\/rcl-radio.ru\/?p=82112","title":{"rendered":"\u0420\u0435\u0433\u0438\u0441\u0442\u0440\u044b \u043f\u043e\u0440\u0442\u043e\u0432 STM32F103C8T6 (Arduino IDE)"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2019\/12\/3285237.png\" width=\"479\" height=\"332\" \/><\/p>\n<blockquote>\n<p style=\"text-align: center;\"><strong>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043e\u0442\u043b\u0430\u0434\u043e\u0447\u043d\u043e\u0439 \u043f\u043b\u0430\u0442\u044b STM32 \u0432 Arduino IDE &#8212; <a href=\"http:\/\/rcl-radio.ru\/?p=68376\">http:\/\/rcl-radio.ru\/?p=68376<\/a><\/strong><\/p>\n<\/blockquote>\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u043f\u043e\u0440\u0442\u043e\u0432 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0435 \u0432\u044b\u0441\u043e\u043a\u043e\u0441\u043a\u043e\u0440\u043e\u0441\u0442\u043d\u044b\u0435 \u043c\u0430\u043d\u0438\u043f\u0443\u043b\u044f\u0446\u0438\u0438 \u0441 \u0432\u044b\u0432\u043e\u0434\u0430\u043c\u0438 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430. \u041c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 STM32F103C8T6 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 37 \u043f\u043e\u0440\u0442\u043e\u0432 \u0432\u0432\u043e\u0434\u0430-\u0432\u044b\u0432\u043e\u0434\u0430:<\/p>\n<ul>\n<li>GPIOA \u2013 16 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PA0-PA15<\/li>\n<li>GPIOB \u2013 16 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PB0-PB15<\/li>\n<li>GPIOC \u2013 3 \u0432\u044b\u0432\u043e\u0434\u0430: PC13-PC15<\/li>\n<li>GPIOD \u2013 2 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PD0, PD1<\/li>\n<\/ul>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82114\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31.png\" alt=\"\" width=\"1022\" height=\"671\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31.png 1022w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31-200x131.png 200w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31-500x328.png 500w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/381e31-768x504.png 768w\" sizes=\"auto, (max-width: 1022px) 100vw, 1022px\" \/><\/a><\/p>\n<p>\u041f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 \u043f\u043e\u0440\u0442\u0430\u043c\u0438 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u043e\u0441\u043e\u0431\u043e\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u0420\u041011 \u0438 \u0420\u041012 \u2014 \u044d\u0442\u043e \u0432\u0445\u043e\u0434 USB, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435 \u0436\u0435\u043b\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0438\u0445 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c (\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u044d\u0442\u0438\u0445 \u043f\u043e\u0440\u0442\u043e\u0432 \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 \u043a \u043d\u0435\u0440\u0430\u0431\u043e\u0442\u043e\u0441\u043f\u043e\u0441\u043e\u0431\u043d\u043e\u0441\u0442\u0438 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430). \u0422\u0430\u043a \u0436\u0435 \u043a \u0420\u042114 \u0438 \u0420\u042115 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0451\u043d \u0432\u043d\u0435\u0448\u043d\u0438\u0439 \u043a\u0432\u0430\u0440\u0446 \u0434\u043b\u044f \u0447\u0430\u0441\u043e\u0432 (32.768). \u0412\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043f\u0438\u043d\u044b \u043c\u043e\u0433\u0443\u0442 \u0432\u044b\u0434\u0430\u0442\u044c \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c 20 \u043c\u0410, \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f 8 \u043c\u0410. \u041e\u0431\u0449\u0430\u044f \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u043d\u0430 \u0432\u0441\u0435 \u043f\u043e\u0440\u0442\u044b \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u0430 \u043f\u0440\u0435\u0432\u044b\u0448\u0430\u0442\u044c 150 \u043c\u0410.<\/p>\n<div id=\"marketWidget\"><\/div>\n<p>\u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043f\u043e\u0440\u0442\u0430\u043c\u0438 STM32 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u043d\u0430\u0431\u043e\u0440\u043e\u0432 \u0438\u0437 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 32-\u0440\u0430\u0437\u0440\u044f\u0434\u043d\u044b\u0445 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432.<\/p>\n<p>\u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u044b \u043f\u043e\u0440\u0442\u043e\u0432:<\/p>\n<ul>\n<li><strong>GPIOx_CRL, GPIOx_CRH<\/strong> \u2013 \u0437\u0430\u0434\u0430\u044e\u0442 \u0440\u0435\u0436\u0438\u043c\u044b \u0440\u0430\u0431\u043e\u0442\u044b \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0438\u0437 \u0431\u0438\u0442\u043e\u0432 \u043f\u043e\u0440\u0442\u0430 \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0432\u0445\u043e\u0434\u0430 \u0438\u043b\u0438 \u0432\u044b\u0445\u043e\u0434\u0430, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u044e\u0442 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0438 \u0432\u044b\u0445\u043e\u0434\u043d\u044b\u0445 \u043a\u0430\u0441\u043a\u0430\u0434\u043e\u0432<\/li>\n<li><strong>GPIOx_IDR<\/strong> \u2013 \u0432\u0445\u043e\u0434\u043d\u043e\u0439 \u0440\u0435\u0433\u0438\u0441\u0442\u0440 \u0434\u0430\u043d\u043d\u044b\u0445 \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0432\u044b\u0432\u043e\u0434\u043e\u0432 \u043f\u043e\u0440\u0442\u0430 x<\/li>\n<li><strong>GPIOx_ODR<\/strong>\u2013 \u0432\u044b\u0445\u043e\u0434\u043d\u043e\u0439 \u0440\u0435\u0433\u0438\u0441\u0442\u0440 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442 \u0437\u0430\u043f\u0438\u0441\u044c \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0432 \u043f\u043e\u0440\u0442<\/li>\n<\/ul>\n<p>\u0420\u0435\u0433\u0438\u0441\u0442\u0440 <strong>CRL<\/strong> \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0443\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\u044b 0&#8230;7 \u043f\u043e\u0440\u0442\u0430, \u0430 \u0440\u0435\u0433\u0438\u0441\u0442\u0440 <strong>CRH <\/strong>\u0432\u044b\u0432\u043e\u0434\u044b 8&#8230;15.<\/p>\n<p style=\"text-align: center;\"><strong>\u0420\u0435\u0433\u0438\u0441\u0442\u0440 CRL<\/strong><\/p>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82113\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334.png\" alt=\"\" width=\"828\" height=\"159\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334.png 828w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334-200x38.png 200w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334-500x96.png 500w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334-768x147.png 768w\" sizes=\"auto, (max-width: 828px) 100vw, 828px\" \/><\/a><\/p>\n<p>\u0411\u0438\u0442\u044b MODE \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u044e\u0442 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u044b\u0432\u043e\u0434\u0430 \u0438 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435 \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u0438 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0432 \u0440\u0435\u0436\u0438\u043c\u0435 \u0432\u044b\u0445\u043e\u0434\u0430:<\/p>\n<ul>\n<li><strong>MODE[1:0] = 00:<\/strong> \u0420\u0435\u0436\u0438\u043c \u0432\u0445\u043e\u0434\u0430 (\u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435 \u0441\u0431\u0440\u043e\u0441\u0430)<\/li>\n<li><strong>MODE[1:0] = 01:<\/strong> \u0420\u0435\u0436\u0438\u043c \u0432\u044b\u0445\u043e\u0434\u0430, \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u2013 10 \u041c\u0413\u0446<\/li>\n<li><strong>MODE[1:0] = 10:<\/strong> \u0420\u0435\u0436\u0438\u043c \u0432\u044b\u0445\u043e\u0434\u0430, \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u2013 2 \u041c\u0413\u0446<\/li>\n<li><strong>MODE[1:0] = 11:<\/strong> \u0420\u0435\u0436\u0438\u043c \u0432\u044b\u0445\u043e\u0434\u0430, \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u2013 50 \u041c\u0413\u0446<\/li>\n<\/ul>\n<p>\u0411\u0438\u0442\u044b CNF \u0437\u0430\u0434\u0430\u044e\u0442 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0432\u044b\u0445\u043e\u0434\u043d\u044b\u0445 \u043a\u0430\u0441\u043a\u0430\u0434\u043e\u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u0432\u044b\u0432\u043e\u0434\u043e\u0432.<\/p>\n<p>\u0412 \u0440\u0435\u0436\u0438\u043c\u0435 \u0432\u0445\u043e\u0434\u0430:<\/p>\n<ul>\n<li><strong>CNF[1:0] = 00:<\/strong> \u0410\u043d\u0430\u043b\u043e\u0433\u043e\u0432\u044b\u0439 \u0432\u0445\u043e\u0434<\/li>\n<li><strong>CNF[1:0] = 01:<\/strong> \u0412\u0445\u043e\u0434 \u0432 \u0442\u0440\u0435\u0442\u044c\u0435\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 (\u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435 \u0441\u0431\u0440\u043e\u0441\u0430)<\/li>\n<li><strong>CNF[1:0] = 10:<\/strong> \u0412\u0445\u043e\u0434 \u0441 \u043f\u0440\u0438\u0442\u044f\u0433\u0438\u0432\u0430\u044e\u0449\u0438\u043c \u0440\u0435\u0437\u0438\u0441\u0442\u043e\u0440\u043e\u043c pull-up (\u0435\u0441\u043b\u0438 PxODR=1) \u0438\u043b\u0438 pull-down (\u0435\u0441\u043b\u0438 PxODR=0)<\/li>\n<li><strong>CNF[1:0] = 11:<\/strong> \u0417\u0430\u0440\u0435\u0437\u0435\u0440\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e<\/li>\n<\/ul>\n<p>\u0412 \u0440\u0435\u0436\u0438\u043c\u0435 \u0432\u044b\u0445\u043e\u0434\u0430:<\/p>\n<ul>\n<li><strong>CNF[1:0] = 00:<\/strong> \u0414\u0432\u0443\u0445\u0442\u0430\u043a\u0442\u043d\u044b\u0439 \u0432\u044b\u0445\u043e\u0434 \u043e\u0431\u0449\u0435\u0433\u043e \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f<\/li>\n<li><strong>CNF[1:0] = 01:<\/strong> \u0412\u044b\u0445\u043e\u0434 \u0441 \u043e\u0442\u043a\u0440\u044b\u0442\u044b\u043c \u0441\u0442\u043e\u043a\u043e\u043c \u043e\u0431\u0449\u0435\u0433\u043e \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f<\/li>\n<li><strong>CNF[1:0] = 10:<\/strong> \u0414\u0432\u0443\u0445\u0442\u0430\u043a\u0442\u043d\u044b\u0439 \u0432\u044b\u0445\u043e\u0434 \u0441 \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043d\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439<\/li>\n<li><strong>CNF[1:0] = 11:<\/strong> \u0412\u044b\u0445\u043e\u0434 \u0441 \u043e\u0442\u043a\u0440\u044b\u0442\u044b\u043c \u0441\u0442\u043e\u043a\u043e\u043c \u0441 \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043d\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439<\/li>\n<\/ul>\n<p>\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0435\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0432\u044b\u0445\u043e\u0434\u0430 <strong>PA0<\/strong>, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0431\u0438\u0442\u044b <strong>MODE0<\/strong> \u0438 <strong>CNF0<\/strong> \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430 <strong>CRL:<\/strong><\/p>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82115\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348.png\" alt=\"\" width=\"828\" height=\"159\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348.png 828w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348-200x38.png 200w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348-500x96.png 500w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348-768x147.png 768w\" sizes=\"auto, (max-width: 828px) 100vw, 828px\" \/><\/a><\/p>\n<p>\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0435\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0432\u044b\u0445\u043e\u0434\u0430 <strong>PB11<\/strong>, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0431\u0438\u0442\u044b <strong>MODE3<\/strong>\u00a0\u0438 <strong>CNF3<\/strong>\u00a0\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430 <strong>CRH:<\/strong><\/p>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82116\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097.png\" alt=\"\" width=\"828\" height=\"159\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097.png 828w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097-200x38.png 200w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097-500x96.png 500w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-175334298792348707097-768x147.png 768w\" sizes=\"auto, (max-width: 828px) 100vw, 828px\" \/><\/a><\/p>\n<p>\u0420\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u0434\u0432\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0430, \u0434\u043b\u044f \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438 \u043c\u043e\u0436\u043d\u043e \u0432\u0437\u044f\u0442\u044c \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 (\u0447\u0435\u0440\u0435\u0437 \u0440\u0435\u0437\u0438\u0441\u0442\u043e\u0440 300 \u041e\u043c) \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u043c \u043a \u0432\u044b\u0445\u043e\u0434\u0443 <strong>PA0<\/strong> \u0432 \u043f\u0435\u0440\u0432\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0438 <strong>PB11<\/strong> \u0434\u043b\u044f \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430.<\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0441\u043a\u0435\u0442\u0447\u0430 \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u043d\u0430\u0447\u043d\u0435\u0442 \u043c\u0438\u0433\u0430\u0442\u044c \u0441 \u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u043e\u043c 1 \u0441\u0435\u043a\u0443\u043d\u0434\u0430, \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d \u043a \u0432\u044b\u0445\u043e\u0434\u0443 PA0:<\/p>\n<pre><span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRL<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b<strong>0011<\/strong><\/span><span style=\"color: #000000;\">; \/\/ <strong>CNF[1:0] = 00 | MODE[1:0] = 11<\/strong><\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b00<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b01<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p>\u0420\u0435\u0433\u0438\u0441\u0442\u0440 <strong>ODR<\/strong> \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 <strong>PA0<\/strong> \u043b\u043e\u0433. \u0435\u0434\u0438\u043d\u0438\u0446\u0443.<\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0441\u043a\u0435\u0442\u0447\u0430 \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u043d\u0430\u0447\u043d\u0435\u0442 \u043c\u0438\u0433\u0430\u0442\u044c \u0441 \u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u043e\u043c 1 \u0441\u0435\u043a\u0443\u043d\u0434\u0430, \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d \u043a \u0432\u044b\u0445\u043e\u0434\u0443 PB11:<\/p>\n<pre><span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRH<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b<strong>0011<\/strong>000000000000<\/span><span style=\"color: #000000;\">; \/\/ <strong>CNF[1:0] = 00 | MODE[1:0] = 11<\/strong><\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b00<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b100000000000<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p>\u0420\u0435\u0433\u0438\u0441\u0442\u0440 <strong>ODR<\/strong> \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 <strong>PB11<\/strong>\u00a0\u043b\u043e\u0433. \u0435\u0434\u0438\u043d\u0438\u0446\u0443.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043c\u0435\u043d\u044f\u0442\u044c \u043b\u043e\u0433. \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0432\u044b\u0445\u043e\u0434\u0430 \u0438 \u043d\u0435 \u043c\u0435\u043d\u044f\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0434\u0440\u0443\u0433\u0438\u0445 \u0432\u044b\u0445\u043e\u0434\u043e\u0432, \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u043c:<\/p>\n<pre><span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRH<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0x3000<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #434f54;\">\/\/ 0b0011000000000000<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">&amp;=<\/span> <span style=\"color: #434f54;\">~<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1<\/span> <span style=\"color: #434f54;\">&lt;&lt;<\/span> <span style=\"color: #000000;\">11<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #434f54;\">\/\/ \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043b\u043e\u0433. 0 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 PB11<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">|=<\/span> <span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1<\/span> <span style=\"color: #434f54;\">&lt;&lt;<\/span> <span style=\"color: #000000;\">11<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span> \u00a0<span style=\"color: #434f54;\">\/\/ \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043b\u043e\u0433. 1 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 PB11<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0412\u0430\u0441 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0441\u043a\u0435\u0442\u0447 \u043d\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a \u0440\u0430\u0437\u043c\u0435\u0440\u0443 \u043f\u0430\u043c\u044f\u0442\u0438 \u0438 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430, \u0442\u043e \u043f\u0440\u043e\u0449\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438. \u041d\u043e \u0435\u0441\u043b\u0438 \u0441\u043a\u0435\u0442\u0447 \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0438 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u0438 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0446\u0438\u0444\u0440\u043e\u0432\u044b\u0445 \u0432\u044b\u0432\u043e\u0434\u043e\u0432, \u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u0431\u0443\u0434\u0435\u0442 \u0441\u0430\u043c\u044b\u043c \u043e\u043f\u0442\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u043c \u0434\u043b\u044f \u0412\u0430\u0441 \u0440\u0435\u0448\u0435\u043d\u0438\u0435\u043c.<\/p>\n<p>\u0421\u0440\u0430\u0432\u043d\u0438\u043c \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0434\u0432\u0430 \u0441\u043a\u0435\u0442\u0447\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442 \u043e\u0434\u043d\u043e \u0438 \u0442\u043e\u0436\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 &#8212; \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u044e\u0442 \u043b\u043e\u0433. \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0432\u044b\u0445\u043e\u0434\u0430 1000 \u0440\u0430\u0437.<\/p>\n<pre><span style=\"color: #00979c;\">unsigned<\/span> <span style=\"color: #00979c;\">long<\/span> <span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">;<\/span>\r\n\r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #d35400;\">pinMode<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">PB11<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">OUTPUT<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">times<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #d35400;\">micros<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #5e6d03;\">for<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #00979c;\">int<\/span> <span style=\"color: #000000;\">i<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #000000;\">i<\/span> <span style=\"color: #434f54;\">&lt;<\/span> <span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #000000;\">i<\/span><span style=\"color: #434f54;\">++<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #d35400;\">digitalWrite<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">PB11<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">LOW<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">digitalWrite<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">PB11<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">HIGH<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #000000;\">}<\/span>\r\n \u00a0<span style=\"color: #000000;\">times<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #d35400;\">micros<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #434f54;\">-<\/span> <span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">println<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183855.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82117\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183855.png\" alt=\"\" width=\"198\" height=\"224\" \/><\/a><\/p>\n<p>\u0412\u0440\u0435\u043c\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f 1000 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0439 \u043b\u043e\u0433. \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0432\u044b\u0445\u043e\u0434\u0430 1377 \u043c\u043a\u0441.<\/p>\n<pre><span style=\"color: #00979c;\">unsigned<\/span> <span style=\"color: #00979c;\">long<\/span> <span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">;<\/span>\r\n\r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRH<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0x3000<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #434f54;\">\/\/ 0b0011000000000000<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">times<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #d35400;\">micros<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #5e6d03;\">for<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #00979c;\">int<\/span> <span style=\"color: #000000;\">i<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #000000;\">i<\/span> <span style=\"color: #434f54;\">&lt;<\/span> <span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #000000;\">i<\/span><span style=\"color: #434f54;\">++<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">&amp;=<\/span> <span style=\"color: #434f54;\">~<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1<\/span> <span style=\"color: #434f54;\">&lt;&lt;<\/span> <span style=\"color: #000000;\">11<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #434f54;\">\/\/ \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043b\u043e\u0433. 0 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 PB11<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">|=<\/span> <span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1<\/span> <span style=\"color: #434f54;\">&lt;&lt;<\/span> <span style=\"color: #000000;\">11<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span> \u00a0<span style=\"color: #434f54;\">\/\/ \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043b\u043e\u0433. 1 \u043d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 PB11<\/span>\r\n \u00a0<span style=\"color: #000000;\">}<\/span>\r\n \u00a0<span style=\"color: #000000;\">times<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #d35400;\">micros<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #434f54;\">-<\/span> <span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">println<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">times<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183732.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82118\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183732.png\" alt=\"\" width=\"227\" height=\"207\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183732.png 227w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-183732-200x182.png 200w\" sizes=\"auto, (max-width: 227px) 100vw, 227px\" \/><\/a><\/p>\n<p>\u0412\u0440\u0435\u043c\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f 1000 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0439 \u043b\u043e\u0433. \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0432\u044b\u0445\u043e\u0434\u0430 293 \u043c\u043a\u0441.<\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0435\u0436\u0438\u043c \u0447\u0442\u0435\u043d\u0438\u044f \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043f\u043e\u0440\u0442\u0430 \u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0432\u044b\u0445\u043e\u0434\u0430. \u0414\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043f\u043e\u0440\u0442\u0430 \u0438\u043b\u0438 \u0432\u044b\u0445\u043e\u0434\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0440\u0435\u0433\u0438\u0441\u0442\u0440 <strong>IDR<\/strong>. \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440 \u0447\u0442\u0435\u043d\u0438\u044f \u0432\u0445\u043e\u0434\u0430 PA0:<\/p>\n<pre><span style=\"color: #00979c;\">bool<\/span> <span style=\"color: #000000;\">data<\/span><span style=\"color: #000000;\">;<\/span>\r\n\r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRL<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b0100<\/span><span style=\"color: #000000;\">;<\/span> \/\/ <strong>CNF[1:0] = 01 | MODE[1:0] = 00<\/strong>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n  <span style=\"color: #000000;\">data<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">IDR<\/span> <span style=\"color: #434f54;\">&amp;<\/span> <span style=\"color: #000000;\">0b01<\/span><span style=\"color: #000000;\">;<\/span> \/\/ \u0447\u0442\u0435\u043d\u0438\u0435 \u0432\u0445\u043e\u0434\u0430 \u043f\u043e\u0440\u0442\u0430 0b0000000000000001 (PA0)\r\n  <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">println<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">data<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">BIN<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-191227.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82120\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-191227.png\" alt=\"\" width=\"173\" height=\"257\" \/><\/a><\/p>\n<p>\u041f\u0440\u0438 \u043f\u043e\u0434\u0430\u0447\u0435 \u043d\u0430 \u0432\u0445\u043e\u0434 <strong>PA0<\/strong> \u043b\u043e\u0433. 1 (3,3 \u0412) \u0438\u043b\u0438 0, \u0432 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0435 \u043f\u043e\u0440\u0442\u0430 \u0432\u0438\u0434\u043d\u043e \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0435\u0433\u043e \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f.<\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0435 \u0447\u0442\u0435\u043d\u0438\u0435 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0432\u0445\u043e\u0434\u043e\u0432 \u043f\u043e\u0440\u0442\u0430 (PA0&#8230;PA3):<\/p>\n<pre><span style=\"color: #00979c;\">unsigned<\/span> <span style=\"color: #00979c;\">int<\/span> <span style=\"color: #000000;\">data<\/span><span style=\"color: #000000;\">;<\/span>\r\n\r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRL<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b0100010001000100<\/span><span style=\"color: #000000;\">;<\/span> \/\/ <span style=\"color: #000000;\">0100 0100 0100 0100<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <span style=\"color: #000000;\">data<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">IDR<\/span> <span style=\"color: #434f54;\">&amp;<\/span> <span style=\"color: #000000;\">0b1111<\/span><span style=\"color: #000000;\">;<\/span> \/\/ \u0447\u0442\u0435\u043d\u0438\u0435 \u0432\u0445\u043e\u0434\u043e\u0432 \u043f\u043e\u0440\u0442\u0430 0b0000000000001111 (PA0...PA3)\r\n  <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">println<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">data<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">BIN<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p><a href=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-192239.png\" class=\"highslide-image\" onclick=\"return hs.expand(this);\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-82122\" src=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-192239.png\" alt=\"\" width=\"239\" height=\"267\" srcset=\"http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-192239.png 239w, http:\/\/rcl-radio.ru\/wp-content\/uploads\/2020\/08\/\u0421\u043d\u0438\u043c\u043e\u043a-\u044d\u043a\u0440\u0430\u043d\u0430-\u043e\u0442-2020-08-02-192239-200x223.png 200w\" sizes=\"auto, (max-width: 239px) 100vw, 239px\" \/><\/a>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u0434\u0442\u044f\u0433\u0438\u0432\u0430\u044e\u0449\u0435\u0433\u043e \u0440\u0435\u0437\u0438\u0441\u0442\u043e\u0440\u0430 \u043d\u0430 \u0432\u0445\u043e\u0434\u0435:<\/p>\n<pre><span style=\"color: #00979c;\">bool<\/span> <span style=\"color: #000000;\">data<\/span><span style=\"color: #000000;\">;<\/span>\r\n\r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRL<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b1000<\/span><span style=\"color: #000000;\">;<\/span> \r\n <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">ODR<\/span> <span style=\"color: #434f54;\">|=<\/span> <span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1<\/span> <span style=\"color: #434f54;\">&lt;&lt;<\/span> <span style=\"color: #000000;\">0<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">data<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">GPIOB<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">IDR<\/span> <span style=\"color: #434f54;\">&amp;<\/span> <span style=\"color: #000000;\">0b01<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #434f54;\">\/\/ PB0 INPUT<\/span>\r\n \u00a0<b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">println<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">data<\/span><span style=\"color: #434f54;\">,<\/span><span style=\"color: #00979c;\">BIN<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">200<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n<p>\u0412\u0445\u043e\u0434 <strong>PB0<\/strong> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043f\u043e\u0434\u0442\u044f\u0433\u0438\u0432\u0430\u044e\u0449\u0438\u0439 \u0440\u0435\u0437\u0438\u0441\u0442\u043e\u0440 \u043a 3.3 \u0412, \u0432 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0435 \u043f\u043e\u0440\u0442\u0430 \u043d\u0430 \u0432\u0445\u043e\u0434\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u043e\u0433. \u0435\u0434\u0438\u043d\u0438\u0446\u0430, \u043f\u0440\u0438 \u0437\u0430\u043c\u044b\u043a\u0430\u043d\u0438\u0438 \u0432\u0445\u043e\u0434\u0430 \u043d\u0430 GND, \u043b\u043e\u0433 1 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u043d\u0430 0.<\/p>\n<hr \/>\n<p><strong>\u0421\u0431\u0440\u043e\u0441 \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0431\u0438\u0442\u043e\u0432 \u043f\u043e\u0440\u0442\u0430<\/strong><\/p>\n<p>\u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u0441\u0431\u0440\u043e\u0441\u0430 \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 &#8212;\u00a0 <strong>BRR<\/strong> \u0438 <strong>BSRR<\/strong> \u043c\u043e\u0436\u043d\u043e \u0441\u0431\u0440\u043e\u0441\u0438\u0442\u044c \u0438\u043b\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u0431\u0438\u0442 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430 <strong><em>ODR<\/em><\/strong>. \u0418\u043d\u0430\u0447\u0435 \u0433\u043e\u0432\u043e\u0440\u044f \u043f\u043e\u043c\u0435\u043d\u044f\u0442\u044c \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043b\u044e\u0431\u043e\u0433\u043e \u0432\u044b\u0445\u043e\u0434\u0430, \u043d\u0435 \u0437\u0430\u0442\u0440\u0430\u0433\u0438\u0432\u0430\u044f \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0432\u044b\u0445\u043e\u0434\u044b.<\/p>\n<p><strong>BRR:<\/strong> \u0421\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u0431\u0438\u0442 <em>\u0443<\/em>\u00a0\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u00a0<em>ODR<\/em><\/p>\n<ul>\n<li>0: \u043d\u0435 \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u0432\u043b\u0438\u044f\u043d\u0438\u0435 \u043d\u0430 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0442 ODR<\/li>\n<li>1: \u0421\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442 \u0432 \u043d\u043e\u043b\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0442 ODR<\/li>\n<\/ul>\n<p><strong>BSy:<\/strong> \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0431\u0438\u0442 <em>\u0443<\/em>\u00a0\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u00a0<em>ODR<\/em><\/p>\n<ul>\n<li>0: \u043d\u0435 \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u0432\u043b\u0438\u044f\u043d\u0438\u0435 \u043d\u0430 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0442 ODR<\/li>\n<li>1: \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0432 \u0435\u0434\u0438\u043d\u0438\u0446\u0443 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0442 ODR<\/li>\n<\/ul>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u0435 \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u043a \u0432\u044b\u0445\u043e\u0434\u0443 PA0, \u043f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0441\u043a\u0435\u0442\u0447\u0430 \u0431\u0443\u0434\u0435\u0442 \u043c\u0438\u0433\u0430\u0442\u044c \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434 \u0441 \u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u043e\u043c 1 \u0441\u0435\u043a\u0443\u043d\u0434\u0430.<\/p>\n<pre><span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">setup<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n <b><span style=\"color: #d35400;\">Serial<\/span><\/b><span style=\"color: #434f54;\">.<\/span><span style=\"color: #d35400;\">begin<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">9600<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n <span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">CRL<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b0011<\/span><span style=\"color: #000000;\">;<\/span> \r\n<span style=\"color: #000000;\">}<\/span>\r\n \r\n<span style=\"color: #00979c;\">void<\/span> <span style=\"color: #5e6d03;\">loop<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">)<\/span> <span style=\"color: #000000;\">{<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">BRR<\/span> <span style=\"color: #434f54;\">=<\/span> \u00a0<span style=\"color: #000000;\">0b0000000000000001<\/span><span style=\"color: #000000;\">; <\/span><span style=\"color: #999999;\">\/\/ \u0441\u0431\u0440\u043e\u0441 \u0432 0 \u0432\u044b\u0445\u043e\u0434\u0430 PA0<\/span>\r\n  <span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n \u00a0<span style=\"color: #000000;\">GPIOA<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">regs<\/span><span style=\"color: #434f54;\">-<\/span><span style=\"color: #434f54;\">&gt;<\/span> <span style=\"color: #000000;\">BSRR<\/span> <span style=\"color: #434f54;\">=<\/span> <span style=\"color: #000000;\">0b0000000000000001<\/span><span style=\"color: #000000;\">;<\/span> <span style=\"color: #999999;\">\/\/ \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 1 \u0432\u044b\u0445\u043e\u0434\u0430 PA0<\/span>\r\n  <span style=\"color: #d35400;\">delay<\/span><span style=\"color: #000000;\">(<\/span><span style=\"color: #000000;\">1000<\/span><span style=\"color: #000000;\">)<\/span><span style=\"color: #000000;\">;<\/span>\r\n<span style=\"color: #000000;\">}<\/span>\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043e\u0442\u043b\u0430\u0434\u043e\u0447\u043d\u043e\u0439 \u043f\u043b\u0430\u0442\u044b STM32 \u0432 Arduino IDE &#8212; http:\/\/rcl-radio.ru\/?p=68376 \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u043e\u0432 \u043f\u043e\u0440\u0442\u043e\u0432 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0435 \u0432\u044b\u0441\u043e\u043a\u043e\u0441\u043a\u043e\u0440\u043e\u0441\u0442\u043d\u044b\u0435 \u043c\u0430\u043d\u0438\u043f\u0443\u043b\u044f\u0446\u0438\u0438 \u0441 \u0432\u044b\u0432\u043e\u0434\u0430\u043c\u0438 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430. \u041c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 STM32F103C8T6 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 37 \u043f\u043e\u0440\u0442\u043e\u0432 \u0432\u0432\u043e\u0434\u0430-\u0432\u044b\u0432\u043e\u0434\u0430: GPIOA \u2013 16 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PA0-PA15 GPIOB \u2013 16 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PB0-PB15 GPIOC \u2013 3 \u0432\u044b\u0432\u043e\u0434\u0430: PC13-PC15 GPIOD \u2013 2 \u0432\u044b\u0432\u043e\u0434\u043e\u0432: PD0, PD1 \u041f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 \u043f\u043e\u0440\u0442\u0430\u043c\u0438 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u043e\u0441\u043e\u0431\u043e\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":82114,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[239,21],"tags":[],"class_list":["post-82112","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-arduino","category-21"],"views":7720,"_links":{"self":[{"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/posts\/82112","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=82112"}],"version-history":[{"count":7,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/posts\/82112\/revisions"}],"predecessor-version":[{"id":111222,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/posts\/82112\/revisions\/111222"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=\/wp\/v2\/media\/82114"}],"wp:attachment":[{"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=82112"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=82112"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/rcl-radio.ru\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=82112"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}