Category Archives: Electronics

RadioShack is back!

Have you checked the RadioShack store locator page lately? I did, last week, and instead of just finding three dealer stores in my state (none within an hour), I was surprised to see on in nearby Ankeny, Iowa. It was in some place called HobbyTown.

Somehow I missed the announcement that the Shack posted to their Facebook page back in July. Indeed, they now have a store-within-a-store at some HobbyTown locations.

I went to visit this location, and thought I’d share a trip report.

HobbyTown… Remote controlled cars, model rockets, and … RadoShack Express!
Yes, Virginia. There IS a RadioShack inside.
They only have the electronics parts, all displayed on the wall. No answering machines, video cables, or cell phones.
Even perfboards! This IS your father’s RadioShack! Except it’s still missing the space between the words :(

There was also another small glass cabinet nearby with a few other parts, and at the front checkout counter they had RadioShack brand batteries and such.

I have been working on some projects for Halloween, and found several items that I could put to use. I picked up a 12V buzzer, some 12V lights, some button switches, and some wire nuts. (Yeah, I know I could buy a whole bag of industrial wire nuts at the hardware store for just a bit more, but I only needed a few and “it was just a few bucks.”)

My bounty from my first trip to a RadioShack Express. They even use the old RS catalog numbers (after the RSH).

Leave a comment if you have a RadioShack near you.

RS232 to TTL adapters with all signals, including DCD

I have been experimenting with hooking up low-cost ESP8266 WiFi modules to the Radio Shack Color Computer (or anything with an RS-232 port) using cheap RS232-to-TTL adapters. Most of these adapters only support 3-wire RS-232 (transmit, receive and ground). This is fine for most uses of the CoCo’s built-in Serial I/O port (bitbanger) since it is only a 4-pin DIN connector with TX, RX, GND and CD, and most things do not rely on carrier detect.

But, for the Deluxe RS-232 Program Pak, a hardware 6551 UART chip is used and that chip requires to see carrier detect before it will receive any data. A workaround is to simply tie some of the TTL converter pins together to make it always present DCD to the RS-232 Pak:

This works fine if you are just connecting to remote systems, but if you want to run a BBS, those often rely on carrier detect to know if a caller is online. If a caller disconnects without properly logging off, the system may sit there forever (worst case) or until some software timeout is reached and the system resets. During that time, it would be possible for the next person connecting to resume that session.

This was a real and common issue with BBSes back in the 1980s, for this very reason – lack of carrier detection.

Another issue is the lack of hardware flow control. There could be times when the ESP8266 could try to send data faster than the computer could process, and there is no way (other than XON/OFF, which can’t be used for binary transfers) to tell it to pause sending.

I have found RS232-to-TTL adapters that provided 5-wire signals (adding RTS and CTS), which is needed for this hardware flow control. Those are a bit more costly (I found one for $9 on Amazon), and still do not address the carrier detect issue.

Once again, David Chesek comes to the rescue. He located an adapter that supports all the RS-232 signals, including RI (ring indicator). It is available for $11.50 plus shipping from a company in Las Vegas called Pololu (and might even be manufactured there):

Pololu RS-232 to TTL adapter with all signals. (Photo taken from Pololu.com)
https://www.pololu.com/product/126

I took a gamble (pun intended) and ordered a few. I will report back as soon as I receive them and have had a chance to try them out.

Meanwhile, knowing such a thing exists, I did more searching and found a similar one on e-Bay from a seller called MDFLY. They have them for $3.25 plus shipping, and are shipped from California:

eBay seller MDFLY RS-232 to TTL adapter with all signals. (Photo taken from their eBay listing.)
https://rover.ebay.com/rover/0/0/0?mpre=https%3A%2F%2Fwww.ebay.com%2Fulk%2Fitm%2F382224238410

The board layouts are quite different, but the functionality should be similar. I will be comparing both of these (and noting shipping time) when I have them.

With either one of these boards, properly wired to additional pins on a full ESP8266 development module, it should be able to provide hardware flow control and carrier detect. (Sorry, the ESP-01 module only has two I/O pins, so we’d have to pick and choose what to support on that one — like DTR and DCD for BBS use, or CTS/RTS flow control.)

More to come…

YQ8008 bicycle LED light for $74.96 on e-Bay

  • 2015/8/25 – Added not about $36 YQ8007.
YQ8008 bicycle LED light (pic from e-Bay store), currently $75 on e-Bay.
YQ8008 bicycle LED light (pic from e-Bay store), currently $75 on e-Bay.

A relatively new e-Bay store, Newell Development, has a listing for the YQ8008 three-arm bicycle LED light for $74.96 with free shipping from China. This model typically sells for around $130, but many e-Bay stores have it for around $80 with a $20 shipping fee. This $74.96 price is the lowest I have found so far.

They list the item as “generic” but I wrote them to ask if it was a YQ8008 (they use all the same official photos) and they responded:

“…it is Original with 100 Modes Programmable DIY Bike Bicycle Wheel Spoke Light. And it is in stock.”

Although the XuanWheel has four arms (so it can display images at lower speeds), the YQ8008 has a higher LED count per arm and thus produces a higher resolution image. You can check my comparison chart to see more details.

I have also found the YQ8007 (two arms) for $40 with free shipping from GearBest.com. I have received one to review. It shipped on 8/11 and was received in Iowa on 8/20, so just over a week — not bad. (As of this update, it is currently $36.)

See Also: XuanWheel for $79.

XuanWheel bicycle LED light for $79 on Amazon

  • 2015/8/14: Added note about e-Bay seller.
  • 2015/8/24: Added note that it now is shipped by Amazon, and qualifies for Amazon Prime shipping.
  • 2015/12/8: $72 on Amazon currently, and there are some reviews now (and notes from the seller explaining why the iOS app is “untrusted”. Buyer beware!)
XuanWheel (pic from Amazon store).
XuanWheel (pic from Amazon store).

The XuanWheel (or is it Xuan Wheel?) just saw a $10 price drop. It is currently $79 at Amazon with shipping  from Amazon, so it qualifies for Amazon Prime. This model has four arms, and thus produces an image (or moving video) at lower speeds than the cheaper two arm models.

One of the two e-Bay sellers has them for $69 with free shipping (from China), currently.

See Also: There is also the YQ8008 (now found for $75 on e-Bay with free shipping) three arm unit which has a higher density of LEDs no each arm for higher resolution photos. XuanWheel is probably better at slower speeds, and YQ8008 probably has better images at higher speeds.

More on bike spoke light LED signs (POV)

  • 2004/8/09 – Adding link to Hokey Spokes.
  • 2014/8/10 – Adding link to manufacturer of YQ800X series products.

Last year, I posted an article discussing a cheap bike wheel LED display I picked up for $6 on e-Bay. Recently, I discovered many other ones seem much better. The cheap one I have has 32 blue LEDs, and is single sided, so you can only view it from on side of the bike. Since then, I have discovered full color versions with more LEDs and, most importantly, double-sided so they can be viewed on either side of the bike. Here is a rundown of my researc so far, mostly posted here so it can be indexed in Google, BING, etc. and maybe help others.

I will post links to the items available from Amazon (but NONE are actually sold BY Amazon, and most ship from China and take weeks to arrive). I have found hundreds of e-Bay stores selling them, too, often at far lower prices.

There is a company called ExcelVan that makes several, ranging from $20 to over $100.

The ones I have found so far include:

  1. YQ8003 – $45, double-sided, two arm, 128 LED, programmed via USB cable.
    http://www.amazon.com/Excelvan-Colorful-Waterproof-Programmable-customize/dp/B00WS2I8K2
  2. YQ8005 – $26, double-sided, two-arm, 96 LED, maybe not programmable (25 included pictures).
    http://www.amazon.com/Excelvan-Colorful-Pictures-Waterproof-Mountain/dp/B00W8QC1JC/ref=sr_1_cc_2?s=aps&ie=UTF8&qid=1439079623&sr=1-2-catcorr&keywords=YQ8005
  3. YQ8007 – $90 (but I found it for $40), double-sided, two-arm, 144 LED, programmable by SD memory card. This Amazon link is for a different brand name, so it is either a clone/bootleg or just another company selling the item under their name.
    http://www.amazon.com/Yongchengg-Programmable-Programming-Double-side-Waterproof/dp/B011U02790/ref=sr_1_1?s=sporting-goods&ie=UTF8&qid=1439079839&sr=1-1&keywords=YQ8007
  4. YQ8008 – $150 (Amazon Prime), double-sided, three-arm, 216 LEDs, programmable by SD memory card. By having THREE arms, it can display the color picture at a slower speed.
    http://www.amazon.com/gp/product//B00RE6KGNY/ref=twister_dp_update?ie=UTF8&psc=1

Update: Since the original posting, I think I have located the manufacturer of these devices. They produce YQ8001 to YQ8009. Some use preset patterns, some are programmable (they call them “DIY”), and some can even do video. I will try to put a chart together as I learn more.

Here is the YQ8003 installation video:

By searching for the “YQxxxx” numbers, you can find them being sold all over e-Bay and other online places — most shipping from China. The prices vary greatly. GearBest has the YQ8007 (they claim) for $40.99 with free shipping, for example.

XuanWheel (pic from Amazon store).
XuanWheel (pic from Amazon store).

There is a difference in how they work, too. Some just display static photos, and some can display animation. But, the best one (maybe), is the XuanWheel.

http://www.ixuanlun.com/en/indexEnMobile.html

I believe it started out as an IndieGogo campaign called HaloWheel, but since Halo Wheels is a name of a bike wheel brand, maybe that’s why they changed it to XuanWheel? It is a double-sided, four-armed one that is programmed via Bluetooth over an Android or iOS device. This HaloWheel (per IndiGogo name) or XuanWheel (per website) runs $89 on Amazon (there is a $5 discount code right now) with free shipping (from China, so it takes a month to reach the USA). I found similar devices on e-Bay for as low as $73 (they may be knockoffs or clones).

This one looks like it can synchronize both wheel displays (if you have two). I could not find ANY information on what size hub it would fit, so I asked on YouTube and they replied:

The diameter of the hub should not be larger than 3.8 centimeter

WARNING: Their iOS app is not in the App Store. Instead, you just go and download it direct from their website. Assuming you like to just download random apps from sites in China… Yes, just like Android, you can directly install iOS apps without going through the App Store. BUT, they are not supposed to do that. That is, I think, how developers allow beta testers to get access to their apps before they are done and submitted to Apple. They only get a limited number of installs this way, I believe, and they are not meant to be distributing software like this. At least the iOS device will warn you:

Currently not in the App Store, you have to take changes with a non-inspected app from a website in China. Scary!
Currently not in the App Store, you have to take changes with a non-inspected app from a website in China. Scary!

And lastly, there is even the Monkey Light Pro  by Monkeylectric that sells for $1000. It looks good, but not $1000 good!

More to come… I am hoping to have a review unit of one of these in a few weeks.

UPDATE: Commenter wb8nbs pointed me to Hokey Spokes, which at $20 16-LED spoke lights that can display preset patterns or simple one line text. The unique thing about them is you can use just one, or multiple. They sync to each other using infrared, and from the demo videos, it appears they all just do the same thing so all patterns look symmetrical (thus, any text would show the same in three places of the wheel when using three of these). Not color, but you can get them in different colors and create interesting rainbow effects. Not the most cost effective solution, but if you just want cool lights, one would be pretty cheap, and they ship from Indiana!

Cheap bicycle wheel LED sign (POV)

Due to finances, about the only form of recreation I have these days is riding my bike. I like to take casual rides on the many trails here in Des Moines (Iowa is famous for it’s massive bike trail network).

A few years ago, I came across this neat LED display that attaches to a bike wheel and created images using persistence of image (i.e. lights flashing real fast as the wheel rotates, which the eye sees as a complete, though flickering, image):

http://www.ladyada.net/make/spokepov/

Go there and look at the pictures and watch the videos. It is able to display full color and even animate images (I love the Pac-Man and Ghost images they show). It works by having a row of LEDs that flicker on and off as the wheel spins. The wheel has to spin very fast to show an image, so they sell kits with multiple circuit boards of LEDs. The more on the wheel, the slower it has to turn to show an image.

It looked really cool, but it came in a kit, and I am not really that capable of an electronics person. Plus, the kit with three circuit boards was $113.

A found similar (much cheaper) devices on Amazon, though most of them just did preset patterns and didn’t let you load your own. You can find some simple LED wheel lights at Amazon for around $13 that can display short text messages:

Do some searching and you will find all kinds of cheap POV displays for bike wheels. I even found one for around $12 that was programmable via USB:

None of these are anywhere near as cool as the Adafruit SPOKEPOV kit, but they might be pretty neat for the money.

Then, I came across this one on from an e-Bay store:

http://www.ebay.com/itm/PC-Programmable-Wireless-LED-Custom-Message-Bike-Wheel-Lights-/400354534043?pt=LH_DefaultDomain_0&hash=item5d36fd629b

It had two rows of LEDs and could attach to the hub of the bike and display messages or graphics. At the time I found it, there was a seller auctioning them off, and I picked one up for $6 (shipped from the US, even). Unfortunately, the device was not like the pictures show — it was not in color, just blue (the description says this, but all the listings, including Amazon, use pictures showing one with color).

Also, the device would not fit the hub of my bike (the bolts were too short), nor the sensor on the frame (the bracket was too small). I am not sure what tiny little bikes these were made for, but my old 1998 Trek wasn’t one of them.

However, with a bit of rigging, it was easy to attach the device to the spokes of my bike (rather than clamping it around the hub) using some tape, and then I could do some quick experiments.

If I get time, I would like to experiment with a very low-cost version of this, using an Arduino-style device and a strip of the high speed LPN8806 addressable LEDs. An Arduino in a plastic enclosure with batteries could easily power two segments of 32 LEDs (wider spacing than the commercial units, though) and do full color. The only other hardware would be a magnet and a sensor so the device can tell when the led strips circle around.

Sound fun? More to come… (I already have created JavaScript code that lets me load in an image in a web browser and convert it to the format that this device would need to display it.)

Simple scrolling LED Sign for NeoPixel (WS2811) or LPN8806

  • 2014/03/16 Update: The source code to this is now on GitHub. Check the Arduino link at the top of each page of this site.

Yesterday evening, I coded up a simple scrolling message sign that uses addressable LED strips like the Adafruit NeoPixels (WS2811) or LPN8806. The code I created is built for NeoPixels, since those were the ones I had access to, but it would be trivial to make it work with the Adafruit LPN8806 library. Future versions will make this simpler.

First, let’s talk about LED signs.

The BetaBrite is a commercially available scrolling message sign that’s been around for ages. I bought one at SAM’S CLUB back in the late 1990s. The BetaBrite that I have uses an 80×7 array of LEDs. This is what I will be trying to replicate.

If you shop around (ahem, e-Bay), you can find 1 meter long WS2811 LED strips with 60 RGB LEDs for around $8-$9. If you had seven of those, you could make a 60×7 LED sign. It wouldn’t be able to show as many characters at the same time as a BetaBrite does, but it would be good enough to experiment with. (There are strips with 144 pixels per meter, but they are very expensive. And, when you get past 500 or so LEDs, you start running out of memory on the Arduino. I plan to fix this with some updates to the LED library, eventually.)

Consider this wonderful drawing as I discuss a few possible ways to present a sign made out of LED strips:

LED Sign ideas

A. At the top is an example of one of these LED strips with LED number 0 to “n”. One end hooks to the Arduino and power, and the other end can be used to daisy chain multiple strips together. The first LED will be 0, and they count up to the end of the last strip. If you have three 60 LED strips, you have LEDs 0 to 179. The green arrow shows the direction of the data (the LEDs count up in that direction).

B. Next is an example of how you might arrange multiple strips so they could make up an LED sign. Each strip is shown running left-to-right, so at the end of the first strip the cables go all the way back to the left to connect to the start of the next strip. Wiring them like this makes it real easy to do things with. Notice that the green arrow runs left-to-right on each row.

C. However, it would be much much easier to just connect them like this, without all the extra wires running around. But, this causes every other row to run in the opposite direction (again, see the green arrows). This means the software has to be smart enough to know how to reverse drawing the pixels for every other row.

ALSO, based on where you decide to make LED 0, that changes everything. In these drawings, we are hooking the Arduino up at the top left. But, if it was easier to hook up at the bottom right, the entire numbering system would be backwards.

I decided to write a simple LED message program that could handle all of this. It’s not pretty, but it (maybe) works. I configure it with the number of LEDs in use, and how many are in each row, then I set where the start pixel is (TOPLEFT, TOPRIGHT, BOTTOMLEFT or BOTTOMRIGHT). I support running the rows STRAIGHT (A) or ZIGZAG (B). It can even do something fun…

D. This is the only thing I have actually done. I had two 1 meter strips, so I decided to spiral them with 20 LEDs in each spiral before the next row starts. These 120 LEDs can be split up in my program as six rows of 20 LEDs each, and then (with a small enough font), a message can rotate around it.

If you’d like to try out my code, I have posted it to GitHub:

https://github.com/allenhuffman/LEDSign

I have only tested it in the D configuration, but I have done some debug prints that make me think it should be handling all the other variations. Until I have access to more LED strips, I won’t know for sure.

Anyone want to try it out and let me know how it works for you?

Poor documentation, and the code could be cleaned up and optimized quite a bit. Perhaps I will have that done when I reach version 1.0.

Here’s a video of my first working version:

Arduino WS2811 scrolling message sign

I have two 1m 60 LED WS2811 strips, and expect to receive several more in coming weeks from Chinese suppliers. Once I have seven of them, I plan to use them as a scrolling message sign.

However, with two 1m strips (120 LEDs total), you can spiral them loosely (not tight enough to break the strip) and end up with six rows… Sorta. And, with a quick Arduino sketch (making use of some TVout fonts)… You can create a mini-circular scrolling message sign.

Here is “HELLO WORLD”:

Just for fun…

RGB addressable LEDs (WS2811, LPD8806)

Last year, I was involved with a large Halloween project that involved upgrading the lighting in a haunted house attraction to DMX controlled RGB LEDs. We spent many, many late hours running 12V power through the entire attraction to power all the lights, and Ethernet cable to carry the DMX (RS485) control signal. The end result was the ability to set the lights to any color without having to change bulbs.

Changing the bulbs would have been much easier.

A year before this project, the manager there had introduced me to HolidayCoro.com. This site resells LED lighting mostly for Christmas light displays. (The manager had one of those synchronized Christmas light displays at his house and he was in the process of converting the entire setup to RGB LEDs as well, which he did in 2013.)

Like many things here, one thing seems to lead to another, and I want to share some information in “addressable RGB LED lights.”

Adafruit.com sells a number of RGB LEDs, including their Neo Pixels which allow each light to be individually controlled. I first learned of this type of technology in 2010 when some GE Color Effect G-35 Christmas lights were introduced and quickly hacked so they could be controlled by an external computer. In 2010, this was cutting edge, but today, there are several off-the-shelf ways to do this.

An Arduino controls a strip of 32 LPD8806 RGB LEDs.
An Arduino controls a strip of 32 LPD8806 RGB LEDs.

There are two main LED chipsets I see being used:

  • WS2811 – Adafruit calls these Neo Pixels, and the lights run in series and are addressed over a one wire connection (power, ground, data) using a special protocol. The library for Arduino to do this is very clever and involves specific assembly language timing to toggle the data line at the proper frequency to send the data.
  • LPD8806 – this version uses a two-wire interface (SPI protocol) to talk to the lights (power, ground, clock and data). These lights are far easier to address and less timing sensitive.

At Adafruit, a string of 60 Neo Pixels (1 meter) runs $24.95. You can find similar strips (same chipset, same number of lights) on e-Bay shipped from China for around $18, or bid on auctions and get them for less than $10 each.

At Adafruit, the LPD8806 strips of 32 LEDs (1 meter) run $29.95. A coworker at my day job just bought one of these, which is where I first saw them in person.  On e-Bay, you can find these for $20 on e-Bay with free shipping from China. To find versions with 52 lights per meter (to get light density similar to the WS2811 version), the cost is around $30.

If you want to experiment with the LPD8806 lights without spending a ton of money or waiting weeks for a shipment from China, check out this seller on e-Baykbellenterprises is located in Missouri and will sell a 1-foot strip of LPD8806 lights for $12.99 (with free shipping). They also sell Arduino clones, power supplies and other items at near-China prices (you can get an UNO clone for around $10). You can get one of their strips and hook it up to an Arduino with four wires and safely power the 32 LEDs. (They say you should be able to power up to 2 feet off an Arduino’s 5V 500ma output. More lights than that requires an external power supply.)

As you can see, the LPD8806 lights are about 3 times the cost of the WS2811. The LPD8806 lights are “smarter” (in a way) and easier to work with, without needing specific timing code like the WS2811 require.

For casual play, both work the same way — in fact, Adafruit has posted libraries for each type of light and they both use the same API. You simply set some pixel colors (RGB) and then display them:

strip.begin();

// Set the first 10 LEDs...
for (i=0; i<10; i++)
{
strip.setPixelColor(i, strip.Color(127,0,0));
}
strip.show();

There are some limitations to using these lights on an Arduino. First, the libraries require a buffer of 3-bytes for each LED on the strip  (one byte for red, green and blue). An Arduino with only 2K of RAM can only handle 500 or so lights (more or less, depending on how much RAM your sketch uses, and any libraries you use). This severely limits how useful this is for anything other than just blinking a small strip of lights. My old 1990s BetaBrite LED sign, for instance, is made up of 80×7 LEDs (560) so I couldn’t replicate that using an Arduino and these types of lights using the standard library. More on this later…

There are dedicated controllers (Look for the T1000S, around $43 with free USA shipping, or less from China) that can display light sequences on up 2048 LEDs from an SD memory card. You don’t get any computer control this way (all sequences are made ahead of time using special Windows software), but this would be a much better way to drive a large amount of lights than trying to do it with an Arduino.

But what if one really wanted to use a 2K Arduino? Could you actually make a scrolling LED sign similar to a BetaBrite?

Perhaps.

In coming weeks, I will be sharing some embedded programming tricks that might allow controlling far more than 500 or so LEDs from an Arduino.

Check back…