Renard Firmware: Difference between revisions

From doityourselfchristmas.com
Jump to navigation Jump to search
No edit summary
No edit summary
Line 13: Line 13:
'''Operation with 50 Hz power'''
'''Operation with 50 Hz power'''


The Renard firmware is designed to sense the power line frequency and change how it works according to the line frequency.  In a 60 Hz locale the duration of each (non-PWM) pulse to the SSR is about 30 μS, and the pulses are placed about 30μS earlier in the AC cycle for each higher dimmer value.  For 50 Hz locales the width of each pulse is 40 μS (approx), and they are placed on multiples of 40 μS across the AC waveform.  The PWM versions operate in a similar manner, with the pulse widths being a multiple of 30 μS and 40 μS (roughly) for 60 and 50 Hz locales, respectively.
The Renard firmware is designed to sense the power line frequency and change how it works according to the line frequency.  In a 60 Hz locale the duration of each (non-PWM) pulse to the SSR is about 30 μS, and the pulses are placed about 30 μS earlier in the AC cycle for each higher dimmer value.  For 50 Hz locales the width of each pulse is 40 μS (approx), and they are placed on multiples of 40 μS across the AC waveform.  The PWM versions operate in a similar manner, with the pulse widths being a multiple of 30 μS and 40 μS (roughly) for 60 and 50 Hz locales, respectively.


Testing has taken place in both environments.  
Testing has taken place in both environments.  

Revision as of 17:54, 16 August 2007

There are two versions of the firmware available for use in slightly different circumstances. They will both work on all of the Renard boards (except the Ren-C board, which has its own firmware). They all use version 1 of the Renard protocol, and operate at 57600 baud.

The first (regular) version of the firmware causes a narrow output pulse (30 μS, or so) to turn on the SSRs. This results in the lowest PCB current requirements, because the waveform driving each SSR has a 1:256 duty cycle. The drawbacks to this version is that it will not properly control any channel status LEDs (present only on the Renard64 board), and may cause some issues when driving LED strings (e.g. they may possibly not turn on at the upper 25% of the brightness range).

The second (PWM) version of the firmware sends a variable-width output pulse to turn on the SSRs (the output turns on at a variable time in the AC power cycle, and stays on until the end of the cycle). This presents a PWM signal to any attached channel status LEDs, causing them to have a variable brightness that somewhat corresponds to the brightness of lamps attached to the SSRs. It will also be better at driving LED strings on the output of the SSR (because the PIC drives the SSRs throughout the cycle, rather than relying on the current through the opto-isolator to latch the opto).

Non-PWM Firmware

PWM Firmware

There are later, Beta-test versions of the firmware available over at the forum.

Operation with 50 Hz power

The Renard firmware is designed to sense the power line frequency and change how it works according to the line frequency. In a 60 Hz locale the duration of each (non-PWM) pulse to the SSR is about 30 μS, and the pulses are placed about 30 μS earlier in the AC cycle for each higher dimmer value. For 50 Hz locales the width of each pulse is 40 μS (approx), and they are placed on multiples of 40 μS across the AC waveform. The PWM versions operate in a similar manner, with the pulse widths being a multiple of 30 μS and 40 μS (roughly) for 60 and 50 Hz locales, respectively.

Testing has taken place in both environments.

Diagnostic Firmware

There is also a special firmware available to help in diagnosing hardware problems. This firmware uses the output channel signals to provide indications of which features are working. The safest way to use this firmware is to temporarily replace the SSRs with LEDs (and current limit resistors) between the output pin of the PIC and +5V on the board. Also note that this firmware does not re-transmit the serial data, so the 'downstream' PICs won't see any serial data.

The function of the output LEDs/lamps is as follows:

Channel 1 - blinks on and off as a heartbeat (if you see blinking, the PIC has power, clock, and is basically working ok).
Channel 4 - blinks on and off if the PIC is seeing a more or less proper Zero-crossing signal
Channel 5 - blinks as the PIC receives good serial data (no framing error, no overrun errors).
Channel 6 - blinks if the PIC receives bytes on the serial line with framing errors (usually wrong baudrate or inverted data).
Channel 7 - blinks if the PIC has overrun error on the serial line (no known causes for this, other than possibly a bad PIC).