Posts | Comments

Planet Arduino

Archive for the ‘node-red’ Category

In today’s modern world, smart technology is revolutionizing the way we interact with our surroundings. From managing our home’s energy consumption to controlling appliances remotely — such as washing machines, fans, coffee makers, and even air conditioners. Smart devices offer us a level of convenience and control that was once unimaginable. However, dealing with multiple apps for various systems can be cumbersome and inefficient. This is where an integrated platform like the Arduino Cloud comes into play, offering a unified dashboard to control all your smart devices. Moreover, if you’re an Arduino enthusiast, you’ll be excited to learn how Node-RED can bridge the gap between commercial products and the Arduino Cloud. Last, but not least, you can integrate this project with the rest of your Arduino Cloud projects automating your appliance control using other devices’ data.

In this blog post, we’ll delve into a fascinating project that demonstrates how you can harness the power of Arduino Cloud and Node-RED to control TP-Link smart plugs, giving you the ability to manage and monitor your appliances from a centralized hub.

TP-Link smart plugs and Kasa

TP-Link smart Wi-Fi plugs are intelligent devices that transform everyday appliances into smart ones, enabling remote control via your Wi-Fi network. These plugs are part of TP-Link’s smart home ecosystem, designed to offer enhanced convenience and control over your home appliances. To manage and control these smart devices, TP-Link has developed the Kasa Smart platform. Through the Kasa Smart app, you can easily schedule, automate, and control your connected devices, making your home even smarter. Importantly, Kasa Smart provides an API that facilitates seamless integration with other platforms.

Arduino Cloud: Simplifying IoT development

The Arduino Cloud is a versatile platform that simplifies the creation, deployment, and management of IoT devices. It supports a range of hardware, including Arduino boards, ESP32/ESP8266-based boards and devices programmed with Python, JavaScript or Node-RED. This platform is a boon for makers, IoT enthusiasts, and professionals, as it enables them to build connected projects without needing extensive coding skills. Arduino Cloud lets you manage and monitor connected devices through customizable dashboards, offering real-time visualizations of device data. These dashboards can be accessed remotely using your favourite browser or via the Arduino IoT Cloud Remote mobile app, available for both Android and iOS devices, ensuring that you’re in control no matter where you are.

Node-RED: Bridging the gap

Node-RED is an open-source visual programming tool designed to facilitate the connection and automation of devices, services, and APIs. Its browser-based flow editor enables users to effortlessly create workflows by dragging and dropping nodes onto a canvas and connecting them. Each node represents a specific functionality or service, such as data input/output, data transformation, or communication with external systems. Popular in the Internet of Things (IoT) realm, Node-RED simplifies the integration of sensors, devices, and cloud services, empowering users to craft sophisticated IoT applications and automation systems without traditional coding. In this blog post we will see how Node-RED can act as a middleware between TP-Link smart plugs and the Arduino Cloud.

Project setup: Getting started

To embark on this exciting journey of controlling TP-Link smart plugs with the Arduino Cloud and Node-RED, you’ll need a few prerequisites:

  • A TP-Link smart Wi-Fi plug (such as HS100)
  • The Kasa app installed on your mobile phone
  • An Arduino Cloud account
  • An instance of Node-RED (running locally or in the cloud)

No Arduino, ESP32, or ESP8266 devices are required for this project.

Step-by-step implementation

