Yep you read the title correctly... I used a taser to fix my typing and here’s how.Part 1: Why? Why would you do that?
About a month ago I started to notice my typing speed was being slowed down by needing to make corrections in nearly every word. This obviously needed to change, so I devised a plan.Part 2: The plan.
The plan was simple.
- Step 1: Detect typos. In Order to improve my misspellings, we first need to figure out when they’re happening.
- Step 2: Reprimand user Once we’ve detected a typo, we need to trigger the taser, to help make sure I won’t do it again.
- Step 3: No more typos! Hopefully when I get teased I’ll make less typos.
In order to detect the typos I threw together a simple website which generates a random English word, and then prompts me to type it.
But how does it work?
Well the code is actually really simple.
First I grab a list of English words from here.
then I pick a random one.
After that it picks a random key, and sets the element’s content to the word.
Lastly I need to make sure the user is typing the provided word correctly.
That code is a really simple function, all it does is check if you’re typing the word correctly and if not it calls a function called turnOn() which triggers the taser.
(code linked at the bottom of the article)Part 4: The hardware.
Now the fun part!
To handle the taser circuit I’m just going to use some prank shock gum I found on Amazon, it’s a pretty mild shock.
This is good for two reasons, 1: if I mess up I’m not going to electrocute myself, and 2: if I mess up I’m not going to fry any of my electronics.But how will I interface the website with the hardware?
Let me introduce, the particle argon!
This is an Arduino compatible board, with cloud connectivity over WiFi. You can control individual pins over the air, just by pinging an API
So I’m going to use a circuit like this to open and close the taser switch via the particle:
Now that that’s done it’s time forPart 5: Testing!
So yeah it works! If you liked this post you’ll probably like my previous project: https://dev.to/nobody5050/why-i-let-strangers-control-my-lights-and-why-you-should-too-3kg0
Thanks for reading!