Ren4Flood: Difference between revisions

From doityourselfchristmas.com
Jump to navigation Jump to search
Line 115: Line 115:


----
----
--[[User:Budude|Budude]] 03:08, 4 June 2010 (UTC)





Revision as of 23:32, 1 August 2011

Ren4Flood Construction Manual

== THIS IS A WORK IN PROGRESS - NOT FINAL!!! ==

What is the Ren4Flood?

The Ren4Flood is a four channel controller primarily aimed at controlling an RGB+W LED flood such as the MightyMini, Rainbow Flood (RGB only) or the DIYC Flood. It uses the existing Renard architecture and code which has been modified to only consume four channels versus the normal eight that a Renard uses per PIC. The logic/control/communication portion of the circuit comes straight from the RenardSS series of controllers so much of the credit goes to Wayne James and of course Phil Short for their contributions. The output section is taken from the Ren48LSD but reduced to only four channels. One minor difference on the RS-485 interface is that jumpers have been added to bypass the input directly to the output creating a non-regenerated "THRU" port instead of the more common output port on the RenSS series. This allows you to use static node addressing without affecting other nodes further up/down the line.

The other significant difference with the Ren4Flood is that it employs two input trigger ports. While this is not completely defined at the moment, the idea is of at least two different scenarios. The first allowing the installation of a switch to be mounted to the flood enclosure and simply turning on all of the LEDs to create a bright flood to be used during setup or off-season. The other scenario is using a trigger for security reasons. The input would be connected to some type of N/O switches and closing the switch would trigger the board to perform some type of light effect to scare off and/or alert you to this. Additional code could be used to monitor the input for data and if after a particular time period passes with no traffic (say 15 minutes), a light pattern would start for a set length of time to create simple mood/background lighting after the show completes.

How does the Ren4Flood work?

As mentioned before, the Ren4Flood uses the same architecture for the logic portions of the board from the RenardSS series of boards. Sequence information is passed from a PC running Vixen or other sequencing program via an RS-232 or RS-485/DMX interface. The ST485 chips receive this information and turn into standard TTL logic levels that the PIC can understand. The PIC reads in the data and if it determines that the information corresponds to itself, it updates the dimming levels of all 4 channels. It removes this information from the stream and feeds the rest out to the other ST485 chip which translates it to RS-485 levels for the next controller in the line. It is important to realize that the information is removed from the stream and that the resultant leftover stream will have all of the data offset by the 4 channels of information used by the Ren4Flood. For example, if you have two Ren4Flood, on Vixen you would configure a single Renard/DMX plug-in with 8 channels. The first Ren4Flood consumes the first 4 channels of information leaving only 4 channels on it's outputs. The second Ren4Flood will see this incoming data as controller #1 again and assume the data is for it. This is very much different than standard hard/soft-coded DMX or LOR devices that use a set address yet still pass on the entire stream to the next controller on the line. There are advantages and disadvantages to either approach - but you should be aware of this when combining normal DMX devices before/after a Ren4Flood (or any Renard controller running DMX code).

The Ren4Flood has a jumper to bypass this however and can pass the data straight from the input to the output plug. This means you will need to set the hardware address by programming the PIC with different addresses on each Ren4Flood controller.

The PICs receive the data on pin 5 and after consuming their 4 channels of data, forward the rest out of pin 6 of the PIC which in turn goes to the next controller if you have one attached as mentioned above.

The board requires a 12-24vdc supply which is converted to +5v for the logic portion of the controller but is also fed directly out to the outputs via the transistors.

The Ren4Flood uses sourced outputs and not sinked outputs like the RenardSS controllers. Why is this? Because the PIC needs to turn on a transistor and to do this, it supplies 5v on it's output which turns on the transistor (via a resistor to limit the current) which allows current to flow from the collector to the emitter of the transistor. The emitter is directly connected to ground so basically, the transistor sinks the current from the LEDs (or whatever you have attached to the output) to ground. The positive voltage from the DC power supply connects directly to the device you have attached and this completes the circuit.

Revision History

The v1c version is currently the only version of the Ren4Flood in production.

Ren4Flood (v1c) Parts

In addition to the PCB, you will need the following components:

NOTE - THIS BOM IS NOT CORRECT FOR THE REN4FLOOD YET - COMING SOON!

