Peter Todd wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > I'm writing a feasibility report for a project that would involve > placing hundreds, or even thousands, of little nodes consisting of a > really low end PIC, 12f or even 10f, and an PWM'd LED, in trees > outdoors. The project is fairly cost sensitive, given the scale, so I > was thinking of some sort of software one-wire bus implemented on cheap > CAT3. After spending a few hours thinking everything else through, er, I > mean as a responsible first step, I thought I'd try to figure out the > characteristics of my transmission line: > > Nodes: 100 > > [snip] > Yes, I know I'm going to run into lots of other problems... but that can > be saved for the post I nearly sent to piclist... :) > > - -- > http://petertodd.org > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.6 (GNU/Linux) > > iD8DBQFGeJuR3bMhDbI9xWQRAnY9AKCBez4Y6H6FD00ibz+qRcGloyRPrQCeJNyn > IZtKCSOCP0TjudniqSbhp+M= > =8Sdc > -----END PGP SIGNATURE----- > Hi Peter. I have just, as a birthday present to my daughter, completed building a puppet theater (or, would that be 'Theatre' Russel?). Think along the lines of a punch&judy style thing. Anyway, My mother decided it needed red velvet curtains, and then I decided it needed stage lights. Well, scope creep went from scope creep to explosion.... Anyway, I have completed my project, and it is based on 8 RGB LED's (that's 24 individual LED's). These LED's are mounted in the stage of the Theater, and illuminate the puppets, etc. *** Each LED is individually controllable using PWM. I based the control on the PIC18F4620. With 6 buttons to control the different lighting modes (strobe lights, rainbow colours, chasing lights, sound-sensitive, manual, off), and 4 knobs on A/D channels to control the R, G, B and Special Effects respectively, I am using 34 IO pins. This leaves the power pins, and some of the ICSP pins unmuxed. Anyway, without the knobs and buttons you could probably get 10 RGB LED's controlled by the 18F4620 (or 32 normal LEDs). You will struggle to get more LED's than that as well as keep pins available for comms to the master node, and power pins... (and have enough time in the interrupt routine to control the LED's). I chose the 4620 because it has the 8MHz internal OSC, with the 4xPLL option boosting it to 32MHz without a crystal or resonator (freeing up the pins...). At 32MHz I am able to get 256 levels of PWM sequences at about 61Hz refresh on the LED's. (I am using a 8 bit timer with 2x prescalar) This gives me 512 instructions to set up each cycle of PWM, and with each 1/256th of the cycle I have 512 instructions available to switch off the appropriate LED's. Because I am driving bright RGB LED's I have to handle more than 25mA and thus I am using FET's to control the LED's and the PIC's IO pins drive the FETs. Bottom line is that, if I were you, and based on my recent experience, I would consider setting up 30 LED's per mini node, and putting all the control mechanisms on that mini-node, then feeding out a whole bunch of wires which just have the LED attached to the ends (in a star topology). Then, have a separate power and control bus to a master node that can be your real expansion point.... Anyway, if you are interested I am happy to share all my work including Eagle PCB drawings and C18 code (with mostly assembler interrupt routine...). I was also thinking of your cost, and I figure with a trip to Active Surplus (you are in Toronto, right?), you could get that really cheep 'phone' wire that they have near the back (a single twisted pair) at a better rate than the $0.10/ft they advertise, and then you could probably save a bunch of money by having about 1 thirtieth of the PCB's but they would be more complex..... each LED would simply be a LED soldered to the end of a wire with some heat-shrink. All the resistors, regulators would be on the remote control board.... The PIC18F4620 will give you better options (EUART) for comms with a central controller than an 12F part, and there would be far fewer nodes to communicate with... sounds so much simpler. Rolf *** actually, I have 16 RGB LED's, but I have 8 shining up from the stage, and 8 shining down on to a white-board for cool effects.... There are 8 light "boxes" and the 2 RGB LEDs in each box are wired in series. Because the G and B LED's have high forward voltages (4.5V which in series is 9V, I am driving the LED's at 12V, but the PIC at 5V). -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist