{"id":684,"date":"2018-05-12T11:15:03","date_gmt":"2018-05-12T18:15:03","guid":{"rendered":"https:\/\/learn71.ca\/vanier-tech\/?page_id=684"},"modified":"2024-03-15T14:37:07","modified_gmt":"2024-03-15T21:37:07","slug":"nano-shield","status":"publish","type":"page","link":"https:\/\/learn71.ca\/vanier-tech\/nano-shield\/","title":{"rendered":"Nano Shield"},"content":{"rendered":"\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h3 class=\"wp-block-heading\">Schematic<\/h3>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69e9aa1ce1ed7&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"69e9aa1ce1ed7\" class=\"wp-block-image size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"781\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/learn71.ca\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-1024x781.jpg\" alt=\"\" class=\"wp-image-1294\" srcset=\"https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-1024x781.jpg 1024w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-300x229.jpg 300w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-768x586.jpg 768w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-787x600.jpg 787w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2018\/08\/Nano-Shield-Schematic-1600x1220.jpg 1600w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n\n<div style=\"height:20px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Examples &amp; Challenges: <a href=\"https:\/\/learn71.ca\/wp-content\/uploads\/sites\/40\/2024\/03\/Nano-Shield.zip\">Nano-Shield.zip<\/a><\/h3>\n\n\n\n<p>Start each stage by reading and uploading the example (A), then modify it or write your own program to replicate the challenge.<\/p>\n\n\n\n<p>The \u201canswer key\u201d is provided (B), but try to figure out each challenge before you read the program provided.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h3 class=\"wp-block-heading\">PCB<\/h3>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69e9aa1ce285c&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"69e9aa1ce285c\" class=\"wp-block-image size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"776\" height=\"1024\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/learn71.ca\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-776x1024.jpg\" alt=\"\" class=\"wp-image-2820\" srcset=\"https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-776x1024.jpg 776w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-227x300.jpg 227w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-768x1014.jpg 768w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-1164x1536.jpg 1164w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB-455x600.jpg 455w, https:\/\/learn71.ca\/vanier-tech\/wp-content\/uploads\/sites\/40\/2023\/07\/Nano-Shield-PCB.jpg 1220w\" sizes=\"auto, (max-width: 776px) 100vw, 776px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">1. Array<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Example (A)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"6 Array\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/scqwEyxxtQE?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Flash all LEDs on and off. <\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Challenge (B)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"6 Array Challenge\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/teJWLgrSm4g?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Light up, then turn off LEDs one at a time. <\/p>\n\n\n\n<p><\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">2. Tone<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Example (A)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"7 Tone\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/hGc4UIW3o1g?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Beep on and off, while also using the potentiometer to set speaker tone. <\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Challenge (B)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"7 Tone Challenge\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/62Ms1XXZ2QY?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Create a siren that cycles through tones 80Hz &#8211; 4000Hz up and down.<\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">3. Random<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Example (A)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"8 Random\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/rV835atT1-Y?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Beep at random frequency, for a random length of time, at random intervals. <\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h4 class=\"wp-block-heading\">Challenge (B)<\/h4>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"8 Random Challenge\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/nyWyS_dCkpA?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Turn on random LEDs one at a time for a random period of time. <\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">4. Functions Example<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"Functions\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/l5hs8H3c1_g?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p>\nsetup() and loop() are functions, but you can also create your own. This becomes essential when writing larger programs to keep them organized and greatly reduce the amount of text.\n\n<\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Advanced Challenges<\/h3>\n\n\n\n<p>Using functions in combination with the techniques covered in previous exercises, create the three simple games below using the Nano Shield.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">4A. Timing Game<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"TimingGame\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/Try12guSk-M?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p>\nLEDs are illuminated up and down. One button stops, the other resumes, and the pot adjusts game speed. The objective is for the player to stop the LEDs as close to the top as possible.\n\n<\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">4B. Random Reaction<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"RandomReaction\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/OXKRB5xOg5I?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p>\nLEDs light up randomly, for random periods of time. The objective is for the player to press the button when the top LED is illuminated (win). The player will have to wait through a countdown if they miss the top LED.\n\n<\/p>\n<\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">4C. Reflex Tester<\/h3>\n\n\n\n<div class=\"wp-block-columns has-2-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"ReflexTester\" width=\"868\" height=\"488\" src=\"https:\/\/www.youtube.com\/embed\/vdybRO5Cxfg?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p><\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p>\nAfter the starting tone, there will be a delay (random period of time) before the reflex tone. The objective is to react as quickly as possible. Score will be displayed with LEDs and corrosponding tone from the speaker. If the player presses the button too early, or not at all, they will receive a zero score.\n\n<\/p>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Schematic Examples &amp; Challenges: Nano-Shield.zip Start each stage by reading and uploading the example (A), then modify it or write your own program to replicate the challenge. The \u201canswer key\u201d is provided (B), but try to figure out each challenge before you read the program provided. PCB 1. Array Example (A) Flash all LEDs on [&hellip;]<\/p>\n","protected":false},"author":84,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-684","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/pages\/684","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/users\/84"}],"replies":[{"embeddable":true,"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/comments?post=684"}],"version-history":[{"count":50,"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/pages\/684\/revisions"}],"predecessor-version":[{"id":3236,"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/pages\/684\/revisions\/3236"}],"wp:attachment":[{"href":"https:\/\/learn71.ca\/vanier-tech\/wp-json\/wp\/v2\/media?parent=684"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}