Grinch...Maybe?

So I'm looking at _maybe_ doing some upgrades to my lights/display. really don't know for sure what if anything I'll do, there's various things I've considered...

Seeing some of the new stuff like RGB LED strings for the 1st time this year (and even getting a good up-close look at it thanks to a kind member on PC), all I can say is "that is awesome". but I think the cost is a deal-breaker for me...anyway I diegress there (as that would be a different topic...) LOL

My current thing is very simple - 24 channels with 3 parallel ports. One thing I've considered is simply adding more channels (and keep cost/work down) which is where something like 'Grinch' came to mind.

Looking around here some, it looks like it is 64 channels? (no dimming unless you do some sorta addon...and then it doesn't run off the parallel port anymore?? (which would exclude it as an option for me)) 64c would be more than enough for me (I'd probably use half of that to start)

It looks like with the schematic/parts-list I could fairly easily put one of those together. Are the SSR's for this the same thing like you'd use for a basic parallel controller (opto-isolator, a couple resistors & a Triac)? .. I might even be able to use my old 'boxes' if thats the case :)

One of my big questions is how does it work (this is a bit more technical)? Does it still use _only_ the 8 data out lines of a parallel port, or something more? Assuming just the 8, how do you turn on/off the channels - by this I mean what data are you sending to the port? (like with a simple 8-channel parallel control all I do is read a binary number, for simplicity say '00000000' for all off or'11111111' for all on, then convert that to hex and output it. with a grinch how does it work? are you sending multiple pulses for a single on/off command?)

Hopefully that all made sense...
 
Not manny people are useing the grinch anymore, and its getting hard to find the chips.

From my understanding it Uses 3 pins clock, data, strobe. IT can accely use a bit stream as long as it fits in the 25ms or what ever delay you use in vixen. So it can do this 00000001000000100000000000001 rather than just 8 bits.

http://en.wikipedia.org/wiki/Data_strobe_encoding
 
I was looking at some of the other threads here too after posting that, and saw it mentioned the chips were becoming hard to find.
Maybe there's a better option? (I started looking at Grinch because of: 1 the "Less costly" part :) and 2: It connects to a parallel port ... #2 here is really a needed thing, #1 lower cost/easier to build is good LOL)
Tonight I was looking around more here and found some documentation on Grinch, it uses pins 1,2,14 for data/control ... I'm going to have to back through my old info/documentation to see if those are some of the standard 8 data pins (if not it won't work)


I'm actually using my own lights-control program, not Vixen...
That clock/data/strobe thing looks a bit confusing LOL thats gonna take some reading/thinking to figure out exactly what they're doing, how I'd need to reprogram/change things to make it work
This would be one part of the data-file (parts in red) .. (the blue is my comments here & couldn't actually be in the datafile)

~Chase the pattern name - could be anything. "~" states that its the beginning of a pattern
r09 how many times to repeat
t00600 timing (delay - from 000001 to 65535)
00000001 actual lights control data
00000010
00000100
00001000
00010000
00100000
01000000
10000000
end end of pattern
To keep things simple/short I'm showing for 1 port/8 channels (for all 24 it'd have numbers that looked like "00000000_00000000_00000000")

The above would do a simple chase across 8 channels, starting with #1, repeat 9 times before going on to the next pattern, and have a delay-time of 600ms between each step (larger numbers would mean longer delay/slower animation (and while you could technically put in a '1' the computer really can't handle anything less than 100) ).
With the Grinch / bitstream, does it just 'know' that after every 64 clock cycles to re-start at port 1?
I don't fully get: http://www.doityourselfchristmas.com/wiki/index.php?title=The_GRINCH_Controller#Simplified_Theory
But I believe it means I'd have to output 3 signals:
1 for clock - which would change between '1' and '0' each time you send a bit
1 for data - would either be a '1' or '0' depending on whether the channel is on or off
1 for strobe - would change only after all 64 control bits have been output?
(so basically 65 clock-pulses/bits for each 1 animation step?)
 
