{"id":4577,"date":"2025-10-29T09:35:30","date_gmt":"2025-10-29T16:35:30","guid":{"rendered":"https:\/\/www.donluc.com\/?p=4577"},"modified":"2025-10-29T09:35:30","modified_gmt":"2025-10-29T16:35:30","slug":"project-16-sound-esp32-mk27","status":"publish","type":"post","link":"https:\/\/www.donluc.com\/?p=4577","title":{"rendered":"Project #16: Sound \u2013 ESP32 \u2013 Mk27"},"content":{"rendered":"<div style=\"width: 1200px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-4577-1\" width=\"1200\" height=\"675\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03W.mp4?_=1\" \/><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03W.mp4\">https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03W.mp4<\/a><\/video><\/div>\n<p>&#8212;&#8212;<\/p>\n<p>#DonLucElectronics #DonLuc #MiniMP3Player #FireBeetle2ESP32E #ESP32 #DFRobot #Display #IoT #Project #Fritzing #Programming #Electronics #Microcontrollers #Consultant<\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03a.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03a.jpg\" alt=\"ESP32\" width=\"720\" height=\"740\" class=\"alignnone size-full wp-image-4579\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03a.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03a-292x300.jpg 292w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03b.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03b.jpg\" alt=\"ESP32\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-4580\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03b.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03b-300x200.jpg 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03c.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03c.jpg\" alt=\"ESP32\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-4581\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03c.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2025\/10\/DL2510Mk03c-300x200.jpg 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><strong>FireBeetle 2 ESP32-E<\/strong><\/p>\n<p>FireBeetle 2 ESP32-E, specially designed for IoT, is an ESP-WROOM-32E-based main controller board with dual-core chips. FireBeetle 2 ESP32-E supports Arduino programming, support Scratch graphical programming and MicroPython programming. We provide you with detailed online tutorials and application cases, and there are thousands of sensors with welding-free Gravity interfaces and actuators to help you get started easily. Besides, the stamp hole design makes it able to be easily embedded in your PCB, greatly saving your costs and time to build and test a prototype. <\/p>\n<p><strong>Gravity: Digital Push Button (Red)<\/strong><\/p>\n<p>Digital push button with LED, wide voltage range, durable design, and easy plug-and-play functionality. Comes with a cable and features a gold surface.<\/p>\n<p><strong>Gravity: Analog Rotation Potentiometer Sensor<\/strong><\/p>\n<p>This Arduino-compatible rotation potentiometer rotates 300 degrees, allowing easy interaction and MIDI production with expansion boards; works on 3.3V-5V.<\/p>\n<p><strong>MP3<\/strong><\/p>\n<p>1.mp3 &#8211; William Shakespeare<br \/>\n2.mp3 &#8211; Albert Einstein<br \/>\n3.mp3 &#8211; Luc Paquin<br \/>\n4.mp3 &#8211; Carl Sagan<br \/>\n5.mp3 &#8211; Dalek<\/p>\n<p><strong>DL2510Mk03<\/strong><\/p>\n<p>1 x DFRobot FireBeetle 2 ESP32-E<br \/>\n1 x Fermion: 2.0&#8243; 320&#215;240 IPS TFT LCD<br \/>\n1 x GDL Line 10 CM<br \/>\n1 x Gravity: IO Shield for FireBeetle 2<br \/>\n1 x Mini MP3 Player<br \/>\n1 x 1K Ohm Resistor<br \/>\n1 x Speaker<br \/>\n1 x Gravity: Analog Rotation Potentiometer<br \/>\n1 x Gravity: Digital Push Button (Red)<br \/>\n1 x Lithium Ion Battery &#8211; 1000mAh<br \/>\n1 x Switch<br \/>\n1 x SPDT Slide Switch<br \/>\n1 x USB-A to Micro-B Cable<\/p>\n<p><strong>DL2510Mk03p<\/strong><\/p>\n<p><strong>DL2510Mk03p.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/****** Don Luc Electronics \u00a9 ******\r\nSoftware Version Information\r\nProject #16: Sound \u2013 ESP32 \u2013 Mk27\r\n16-27\r\nDL2509Mk03p.ino\r\nDL2509Mk03\r\n1 x DFRobot FireBeetle 2 ESP32-E\r\n1 x Fermion: 2.0&quot; 320x240 IPS TFT LCD\r\n1 x GDL Line 10 CM\r\n1 x Gravity: IO Shield for FireBeetle 2\r\n1 x Mini MP3 Player\r\n1 x 1K Ohm Resistor\r\n1 x Gravity: Analog Rotation Potentiometer\r\n1 x Gravity: Digital Push Button (Red)\r\n1 x Speaker\r\n1 x Lithium Ion Battery - 1000mAh\r\n1 x Switch\r\n1 x SPDT Slide Switch\r\n1 x USB-A to Micro-B Cable\r\n*\/\r\n\r\n\/\/ Include the Library Code\r\n\/\/ EEPROM Library to Read and Write EEPROM\r\n\/\/ with Unique ID for Unit\r\n#include &quot;EEPROM.h&quot;\r\n\/\/ Arduino\r\n#include &quot;Arduino.h&quot;\r\n\/\/ DFRobot Display GDL API\r\n#include &lt;DFRobot_GDL.h&gt;\r\n\/\/ DFRobot DFPlayer Mini\r\n#include &quot;DFRobotDFPlayerMini.h&quot;\r\n\r\n\/\/ FPSerial\r\n#define FPSerial Serial1\r\n\r\n\/\/ DFRobot DFPlayer Mini\r\nDFRobotDFPlayerMini myDFPlayer;\r\n\r\n\/\/ Button R\r\nint iButR = D12;\r\nint iValR;\r\n\r\n\/\/ Volume Potentiometer\r\nint iVolPot = A0;\r\nint iValV;\r\n\r\n\/\/ Defined ESP32\r\n#define TFT_DC  D2\r\n#define TFT_CS  D6\r\n#define TFT_RST D3\r\n\r\n\/*dc=*\/ \/*cs=*\/ \/*rst=*\/\r\n\/\/ DFRobot Display 240x320\r\nDFRobot_ST7789_240x320_HW_SPI screen(TFT_DC, TFT_CS, TFT_RST);\r\n\r\n\/\/ EEPROM Unique ID Information\r\n#define EEPROM_SIZE 64\r\nString uid = &quot;&quot;;\r\n\r\n\/\/ Software Version Information\r\nString sver = &quot;16-27&quot;;\r\n\r\nvoid loop() {\r\n  \r\n  \/\/ isMP3\r\n  isMP3();\r\n\r\n  \/\/ isDisplayMP3\r\n  isDisplayMP3();\r\n\r\n  \/\/ Delay\r\n  delay( 200 );\r\n  \r\n}\r\n<\/pre>\n<p><strong>getDisplay.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ DFRobot Display 240x320\r\n\/\/ DFRobot Display 240x320 - UID\r\nvoid isDisplayUID(){\r\n\r\n  \/\/ DFRobot Display 240x320\r\n  \/\/ Text Display\r\n  \/\/ Text Wrap\r\n  screen.setTextWrap(false);\r\n  \/\/ Rotation\r\n  screen.setRotation(3);\r\n  \/\/ Fill Screen =&gt; black\r\n  screen.fillScreen(0x0000);\r\n  \/\/ Text Color =&gt; white\r\n  screen.setTextColor(0xffff);\r\n  \/\/ Font =&gt; Free Sans Bold 12pt\r\n  screen.setFont(&amp;FreeSansBold12pt7b);\r\n  \/\/ TextSize =&gt; 1.5\r\n  screen.setTextSize(1.5);\r\n  \/\/ Don Luc Electronics\r\n  screen.setCursor(0, 30);\r\n  screen.println(&quot;Don Luc Electronics&quot;);\r\n  \/\/ SD\r\n  screen.setCursor(0, 60);\r\n  screen.println(&quot;GDFPlayer Mini&quot;);\r\n  \/\/ Version\r\n  screen.setCursor(0, 90);\r\n  screen.println(&quot;Version&quot;);\r\n  screen.setCursor(0, 120);\r\n  screen.println( sver );\r\n  \/\/ EEPROM\r\n  screen.setCursor(0, 150);\r\n  screen.println(&quot;EEPROM&quot;);\r\n  screen.setCursor(0, 180);\r\n  screen.println( uid );\r\n\r\n}\r\n\/\/ isDisplayMP3\r\nvoid isDisplayMP3(){\r\n\r\n  \/\/ DFRobot Display 240x320\r\n  \/\/ Text Display\r\n  \/\/ Text Wrap\r\n  screen.setTextWrap(false);\r\n  \/\/ Rotation\r\n  screen.setRotation(3);\r\n  \/\/ Fill Screen =&gt; white\r\n  screen.fillScreen(0xffff);\r\n  \/\/ Text Color =&gt; blue\r\n  screen.setTextColor(0x001F);\r\n  \/\/ Font =&gt; Free Sans Bold 12pt\r\n  screen.setFont(&amp;FreeSansBold12pt7b);\r\n  \/\/ TextSize =&gt; 1.5\r\n  screen.setTextSize(1.5);\r\n  \/\/ Geiger\r\n  screen.setCursor(0, 30);\r\n  screen.println(&quot;MP3&quot;);\r\n  \/\/ 1.mp3 - William Shakespeare\r\n  screen.setCursor(0, 60);\r\n  screen.println(&quot;1.mp3 - William Shakespeare&quot;);\r\n  \/\/ 2.mp3 - Albert Einstein\r\n  screen.setCursor(0, 90);\r\n  screen.println( &quot;2.mp3 - Albert Einstein&quot; );\r\n  \/\/ 3.mp3 - Luc Paquin\r\n  screen.setCursor(0, 120);\r\n  screen.println( &quot;3.mp3 - Luc Paquin&quot; );\r\n\/\/ 4.mp3 - Carl Sagan\r\n  screen.setCursor(0, 150);\r\n  screen.println( &quot;4.mp3 - Carl Sagan&quot; );\r\n \/\/ 5.mp3 - Dalek\r\n  screen.setCursor(0, 180);\r\n  screen.println( &quot;5.mp3 - Dalek&quot; );\r\n  \r\n}\r\n<\/pre>\n<p><strong>getEEPROM.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ EEPROM\r\n\/\/ isUID EEPROM Unique ID\r\nvoid isUID() {\r\n  \r\n  \/\/ Is Unit ID\r\n  uid = &quot;&quot;;\r\n  for (int x = 0; x &lt; 7; x++)\r\n  {\r\n    uid = uid + char(EEPROM.read(x));\r\n  }\r\n\r\n}\r\n<\/pre>\n<p><strong>getMiniMP3.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ Mini MP3\r\n\/\/ isSetupMP3\r\nvoid isSetupMP3(){\r\n\r\n  \/\/ Mini MP3\r\n  \/\/ isACK\r\n  \/\/ doReset\r\n  myDFPlayer.begin(FPSerial, true, true);\r\n\r\n  \/\/ Set serial communictaion time out 500ms\r\n  myDFPlayer.setTimeOut(500);\r\n  \r\n}\r\n\/\/ isMP3\r\nvoid isMP3(){\r\n  \r\n  \/\/ Volume Potentiometer\r\n  iValV = analogRead(iVolPot);\r\n  \r\n  \/\/ Mapping function\r\n  iValV = map(iValV, 0, 4095, 0, 30);\r\n\r\n  \/\/ Set volume value. From 0 to 30\r\n  myDFPlayer.volume( iValV );\r\n\r\n  \/\/ iValR\r\n  iValR = digitalRead(iButR);\r\n\r\n  \/\/ Check high iButR is pressed down.\r\n  if (iValR == HIGH) { \r\n\r\n    \/\/ Play next mp3\r\n    myDFPlayer.next();\r\n\r\n  }\r\n  \r\n}\r\n<\/pre>\n<p><strong>setup.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ Setup\r\nvoid setup()\r\n{\r\n \r\n  \/\/ Delay\r\n  delay( 100 );\r\n\r\n  \/\/ EEPROM Size\r\n  EEPROM.begin(EEPROM_SIZE);\r\n\r\n  \/\/ EEPROM Unique ID\r\n  isUID();\r\n\r\n  \/\/ Delay\r\n  delay( 100 );\r\n\r\n  \/\/ FPSerial\r\n  \/\/ rx\r\n  \/\/ tx\r\n  FPSerial.begin(9600, SERIAL_8N1, D7, D5);\r\n\r\n  \/\/ Delay\r\n  delay( 100 );\r\n\r\n  \/\/ Button R\r\n  pinMode(iButR, INPUT);\r\n\r\n  \/\/ Delay\r\n  delay(100);\r\n\r\n  \/\/ isSetupMP3\r\n  isSetupMP3();\r\n\r\n  \/\/ Delay\r\n  delay(100);\r\n  \r\n  \/\/ DFRobot Display 240x320\r\n  screen.begin();\r\n\r\n  \/\/ Delay\r\n  delay(100);\r\n\r\n  \/\/ DFRobot Display 240x320 - UID\r\n  \/\/ Don Luc Electronics\r\n  \/\/ Version\r\n  \/\/ EEPROM\r\n  isDisplayUID();\r\n\r\n  \/\/ Delay 5 Second\r\n  delay( 5000 );\r\n\r\n  \r\n\r\n}\r\n<\/pre>\n<p>&#8212;&#8212;<\/p>\n<p><strong>People can contact us:<\/strong> https:\/\/www.donluc.com\/?page_id=1927<\/p>\n<p><strong>Consultant, R&#038;D, Electronics, IoT, Teacher and Instructor<\/strong><\/p>\n<ul>\n<li>Programming Language<\/li>\n<li>Single-Board Microcontrollers (PIC, Arduino, Raspberry Pi, Arm, Silicon Labs, Espressif, Etc&#8230;)<\/li>\n<li>IoT<\/li>\n<li>Wireless (Radio Frequency, Bluetooth, WiFi, Etc&#8230;)<\/li>\n<li>Robotics<\/li>\n<li>Automation<\/li>\n<li>Camera and Video Capture Receiver Stationary, Wheel\/Tank , Underwater and UAV Vehicle<\/li>\n<li>Unmanned Vehicles Terrestrial,  Marine and UAV<\/li>\n<li>Machine Learning<\/li>\n<li>Artificial Intelligence (AI)<\/li>\n<li>RTOS<\/li>\n<li>Sensors, eHealth Sensors, Biosensor, and Biometric<\/li>\n<li>Research &#038; Development (R &#038; D)<\/li>\n<li>Consulting<\/li>\n<\/ul>\n<p><strong>Follow Us<\/strong><\/p>\n<p><strong>Luc Paquin \u2013 Curriculum Vitae &#8211; 2024<\/strong><br \/>\nhttps:\/\/www.donluc.com\/luc\/<\/p>\n<p><strong>Web:<\/strong> https:\/\/www.donluc.com\/<br \/>\n<strong>Facebook:<\/strong> https:\/\/www.facebook.com\/neosteam.labs.9\/<br \/>\n<strong>YouTube:<\/strong> https:\/\/www.youtube.com\/@thesass2063<br \/>\n<strong>Twitter:<\/strong> https:\/\/twitter.com\/labs_steam<br \/>\n<strong>Pinterest:<\/strong> https:\/\/www.pinterest.com\/NeoSteamLabs\/<br \/>\n<strong>Instagram:<\/strong> https:\/\/www.instagram.com\/neosteamlabs\/<br \/>\n<strong>DFRobot:<\/strong> https:\/\/learn.dfrobot.com\/user-10186.html<br \/>\n<strong>Elecrow:<\/strong> https:\/\/www.elecrow.com\/share\/sharepj\/center\/no\/760816d385ebb1edc0732fd873bfbf13<br \/>\n<strong>TikTok:<\/strong> https:\/\/www.tiktok.com\/@luc.paquin8<br \/>\n<strong>Hackster:<\/strong> https:\/\/www.hackster.io\/luc-paquin<br \/>\n<strong>LinkedIn:<\/strong> https:\/\/www.linkedin.com\/in\/jlucpaquin\/<\/p>\n<p><strong>Don Luc<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8212;&#8212; #DonLucElectronics #DonLuc #MiniMP3Player #FireBeetle2ESP32E #ESP32 #DFRobot #Display #IoT #Project #Fritzing #Programming #Electronics #Microcontrollers #Consultant &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; FireBeetle 2 ESP32-E FireBeetle 2 ESP32-E, specially designed for IoT, is an ESP-WROOM-32E-based main controller board with dual-core chips. FireBeetle 2 ESP32-E supports Arduino programming, support Scratch graphical programming and MicroPython programming. We provide you with &#8230; <a title=\"Project #16: Sound \u2013 ESP32 \u2013 Mk27\" class=\"read-more\" href=\"https:\/\/www.donluc.com\/?p=4577\" aria-label=\"Read more about Project #16: Sound \u2013 ESP32 \u2013 Mk27\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[119,50,49,61,317,38,368,80,59,115,5,287,58,82],"tags":[6,92,102,4,320,87,369,19,83,85,24,9,84,27,120,33,34,108],"class_list":["post-4577","post","type-post","status-publish","format-standard","hentry","category-sound","category-arduino","category-consultant","category-dayton","category-dfrobot","category-digitalelectronics","category-elecrow","category-esp32","category-fritzing","category-e-mentor","category-microcontrollers","category-program","category-arduino-programming","category-program-esp32","tag-arduino","tag-battery","tag-components","tag-consultant","tag-dfrobot","tag-display","tag-elecrow","tag-electronics","tag-esp32","tag-fritzing","tag-microcontroller","tag-programming","tag-programming-esp32","tag-projects-2","tag-sound","tag-technology","tag-video-blog","tag-vlog"],"_links":{"self":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4577","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4577"}],"version-history":[{"count":2,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4577\/revisions"}],"predecessor-version":[{"id":4832,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4577\/revisions\/4832"}],"wp:attachment":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4577"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4577"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4577"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}