Here’s a concise overview of the steps you’ll undertake to bring your project to life:

  • Configure your TP-Link smart plug: Begin by adding your TP-Link smart plug to the Kasa app on your mobile device. This process connects your plug to both your Wi-Fi network and the internet, enabling remote control.
  • Create the device in the Arduino Cloud: In the Devices section of Arduino IoT Cloud, create a new device. This process involves selecting “Any Device” and following the instructions in the wizard. Don’t forget to save your Device ID and Secret Key.
  • Create the Node-RED flow: Access your Node-RED instance and import the provided code. This code configures the integration between the TP-Link smart plug, Arduino Cloud, and Node-RED.
  • Configure the Kasa and Arduino Cloud nodes: Within Node-RED, you’ll need to input the IP address of your TP-Link smart switch and configure the connection to Arduino Cloud using the API key you generated.
  • Create the Arduino Cloud dashboard: Navigate to the Dashboards section of the Arduino Cloud and create your dashboard. Customize it to your liking for easy monitoring and control.
  • Test the System: With everything set up, it’s time to test your creation. Access your Arduino Cloud dashboard to observe the status of your smart plug and control it using the provided button.

Try it now!

Experience the future of home control now. Discover how Arduino Cloud and Node-RED combine to command TP-Link smart plugs. Create your Arduino Cloud account and dive in at the Project Hub project page and transform your home today!

The post Controlling home appliances with Arduino Cloud and TP-Link smart plugs appeared first on Arduino Blog.

In a world where energy bills are climbing and the environment is on our minds, keeping tabs on how we use energy at home has become a smart move. Every gadget we plug in impacts our wallets and the planet. That’s where home energy monitoring comes in – giving us real-time info on how we’re using energy, so we can save money and do our bit for the Earth.

This post delves into home energy monitoring, spotlighting how to track your energy consumption using the Arduino Cloud and a Tuya-compatible energy meter with Node-RED acting as a middleware.

What’s the deal with home energy monitoring?

Home energy monitoring is all about watching how much energy we’re using at home. It’s not just about paying the bills; it’s about knowing what’s eating up energy, so we can be smarter about it.

Why does it matter? Well, first off, it helps us be more aware. When we can see which devices are energy hogs (looking at you, always-on TV), we can take action. And with energy costs going up, finding ways to save money is a no-brainer. Plus, with everyone talking about being green these days, knowing where your energy goes is like a badge of honor for doing your part.

The ingredients

The key component in this setup is an energy meter designed to monitor both real-time and cumulative power consumption, along with metrics such as voltage and current. This meter is installed within your home’s electrical distribution board. Tuya-compatible devices have gained widespread popularity due to their affordability, user-friendliness, and seamless management through the SmartLife application. Moreover, these devices can also be seamlessly integrated into alternative platforms through the utilization of the Tuya API.

The Arduino Cloud stands out as a versatile and user-friendly IoT platform, supporting a wide range of hardware. It’s not only customizable and adaptable to suit different purposes and use cases, but it also streamlines the incorporation of multiple devices, facilitating smooth information exchange among them. It is a perfect tool to monitor your energy consumption, being informed when outstanding events happen and perform actions on other devices based on the energy information acquired.

While direct connection of Tuya-compatible devices to the Arduino Cloud isn’t possible, the process becomes really straightforward with the intervention of Node-RED. This intermediary acts as a bridge between the energy meter and the Arduino Cloud, ensuring seamless communication between the two. With Node-RED you can integrate almost anything with the Arduino Cloud.

The project

The following project shows how to integrate all those elements to easily build your own energy monitoring system. 