So thinking about it - if my thought is right on that 65 clock-pulses/bits for each 1 animation mentioned above ^^
Then if my delay (time) was set to 100(ms) then that would be 6.5 seconds?? :shock:

---
But anyway, went back & looked through things, I can only output to pins 2,3,4,5,6,7,8,9 ... Grinch needs 1,2,14 (so wouldn't work anyway LOL) Oh well it was still worth it to me to take the time look into this.
 
The chips are still available from King: http://www.kingelectronics.com/index.asp?sid=AB67164DE14B45FCA2F29BD9F7F23715&action=product&id=166

I just ordered a pile of them for less than a buck each for an experiment.

Anyway, those chips are shift registers that drive LED's, and that LED can be a discrete LED or the LED in an optoisolator of some kind - triac for AC, mosfet or bipolar for DC.

The Grinch uses three pins off the parallel port, which Vixen remaps to be:

Clock
Data
Strobe

The grinch has 24 on/off outputs, so to turn on channels # 4, 5, 12, 13, 14, 15, 20 at the same time, that would be transmitted serially in sync with the clock line like so:

000110000001111000010000

Once that 24 bit binary number is loaded, the strobe pin bounces and the latch register chips then replace whatever value they are showing on their outputs with the value that's just been sent, then latches that until the strobe line is bounced to indicate a new value is ready to be loaded.

The basic Olsen595 driver is used, and it's a 1 bit driver since it's a serial data send type thing.

There's another driver in Vixen that's 8 bits parallel, allowing you to drive eight grinches in parallel, each with their own data pin but sharing the clock and strobe pins. You'll have to buffer the clock and strobe pins so they can drive all eight Grinches.

Since I couldn't find the schematic for the Grinch, I reverse engineered one off the PCB images on the wiki, and it's a beautifully simple design for basic on/off lighting control.

I'm going to break the design apart and put one chip in a tube with 16 LED's and two 8-resistor SIP networks and create grinch-driven snowfall tubes using the vixen driver.
 
frederic said:
The Grinch uses three pins off the parallel port, which Vixen remaps to be:
Clock
Data
Strobe
The grinch has 24 on/off outputs, so to turn on channels # 4, 5, 12, 13, 14, 15, 20 at the same time, that would be transmitted serially in sync with the clock line like so:

000110000001111000010000
I thought the grinch was 64 on/off outputs (channels) not 24 ? ... so I'd have to send a 64-bit binary number serially (1-bit at a time) on the 'data' line?
Then after that, flip the 'strobe' line (so 65 clock cycles total)
So i believe and if my thinking & calculations were right 65 * 100 would be 6500ms (or 6.5 seconds)
Maybe I'm missing something along the way though...

Also the wiki shows grinch using pins:
Clock - Pin 1
Data - Pin 2
Strobe - Pin 14
Since I'm using my own lights control software, I can't access Pin 1 or 14. Could it instead be done as:
Clock - Pin 2
Data - Pin 3
Strobe - Pin 4


------
I found a link for the schematic (maybe it was in the wiki section) but it doesn't work...I'll have to see if I can find that somewhere too.

My lights software is currently designed to run simple parallel port controllers (which in reality are nothing more than 8 SSR's). I'd obviously require some re-programming on my end to make a Grinch-compatible version...that part I can do, it'll just take time LOL. (This ofcourse assuming I can use different pins than what the original plans call for). Other than that the only issue I see is that 6.5 seconds thing I mentioned (It'd be just far too slow for me)

Would it be possible to drive an optoisolator _and_ a LED on the low-volt side of each channel? (I have plenty of spare LEDs and would love to have indicators on the board)
I would assume that I can (at least hopefully) find all of the parts on eBay :) rather than ordering from multiple places
 
