06-20-2014 01:07 PM
I need to simulate a bydirectional (+/- Vdc) engine speed encoder pulse train input into an ECU. Does anyone have example code or can recomend proper hardware to use for this type of application.
06-20-2014 01:17 PM
Do you have a specification of what the signal needs to look like? There are multipe encoder types, but generally a coutner output can make an encoder. If you need to respond to an ECU stimulous quickly then you will need an FPGA, or possibly real-time hardware.
I've seen in the past where an ECU would believe it should be in some kind of condition and if sensors stated that it wasn't, the ECU would shutdown. If your ECU is the same then you will have a very difficult time convincing it that there is no issue.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
06-20-2014 01:34 PM
My idea was to use cRIO with DIO card to output a pulse train to a circuit that would take 5 vTTL and convert it to +/- 10 Vdc pulse. What I don't know is if NI already has hardware that can accomplish the same thing.
06-20-2014 01:53 PM
@ChadAnd wrote:
My idea was to use cRIO with DIO card to output a pulse train to a circuit that would take 5 vTTL and convert it to +/- 10 Vdc pulse. What I don't know is if NI already has hardware that can accomplish the same thing.
I think you are on the right track. You wouldn't believe the number of forum members that try to do something like what you asked with a printer port, or the cheapest DO hardware they have on hand.
In the past I've used an opamp circuit to take a digital and turn it into VBat. Remember that your DO will have very low current drive capabilities and you need to drive something else, to bring the voltage up. NI won't have this type of hardware. Analog Devices, and Omega sell some stuff that may work if you don't want to make your own circuit.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
06-20-2014 03:45 PM
i agree you are on the right track. the cRIO with digital can simulate an encoder with a velocity value. the velocity can change instantly when coded in FPGA mode.
the result will be a 0-5 or 0-24 style signal. if this needs to be converted to +-10V, external hardware would be required.
if your encoder signal is slow, you could use something like the NI 9263 analog output module to produce quadrature output as well. just beware of the slew rates (100 kHz module). how many edges per second do you need to simulate?