Magicblocks Lesson 1
Getting Started with Magicblocks
Create Magicblocks.io Account
- Go to magicblocks website http://magicblocks.io/
- Select SIGN UP
- Click on the SIGN UP button after inserted your details
- Go to the email account you provided and activate your Magicblocks account with the Activation Link
- Follow the Activation Link which we have sent you as an email.
Login to Your Magicblocks.io Account
- Go to Magicblocks.io official website. www.magicblocks.io
- Select LOGIN
- Provide your login details.
- Enter your email address and the Magicblocks Password and sign in to magicblocks
Start the Playground
When you login for the first time your playground will not be running. Playground is the visual programming environment based on Node-Red that has been customized for seamless integration with hardware devices to enable IoT. If you do not have a valid subscription, you will be allowed to run the playground only for 1 hour continuously before it is automatically stopped. You will need to restart the playground manually after this 1 hour period. You can subscribe to 3 months free subscription by entering coupon code in Subscription tab provided with your magicbit device. If you have any issue please write to firstname.lastname@example.org
Create a new device
Go to Device Manager and add a new device.. Set device type as Magicbit & set status to Active . You can use any name and description.
Keep this browser tab open since you will need to copy the device Id and the key to setup the device in the next step.
Setting up a device
Connect Magicbit to computer using provided USB cable.
Download Magicbit utility tool and install drivers
Select COM port from drop down list and select magicblocks to install firmware. .. image:: Images/Utility.PNG
- Wait until uploading is completed and search for its configuration WiFi access point to come up. It would be named “Magicbit” in the default configuration
- Connect to this WiFi access point and go to http://192.168.4.1
- Fill in the device Id and the key that was generated in the magicblocks.io device manager. Please note that device id starts with idXXXX-XXXXXXX AND both key and id are case sensitive. You can change the Name to any name you like up to 32 characters. Select the WiFi SSID from the drop down and enter the WiFi password. If your WiFi is not listed here make sure the WiFi AP is active and reset the Magicbit board and retry.
- Save the configuration. The default admin password is 12345. You can change this from the Admin tab
- Once saved, the Magicbit will restart and try to connect to the WiFi and then to magicblocks. You can connect to the Magicbit’s configuration WiFi AP and navigate to http://192.168.4.1 to check the status of the connection.
- Login to magicblocks, navigate to Device Manager and check if the Connection column comes up as a blinking green indicator. If yes, you can proceed to the next step
Go to the playground!
- Login to magicblocks and click on Edit to open the playground.
- The playground is a hosted instance of a customized version of the open source Node-Red application. On the left you will find the palette where all the blocks will reside. You can drag and drop the blocks from the palette to the canvas and start rolling very quickly. Once done click the Deploy button on the top right corner and all your changes will be saved. In the next section we will go through some examples covering all the relevant blocks
Let’s start magic with displaying a text on Magicbit display.
- Turn on your Magicbit board that was setup in the previous section and wait for it to connect
- Copy the device Id of this Magicbit board
- Open the playground
- Drag and drop the Display block under the category Magicbit
- Double click on the block and paste the device Id
- Drag and drop an inject blocks under the input category and connect them to the Display block
- In one inject node set payload type as String and type Hello Magicbit in the text box. You can set a topic too.
- Click deploy
- Click button in Inject node to see the magic. You can set any text from any where in the world!!!