I thought the grinch was 64 on/off outputs (channels) not 24 ? ... so I'd have to send a 64-bit binary number serially (1-bit at a time) on the 'data' line?

Yes, it's a 64 on/off controller. I have "renard" on the brain at the moment so that's where I got 24. My apologies.

Then after that, flip the 'strobe' line (so 65 clock cycles total)

Give this link a healthy read, it's about the Olsen595 controller which the Grinch was modeled after in functionality but with a lower chip count/overall cost:

http://computerchristmas.com/?link=how_to&HowToId=25

And if you want to better understand how shift registers work, this PDF will be very helpful. It has timing diagrams as well as a basic explanation of the concept (serial to parallel conversion)

If you look at this PDF, particularly #5 "Functional Diagram" section, you'll see how the chip works visually, which is probably better than how I explained it, particularly the part that latches the output:

http://www.nxp.com/documents/data_sheet/74HC_HCT595.pdf

And here is the pdf for the chip the grinch uses, also with lots of timing diagrams:

http://attiny.com/software/MBI5027.pdf

A load cycle would be 64 bits of data, plus two bits I believe (reset and latch), with the clock pin pulsing continuously.

The Olsen595 uses 74HCT595 chips which can be clocked into the 100 MHZ range.

The Grinch uses MBI5026 / 5027 chips which can go to 25 Mhz range.

A PC parallel port can change states at or about 2.7 Mhz if I remember correctly - minus bus contention issues, processor speed, overhead for the OS of choice, and so on.

A parallel port data pin can change states in as little 5 microseconds, *if* the hardware is directly accessed by the software. Windows of course prevents that so we're talking 17-25 microseconds for a hardware parallel port or 2-4 ms for a USB-attached parallel port.

So with a hardware parallel port and say, 20 microseconds average per bit, you can in theory refresh all 64 channels of grinch in (64 + 2) * 20 microseconds, or 1320 microseconds.

That's 0.00132 seconds. That's calculated, not necessarily "actual". Needless to say, you can refresh a grinch or Olsen595 many, many times per second. I have no idea how fast Vixen refreshes either controller. I would guess, possibly incorrectly, it's not that fast.


Clock - Pin 1
Data - Pin 2
Strobe - Pin 14
Since I'm using my own lights control software, I can't access Pin 1 or 14. Could it instead be done as:
Clock - Pin 2
Data - Pin 3
Strobe - Pin 4

I'm not sure why you cannot access those pins, but if that's the case you can write your code to put strobe and clock on other pins and wire them up accordingly.

Would it be possible to drive an optoisolator _and_ a LED on the low-volt side of each channel? (I have plenty of spare LEDs and would love to have indicators on the board)

An optoisolator has an LED inside, so putting a tiny one in series with that one will cause the LED to light. You'll have to change the resistor value slightly in order to compensate for the extra voltage drop of the additional LED but that's just math and there are plenty calculators on the web that makes that easy work.

Indicators on the board are useful for testing, but once you install the grinch into your display those LED's aren't going to be very useful and one of the thoughts behind the Grinch was to eliminate as much "fluff" in the design as possible to make it as low-cost as possible.

One thing you may consider doing is create a few test plugs - an RJ45 with four LED's with appropriately sized resistors in series with the LED's, like so:

1 5V
2 (-) LED (+) -- resistor -- (pin 1)
3
4 (-) LED (+) -- resistor -- (pin 1)
5
6 (-) LED (+) -- resistor -- (pin 1)
7 ground
8 (-) LED (+) -- resistor -- (pin 1)

The above ascii art representation of a RJ45 plug would illuminate one to four LED's if the grinch turned on that particular channel.

I would assume that I can (at least hopefully) find all of the parts on eBay :) rather than ordering from multiple places

I didn't find the macroblock shift register chips on ebay, but I haven't looked in a couple of weeks. I ordered mine from Kings Electronics http://www.kingelectronics.com/index.asp?sid=AB67164DE14B45FCA2F29BD9F7F23715&action=product&id=166
 
