Now that we have created our Applet to control our LED using an email, it's time to test out the integration.Â
Here are the steps to create the email:
- Make sure the program in the chapter13/dweet_led.py file is still running in your Terminal.
- Open your favorite email program and create a new email.
- Use trigger@applet.ifttt.com as the email's To address.
When sending a trigger email to IFTTT, it must come from the same email address that you use with IFTTT (you can visit https://ifttt.com/settings to check your email address).
- As the subject, use one of the following to control the LED:
- #LED On
- #LED Off
- #LED Blink
IFTTT strips off the #LED tag, so our dweet_led.py program only receives the text On, Off, or Blink. The leading space is stripped off in our Python code.
The following screenshot shows an example email that will make the LED blink:
13.20 – Trigger email example
- Send the email.
- Wait...