Posts with «iot» label
On Arduino Day, we announced the latest member of the Arduino MKR family: the MKRFOX1200. This powerful IoT development board offers a practical and cost effective solution for Makers looking to add Sigfox connectivity to their projects with minimal previous networking experience.
The MKRFOX1200 shares several similarities with other MKR products, like the MKR1000 and MKRZero, including a compact form factor (67 x 25mm) and a Microchip SAM D21 32-bit Cortex-M0+ microcontroller at its core. The recently unveiled board also features an ATA8520 module for long-range, low-energy consumption, and is capable of running for over six months on two standard AA 1.5V batteries.
Designed for Makers ready to take their IoT projects into the real world, the MKRFOX1200 comes with a GSM antenna that can be attached to the board and a two-year subscription to the Sigfox network. This provides users with full access to Sigfox’s efficient messaging system (up to 140 messages per day), cloud platform, webhooks, APIs, as well as the new Spot’it geolocation service.
MKRFOX1200 can be used in a wide variety of settings, from agriculture (livestock management, smart irrigation and weather stations), to smart cities (dumpster monitoring, air quality networks, street lighting or parking lot tracking), to utility metering and other industrial applications.
“Sigfox loves Makers,” says Nicolas Lesconnec, Head of Developer Relations. “Sigfox aims to empowers billions of new IoT solutions. We’re proud to partner with Arduino, the leading open-source electronics platform, to offer the simplest way to connect anything.”
Sigfox currently operates in over 30 countries, with more to follow in the next few years. (Use this map to see whether it has been deployed or is rolling out in your area.) The first version of the MKRFOX1200 is compatible with Sigfox Radio Configuration Zone 1 (868MHz, 14dBm), meaning it is only supported in network-covered regions of Europe, the Middle East, and South Africa.
This tutorial will show you how to take over the controls of the OWI Robotic Arm with the help of an Arduino compatible, open-source PLC called the Controllino MAXI, together with Cayenne (my go-to iOT application for remote connection to my Arduino projects). The Controllino MAXI will provide the physical connections to the OWI robotic arm, and Cayenne will allow me to control the arm via my web browser or via the Cayenne app on my phone.
Arduino Libraries and IDE
- The Arduino IDE can be used to program the Controllino. You can dowload the Arduino IDE from here: https://www.arduino.cc/en/main/software.
- You will also need to read the Cayenne Ethernet library installation instructions in order to install the Cayenne Ethernet Library.
- The Controllino will connect to the internet via the Ethernet port onboard.
- You do not need the Controllino library for this project, however, if you have a Controllino, you might as well install the library. You can read the Controllino library installation instructions from their GitHub webpage here: https://github.com/CONTROLLINO-PLC/CONTROLLINO_Library.
- You will need to notify the Arduino IDE of the Controllino MAXI board by pasting the supplied URL into the "Additional Boards Manager URLs" in the Arduino IDE.
- This is located under: FILE - PREFERENCES - Additional Boards Manager URLs.
- The URL that you need to paste is in STEP 3 of the Controllino Library installation instructions on their GitHub page.
- The video at the top of this tutorial may help clarify the process.
The code above is very simple, however you will need to create a dashboard of widgets from within your Cayenne account in order to control the OWI robotic Arm from your phone or via the Dashboard webpage.
Setting up Cayenne Dashboard
Once you have created your Cayenne account, you will be presented with a webpage to choose a board to connect to. Controllino is an Arduino compatible PLC, so make sure to follow these instructions for setting up the Controllino in your Cayenne Account.
- Select Arduino from the available list of boards.
- Make sure to install the necessary libraries if your have not done so already.
- Select Arduino MEGA from the avaliable list of Arduino boards
- Select Ethernet Shield W5100
- Copy and paste the Arduino code that pops up on screen into your Arduino IDE and upload to the Controllino.
- Alternatively, copy and paste the code from above, however you will need to insert your Authentication token to get it to work
After you upload the code to the Controllino, and providing it has an ethernet cable connected to the internet router (and has access to the internet), and is powered on, it will connect to your Cayenne Dashboard. You can now add widgets to the dashboard in real time to interact with the Controllino, and without uploading any more code to the open source PLC.
We need to add a number of widgets in order to activate the relays on the Controllino. The relavent digital pins that we will need to know about can be found on the Controllino website here: https://controllino.biz/downloads/.
Here is the direct link to the PINOUT file for the Controllino MAXI.
"Armed" with that knowledge, we can now create the widgets which are necessary to control the relays on the Controllino. From within the Cayenne dashboard, please follow these instructions to create a widget:
- Select - ADD NEW
- Select - DEVICE/WIDGET
- Select - ACTUATORS
- Then - RELAY from the dropdown box
- Select - RELAY SWITCH
- Give the widget a descriptive name to differentiate it from the other widgets and a name that is somewhat informative (eg. R0 - Pos)
- I gave the first widget the name "R0 - Pos", because it will connect to Relay R0, and that relay will be connected to the Positive (POS) terminal of the OWI robotic arm.
- Select the device you would like to connect to. Be aware that you can change the name of the device in the settings. If you followed this tutorial, it should have the name "Arduino MEGA", but I changed the name of the device to "Controllino" to be more accurate.
- We will be using a digital pin to control the relay, therefore select "Digital" as the Connectivity option
- For this specific widget, we will be controlling R0, which is activated by digital pin D22 on the Controllino. Therefore select "D22" from the "Pin" dropdown box.
- Choose a "Button" as the widget type
- Choose an icon from the dropdown box that makes sense to you
- Skip Step 1
- Select Step 2: Add actuator
You should now see your new widget on the dashboard. Select the widget to enable or activate that relay. If you do this, and if everything goes to plan, you will see the LED for R0 illuminate on the Controllino. You now have to add the rest of the widgets to the dashboard in order to control the rest of the relays on the Controllino.
Here is a table to show you how I setup my dashboard.
OWI Robotic Arm Pins
Normal OWI Robotic Arm Circuit
The following circuit diagram will show you how the wired control box is normally connected to the OWI Robotic arm. This is the circuit diagram of the OWI robotic arm under normal operating contidtions.
OWI Robotic Arm Circuit when connected to Controllino
The following circuit diagram will show you how the OWI Robotic Arm will be controlled by the relays of the Controllino. This is the circuit diagram of the OWI robotic arm when it is connected to the Controllino.
The OWI Robotic Arm is connected to a breadboard using the female-to-male jumper wires. Solid core wire is then fed through to the relay terminals of the Controllino. You could just wire it up so that the robotic arm is connected directly to the Controllino, however, I did not have the right connectors for this purpose.
The Controllino is also connected to my internet router via a normal RJ-45 ethernet cable, and is powered by a 12V DC power adapter.
Now that you have all the physical connections made, uploaded the code to the Controllino, and have created your dashboard in Cayenne, you should be able to control your OWI Robotic arm from anywhere in the world. As demonstrated in the video at the start of this tutorial, the robotic arm has quite a bit of give on each of the joints, which makes it difficult to achieve certain tasks that require an element of precision. There goes that idea of being able to perform surgery with this thing !!! At least you can get it to make you a cup of tea, and if you are patient enough, you might even get a grape once in a while.
Visit my ArduinoBasics Google + page.
Follow me on Twitter by looking for ScottC @ArduinoBasics.
I can also be found on Pinterest and Instagram.
Have a look at my videos on my YouTube channel.
If like us you live in mortal fear of someone breaking into your house when you’re on vacation and starting a dryer fire while doing laundry, this full-featured IoT laundry room monitor is for you. And there’s a school bus. But don’t ask about the school bus.
In what [seasider1960] describes as “a classic case of scope creep,” there’s very little about laundry room goings on that escapes the notice of this nicely executed project. It started as a water sensor to prevent a repeat of a leak that resulted in some downstairs damage. But once you get going, why not go too far? [seasider1960] added current sensing to know when the washer and dryer are operating, as well as to tote up power usage. A temperature sensor watches the dryer vent and warns against the potential for the aforementioned tragedy by sounding an obnoxious local alarm — that’s where the school bus comes in. The whole system is also linked into Blynk for IoT monitoring, with an equally obnoxious alarm you can hear in the video below. Oh, and there are buttons for testing each alarm and for making an Internet note to reorder laundry supplies.
We’ve seen a spate of laundry monitoring projects lately, all of which have their relative merits. But you’ve got to like the fit and finish of [seasider1960]’s build. The stainless face plate and in-wall mount makes for a sleek, professional appearance which is fitting with the scope-creepy nature of the build.
Filed under: home hacks
In this tutorial, we are making a temperature logger using arduino and thingspeak.
Hope, you guys had enjoyed the video
Thanks for visiting my blog
IoT, web apps, and connected devices are all becoming increasingly popular. But, the market still resembles a wild west apothecary, and no single IoT ecosystem or architecture seems to be the one bottle of snake oil we’ll all end up using. As such, we hackers are keen to build our own devices, instead of risking being locked into an IoT system that could become obsolete at any time. But, building an IoT device and interface takes a wide range of skills, and those who are lacking skill in the dark art of programming might have trouble creating a control app for their shiny new connected-thing.
Enter Involt, which is a framework for building hardware control interfaces using HTML and CSS. The framework is built on Node-Webkit, which means the conventions should be familiar to those with a bit of web development background. Hardware interactions (on Arduinos) are handled with simple CSS classes. For example, a button might contain a CSS class which changes an Arduino pin from high to low.
While Involt isn’t the only framework to simplify hardware interaction (it’s not even the only Node.js based method), the simplicity is definitely laudable. For those who are just getting started with these sorts of devices, Involt can absolutely make the process faster and less painful. And, even for those who are experienced in this arena, the speed and efficiency of prototyping with Involt is sure to be useful.
Filed under: Arduino Hacks
Thanks for visiting this post.
In the meantime, do check my youtube channel:
Fun with electronics
Using the HMC5883L magnetometer sensor of the GY-80 module from ICStation to monitor a garage door and notify when it has been opened or closed. The Cayenne service provides much of the monitoring and notifying functionality. A major feature of this project. Cayenne takes care of all of the complicated work behind the scenes, making it easy to connect your Arduino to the cloud and allow you to monitor your garage from virtually anywhere.
This project was created specifically to monitor a garage, but you will soon discover that this project could be used to monitor a whole host of other things. Monitor your front door, your back door, your bag, your chair, your cookie jar.
Monitor for peace of mind, or catch someone in the act of stealing your stuff. This project has got you covered. Let's see how:
You can find the datasheet for the HMC5883L pretty easily by searching on the internet.
HMC5883L datasheet - Sparkfun
Arduino Libraries and IDE
Here is a link to the Arduino IDE download. The IDE is required to upload code to the Seeeduino Cloud.
You need the Cayenne Library installed in your Arduino IDE.
You can find the Cayenne library here:
There are libraries on the internet for the GY-80 module, however, it is relatively easy to use the magnetometer on this module. And therefore no libraries are required for the sensor. If you would like some more information about using the magnetometer sensor, and how to get the most out of it, then please have a look at my previous tutorial which goes into much more detail.
You need to make sure to insert your OWN Cayenne token into the sketch above. You will get this token when connecting your Arduino to the Cayenne service. Watch the video for further explanation.
Please make sure to watch the video to see how to connect the Seeeduino Cloud to Cayenne and how to create the Cayenne widgets. Cayenne widgets are necessary to create the dashboard on your phone or browser. They will also interact with the Arduino sketch, and will also be involved in creating the notification system. The following links will take you to the relevant part of the video:
- Master Switch Button
- Request Calibration Button
- x, y, and z Axis display
- Door Status
- Creating a notification trigger
The Master switch button is used to switch monitoring from OFF to ON (and vice versa). Therefore you can choose when to monitor the garage and when to stop monitoring. When first installing the project onto your garage door, and turning the Seeeduino Cloud on, it will automatically calibrate each sensor to a value of 1000.
If you experience any drift away from 1000 for whatever reason, simply press the Request calibration button, and each sensor will be recalibrated back to 1000. The x,y and z axis widgets are there so that you can see the readings coming from the magnetometer sensor. And when any of the axis variables breach the threshold away from 1000, it will trigger the Door Status widget. This is how we can tell if the door is open or closed.
We also use the Door Status widget to help with the notification system. When the Door status changes from "Closed" to "Open", a notification trigger will be activated, and a message will be sent via email or SMS. This notification is useful for monitoring when the door was opened. If you happen to recalibrate when the door is open. You will get a notification when the garage door closes.
This project is relatively simple, and quite easy to set up. What I liked about this project was the versatility and alternate uses. You can use the same setup to monitor many different things. It is not just limited to monitoring a garage door. But being able to tell whether my garage door is opened or closed, especially after I have driven away from my house , is really cool. Now I don't have to drive all the way back home to check. Let me know if you have replicated this project, and also what kinds of things you decided to monitor with this project.
We’ve been waiting for this one. A worm was written for the Internet-connected Arduino Yun that gets in through a memory corruption exploit in the ATmega32u4 that’s used as the serial bridge. The paper (as PDF) is a bit technical, but if you’re interested, it’s a great read.
The crux of the hack is getting the AVR to run out of RAM, which more than a few of us have done accidentally from time to time. Here, the hackers write more and more data into memory until they end up writing into the heap, where data that’s used to control the program lives. Writing a worm for the AVR isn’t as easy as it was in the 1990’s on PCs, because a lot of the code that you’d like to run is in flash, and thus immutable. However, if you know where enough functions are located in flash, you can just use what’s there. These kind of return-oriented programming (ROP) tricks were enough for the researchers to write a worm.
In the end, the worm is persistent, can spread from Yun to Yun, and can do most everything that you’d love/hate a worm to do. In security, we all know that a chain is only as strong as its weakest link, and here the attack isn’t against the OpenWRT Linux system running on the big chip, but rather against the small AVR chip playing a support role. Because the AVR is completely trusted by the Linux system, once you’ve got that, you’ve won.
Will this amount to anything in practice? Probably not. There are tons of systems out there with much more easily accessed vulnerabilities: hard-coded passwords and poor encryption protocols. Attacking all the Yuns in the world wouldn’t be worth one’s time. It’s a very cool proof of concept, and in our opinion, that’s even better.
Thanks [Dave] for the great tip!
Filed under: Arduino Hacks, security hacks