As a side note... I joined this forum recently (http://doityourselfchristmas.com/forums/showthread.php?24131-Potential-Grinch-based-Project) and the kind gents who welcomed me and replied gave me a lot of food for thought - because like you, I was looking for a very low cost-per-port while imagining my lawn covered in blinking lights. After doing the math, I found that going Renard was not that more in cost per port than the Grinch with slews of SSR's around the lawn. And, the Renard supports dimming. And Renards come in a variety of flavors too - some do AC, some do LED's, some drive whatever kind of SSR you devise.

As I thought about this obsessively over the past several weeks, I can see a real application in my future display for both Renard and Grinch - for most things I would want to dim, but there are some things that only need to be full-on or full-off - things like an FM radio station sign, or relays, actuators, and SSR's controlling motors. Or things that immensely dislike dimming such as purchased "snowfall" icicles, or anything that's driven by an included transformer.

Also, as you probably know already, extending the parallel port from inside the house to the lawn requires extra work - for a parallel port cable cannot be very long - and thus there's going to be a ton of wire going through the basement window between the Grinch and the SSR's. For me, that's a huge turn-off. The display design I had come up with before I found this forum would have required 16 cat5 cables per grinch, three grinches required for my initial design. That's 48 cat5 cables that would have to exit my basement in some way or another - that means the basement window would have to be "very" open and thus very cold, or, I'd have to bore a really big hole in the house to run a large diameter conduit.

I'm not trying to change your mind or anything, just sharing some of the thought processes I went through over the past few weeks. And I'm still thinking about it. This "hobby" is very overwhelming as there are so many choices, options, ideas that others have shared, and it's just endless, really.

And a lot of fun :)

With all the post-holiday sales and dumpster driving I've done in the past week, I could easily fill about 85-90 channels no problem, PLUS all the stuff I've accumulated over the past 15 years for my static display. Heck, as of yesterday, I have nine reindeer, one of which is getting a red illuminated nose for next year which might very well be it's own channel.

You know how this goes... more and more ha ha ha.
 
Last edited:
frederic said:
Give this link a healthy read
Big Thanks for all the links...I've downloaded the various PDF's for later viewing

frederic said:
A parallel port data pin can change states in as little 5 microseconds, *if* the hardware is directly accessed by the software. Windows of course prevents that so we're talking 17-25 microseconds for a hardware parallel port or 2-4 ms for a USB-attached parallel port.
I was messing around with/testing things with my lights control program...looks like the lowest delay I can go before there's issues is 56 milliseconds (I believe thats something like 17.8 bits/updates per second) ... so better than the 100 I originally mentioned which came from previous some years test (but I did give the PC a small processor upgrade this year too)
I have no idea if its _actually_ going at that speed, but it definitely made the lights blink fast LOL

frederic said:
I'm not sure why you cannot access those pins, but if that's the case you can write your code to put strobe and clock on other pins and wire them up accordingly.
In the 1st link you gave, I saw that pins 1 & 14 use a different hex address than the rest...so it *might* be do-able, I'm going to have to go look at the documentation for the output "driver" I used (inpout16.dll)
Link already may have proved usefull just for that bit of info..I'll have to do some tests.