Mouser BOM
Mouser PNDescriptionQty
579-PIC16F688-I/PMicrocontrollers (MCU) 7KB 256 RAM 12 I/O1
571-1-390261-3IC & Component Sockets 14P ECONOMY TIN1
511-ST485BNBuffers & Line Drivers Hi-Spd Lo Pwr Trans2
571-1-390261-2IC & Component Sockets 8P ECONOMY TIN2
520-TCH1843-XECS-2100AX-18.432MHZ1
863-MPS2222AGBipolar Transistors 600mA 75V NPN4
78-1N5239BZener Diodes 9.1 Volt 0.5 Watt1
78-1N5229BZener Diodes 4.3 Volt 0.5 Watt1
863-1N5819GSchottky (Diodes & Rectifiers) 1A 40V1
532-577102B00Heatsinks TO-220 HORIZ/VERT SLIM CHANNEL STYLE1
604-WP7113IDStandard LED - Through Hole HI EFF RED DIFFUSED1
581-SA105E104MARMultilayer Ceramic Capacitors (MLCC) - Leaded 50volts 0.1uF 20% Z5U5
299-680-RCCarbon Film Resistors 680ohms1
299-120-RCCarbon Film Resistors 120ohms1
299-27K-RCCarbon Film Resistors 27Kohms2
299-1K-RCCarbon Film Resistors 1.0Kohms2
299-470-RCCarbon Film Resistors 470ohms4
299-10K-RCCarbon Film Resistors 10Kohms3
571-5556416-1Telecom & Ethernet Connectors 8 PCB TOP ENTRY2
571-7969492Terminal Blocks 5.08MM VERTICAL 2P wire protector1
571-5-146281-2Headers & Wire Housings 2 P HEADER GOLD 30u single row2
649-65474-002LFHeaders & Wire Housings SHUNT TIN3

Most of the components are not overly critical and some can be omitted in certain cases.

Building the Ren4Flood

(build steps/pictures coming soon)

Congratulations! That completes the construction of the Ren4Flood!

Initial Testing

The first thing you will want to do in any PCB construction project is to double check that you have all components installed and in the proper orientation. You will then want to inspect the board for any cold/bridged solder joints. Take your time with this step and go over each and every joint.

If you have any of the IC's installed - remove them now. Connect your power supply to the “DC IN” - it supplies power to controller portion of the board as well as the outputs. Turn on the supply and verify the power LED lights up. Verify you have 5v between pins 1 and 14 on the PIC socket as well as between pins 5 and 8 on the 485 chip sockets. Install all of the IC's if this passes.

Programming the PIC controllers

The Ren4Flood does not supply or use a ZeroCross input and therefore the Renard firmware (either Renard or DMX protocol) must be configured for DC/PWM operation. In addition, if you are using the DMX firmware, you may want to set the initial starting address but generally, this can be left at '1' for all PICs since the code is self-addressing. Also – like the ULN2803 drivers, the transistors invert the output so the firmware uses positive outputs.

Renard Protocol

Obtain the standard Renard firmware here:

Make the following changes:

#define PWM_build 1 – change from '0'
#define DC_build 1 – change from '0'
#define CTR_LOCKOUT 1 – change from '15'
;#define OUTPUT_NEGATIVE_TRUE – comment this out

Compile the code into hex code and program all six PICs with the same code. A standard version of the code with the settings above has been compiled already for you in the File Library available here.

Renard-DMX Protocol

Obtain the DMX Renard firmware from here:

#define DC_build 1 – change from '0'
#define CTR_LOCKOUT 0 – change from '40'
#define SINK_map 0x00 – change from '0xFF'

If you want to change the DMX starting address then alter it below – this is only required on the first PIC in the chain. If you have multiple Ren48LSD controllers, you can leave the second/subsequent PICs at '1' and they will automatically start off where the last PIC left off.

#define DMX_START_ADDRESS 1

Compile the code into hex code and program all six PICs with the same code (unless using a starting address). A standard version of the code with the settings above has been compiled already for you in the File Library available here.

Whichever firmware you choose, install the flashed PICs into the sockets noting the correct orientation. Also install the two 485 chips into their sockets noting the correct orientation. You are now ready for final testing.

Final Testing

I chose not to design in the diagnostic LEDs as those used on the RenSS series of controllers. The design is fairly straight-forward and as long as you are sure of the voltage inputs and the PICs are flashed properly you should not have any issues if your soldering is good.

If you are using RS232, you should install the shunt on the "RS232" header which shorts pin 5 of the RJ45-IN connector to ground for proper RS232 operation. The wiring is the same as the RenardSS series so you can follow the cabling requiremnents for that.

As the Renard controller variations do not use bussed DMX it's not critical to install the DMX termination shunt if you are only using Renard controllers. This is because they are using point-to-point configurations. However - if this particular controller is at the end of a line of other normal (bussed) DMX devices, you should install the shunt to properly terminate the bus.

Connect the Ren4Flood to your PC using standard wiring practices as on the Wiki for other Renard controllers. Develop a Vixen sequence to turn on/off each channel one-by-one using the appropriate Renard/DMX plug-in. With the sequence running, measure the output of each terminal block pair and ensure the voltage swings from 0 to DC IN.

FAQ

Schematic

Here is the schematic drawing for the Ren48LSD v3c in PDF format - (not available yet)