Use the Buzzer on the Magicbit [Magicblocks]
Use the buzzer on the Magicbit using Magicblocks
Hello and Welcome, This tutorial will teach you to use the buzzer on the Magicbit using Magicblocks.
There are 1 main method of achieving this goal;
By using Inject Block.
First, log into your Magicblocks account,
Magicblocks is easy visual programming software for the program of your Magicbit. Anyone can program their microcontroller by using magicblocks.io and there is no need for programming knowledge. You can sign up for free.
Start and Open the Playground.
Next, make sure your Magicbit is connected to the internet and plugged in, and also linked to your account through Device Manager.
All Done? Then scroll down to Method 1
Set up the Buzzer Block
1. Drag & Drop the Buzzer block from the Magicbit nodes section to the flow.
2. Double-click on the Buzzer block and type or paste your unique Device ID from the Device Manager Tab on your Magicblocks account. [This will link the buzzer on your Magicbit with your Magicblocks account]
3. Frequency determines the frequency of the buzzer.
4. Duration determines the duration of the buzzer output.
Set up the Inject Block
(This Node is used to activate the buzzer repeatedly between an interval)
1. Drag & Drop the Inject Block from the input nodes section on the left of the screen to the flow.
2. Make sure the payload type is timestamp and repeat is set to the interval.
3. Next set an interval, this will determine the delay between buzzer outputs.
[Optional] Import Already Setup Nodes
If you had trouble setting up nodes, you can use the import feature in Magicblocks to get the nodes which have been already set up.
- First copy this code to your clipboard;
- Click on the options menu on the top right-hand corner of the screen.
- Next, hover your cursor over the Import sub-menu.
- Then click on Clipboard and paste the code on your clipboard to the text field
- Select current flow or new flow and click on Import.
Make sure you type your device ID on the Buzzer node properties.
Finally, Deploying the Blocks
- Connect all the blocks.
- Click on the Deploy button on the top right-hand corner of the screen.
- The Buzzer will activate according to the frequency, duration, and delay given.
- You can change the frequencies and get a different frequency output from the buzzer.
- Check whether your Magicbit is connected to the internet.
- Check whether the Device ID is correct on the buzzer node properties.
YouTube video by clicking here: