{"id":137,"date":"2020-11-07T23:07:30","date_gmt":"2020-11-08T04:07:30","guid":{"rendered":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/?p=137"},"modified":"2020-11-07T23:30:15","modified_gmt":"2020-11-08T04:30:15","slug":"annas-status-update-for-11-7","status":"publish","type":"post","link":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/2020\/11\/07\/annas-status-update-for-11-7\/","title":{"rendered":"Anna\u2019s Status Update for 11\/7"},"content":{"rendered":"<p><span style=\"font-weight: 400\">The plan laid out last week about using multiple I2C mics and a much simpler acoustic location algorithm was scrapped. I actually decided to abandon I2C mics altogether, since the sampling rate was simply too garbage. Instead, I resolved to find other higher-sampling mics and spent the first couple days of the week researching. I found some mini USB mics on Amazon that could sample at 44100 Hz &#8212; which is significantly better than the previous I2C mics, by two orders of magnitude &#8212; and ordered them right away. In the short time that I waited for them to arrive, I learned a lot about arecord (a command line soundfile recorder), the pyaudio module, and how to configure the USB microphones. By the time the mics arrived, I was ready to immediately hop on the coding. I first did some testing with the mics, of course, and they are unfortunately not of the best quality. I tried using them on a call with Heather and Edward, and apparently my voice sounded incredibly muffled. When I hooked them up to the Jetson, I tried recording with arecord and found that the mics really don\u2019t pick up voices unless they\u2019re right up against your mouth. However, they seem to pick up the sound of a clap decently, within about five feet. They&#8217;re\u00a0 a little finicky, though, and one mic in particular doesn&#8217;t seem to pick up sound as well as the others. Obviously, these mics will not be good enough for our final project, but for the sake of demo, they\u2019ll do.<\/span><\/p>\n<p><span style=\"font-weight: 400\">After testing the mics and playing with them a bit, I coded up the acoustic location module, which took a solid amount of time. What I ultimately ended up implementing was a peak detector for two mics, such that if two mics experience amplitude peaks close to each other in time, then the program spits out a print statement saying \u201cMic x detected first by ### microseconds.\u201d\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">I ran into some trouble along the way, particularly with the Jetson recognizing the devices (mics). I figured out that that was because the program is an infinite while loop, which I quit with Ctrl+Z, but killing the process doesn\u2019t properly \u201cclose\u201d the device and prevents the Jetson from recognizing it again after.<\/span><\/p>\n<p><span style=\"font-weight: 400\">I also found that the different mics and USB connectors (and different combinations of the two) yielded different delays between them, but I was able to determine these delays and hardcode them into the program. (There was also some difficulty here, because I did not understand the datetime module as well as I thought I did\u2026 whoops)<\/span><\/p>\n<p><span style=\"font-weight: 400\">I have the program working relatively well between two mics now, which I hope will be enough for demo. I plan to get the third mic incorporated later this week, and I will also be looking into better microphones that can pick up voices better.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>The plan laid out last week about using multiple I2C mics and a much simpler acoustic location algorithm was scrapped. I actually decided to abandon I2C mics altogether, since the sampling rate was simply too garbage. Instead, I resolved to find other higher-sampling mics and spent the first couple days of the week researching. I found some mini USB mics on Amazon that could sample at 44100 Hz &#8212; which is significantly better than the previous I2C mics, by two&#8230;<\/p>\n<p class=\"read-more\"><a class=\"btn btn-default\" href=\"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/2020\/11\/07\/annas-status-update-for-11-7\/\"> Read More<span class=\"screen-reader-text\">  Read More<\/span><\/a><\/p>\n","protected":false},"author":331,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[2],"tags":[6,4],"_links":{"self":[{"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/posts\/137"}],"collection":[{"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/users\/331"}],"replies":[{"embeddable":true,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/comments?post=137"}],"version-history":[{"count":3,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/posts\/137\/revisions"}],"predecessor-version":[{"id":140,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/posts\/137\/revisions\/140"}],"wp:attachment":[{"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/media?parent=137"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/categories?post=137"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/course.ece.cmu.edu\/~ece500\/projects\/f20-teama3\/wp-json\/wp\/v2\/tags?post=137"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}