Before getting started, you’ll require:

  • A Tuya/Smartlife-compatible energy meter
  • The SmartLife or Tuya app installed on your iOS/Android device
  • The Energy Meter added to the Tuya Smart app
  • An Arduino Cloud account (https://cloud.arduino.cc)
  • An instance of Node-RED running locally or on a cloud machine (installation guide found here)

The process is really straightforward:

  • Install the energy meter within your electric board.
  • Obtain your Tuya device API key.
  • Create the Device and Thing within the Arduino Cloud.
  • Develop the Node-RED flow to manage data traffic.
  • Fashion the Arduino Cloud Dashboard.

Build your own energy meter from the ground up

Monitoring energy consumption with Arduino Cloud doesn’t solely rely on Tuya-compatible energy meters. If you’re inclined to build your own solution from the ground up, consider exploring the Arduino IoT-based energy meter hosted on the Project Hub. There is additional detailed documentation available and a ready-to-use template to deploy your solution with one click.  

By engaging with this project, you’ll not only gain insight into your energy consumption monitoring but also experience the simplicity of crafting practical projects that interface Arduino boards with external components such as the Modbus energy meter. All this will be seamlessly managed and monitored by the Arduino Cloud.

Ready to Get Started? Take Control of Your Energy!

The path to smarter energy consumption begins with your curiosity and action. Now armed with the knowledge of the Arduino Cloud’s potential, it’s time to embark on your own energy monitoring journey. Don’t wait – seize the opportunity to optimize your energy usage, save on bills, and contribute to a more sustainable planet. With the Arduino Cloud as your ally, you can monitor, manage, and make a positive impact starting from your own home. Create your account, dive in, tinker for free, and start your energy-saving adventure today. Your future of empowered energy management is just a click away!

The post Save money with a Tuya/SmartLife energy meter monitored on Arduino Cloud via Node-RED appeared first on Arduino Blog.

In today’s fast-paced world, the convenience and comfort of a smart home have become paramount. Monitoring systems offer us a way to streamline daily tasks, optimize energy usage, and ultimately lead to more comfortable and cost-effective living. One of the key areas where smart systems shine is in heating control, allowing us to optimize temperature levels while keeping energy consumption in check and our bill under control.

In this blog post, we will delve into the benefits of using monitoring systems at home, with a particular focus on how integrating the Honeywell Evohome system, the Arduino Cloud, and Node-RED can revolutionize the way you control your heating, ensuring optimum temperature, enhanced comfort, and significant savings.

Optimizing temperature and comfort with Honeywell Evohome

The Honeywell Evohome system is a cutting-edge smart heating solution designed to provide individual room-by-room temperature control. Unlike traditional thermostats, which often focus on a single temperature setting for the entire house, Evohome empowers users to customize heating schedules for each room, tailoring comfort according to specific preferences and occupancy patterns. This level of personalized control ensures that every family member enjoys their ideal climate, enhancing overall comfort at home while also offering significant cost savings.

Moreover, the precise and responsive nature of the Evohome system enables it to adapt quickly to changing conditions. By utilizing multiple wireless radiator controllers and a central hub, the system ensures that the desired temperatures are maintained accurately, even in large or multi-story houses. This optimized heating control not only provides enhanced comfort but also contributes to reduced energy consumption, leading to valuable savings on heating bills.

Cloud platforms are a must-have for smart heating

Cloud integration is a big deal for modern smart systems. It lets you access and control your devices remotely from anywhere in the world. But here’s the thing: with so many smart home gadgets from different brands, each having its own way of doing things, it can get pretty chaotic. That’s where the Arduino Cloud comes to the rescue! The Arduino Cloud is an all-in-one intuitive IoT platform, supporting a wide range of hardware and backed by the trusted Arduino community. The Arduino Cloud removes complexity to empower users from all levels of expertise to create from anywhere, and control and share their projects with stunning dashboards. It’s a super reliable cloud service that connects all your devices to the internet and makes remote control a breeze. 

Empowering integration with Node-RED

Node-RED, an open-source automation tool, acts as a middleware between different smart systems. It enables seamless integration and communication between devices and services, making it an ideal platform to tie together various IoT components. Through Node-RED, you can create sophisticated automation flows that trigger actions based on specific events or data received from different sources.

With the help of Node-RED, you can integrate almost everything into the Arduino Cloud. The set of Node-RED nodes allow you to inject or retrieve data from the Arduino Cloud emulating a device. The best part? You don’t have to juggle multiple apps or interfaces anymore! Every system that is supported by Node-RED can be integrated with the Arduino Cloud. Furthermore, thanks to the Arduino Cloud device-to-device feature, you can use the data from all these systems in any other device that is connected to the Arduino Cloud.

Integrate Honeywell Evohome and Arduino Cloud with  Node-RED

The following project shows how simple it is to integrate your Honeywell Evohome system with the Arduino Cloud using Node-RED as a middleware. The only thing you need is a spare PC or Raspberry Pi where you can run Node-RED. 

With the Arduino Cloud dashboard, you can monitor the evolution of the temperature and set points in all the zones of your home, establish the set points and turn the heating system on and off.

The process is really straightforward:

  • Get your Honeywell getconnected credentials 
  • Create the Device and Thing in the Arduino Cloud 
  • Install Node-RED in a machine and import the Node-RED flow 
  • Create the Arduino Cloud dashboard 
  • Test everything and enjoy!

You can learn more about the project on the Arduino Project Hub or access the code directly on GitHub.

Conclusion

By embracing the power of smart home monitoring systems, such as Honeywell Evohome, and combining it with cloud platforms like the Arduino Cloud and the flexible integration capabilities of Node-RED, you can create an ecosystem that optimizes temperature, enhances comfort, and significantly reduces energy consumption. This convergence of technology empowers you to take control of your heating system like never before, ultimately leading to a more comfortable, efficient, and sustainable home. So, why wait? Embrace the future of smart heating today!

The post Save money with your Honeywell heating system: Control it on Arduino Cloud via Node-RED appeared first on Arduino Blog.

Arduino Cloud Free

There are dozens, if not hundreds of amazing Arduino Cloud features. So it’s perfectly understandable if you’ve missed some of them.

So we’ve put together a list of our favorite Arduino Cloud features that you might not know existed.

1) Auto-generate Sketches

