[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-510229-105":59,"doc-detail-510229-en":130},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":123,"head_meta":125,"extra_data":127,"updated_unix":129},105,"en","microbits-dice-set-learn-to-program-microbit-dice","Micro:Bits Dice Set - Learn to Program Micro:bit Dice","","Guide to building and programming a Micro:bit dice set using the MakeCode editor. Explains what a Micro:bit is, required materials, and the flashing workflow to load code onto the device. Steps cover creating LED display patterns for button A, animating output, using different input methods such as button presses and shaking, and incorporating sensor-based decisions with an if-then-else temperature check. Includes a take-home dice roller activity that maps six dice types (d4, d6, d8, d10, d12, d20) to six inputs using random-number blocks.",{"@graph":69,"@context":122},[70,84,105],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":30,"@type":76,"position":81},"https://docshare.wps.com/document/technology/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/microbits-dice-set-learn-to-program-microbit-dice/510229/",{"url":83,"name":65,"@type":85,"image":86,"author":91,"headline":65,"publisher":94,"fileFormat":97,"inLanguage":63,"description":67,"dateModified":98,"datePublished":99,"encodingFormat":97,"isAccessibleForFree":100,"interactionStatistic":101},"DigitalDocument",{"url":87,"@type":88,"width":89,"height":90},"https://docshare.wps.com/thumbnails/microbits-dice-set-learn-to-program-microbit-dice/510229.png","ImageObject",300,407,{"name":92,"@type":93},"Terk","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-10-22","2026-10-05",true,{"@type":102,"interactionType":103,"userInteractionCount":29},"InteractionCounter",{"@type":104},"ViewAction",{"@type":106,"mainEntity":107},"FAQPage",[108,114,118],{"name":109,"@type":110,"acceptedAnswer":111},"What are the basic materials needed for the Micro:bit dice set?","Question",{"text":112,"@type":113},"You need a Micro:bit kit with a Micro:bit, a battery pack, and a Micro USB cable. A dongle adapter is optional when using a Mac.","Answer",{"name":115,"@type":110,"acceptedAnswer":116},"How do you get code onto a Micro:bit during the setup?",{"text":117,"@type":113},"Use the MakeCode editor to create code, download the file, then drag it onto the Micro:bit drive. Watch the yellow LED flash to confirm the flashing process.",{"name":119,"@type":110,"acceptedAnswer":120},"How can the dice set generate random results?",{"text":121,"@type":113},"Use the Math tab random block (e.g., pick random 1 to 6) and place it inside a Basic tab show number block. Duplicate and adjust the random ranges to represent different dice types.","https://schema.org",{"og:url":83,"og:type":124,"og:title":65,"og:site_name":95,"og:description":67},"article",{"robots":126,"canonical":83},"index,follow",{"doc_id":128,"site_id":62},510229,1791337124,{"code":4,"msg":5,"data":131},{"doc_id":128,"user_id":132,"nickname":92,"user_avatar":133,"doc_module":4,"category_id":29,"category_name":30,"doc_title":65,"doc_description":67,"doc_content":134,"file_id":135,"file_url":136,"file_type":137,"file_size":138,"view_count":29,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":29,"language":139,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":140,"faqs":141,"seo_title":142,"seo_description":67,"update_tm":143,"read_time":144},1099525198933,"https://ap-avatar.wpscdn.com/davatar_155a257f0dc6eb9ab79c44ca47cae57d","Micro:Bits  \nMicro:Bits Dice Set   \nFirst, learn how to use the make code editor and to put the code into your  \nMicro:bit . Learn how to turn a micro:bit into a whole set of dice. For example, the Micro:bit will generate a random number between 1 and 6 for one action, or a random number between 1 and 12 for a different action.  \nWhat is a Micro:Bit?  \nA Micro:bit is a miniature computer with a 5x5 LED display grid. We can use the MakeCode editor to code a program to execute on our Micro:bit. A program is simply a set of instructions for our Micro:bit to complete.  \nMaterials  \n● Micro:bit kit  \n○ 1 Micro:bit  \n○ 1 Battery pack  \n○ 1 Micro USB cable  \n● Optional: 1 Dongle adapter if using Mac  \nMicro:Bits Dice Set   \nProcedure  \n1) First, bring out the show string icon block to the “on start” code frame. The phrase“Hello, World!” is frequently used by programmers when they are trying to use a new programming language or a new computer set up. Now, download the ﬁle to your computer, then drag that ﬁle onto the micro:bit drive. You will see a small yellow led on the back of your micro:bit ﬂashing, which is why we call this whole process“ﬂashing code to your Micro:bit”.  \n2) Let’s make some additions to our code, then ﬂash it to our micro:bit again.  \nWe will be ﬂashing to our Micro:bit a lot this week, so it is good to practice early! Go to the Input tab and drag out the “on button A pressed” block.  \nThen, go to the Basic tab and pull out the “show leds” block. Make a design by clicking on which LEDs you would like to illuminate. Then, right click on the block and select duplicate. You can also use keyboard shortcuts to copy and paste blocks. You can use a sequence of show led blocks to create an animation, like this winking smiley face.  \n3) Now, when you ﬂash this code to your Micro:bit, you should see a winking smiley face when you press the A button. What happens when you press A while the“Hello, World!” message is still being displayed?  \n4) Let’s try out some different input methods. First, delete the hello world message (it takes so long to display!) . Then, bring out “on shake” from the input tab. If you click on the arrow, it gives other options for input actions as well. I stuck with “on shake” this time, and put an animation of an upset face  \nMicro:Bits Dice Set   \n5) We can also program the Micro:bit to make decisions based on it’s sensor values.  \nBring out an “on button A pressed” frame, then change it to be activated when B is pressed. We’ll try to use the temperature sensor to display a different image to show us if it is hot or cold. Since our program needs to make a decision, we will need to use an if-then-else block. These can be found under the logic tab. Drag out a “0\u003C0”block, also from the logic tab, and use it to replace the “True” block.  \n6) Under the input tab, ﬁnd the “Temperature” block, and replace the left 0 with it.  \nDecide what temperature will be your cut off for a “cold” temperature. I chose 12 degrees celsius but the choice is yours! When the B button is pressed our new code should check to see if the temperature is less than 12. If it is, then we display the sad face and pause. If not, we display a happy face.  \nMicro:Bits Dice Set   \nTake Home Activity  \nDice set roller: In some tabletop games, different dice are used to generate random numbers for the game. Your standard six sided dice is called a d6, since it rolls a number between 1 and 6 at random. A standard set of dice contains a d4, d6, d8, d10, d12, and d20 . We can use six different input methods to roll dice of each of these six types. The buttons A, B, or A+B give us three options. We can use shake, tilt left, or tilt right for the other three.  \n1) To start, pull out all of the input frames you choose to use.  \n2) Let’s code the d6 ﬁrst, for on button A pressed. Bring out a show number block from the Basic tab, then go to the Math tab, and pull out the “pick random 0 to 10” block. Change the numbers to be 1 to 6, then put this ","cbCaigNmjETpNmtk","https://ap.wps.com/l/cbCaigNmjETpNmtk","pdf",643967,"English","# Procedure\n## Materials\n## Procedure steps\n# Take Home Activity\n## Dice set roller","[{\"question\":\"What are the basic materials needed for the Micro:bit dice set?\",\"answer\":\"You need a Micro:bit kit with a Micro:bit, a battery pack, and a Micro USB cable. A dongle adapter is optional when using a Mac.\"},{\"question\":\"How do you get code onto a Micro:bit during the setup?\",\"answer\":\"Use the MakeCode editor to create code, download the file, then drag it onto the Micro:bit drive. Watch the yellow LED flash to confirm the flashing process.\"},{\"question\":\"How can the dice set generate random results?\",\"answer\":\"Use the Math tab random block (e.g., pick random 1 to 6) and place it inside a Basic tab show number block. Duplicate and adjust the random ranges to represent different dice types.\"}]","Micro:Bits Dice Set - Learn to Program Micro:bit Dice | PDF",1791239773,15]