Someone Finally Did It With A 555

Someone Finally Did It With A 555

[Jarunzel] needed a device that would automatically click the left button on a mouse at a pre-set interval. For regular Hackaday readers, this is an easy challenge. You could do it with an ATtiny85 using the VUSB library, a few resistors and diodes, and a bit of code that emulates a USB device that constantly sends mouse clicks over USB every few seconds. You could also do it with a Raspberry Pi Zero, using the USB gadget protocol. Now, this mouse-clicking gadget would be connected to the Internet (!), programmable with Node or whatever the kids are using these days, and would have some major blog cred. If you’re feeling adventurous, this mouse clicker gadget could be built with an STM32, Cypress PSoC, or whatever microcontroller you have in your magical bag of hacker tricks.

Then again, you could also do it with a 555 timer.

The reason [Jarunzel] couldn’t use any of the fancy hackertools for this build is because the system wouldn’t accept two mouse devices. No matter, because Maplin has a neat kit with a 555 timer and a relay. The relay is wired up across the microswitch in the mouse, and setting the values correctly makes the mouse click about once per second, with a click duration of about 100ms. Good enough.

With the kit built, wired into the mouse, a small app built to test the device, and a nice project box constructed, [Jarunzel] had exactly what he needed. There’s even a video of this mouse clicker in action. You can check out that riveting footage below.

VIDEO

Posted in peripherals hacksTagged , ,

from Hack a Day http://ift.tt/2wlyxkB
via IFTTT

Advertisements
Posted in Uncategorized | Tagged , | Leave a comment

Alexa – NodeMCU: WeMo Emulation Made Simple

Let’s connect a 4 Channel relay module to control 2 lamps and 2 outlets as shown in above diagram.

We will create 4 “single smart devices”:

  • Light1 ==> Relay 1 ==> NodeMCU D5
  • Light2 ==> Relay 3 ==> NodeMCU D7
  • Outlet1 ==> Relay 2 ==> NodeMCU D6
  • Outlet2 ==> Relay 4 ==> NodeMCU D8

and 3 groups of combined devices:

  • All Devices (Light1, Light2, Outlet1 and Outlet2)
  • Living Room (Light1 and Outlet1)
  • Bed Room (Light2 and Outlet2)

Download and open the file NODEMCU_ALEXA_WeMos_4X_Fauxmo_EXT.ino from my GitHub and change the dummy wifi credentials, with your own:

/* Network credentials */
#define WIFI_SSID "YOUR SSID HERE" #define WIFI_PASS "YOUR PASSWORD HERE"

Confirm that you have properly defined the pins where the relays are connect:

/* Set Relay Pins */
#define RELAY_1 D5 #define RELAY_2 D6 #define RELAY_3 D7 #define RELAY_4 D8

Now, we must define the “name” as our devices will be understood by Alexa:

// Device Names for Simulated Wemo switches
fauxmo.addDevice("Light One"); fauxmo.addDevice("Light Two"); fauxmo.addDevice("Outlet One"); fauxmo.addDevice("Outlet Two"); fauxmo.addDevice("Bed Room"); fauxmo.addDevice("Living Room"); fauxmo.addDevice("All Devices");

And, we must at setup(), define the “callback” function:

fauxmo.onMessage(callback);

The loop() should be:

void loop()
{ fauxmo.handle(); }

The callback function should be developed as below (this is only for Light1):