We’ve talked elsewhere about getting an understanding of what cloud computing really is, and how it’s not just the domain of experts. The cloud is how total beginners can get started much more easily. There’s no better demonstration of that than our first top Arduino Cloud feature; auto-generated sketches.

When you create a new “Thing” in your Arduino Cloud, you add various bits of info to it. Wi-Fi connection credentials, and any variables you want to control or monitor. The Cloud automatically generates a starting sketch from this info. That sketch can then be sent to your boards, so all your initial configuration is taken care of, without a single line of code.


2) Device-to-Device Communication

There’s simply no easier way to make two microcontroller boards talk to each other than Arduino Cloud. We’ve covered in detail how easy it is to wirelessly connect your boards.

This isn’t just for Arduino devices either. If you want any combination of Arduino, ESP32 and ESP8266 devices to work together, this is how you do it.


3) Over-the-Air Updates

Working through your Arduino Cloud means you don’t have to disconnect any Arduino boards when updating them. If you want to edit or add a new sketch, it can all be done wirelessly, over-the-air.

Anyone who’s had to dismantle a project or device to get to a board’s USB socket will appreciate the simple, vital value of this feature. It’s one of those things that you’ll wonder how you ever lived without.

Arduino cloud features over-the-air updates

4) Support for ESP Boards

There’s a reason we call it the Arduino IoT Cloud. This is an all-encompassing platform for Internet of things, home automation, and electronics project control and management. So first we added support for ESP8266 devices. More recently, experimental support for ESP32 boards became available.

So even if your project doesn’t actually have any Arduino products in there, the Cloud is just as useful. Secure, private, and accessible to all kinds of IoT and maker devices.

Arduino Cloud also supports ESP8266 and ESP32

5) Trigger Actions on Cloud Events

Arduino Cloud makes it super easy to do things that you might normally need the IDE for. But it’s also got lots of exclusive features that you only get in the Cloud.

For example, there are actions that can be triggered based on your board’s interactions with your Arduino Cloud. You can include actions within your sketches when a Cloud connection is successful, and when the Cloud has synced with a device. Or perhaps most useful of all, trigger an action if Cloud connectivity is lost. Getting an indication that a project has disconnected could be incredibly useful!

Here’s an example of using these actions within a sketch.


6) Sharing Your Dashboards

