GARTHWILSON wrote:
There are times in embedded control however when you simply must know and control the amount of time a piece of code takes. No choice. If you know your compiler well enough to know that, you might as well write in assembly, unless the compiler can tell you for sure how many clock cycles it will take, or you want to look at the compiler's output.
I agree on that. Processing deadlines cannot be met with consistency if the programmer has no direct control over the instructions used to produce the desired result. Subtle timing issues about which the compiler might not know can only be resolved to their best-case outcome by a skilled assembly language programmer who is cognizant of the number of clock cycles required to complete each instruction. This is why a few device drivers for MC68K and x86 MPUs are written in assembly language, not C.
Quote:
We use relays in our equipment for lower distortion in situations where it has to pass a signal in the normally closed state if it loses power. I've had other situations in test equipment where solid-state relays couldn't cut it, for various reasons of distortion, controlling voltages far outside the power supply rails, etc..
Despite all of the advances in solid state switching technology, relays and contactors continue to be the preferred choice when guaranteed action under all foreseeable conditions is demanded. As I earlier noted, this is especially the case in railway signalling, where a failure that results in a
CLEAR or
APPROACH signal display when it should be
STOP can set the stage for a disastrous wreck.