{"id":17170,"date":"2023-02-13T16:12:36","date_gmt":"2023-02-13T21:12:36","guid":{"rendered":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/?p=17170"},"modified":"2023-02-22T10:20:49","modified_gmt":"2023-02-22T15:20:49","slug":"double-transducer-transparency-to-water-level","status":"publish","type":"post","link":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/double-transducer-transparency-to-water-level\/","title":{"rendered":"Double Transducer: Transparency to Water Level"},"content":{"rendered":"<p style=\"text-align: center\">Full View:<\/p>\n<div id=\"attachment_17215\" style=\"width: 2570px\" class=\"wp-caption aligncenter\"><img aria-describedby=\"caption-attachment-17215\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17215 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-scaled.jpg\" alt=\"Top level view of project showing Arduino, transparency station, servo motor, potentiometer, peristaltic pump, and two graduated cylinders filled with water.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4153-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17215\" class=\"wp-caption-text\">Overall top-level view of project<\/p><\/div>\n<p>&nbsp;<\/p>\n<p>Yuxi<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17505\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222.jpg\" alt=\"\" width=\"1616\" height=\"1080\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222.jpg 1616w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-300x200.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-1024x684.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-768x513.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-1536x1027.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-973x650.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/DSC01222-508x340.jpg 508w\" sizes=\"(max-width: 1616px) 100vw, 1616px\" \/><\/p>\n<p>Overall view of the project<\/p>\n<p style=\"text-align: center\">~~~<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">Transparency station:<\/p>\n<p style=\"text-align: center\">Light valve is inserted between LED and photo-resistor<\/p>\n<div id=\"attachment_17220\" style=\"width: 2570px\" class=\"wp-caption aligncenter\"><img aria-describedby=\"caption-attachment-17220\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17220 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-scaled.jpeg\" alt=\"Transparency station with LED in front of photo-resistor with space in the middle for light valve.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-scaled.jpeg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-300x225.jpeg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-1024x768.jpeg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-768x576.jpeg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-1536x1152.jpeg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-2048x1536.jpeg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-973x730.jpeg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/EB721CFA-5F2D-4ABF-90CB-E7D971F54EF1-508x381.jpeg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17220\" class=\"wp-caption-text\">LED (off)<\/p><\/div>\n<div id=\"attachment_17221\" style=\"width: 2570px\" class=\"wp-caption aligncenter\"><img aria-describedby=\"caption-attachment-17221\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17221 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-scaled.jpeg\" alt=\"Transparency station with LED in front of photo-resistor with space in the middle for light valve. LED is on.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-scaled.jpeg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-300x225.jpeg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-1024x768.jpeg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-768x576.jpeg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-1536x1152.jpeg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-2048x1536.jpeg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-973x730.jpeg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/367A01DA-BCBC-49B2-B4E1-F5A157AEEEAE-508x381.jpeg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17221\" class=\"wp-caption-text\">LED (on)<\/p><\/div>\n<p>&nbsp;<\/p>\n<p>Yuxi<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17432\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-scaled.jpg\" alt=\"\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/LED-Off-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><\/p>\n<p>LED OFF<\/p>\n<p>&nbsp;<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17433\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-scaled.jpeg\" alt=\"\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-scaled.jpeg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-300x225.jpeg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-1024x768.jpeg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-768x576.jpeg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-1536x1152.jpeg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-2048x1536.jpeg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-973x730.jpeg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Photoresistor-LED-ON-508x381.jpeg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><\/p>\n<p>LED ON<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">~~~<\/p>\n<p style=\"text-align: center\">Servo -&gt; Potentiometer:<\/p>\n<div id=\"attachment_17223\" style=\"width: 2570px\" class=\"wp-caption aligncenter\"><img aria-describedby=\"caption-attachment-17223\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17223 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-scaled.jpg\" alt=\"Servo motor attached to potentiometer with wires\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/9F0F8452-335E-4994-BB42-E43A148BA3CA-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17223\" class=\"wp-caption-text\">Servo motor attached to potentiometer<\/p><\/div>\n<p>&nbsp;<\/p>\n<p>Yuxi<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17506\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-scaled.jpg\" alt=\"\" width=\"1920\" height=\"2560\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-scaled.jpg 1920w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-225x300.jpg 225w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-768x1024.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-1152x1536.jpg 1152w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-1536x2048.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-973x1297.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/ServoMotor-Potentiometer-508x677.jpg 508w\" sizes=\"(max-width: 1920px) 100vw, 1920px\" \/><\/p>\n<p>Servo motor physically connected to the potentiometer (by hot glue)<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">~~~<\/p>\n<p style=\"text-align: center\">Video Demo:<\/p>\n<div style=\"width: 620px;\" class=\"wp-video\"><!--[if lt IE 9]><script>document.createElement('video');<\/script><![endif]-->\n<video class=\"wp-video-shortcode\" id=\"video-17170-1\" width=\"620\" height=\"1102\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/4FED25E8-D9D3-48D1-8F8D-AE022B2EC06C.mp4?_=1\" \/><a href=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/4FED25E8-D9D3-48D1-8F8D-AE022B2EC06C.mp4\">https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/4FED25E8-D9D3-48D1-8F8D-AE022B2EC06C.mp4<\/a><\/video><\/div>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">Simple Narrative:<\/p>\n<p style=\"text-align: center\">A square that can change its transparency called a light valve is placed between the LED and photo-resistor. This triggers the servo motor (blue motor on the right) to twist which in turn twists the potentiometer. This triggers the pump to vary the water level in the cylinders.<\/p>\n<p>&nbsp;<\/p>\n<div style=\"width: 620px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-17170-2\" width=\"620\" height=\"349\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/video.mp4?_=2\" \/><a href=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/video.mp4\">https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/video.mp4<\/a><\/video><\/div>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">Simple Narrative:<\/p>\n<p style=\"text-align: center\">The photoresistor receives the light signal from the LED, which triggers the rotation of the blue servo motor, which physically controls the rotation of the potentiometer and eventually triggers the water pump to change the water level.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">&#8212;<\/p>\n<p style=\"text-align: center\">Mid-process Photos:<\/p>\n<div id=\"attachment_17222\" style=\"width: 2570px\" class=\"wp-caption aligncenter\"><img aria-describedby=\"caption-attachment-17222\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17222 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-scaled.jpg\" alt=\"A black aluminum cover covering the transparency station for more accurate readings.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/961CEA32-E01A-45C5-97F3-6C0380CEBF85-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17222\" class=\"wp-caption-text\">Custom dark room cover for transparency station in order to get more accurate readings of the light valve.<\/p><\/div>\n<p>&nbsp;<\/p>\n<div id=\"attachment_17275\" style=\"width: 2570px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-17275\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17275 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-scaled.jpg\" alt=\"Servo motor attached to potentiometer with wires.\" width=\"2560\" height=\"2149\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-300x252.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-1024x860.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-768x645.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-1536x1289.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-2048x1719.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-973x817.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4162-508x426.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17275\" class=\"wp-caption-text\">We chose to attach the servo motor with the potentiometer by inserting a popsicle stick in the potentiometer knob and then wrapping wire around the servo arm and the stick.<\/p><\/div>\n<p>&nbsp;<\/p>\n<div id=\"attachment_17272\" style=\"width: 2570px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-17272\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17272 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-scaled.jpg\" alt=\"Initial basic layout of all components of the double transducer showing the Arduino, breadboard, LED, photo-resistor, servo motor, potentiometer, pump, and two empty cylinders.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4134-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17272\" class=\"wp-caption-text\">Initial basic layout of all components of the double transducer.<\/p><\/div>\n<p>&nbsp;<\/p>\n<div id=\"attachment_17274\" style=\"width: 2570px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-17274\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-17274 size-full\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-scaled.jpg\" alt=\"Small bread board with popsicle sticks glued to it to act as a slot for the square light valve for easy insert.\" width=\"2560\" height=\"1920\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-scaled.jpg 2560w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-300x225.jpg 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-1024x768.jpg 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-768x576.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-1536x1152.jpg 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-2048x1536.jpg 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-973x730.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/IMG_4138-508x381.jpg 508w\" sizes=\"(max-width: 2560px) 100vw, 2560px\" \/><p id=\"caption-attachment-17274\" class=\"wp-caption-text\">Custom slot for light valve for other team to easily insert their light valve into our station.<\/p><\/div>\n<p>&nbsp;<\/p>\n<p>Yuxi<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17507\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d.png\" alt=\"\" width=\"2440\" height=\"1818\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d.png 2440w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-300x224.png 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-1024x763.png 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-768x572.png 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-1536x1144.png 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-2048x1526.png 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-973x725.png 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/\u672a\u547d\u540d-508x379.png 508w\" sizes=\"(max-width: 2440px) 100vw, 2440px\" \/><\/p>\n<p>We try to connect servo motor and potentiometer directly with hot glue by a simpler method.<\/p>\n<p>&nbsp;<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17508\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111.png\" alt=\"\" width=\"2442\" height=\"1822\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111.png 2442w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-300x224.png 300w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-1024x764.png 1024w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-768x573.png 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-1536x1146.png 1536w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-2048x1528.png 2048w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-973x726.png 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/111-508x379.png 508w\" sizes=\"(max-width: 2442px) 100vw, 2442px\" \/><\/p>\n<p>We solved the problem of how to connect the pump to the Arduino Uno. The key is that we need a motor driver and how we need to connect it.<\/p>\n<p>&nbsp;<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17509\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222.png\" alt=\"\" width=\"1358\" height=\"1798\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222.png 1358w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-227x300.png 227w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-773x1024.png 773w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-768x1017.png 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-1160x1536.png 1160w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-973x1288.png 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/222-508x673.png 508w\" sizes=\"(max-width: 1358px) 100vw, 1358px\" \/><\/p>\n<p>When trying to get LCD Screen to work, the code would run on the simulator, but not on the actual LCD Screen. Finally it turned out to be a material problem.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center\">~~~<\/p>\n<p style=\"text-align: center\">Discussion:<\/p>\n<p style=\"text-align: left\">This project had its ups and downs. The best part was getting exposed to such a variety of devices and getting to put together a working gadget. We learned how to combine code with hardware, wire up circuits, write block diagrams and transfer said block diagrams to real circuits.<\/p>\n<p style=\"text-align: left\">Surprisingly, the part that was the easiest was getting the rudimentary signal to flow through the gadget (input to output). The hardest part was mapping the input signal to the output signal in a continuous fashion. The physical placing of the parts on the board was also challenging, since there were many wires and moving parts (literally) that hindered the goal of making a clean, intuitive layout.<\/p>\n<p>This project was also a great way to spread one&#8217;s wings creatively, since we could pick any intermediate transducer we wanted and create a narrative with our final project. Our narrative was of a sun and moon that would rise and set due to the change in water level in the graduated cylinders.<\/p>\n<p>The next step will be to focus on project 2, which is a great opportunity for us to work independently. Also losing the fixed theme, our creativity becomes more important and can be better reflected. This does not only mean a bigger challenge, but also an opportunity for us to make more progress. We hope to use the experience we have gained to better our next project.<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-17500\" src=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1.jpg\" alt=\"\" width=\"1541\" height=\"2051\" srcset=\"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1.jpg 1541w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-225x300.jpg 225w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-769x1024.jpg 769w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-768x1022.jpg 768w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-1154x1536.jpg 1154w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-1539x2048.jpg 1539w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-973x1295.jpg 973w, https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-content\/uploads\/2023\/02\/Project-1-508x676.jpg 508w\" sizes=\"(max-width: 1541px) 100vw, 1541px\" \/><\/p>\n<p>&nbsp;<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"c\">\/\/ Double Transducer: Transparency -&gt; Rotation -&gt; Water Level\r\n\/\/ Contributors: Cameron, Ethan\r\n\/\/ Date: 2\/15\/23\r\n\/\/ This code facilitates the signal inputted by the photoresistor into an output signal\r\n\/\/ to the servo motor, which triggers a signal to the potentiometer which signals the\r\n\/\/ persitaltic pump.\r\n\/\/\r\n\/\/                   ---------------------------\r\n\/\/                   |   PIN        |  LABEL   |\r\n\/\/                   ---------------------------\r\n\/\/                   | PHOTORESPIN  |    A0    |\r\n\/\/                   | LEDPIN       |    6     |\r\n\/\/                   | PUMPPIN1     |    3     |\r\n\/\/                   | PUMPPIN2     |    4     |\r\n\/\/                   | SERVOPIN     |    10    |\r\n\/\/                   | POTENTPIN    |    A5    |\r\n\/\/                   ---------------------------\r\n\/\/ LCD Code from https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/tutorials\/I2C-lcd\r\n\/\/ by Robert Zacharias\r\n\r\n\r\n\/\/ LCD\r\n#include &lt;Wire.h&gt;\r\n#include &lt;LiquidCrystal_I2C.h&gt;\r\nLiquidCrystal_I2C screen(0x27, 16, 2);\r\nint x = 123;\r\n\r\nconst int PHOTORESPIN = A0;\r\nconst int  PHOTOMIN = 5;\r\nconst int PHOTOMAX = 980;\r\n\r\n\r\nconst int LEDPIN = 6;\r\nconst int LEDMAX = 255;\r\nconst int LEDMIN = 0;\r\n\r\nconst int PUMPPIN1 = 3;\r\nconst int PUMPPIN2 = 4;\r\n\r\n#include &lt;Servo.h&gt;\r\nServo motor;\r\nconst int SERVOPIN = 10;\r\nconst int  ROTMIN = 0;\r\nconst int ROTMAX = 150;\r\n\r\nconst int POTENTPIN = A5;\r\nint POTENTMAX = 631;\r\nint POTENTMIN = 276;\r\n\r\n\/\/ GLOBALS\r\nint rot = 0;\r\nint new_rot = 0;\r\n\r\n\/\/ MACROS\r\n#define min(a, b) ((a) &lt; (b) ? (a) : (b))\r\n#define max(a, b) ((a) &gt; (b) ? (a) : (b))\r\n\r\n\r\n\/\/LCD SCREEN\r\nvoid lcd_loop(int photoVal, int rotVal, int potVal, int ml){\r\n  \/\/ just count up to show x changing (the rest of the text will remain untouched)\r\n  screen.setCursor(0, 0);\r\n  screen.print(\"i:\");\r\n  screen.print(photoVal);\r\n  screen.print(\"  m:\");\r\n  screen.print(rotVal);\r\n\r\n  screen.setCursor(1, 9);\r\n  screen.print(\" -&gt;\");\r\n  screen.print(potVal);\r\n  screen.print(\" o:\");\r\n  screen.print(ml);\r\n  \r\n  delay(1000);\r\n}\r\n\r\n\/\/ set ups\r\nvoid potent_setup(){\r\n  pinMode(POTENTPIN, INPUT);\r\n}\r\n\r\n\r\nvoid pump_setup(){\r\n  pinMode(PUMPPIN1, OUTPUT);\r\n  pinMode(PUMPPIN2, OUTPUT);\r\n}\r\n\r\nvoid photo_setup(){\r\n  pinMode(PHOTORESPIN,INPUT);\r\n}\r\n\r\nvoid servo_setup(){\r\n  motor.attach(SERVOPIN);\r\n}\r\n\r\nvoid led_setup(){\r\n  pinMode(LEDPIN, OUTPUT);\r\n}\r\n\r\n\/\/ led loop\r\nvoid led_loop(int i){\r\n  Serial.print(\"LED AT LEVEL: \");\r\n  Serial.println(i);\r\n  analogWrite(LEDPIN, i);\r\n}\r\n\r\n\/\/ photo loop\r\nint photo_loop(){\r\n  int photoVal = analogRead(PHOTORESPIN);\r\n  Serial.print(\"Photo lvl: \");\r\n  Serial.println(photoVal);\r\n  return photoVal;\r\n}\r\n\r\n\r\n\/\/ pump loop\r\nint pump_loop(){\r\n  Serial.println(\"Turning on pump\");\r\n  int diff = abs(new_rot - rot);\r\n  \/\/ if(diff &lt; 50){\r\n  \/\/   return;\r\n  \/\/ }\r\n  int time = map(POTENTMIN + diff, POTENTMIN, POTENTMAX, 800, 3000);\r\n  \/\/ (we turned CW)\r\n  if(new_rot &gt; rot){\r\n    Serial.print(\"We are pumping CW for this many ms: \");\r\n    Serial.println(time);\r\n    digitalWrite(PUMPPIN1, HIGH);\r\n    delay(time);\r\n    digitalWrite(PUMPPIN1, LOW);\r\n  }\r\n  \/\/ (we turned C'CW)\r\n  if (new_rot &lt; rot){\r\n    Serial.print(\"We are pumping CCW for this many ms: \");\r\n    Serial.println(time);\r\n    digitalWrite(PUMPPIN2, HIGH);\r\n    delay(time);\r\n    digitalWrite(PUMPPIN2, LOW);\r\n  }\r\n  delay(time);\r\n  return time;\r\n  \r\n}\r\n\r\n\/\/ servo loop\r\nint servo_loop(int photoVal){\r\n  int rot = map(photoVal, PHOTOMIN, PHOTOMAX, ROTMIN, ROTMAX);\r\n  Serial.print(\"Servo rot: \");\r\n  Serial.println(rot);\r\n\r\n  motor.write(rot);\r\n  \/\/ return its rotation\r\n  return rot;\r\n}\r\n\r\n\/\/ potentiometer loop\r\nint potent_loop(){\r\n  int potVal = analogRead(POTENTPIN);\r\n  Serial.print(\"Pot val: \");\r\n  Serial.println(potVal);\r\n\r\n  \/\/ return its potential\r\n  return potVal;\r\n}\r\n\r\n\r\n\r\n\/\/*********\r\n\r\nvoid setup() {\r\n  Serial.begin(9600);\r\n\r\n  \/\/ debug_setup();\r\n\r\n  \/\/ LCD\r\n  lcd_setup();\r\n  \/\/ pump\r\n  pump_setup();\r\n  \/\/ photo\r\n  photo_setup();\r\n  \/\/servo\r\n  servo_setup();\r\n  \/\/led\r\n  led_setup();\r\n  \/\/ potent\r\n  potent_setup();\r\n\r\n}\r\nint i = 0;\r\nbool reset = 0;\r\n\r\nvoid loop() {\r\n  if(reset){\r\n    \/\/fill debug\r\n    digitalWrite(PUMPPIN2, HIGH);\r\n    delay(1000);\r\n    digitalWrite(PUMPPIN1, LOW);\r\n    delay(1000);\r\n  }\r\n  else{\r\n    Serial.println();\r\n\r\n    \/\/ \/\/ debug_loop();\r\n    \r\n    led_loop(255);\r\n\r\n    \/\/ read in from photo resistor\r\n    int pV = photo_loop();\r\n\r\n    \/\/ trigger server\r\n    int sV = servo_loop(pV);\r\n\r\n    \/\/ servo physically triggers potent\r\n\r\n    \/\/ read in potent\r\n    new_rot = potent_loop();\r\n    POTENTMAX = max(POTENTMAX, new_rot);\r\n    POTENTMIN = min(POTENTMIN, new_rot);\r\n\r\n    \/\/ trigger pump\r\n    int ml = pump_loop();\r\n    \r\n    lcd_loop(pV, sV, new_rot, ml);\r\n\r\n    rot = new_rot;\r\n    delay(1000);\r\n\r\n    i += 10;\r\n    if(i &gt;= LEDMAX){\r\n      i = LEDMAX;    \r\n    }\r\n  }\r\n\r\n  \r\n}\r\n\r\n\r\n\r\n\r\nvoid lcd_setup() {\r\n  \/\/ initialize the screen (only need to do this once)\r\n  screen.init();\r\n\r\n  \/\/ turn on the backlight to start\r\n  screen.backlight();\r\n\r\n  \/\/ set cursor to home position, i.e. the upper left corner\r\n  screen.home();\r\n  \/\/ print the words Hello, world! onto the screen starting at the above cursor position\r\n  screen.print(\"Hello, world!\");\r\n\r\n  \/\/ move cursor to column 0, row 1\r\n  screen.setCursor(0, 1);\r\n  \/\/ print text starting in that position\r\n  screen.print(\"2nd row text\");\r\n  \r\n  \r\n  screen.display();\r\n  screen.clear();\r\n\r\n\r\n  \/\/ you can also display a variable on the screen\r\n  screen.home();\r\n  screen.print(\"x = \");\r\n  screen.print(x);\r\n  delay(1000);\r\n\r\n  screen.clear();\r\n}\r\n\r\n\r\n\r\nvoid debug_setup(){\r\n  Wire.begin();\r\n  Serial.begin(9600);\r\n  Serial.println(\"\\nI2C Scanner\");\r\n}\r\n\r\n\r\nvoid debug_loop() {\r\n  byte error, address;\r\n  int nDevices;\r\n\r\n  Serial.println(\"Scanning...\");\r\n\r\n  nDevices = 0;\r\n  for (address = 1; address &lt; 127; address++ )\r\n  {\r\n    \/\/ The i2c_scanner uses the return value of\r\n    \/\/ the Write.endTransmisstion to see if\r\n    \/\/ a device did acknowledge to the address.\r\n    Wire.beginTransmission(address);\r\n    error = Wire.endTransmission();\r\n\r\n    if (error == 0)\r\n    {\r\n      Serial.print(\"I2C device found at address 0x\");\r\n      if (address &lt; 16)\r\n        Serial.print(\"0\");\r\n      Serial.print(address, HEX);\r\n      Serial.println(\"  !\");\r\n\r\n      nDevices++;\r\n    }\r\n    else if (error == 4)\r\n    {\r\n      Serial.print(\"Unknown error at address 0x\");\r\n      if (address &lt; 16)\r\n        Serial.print(\"0\");\r\n      Serial.println(address, HEX);\r\n    }\r\n  }\r\n  if (nDevices == 0)\r\n    Serial.println(\"No I2C devices found\\n\");\r\n  else\r\n    Serial.println(\"done\\n\");\r\n\r\n  delay(5000);           \/\/ wait 5 seconds for next scan\r\n}\r\n<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Full View: &nbsp; Yuxi Overall view of the project ~~~ &nbsp; Transparency station: Light valve is inserted between LED and photo-resistor &nbsp; Yuxi LED OFF &nbsp; LED ON&#8230;<\/p>\n","protected":false},"author":40,"featured_media":17201,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[86],"tags":[],"_links":{"self":[{"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/posts\/17170"}],"collection":[{"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/users\/40"}],"replies":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/comments?post=17170"}],"version-history":[{"count":18,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/posts\/17170\/revisions"}],"predecessor-version":[{"id":17510,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/posts\/17170\/revisions\/17510"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/media\/17201"}],"wp:attachment":[{"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/media?parent=17170"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/categories?post=17170"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/60-223\/s2023\/work\/wp-json\/wp\/v2\/tags?post=17170"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}