Dashboards are control panels within your Arduino Cloud. It’s one of the most powerful Arduino Cloud features, and essential to making full use of Cloud control. But what’s often overlooked is that you can share dashboards with anyone you want.

For example, let’s say you’re using Arduino Cloud to control your home automation. You can set up a dashboard for a tablet in the living room that the whole family can use, but doesn’t have sensitive admin controls in there. And then another for people to use on their phones. 

All Cloud plans include unlimited dashboards. And anyone can have a free Cloud account. So you can create as many dashboards as you like, and share them with literally anyone, anywhere.

Share dashboards with anyone you want from Arduino Cloud

7) Alexa Integration

Natural language voice control is genuine Star Trek stuff. So it’s no wonder people love the functionality of Alexa. Did you know it’s incredibly easy to connect your Arduino Cloud to Alexa? And once you have, it effectively adds voice control to every board, and every project. Nothing else needed.

There’s literally no easier way to make an Alexa-controlled device or project than with your Arduino Cloud. You’ll never look back, and you’ll always have someone to talk to.


8) Full API Integration

For the engineers, coders, developers and those among you who’ve been using Arduino for a long time, API integration is the powerhouse secret feature you’ve been looking for.

The API can be called with any HTTP client, or with languages like Javascript, Python, Golang and more. It’s what you need to incorporate the power of Arduino Cloud features into your systems, platforms and projects.


9) Use IFTT, Zapier and More with Webhooks

There are lots of reasons you might want to include control platforms outside of your Arduino Cloud. Like sending an email or a Tweet when you press a button on a Nano, or a device disconnects from the Cloud (see above).

That’s what webhooks are for, and they give you a universal way to send commands out of Arduino Cloud, and into… well, anything!

IFTTT and Zapier are great examples of services that can do almost anything from a webhook. Get to know this feature, and connected projects suddenly have easy access to the whole web.


10) Easy Firmware Updates

When you connect a new Arduino board, your Arduino Cloud automatically checks its firmware version. If there’s an update available, it offers you the option of applying that update.

Very easy, and you don’t have to worry about finding the correct/latest firmware version yourself. This simple, background function makes sure your boards and projects always have the latest features, security updates and bug fixes.

For people who use a lot of Arduino devices, it’s worth adding them to the Cloud for this feature alone.


11) Full Dashboard Customization

We’ve already talked about unlimited dashboards in your Arduino Cloud. Creating them is easy, but did you know you can customize them too?

Anyone who’s dipped their toe in the home automation waters knows how essential dashboard editing is. Some platforms work great, but offer very little when it comes to controlling your dashboard layout. For many people, that’s a deal breaker.

Your Arduino Cloud widgets can easily be added, edited, removed, repositioned and resized in any configuration you want. It’s as simple as drawing and resizing boxes, but the result makes your Cloud projects infinitely more useable.


12) Watchdog Timer

The Arduino Cloud automatically runs a watchdog timer that will reset your board, hardware or project if it crashes. This is a small feature, but a powerful one that can keep your projects running while unattended. 

It means you never have to manually reset it when you eventually realize it’s not been running all day. You can have devices running remotely (very remotely, with SIM or LoRa connectivity) and be sure they’re robust enough to keep on ticking.

It’s included and running automatically, but can easily be disabled if you don’t need it.


13) Node-RED Integration

Arduino provides a super easy way to use Node-RED for IoT automations. This is a powerful, but very easy-to-use visual programming platform specifically designed for IoT projects.

Complex automations using advanced triggers like sunrise or sunset, presence detection, combined actions or sensor readings and so much more. The possibilities are endless, and learning Node-Red is incredibly easy. Get to grips with this feature, and you’ll be creating IoT automations that would otherwise need an experienced coder.


13A) Fully Functional Free Account

One of the best kept secrets of the Arduino Cloud is that if you’re registered on the Arduino website or forum, you already have a free Cloud waiting for you. Simply head on over to the Cloud site and get started with unlimited dashboards and unlimited sketches. The free tier of Arduino Cloud is fully functional, and it’s ready and waiting for you to give it a try.