/* ---------------------------------------------------------------------------
Device Callback ----------------------------------------------------------------------------*/ void callback(uint8_t device_id, const char * device_name, bool state) { Serial.print("Device "); Serial.print(device_name); Serial.print(" state: "); if (state) { Serial.println("ON"); } else { Serial.println("OFF"); } //Switching action on detection of device name if ( (strcmp(device_name, "Light One") == 0) ) { if (!state) { digitalWrite(RELAY_1, HIGH); } else { digitalWrite(RELAY_1, LOW); } }

Note that I used “!state” inside the “if statement”, because the 4 channel relays use reversed logic for activation.

On the Serial monitor you can see the messages exchanged:

[WIFI] Connecting to ROVAI TIMECAP
............................. ==> CONNECTED! [WIFI] STATION Mode, SSID: ROVAI TIMECAP, IP address: 10.0.1.36

Now, let’s ask to Alexa to find your device. There are 2 methods to do it:

  1. Using the Alexa App in your Smartphone
  2. Asking Alexa to do it directly using voice command, like: “Alexa (in our case “Computer”), Find connected devices” as shown in the video below:

VIDEO

Once Alexa has discovery your device, you can give her voice commands as shown below:

VIDEO

The above screenshot shows the Serial monitor response.

from Instructables: exploring – featured http://ift.tt/2w0kn5K
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment

Catalog of visualization types to find the one that fits your dataset

Catalog of visualization types to find the one that fits your dataset

There are a lot of visualization methods to choose from, and it can be daunting finding the right visual for your data, especially for those just starting out. The Data Viz Project by ferdio is a work-in-progress catalog that aims to make the picking process a bit easier. Start with a bunch of chart types and filter by things like shape, purpose, and data format. If you’re stuck, this should help get the juices going.

from FlowingData http://ift.tt/2uWSxGj
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment

DIY ant killer

Homebrew ant killer made from sugar, borax, and water is very effective in keeping ants out of the house. Dissolve a half cup of sugar with 1.5 tablespoons of borax into 1.5 cups of warm water. Then dip a cotton ball into the solution and set it on a countertop (where kids and pets won’t eat it). The ants will flock to it and 12 hour later, you won’t see any more ants for a long time. Get a one-pound bag of borax on Amazon for $8.50 (which you can also use to make slime).

Image: Balaram Mahalder/Wikipedia

from Boing Boing http://ift.tt/2w8NDKk
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment

Multiple Monitors With Multiple Pis

One of the most popular uses for the Raspberry Pi in a commercial setting is video walls, digital signage, and media players. Chances are, you’ve probably seen a display or other glowing rectangle displaying an advertisement or tweets, powered by a Raspberry Pi. [Florian] has been working on a project called info-beamer for just this use case, and now he has something spectacular. He can display a video on multiple monitors using multiple Pis, and the configuration is as simple as taking a picture with your phone.

[Florian] created the info-beamer package for the Pi for video playback (including multiple videos at the same time), displaying public transit information, a twitter wall, or a conference information system. A while back, [Florian] was showing off his work on reddit when he got a suggestion for auto-configuration of multiple screens. A few days later, everything worked.

Right now, the process of configuring screens involves displaying fiducials on each display, taking a picture from with your phone and the web interface, and letting the server do a little number crunching. Less than a minute after [Florian] took a picture of all the screens, a movie was playing across three weirdly oriented displays.

Below, you can check out the video of [Florian] configuring three Pis and displays to show a single video, followed by a German language presentation going over the highlights of info-beamer.

Filed under: Raspberry Pi

from Hack a Day http://ift.tt/2x6WYif
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment

DIY Raspberry Pi Indoor Outdoor Webcam

In the boot partition, the one you see on windows, add a file named wpa_supplicant.conf and edit it in notepad. Copy and past the code below, and edit the ssid and password variables.

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

network={
ssid=”SSID”

psk=”PASSWORD” }

Then add a blank ssh.txt file to turn on ssh.

from Instructables: exploring – featured http://ift.tt/2v1MzGy
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment

British place-names generated by a neural net

Dan Hon (perfecting earlier work by Tom Taylor) trained an AI on the vast corpus of British place names, then set it loose. The results are amazing, illustrative of an uncannily human humor seemingly at work, something you’d never get from the standard syllable-randomizing place name generators of yore.

"There aren’t as many cocks as you’d think," he writes.

My favorites: Brotters Common, Boll of Binclestead, Farton Green Pear End, Weston Parpenham, Sutsy Compton, Stoke of Inch, Kinindworthorpe Marmile, Rastan-on-croan, Fuckley, Fapton, Waterwitherwell.

See also Hon’s AI trained to generate Ask Metafilter post titles.

Surely neural-net-generated Liffs are next.

from Boing Boing http://ift.tt/2v3Nu9D
via IFTTT

Posted in Uncategorized | Tagged , | Leave a comment