{"id":3161,"date":"2020-09-05T16:58:55","date_gmt":"2020-09-05T07:58:55","guid":{"rendered":"http:\/\/otsuka.biz\/blog1\/?p=3161"},"modified":"2024-02-12T17:47:28","modified_gmt":"2024-02-12T08:47:28","slug":"email-sender-smtp-using-esp32","status":"publish","type":"post","link":"https:\/\/otsuka.biz\/blog1\/email-sender-smtp-using-esp32\/","title":{"rendered":"Email sender (SMTP) using ESP32-WROOM-32"},"content":{"rendered":"\n<p>&lt;&lt; Introduction in Japanese &gt;&gt;<\/p>\n\n\n\n<p>\u3053\u306e\u590f\u3001\u6700\u5f8c\u306e\u8da3\u5473\u904a\u3073\u306f ESP32-WROOM-32 \u3067 SMTP \u3092\u52d5\u304b\u3059\u4e8b\u3068\u3057\u305f\u3002\u904e\u53bb\u306ePIC \u30de\u30a4\u30b3\u30f3\u306e\u5b9f\u9a13\u3068\u540c\u69d8\u306b\u3001\u7c21\u5358\u306a\u6587\u7ae0\u3092\u30e1\u30fc\u30eb\u9001\u4fe1\u3059\u308b\u3002SMTP \u306b\u5fc5\u8981\u306a\u30b3\u30fc\u30c9\u306f\u3001<a href=\"https:\/\/github.com\/gpepe\/esp8266-sendemail\">Send email with esp8266 arduino<\/a> \u306e\u3082\u306e\u3092\u5229\u7528\u3057\u305f\u3002\u30bf\u30af\u30c8\u30b9\u30a4\u30c3\u30c1\u3092\uff11\u500b\u7e4b\u3044\u3067\u3001\u30b9\u30a4\u30c3\u30c1\u3092\u62bc\u3059\u3068\u30e1\u30fc\u30eb\u304c\u9001\u4fe1\u3055\u308c\u308b\u4ed5\u69d8\u3068\u3057\u305f\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"822\" src=\"http:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-1024x822.jpg\" alt=\"\" class=\"wp-image-3177\" srcset=\"https:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-1024x822.jpg 1024w, https:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-300x241.jpg 300w, https:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-768x617.jpg 768w, https:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-1536x1233.jpg 1536w, https:\/\/otsuka.biz\/blog1\/wp-content\/uploads\/2020\/09\/ESP32_SMTP-2048x1645.jpg 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>The ESP32 board in my page on Aug. 16, 2020 is working as a SMTP client.<\/p>\n\n\n\n<p>The GPIO34 pin is pulled up to Vdd normally and can be pulled down to Vss by the tact switch.<\/p>\n\n\n\n<p>If the switch is pushed, an Email will be sent to the programmed address.<\/p>\n\n\n\n<p><br><br><\/p>\n\n\n\n<p>&lt;&lt; Sample sketch of the&nbsp;SMTP client &gt;&gt;<\/p>\n\n\n\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"\u30a2\u30a4\u30b3\u30f3\" src=\"data:image\/svg+xml;base64,CiAgICAgICAgICAgIDxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNDAgNDAiPgogICAgICAgICAgICAgICAgPGRlZnM+CiAgICAgICAgICAgICAgICAgICAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkaWVudCIgeDE9IjAiIHkxPSIwIiB4Mj0iMCIgeTI9IjEiPgogICAgICAgICAgICAgICAgICAgICAgICA8c3RvcCBzdG9wLWNvbG9yPSIjMjY5ZGVmIiBvZmZzZXQ9IjAiLz4KICAgICAgICAgICAgICAgICAgICAgICAgPHN0b3Agc3RvcC1jb2xvcj0iIzI2YmRlZiIgb2Zmc2V0PSIxIi8+CiAgICAgICAgICAgICAgICAgICAgPC9saW5lYXJHcmFkaWVudD4KICAgICAgICAgICAgICAgIDwvZGVmcz4KICAgICAgICAgICAgICAgIDxnPgogICAgICAgICAgICAgICAgICAgIDxyZWN0IGZpbGw9InVybCgjZ3JhZGllbnQpIiB4PSIwIiB5PSIwIiB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHJ4PSIzIiByeT0iMyIvPgogICAgICAgICAgICAgICAgICAgIDx0ZXh0IHg9IjUiIHk9IjE5IiBmb250LWZhbWlseT0iQXJpYWwsIEhlbHZldGljYSwgc2Fucy1zZXJpZiIgZm9udC1zaXplPSIxM3B4IiBsZXR0ZXItc3BhY2luZz0iMSIgZmlsbD0iI0ZGRkZGRiI+CiAgICAgICAgICAgICAgICAgICAgICAgIDx0c3Bhbj5MWkg8L3RzcGFuPgogICAgICAgICAgICAgICAgICAgICAgICA8dHNwYW4geD0iNiIgeT0iMjgiPl88L3RzcGFuPgogICAgICAgICAgICAgICAgICAgIDwvdGV4dD4KICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgPC9zdmc+CgoJCQk=\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/otsuka.biz\/blog1\/download\/esp32-smtp\/'>ESP32 SMTP<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 \u30d5\u30a1\u30a4\u30eb <i class=\"fas fa-hdd ml-3\"><\/i> 2.09 KB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/otsuka.biz\/blog1\/download\/esp32-smtp\/?wpdmdl=3408&refresh=69ff2b1a82dbe1778330394\">\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n\n\n\n<p>(Compiled by the Arduino IDE with the Arduino Core for the ESP32)<\/p>\n\n\n\n<p>You must fill in the blanks of &#8220;ESP32_SMTP.ino&#8221; correctly to send an Email.<\/p>\n\n\n\n<p><br><br><\/p>\n\n\n\n<p>&lt;&lt; Summary in Japanese &gt;&gt;<\/p>\n\n\n\n<p>\u5b9f\u9a13\u3067\u306f\u3001YahooBB \u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u4f7f\u3063\u3066\u9001\u4fe1\u304c\u51fa\u6765\u305f\u3002\u30b5\u30fc\u30d0\u30fc\u3068\u30dd\u30fc\u30c8\u306f\u3001<\/p>\n\n\n\n<p>smtp server : ybbsmtp.mail.yahoo.co.jp<\/p>\n\n\n\n<p>port : 465<\/p>\n\n\n\n<p>\u3067\u3042\u308b\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&lt;&lt; Introduction in Japanese &gt;&gt; \u3053\u306e\u590f\u3001\u6700\u5f8c\u306e\u8da3\u5473\u904a\u3073\u306f ESP32-WROOM-32 \u3067 SMTP \u3092\u52d5\u304b\u3059\u4e8b\u3068\u3057\u305f\u3002\u904e\u53bb\u306ePIC \u30de\u30a4\u30b3\u30f3\u306e\u5b9f\u9a13\u3068\u540c\u69d8\u306b\u3001\u7c21\u5358\u306a\u6587 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"vkexunit_cta_each_option":"","footnotes":""},"categories":[13,12,5,1],"tags":[],"class_list":["post-3161","post","type-post","status-publish","format-standard","hentry","category-esp32","category-internet","category-radio-frequency","category-unclassification"],"_links":{"self":[{"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/posts\/3161","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/comments?post=3161"}],"version-history":[{"count":2,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/posts\/3161\/revisions"}],"predecessor-version":[{"id":3409,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/posts\/3161\/revisions\/3409"}],"wp:attachment":[{"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/media?parent=3161"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/categories?post=3161"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/otsuka.biz\/blog1\/wp-json\/wp\/v2\/tags?post=3161"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}