In fact, it’s the perfect option especially if you haven’t used Arduino before! Give it a shot and let us know what you think. No credit card required; just your creativity and a passion for connected projects.

The post 14 Awesome Arduino Cloud Features You Never Knew Existed appeared first on Arduino Blog.

When you think of world-changing devices, you usually don’t think of the washing machine. However, making laundry manageable changed not only how we dress but how much time people spent getting their clothes clean. So complaining about how laborious our laundry is today would make someone from the 1800s laugh. Still, we all hate the laundry and [Andrew Dupont], in particular, hates having to check on the machine to see if it is done. So he made Laundry Spy.

How do you sense when the machine — either a washer or a dryer — is done? [Andrew] thought about sensing current but didn’t want to mess with house current. His machines don’t have LED indicators, so using a light sensor wasn’t going to work either. However, an accelerometer can detect vibrations in the machine and most washers and dryers vibrate plenty while they are running.

The four-part build log shows how he took an ESP8266 and made it sense when the washer and dryer were done so it could text his cell phone. He’d already done a similar project with an Adafruit HUZZAH. But he wanted to build in some new ideas and currently likes working with NodeMCU. While he was at it he upgraded the motion sensor to an LIS3DH which was cheaper than the original sensor.

[Andrew] already runs Node – RED on a Raspberry Pi, so incorporating this project with his system was a snap. Of course, you could adapt the approach to lots of other things, as well. The device produces MQTT messages and Node – RED subscribes to them. The Pushover handles the text messaging. Node – RED has a graphical workflow that makes integrating all the pieces very intuitive. Here’s the high-level workflow:

You might wonder why he didn’t just have the ESP8266 talk directly to Pushover. That is possible, of course, but in part 2, [Andrew] enumerates some good reasons for his design. He wants to decouple components in the system for easier future upgrades. And MQTT is simple to publish on the sensor side of things compared to API calls which are handled by the Raspberry Pi for now.

Laundry monitoring isn’t a unique idea and everyone has a slightly different take on it, even some Hackaday authors. If phone notification is too subtle for you, you can always go bigger.

Giu
22

Motion Sensing Water Gun Tweets Photos To Embarrass Enemies

arduino, arduino hacks, Bean, gun, Lightblue, mosfet, node-red, python, squirt gun, super soaker, twitter, water Commenti disabilitati su Motion Sensing Water Gun Tweets Photos To Embarrass Enemies 

[Ashish] is bringing office warfare to the next level with a motion sensing water gun. Not only does this water gun automatically fire when it detects motion, but it also takes a photo of the victim and publishes it on Twitter.

This hack began with the watergun. [Ashish] used a Super Soaker Thunderstorm motorized water gun. He pulled the case apart and cut one of the battery wires. he then lengthened the exposed ends and ran them out of the gun to his control circuit. He also placed a protection diode to help prevent any reverse EMF from damaging his more sensitive electronics. The new control wires run to a MOSFET on a bread board.

[Ashish] is using a Lightblue Bean board as a microcontroller. The Bean is Arduino compatible and can be programmed via low energy Bluetooth. The Bean uses an external PIR sensor to detect motion in the room. When it senses the motion, it activates the MOSFET which then turns on the water gun.

[Ashish] decided to use Node-RED and Python to link the Bean to a Twitter account. The system runs on a computer and monitor’s the Bean’s serial output. If it detects the proper command, it launches a Python script which takes a photo using a webcam. A second script will upload that photo to a Twitter account. The Node-RED server can also monitor the Twitter account for incoming direct messages. If it detects a message with the correct password, it can use the rest of the message as a command to enable or disable the gun.


Filed under: Arduino Hacks


  • Newsletter

    Sign up for the PlanetArduino Newsletter, which delivers the most popular articles via e-mail to your inbox every week. Just fill in the information below and submit.

  • Like Us on Facebook