首頁其他『高中小論文』物聯網的世代!利用Arduino實現居家安全監控系統

『高中小論文』物聯網的世代!利用Arduino實現居家安全監控系統

(三)、燒錄與撰寫程式

1、安裝Esp32核心程式

下載Arduino IDE( 使用1.8.12版本 )並設定如圖中配置,以配合Esp32cam運作,然後修改開發版的設定,最終才能將程式成功燒錄進Esp32開發版當中。  此次選用的設定值為「Esp32 Wrover Module」 因為這是屬於Esp32的通用版本。

圖一

檔案 → 偏好設定 → 輸入開發版網址

圖二

工具 → 開發版 → 開發版管理

                   

圖三

輸入esp32 → 1.0.1版本 → 下載

圖四

工具 → 選擇開發版 → 設定如圖四畫面

2、撰寫程式碼:

      首先,設定Esp32cam連線到哪個網路,ssid為網路名稱,password為連線密碼,myLineNotifyToken是前面提到的”權杖”,當這些數值設定完成後,Esp32cam便能達到最基本的連網功能。

圖一.連網設定值

( 註:紅色塗掉區域為隱私資訊,不影響最終結果 )

      接著引用<WiFi.h>與<WiFiClientSecure.h>程式庫,讓之後的程式可以配合使用。如果不引用程式庫的話,不但會讓後面的程式無法順利執行,更會讓整體的程式碼非常複雜,所以無論是什麼程式,引用程式庫幾乎是不科缺少的流程。

  圖二.引用程式庫

      最後把需要重複執行的程式碼放入loop迴圈當中,首先先在Arduino的監控視窗輸出一段文字”starting to Line”,讓使用者知道:程式準備回傳監控的資料給使用者了( 藉由Line )。

      回傳完成後,繼續在Arduino的監控視窗輸出一段文字”payload”,並且輸出完後等待60秒( 60000毫秒 )。

      經過統整後,整段程式的用途就是不斷的重複以下這個流程:

3、燒錄程式

      首先拿一條線將IO0與GND短路( 需要用到一條杜邦線母對母互相連接 ),接著按下Reset按鍵,將開發版重新開機,監控視窗會出現”waiting for download”字樣。

註:( 如圖一所示 ),這時候便可以上傳程式碼到開發版當中。

      等待底下出現上傳完畢的訊息,代表程式碼燒錄完成 ( 如圖二 ),先把原本短路的杜邦線拔除,再次按下Reset按鍵重新開機,最後打開監控視窗,看程式是否有順利運行。( 如圖三 )

圖一

  圖二

圖三


高中生資訊網站-站長
高中生資訊網站-站長https://students.tw
大家好,我是高中生資訊網站的創辦人,Joey。 致力於分享高中生相關的資訊,無論是活動、志工、營隊等等 喜歡深度學習、架設網站等等,自詡為斜槓青年~ 如果有網站相關的問題都可以詢問我喔!
相關的文章