frederic said:
An optoisolator has an LED inside, so putting a tiny one in series with that one will cause the LED to light.
I was thinking more-so putting it in parallel - basically so each output pin on the IC would go to 2-resistors (1 for the opto, 1 for the LED) whether it can handle that much current or not I don't know...but I assume that info is probably in the PDF
I have a few hundred spare LEDs & resistors, so the cost wouldn't be an issue (plus it would 'look cool' even though I'm the only one who'd see it...)
(your idea of doing test plugs is a good one, that'd be easy to do)


frederic said:
As a side note... I joined this forum recently (http://doityourselfchristmas.com/forums/showthread.php?24131-Potential-Grinch-based-Project) and the kind gents who welcomed me and replied gave me a lot of food for thought - because like you, I was looking for a very low cost-per-port while imagining my lawn covered in blinking lights. After doing the math, I found that going Renard was not that more in cost per port than the Grinch with slews of SSR's around the lawn. And, the Renard supports dimming.
Having seen it in action, dimming would be cool (and awesome for RGB). The costs on those Renard's seem awfully high (but I haven't yet priced out what the total for all parts of a Grinch would be either)

In my current case things work out good. "lights computer" is in the basement, "Grinch" would be in the shed (approx 16-foot cable), then SSR's would be placed as needed.
Right now personally couldn't see myself using more than "half a grinch" (32ch) LOL, but like you said: You know how this goes..
If I was ever to do RGB (would love to) I'd need more channels, plus something other than a Grinch. (At this point I think that far exceeds both my budget and programming skills)
 
Last edited:
Still thinking about this...
Whats the diff between IC's MBI5026GN & MBI5027GN ? (the 1st one I can get on ebay...along with nearly all the other parts)

Looking at things, total cost (including parts for SSRs, but not including outlets/cables/etc) is still something a bit over $100 .. which is .eek. :shock: making it look allot less tempting to build one of these since its a big expense... ...Which means I'll just have to stick with my existing 24ch using 3 printerports.
------
Before I absolutely give up I'll have to think some more on it. But also wondering if there are any other DIY plans for a controller that connects to parallel port (my only option) and does dimming, but is maybe something like 32ch ?
 
@Ronp:
Thanks.. wow allot of different controllers/options there
Yeah I know that parallel port stuff is all really dated

@P. Short:
It relates back to my lights control program (originally designed to do a single parallel port (8 channels..which at the time is all I'd ever need), I eventually added 2 more ports (for another 16ch) & did some fairly minor coding changes to make it work). I'm pretty sure I could make a Grinch work (a fair bit of code changes LOL)...or other types of controllers as long as I knew what exactly 'data' to send the thing.
Biggest reason for 'parallel port only' is the driver used for VB programs to "talk" to ports - something called INPOUT16.DLL

@Warlock:
Believe it or not I actually do still use that ancient museum piece LOL to control my lights. (my lights control program will only work in win 3.1x )
(If I got a more recent ver of VB I could port it over to a 32bit program & use win 98 .. then it'd use the INPOUT32.DLL driver (which like the '16' ver was meant for parallel ports))
 
It looks like with the schematic/parts-list I could fairly easily put one of those together. Are the SSR's for this the same thing like you'd use for a basic parallel controller (opto-isolator, a couple resistors & a Triac)? .. I might even be able to use my old 'boxes' if thats the case

Something to think about, and someone can correct me if i'm wrong, but I think the majority of the controllers on here (and SSRez) will SINK current on a pin to turn on a channel. The example code you wrote for your chaser { 00000001, 00000010, ...} gave me the impression that your output pins are SOURCING current to turn on a channel in your design? This might mean that your controller choice may not work with your "SSR 'boxes'".

I am using a homegrown controller that originally sourced (a 1 meant "on") pins to activate a given channel. I had to redesign it to be compatible with the SSRez. Just something to keep in mind.
 
@umodjm: You are correct in that my current SSR's are designed for a Sourcing setup ... and it looks like allot of the stuff here looks like it is indeed for Sinking.
When I originally posted the question I wasn't sure on that, so yeah my existing SSR boxes wouldn't work on a Grinch/etc.

Where I listed 00000001/00000010/etc thats simply the on/off data the computer would read. If a different controller needed to actually "see" a '0' for on / '1' for off I'd just write it into my control program to invert the values being read - so when I go type in all those 1's & 0's to flash the lights I'd still know that a '1' was on :)

------
I've also been trying to find if INPOUT32.DLL can be used to send data to a serial port (that might give more options)... All I've seen is its a maybe.
 
Back
Top