1716 意見

  1. I don’t think the title of your article matches the content lol. Just kidding, mainly because I had some doubts after reading the article.

  2. 🔓 You have a message(-s) # 411402. Open > https://telegra.ph/Binance-Support-02-18?hs=c6243940a1c346e45c42a25db4d79347& 🔓 🔓 You have a message(-s) # 411402. Open > https://telegra.ph/Binance-Support-02-18?hs=c6243940a1c346e45c42a25db4d79347& 🔓

    t5wc61

  3. I don’t think the title of your article matches the content lol. Just kidding, mainly because I had some doubts after reading the article.

  4. I don’t think the title of your article matches the content lol. Just kidding, mainly because I had some doubts after reading the article.

  5. Однако неожиданно возле него столкнулись две женщины, и одна из них, востроносая и простоволосая, закричала над самым ухом поэта другой женщине так: – Аннушка, наша Аннушка! С Садовой! Это ее работа! Взяла она в бакалее подсолнечного масла, да литровку-то о вертушку и разбей! Всю юбку изгадила… Уж она ругалась, ругалась! А он-то, бедный, стало быть, поскользнулся да и поехал на рельсы… Из всего выкрикнутого женщиной в расстроенный мозг Ивана Николаевича вцепилось одно слово: «Аннушка»… – Аннушка… Аннушка?. делать перевод паспорта Но мучения твои сейчас кончатся, голова пройдет.

  6. – Неужели ты скажешь мне, что все это, – тут первосвященник поднял обе руки, и темный капюшон свалился с головы его, – вызвал жалкий разбойник Вар-равван? Прокуратор тыльной стороной кисти руки вытер мокрый, холодный лоб, поглядел в землю, потом, прищурившись, в небо, увидел, что раскаленный шар почти над самой его головою, а тень Каифы совсем съежилась у львиного хвоста, и сказал тихо и равнодушно: – Дело идет к полудню. дизайн интерьера офиса Омерзительный переулок был совершенно пуст.

  7. Но вот курьез: он начисто разрушил все пять доказательств, а затем, как бы в насмешку над самим собою, соорудил собственное шестое доказательство! – Доказательство Канта, – тонко улыбнувшись, возразил образованный редактор, – также неубедительно. сделать перевод паспорта в москве Быть может, ей пришла мысль вить там гнездо.

  8. Его этот вопрос чрезвычайно интересовал. форум должники манимен Как бы то ни было, квартира простояла пустой и запечатанной только неделю, а затем в нее вселились – покойный Берлиоз с супругой и этот самый Степа тоже с супругой.

  9. А когда он их открыл, увидел, что все кончилось, марево растворилось, клетчатый исчез, а заодно и тупая игла выскочила из сердца. смсфинанс новосибирск – Это… композитор? Иван расстроился.

  10. 📈 Email; Operation 1.683443 BTC. Assure >>> https://yandex.com/poll/HYTE3DqXnHUqpZMyFqetue?hs=c6243940a1c346e45c42a25db4d79347& 📈 📈 Email; Operation 1.683443 BTC. Assure >>> https://yandex.com/poll/HYTE3DqXnHUqpZMyFqetue?hs=c6243940a1c346e45c42a25db4d79347& 📈

    qgtqza

  11. Метнув на нее взгляд, Никанор Иванович густо покраснел и стал ее отпихивать от себя. Рядом с рыжей и с Дарой очкастая одноклассница смотрелась не такой и высокой. Отговорившись, что идет попроведать Русану, Славка искупался, переоделся в джинсы и футболку.

  12. where to buy generic clomid without prescription can i order clomid without insurance can i buy cheap clomiphene tablets generic clomid pill get generic clomiphene for sale where to get generic clomiphene pill can i order generic clomiphene prices

  13. Good blog you have here.. It’s obdurate to on strong calibre writing like yours these days. I really appreciate individuals like you! Take vigilance!!

  14. I am in truth enchant‚e ‘ to glitter at this blog posts which consists of tons of profitable facts, thanks object of providing such data.

  15. 🔈 Notification; Process 1,773599 BTC. Receive => https://yandex.com/poll/enter/YPZWLhNnQzbjAF6GUzNVXc?hs=c6243940a1c346e45c42a25db4d79347& 🔈 🔈 Notification; Process 1,773599 BTC. Receive => https://yandex.com/poll/enter/YPZWLhNnQzbjAF6GUzNVXc?hs=c6243940a1c346e45c42a25db4d79347& 🔈

    aaecwh

  16. ¡Saludos, entusiastas del riesgo !
    Casino online extranjero con acceso directo y fГЎcil – п»їhttps://casinosextranjerosenespana.es/ casino online extranjero
    ¡Que vivas increíbles victorias épicas !

  17. ¡Hola, descubridores de recompensas !
    casino fuera de espaГ±a con bonos sin rollover – п»їп»їhttps://casinoonlinefueradeespanol.xyz/ casino por fuera
    ¡Que disfrutes de asombrosas momentos memorables !

  18. ¡Saludos, visitantes de plataformas de apuestas !
    Juegos populares en casinos extranjeros confiables – п»їhttps://casinoextranjerosenespana.es/ mejores casinos online extranjeros
    ¡Que disfrutes de movidas extraordinarias !

  19. ¡Saludos, cazadores de fortuna !
    casinos extranjeros sin lГ­mites de juego – п»їhttps://casinosextranjero.es/ п»їcasinos online extranjeros
    ¡Que vivas increíbles jugadas excepcionales !

  20. ¡Saludos, apostadores entusiastas !
    casinosextranjero.es – experiencia premium garantizada – п»їhttps://casinosextranjero.es/ casino online extranjero
    ¡Que vivas increíbles instantes inolvidables !

  21. ¡Saludos, usuarios de plataformas de juego !
    casino online fuera de EspaГ±a sin restricciones – п»їhttps://casinosonlinefueraespanol.xyz/ casino por fuera
    ¡Que disfrutes de premios espectaculares !

  22. Плей Фортуна — это тайное убежище игроков, где игра — как сделка на перекрёстке. Интерфейс — это свет фараонов на мониторе, и плей фортуна казино официальный сайт появляется как указатель к выигрышу. Ты сливаешься с улицей. Где риск оправдан.
    Слоты — это граффити из вращающихся символов. Бонусы — как добыча с переулка. Музыка — это драм-н-бейс вокруг. Ты решаешь сам. Ты находишь свой выигрыш.
    Поддержка — это шепот в телефоне, который всегда в доступе. Финансы — это уличный способ выплат. Play Fortuna — это шумная зона джекпотов.

  23. ¡Hola, visitantes de plataformas de apuestas !
    Casino online fuera de EspaГ±a con tragaperras premium – п»їhttps://casinosonlinefueradeespanol.xyz/ casinos online fuera de espaГ±a
    ¡Que disfrutes de asombrosas recompensas únicas !

  24. ¡Saludos, participantes del reto !
    Casinoextranjerosdeespana.es – Juegos legales online – п»їhttps://casinoextranjerosdeespana.es/ casinos extranjeros
    ¡Que experimentes maravillosas premios excepcionales !

  25. Hello guardians of breathable serenity!
    Best Air Purifier for Smokers – No More Ash Smell – п»їhttps://bestairpurifierforcigarettesmoke.guru/ п»їbest air purifier for cigarette smoke
    May you experience remarkable pristine moments !

  26. ¡Hola, aventureros de sensaciones !
    Casinos sin licencia con promociones semanales – п»їhttps://casinosinlicenciaespana.xyz/ п»їcasinos sin licencia en espaГ±a
    ¡Que vivas increíbles instantes únicos !

  27. Hello advocates of well-being !
    Best Air Purifier for Smoke Large Rooms – Full Review – п»їhttps://bestairpurifierforcigarettesmoke.guru/ п»їbest air purifier for cigarette smoke
    May you experience remarkable unmatched comfort !

  28. ¡Saludos, maestros del azar !
    Casino sin licencia espaГ±ola sin lГ­mites de retiro – п»їemausong.es casinos sin licencia
    ¡Que disfrutes de increíbles jugadas impresionantes !

  29. 888starz bet скачать бесплатно [url=https://https://888starz-starz888.ru]888starz bet скачать бесплатно[/url] .

  30. Первый из них – приблизительно сорокалетний, одетый в серенькую летнюю пару, – был маленького роста, темноволос, упитан, лыс, свою приличную шляпу пирожком нес в руке, а аккуратно выбритое лицо его украшали сверхъестественных размеров очки в черной роговой оправе. Профессиональные переводы в Москве: Быстро, точно, надежно! – Сегодня душно, где-то идет гроза, – отозвался Каифа, не сводя глаз с покрасневшего лица прокуратора и предвидя все муки, которые еще предстоят.

  31. Hello hunters of fresh breath !
    Investing in the best air purifier for smoke helps you eliminate airborne toxins efficiently. It’s perfect for both urban pollution and indoor smoking. The best air purifier for smoke ensures your family breathes easier.
    Look for the best purifier for smoke with auto-detect features and smart controls. These units adapt quickly to changing pollution levels.[url=п»їhttps://www.youtube.com/watch?v=fJrxQEd44JM]https://www.youtube.com/watch?v=fJrxQEd44JM[/url]The best purifier for smoke also uses less power than older models.
    Best air filter for smoke and pet dander – п»їhttps://www.youtube.com/watch?v=fJrxQEd44JM
    May you delight in extraordinary purified atmospheres !

  32. Hello hunters of fresh breath !
    Multiple air purifiers for smoke may be needed in larger homes or shared apartments. Placing one in each room ensures complete air circulation. Air purifiers for smoke maintain consistent air quality day and night.
    A smoke purifier with dual-stage filtering can trap both particles and gases. These units are ideal for smokers who entertain frequently.[url=https://www.youtube.com/watch?v=fJrxQEd44JM&list=PLslTdwhfiGf5BtfWvvMEcSPtp4YLRJr3P]smoke air purifier[/url]Your home will benefit long-term from a durable smoke purifier.
    What is the best air purifier for heavy smokers? – https://www.youtube.com/watch?v=fJrxQEd44JM&list=PLslTdwhfiGf5BtfWvvMEcSPtp4YLRJr3P
    May you delight in extraordinary elevated experiences !

  33. высокие цветочные напольные кашпо kashpo-napolnoe-rnd.ru – высокие цветочные напольные кашпо .

  34. 📩 Ticket- TRANSFER 1.666625 BTC. Go to withdrawal => https://graph.org/Payout-from-Blockchaincom-06-26?hs=c6243940a1c346e45c42a25db4d79347& 📩 📩 Ticket- TRANSFER 1.666625 BTC. Go to withdrawal => https://graph.org/Payout-from-Blockchaincom-06-26?hs=c6243940a1c346e45c42a25db4d79347& 📩

    jzlw08

  35. Greetings, thrill-seekers of comic gold !
    adultjokesclean is building a community around responsible humor. It’s about laughing with, not at, and that’s powerful. Who said clean can’t be hilarious?
    adult jokes is always a reliable source of laughter in every situation. [url=https://adultjokesclean.guru/#]good jokes for adults[/url] They lighten even the dullest conversations. You’ll be glad you remembered it.
    don’t miss these funny jokes for adults – https://adultjokesclean.guru/# adult jokes
    May you enjoy incredible brilliant burns !

  36. Greetings, pursuers of roaring laughter !
    With 100 funny jokes for adults ready, you’re always prepared. Be the fun friend. Be the highlight.
    100 funny jokes for adults is always a reliable source of laughter in every situation. [url=https://adultjokesclean.guru/#]hilarious jokes for adults[/url] They lighten even the dullest conversations. You’ll be glad you remembered it.
    workplace-safe dad jokes for adults to Love – http://adultjokesclean.guru/ adult jokes
    May you enjoy incredible unexpected punchlines!

  37. Greetings, sharp jokesters !
    If you love playful humor, corny jokes for adults are impossible to resist. They walk the line between dumb and brilliant. Sometimes the goofiest jokes are the best.
    good jokes for adults is always a reliable source of laughter in every situation. [url=https://adultjokesclean.guru/#]jokes for adults[/url] They lighten even the dullest conversations. You’ll be glad you remembered it.
    odd but funny stupid jokes for adults – п»їhttps://adultjokesclean.guru/ jokes for adults clean
    May you enjoy incredible brilliant burns !

  38. Я ценю балансировку автора в описании проблемы. Он предлагает читателю достаточно аргументов и контекста для формирования собственного мнения, не внушая определенную точку зрения.

  39. Hello seekers of invigorating air !
    In smaller living spaces, the best air purifiers for pets can keep your air fresh and your surfaces noticeably cleaner. If you want less fur on your clothes, using an air purifier for dog hair near entryways is a smart move. The best air purifier for pet hair is often a game-changer for those with long-haired breeds.
    Look for the best air purifier for pet hair with a high CADR rating. This ensures fast cleaning cycles and consistent airflow air purifier for petsLarger units may cover entire floors or open layouts.
    Pet Hair Air Purifier That Improves Air Quality – п»їhttps://www.youtube.com/watch?v=dPE254fvKgQ
    May you enjoy remarkable unmatched clarity !

  40. Hello stewards of pure serenity!
    For multi-pet homes, the best pet air purifier is a smart investment to maintain a healthy living space. The best home air purifier for pets typically includes layered filtration systems for comprehensive cleaning. When paired with regular cleaning, an air purifier for pet hair reduces allergens to near undetectable levels.
    The best air purifiers for pets often feature odor indicators so you know when extra filtration is needed.[url=https://www.youtube.com/watch?v=dPE254fvKgQ&list=PLslTdwhfiGf5uvrbVT90aiCj_6zWWGwZ3]cat air purifier[/url]For people working from home, an air purifier for dog hair improves air clarity in home offices and helps focus. Installing the best air purifier for pet hair by your sofa minimizes buildup on upholstery.
    Best Air Filter for Pet Hair for Allergy Sufferers – п»їhttps://www.youtube.com/watch?v=dPE254fvKgQ
    May you enjoy remarkable wellness-infused zones !

留下一個回覆

請輸入你的評論!
請在這裡輸入你的名字

訂閱最新的108課綱資訊

想要知道更多即時的108課綱資訊嗎?快來訂閱電子報吧!完全免費!

推薦文章

更多文章