Page 1 of 1

Analog Out enabled on bit 0 value for Analog2

Posted: Mon 28. Sep 2015, 05:43
by Foxtrott
Hi,

I would like to trigger two LED's connected to the AOut 0 and AOut1 depending on the
state of the same 1-bit signal on CAN.

I'm only able to turn either ON when the bit value is = "1" but not when it's "0".

Would it be possible to create the following logic in PCAN MicroMod for Analog2?

Bit Value AOut1 AOut2
0 ON OFF
1 OFF ON

If this can only be done using custom firmware could someone please provide and example code on how
this could be done?

Thanks

Re: Analog Out enabled on bit 0 value for Analog2

Posted: Mon 28. Sep 2015, 15:31
by G.Bohlen
Hello,

please look at the attached example:
AOUT 0 is controlled via CAN-ID 0x100, Byte0, Bit 0. Scale is set to -4000, Offset is set to 4000.
If the bit is 0:
(0* -4000) + 4000 = 4000 (led goes on)

if the bit is 1:
(1* -4000) + 4000=0 (led goes off)

AOUT 1 is also controlled via CAN-ID 0x100, Byte0, Bit 0. Scale is set to 4000, Offset is set to 0.
If bit is 0:
(0* 4000) + 0 = 0 (led goes off)

If bit is 1
(1* 4000) + 0 = 4000 (led goes on)

A value of 4000 represents ~9.75V.

Regards,
Gunnar Bohlen

Re: Analog Out enabled on bit 0 value for Analog2

Posted: Mon 5. Oct 2015, 08:58
by Foxtrott
Hi Gunnar,

Thank you very much for the input. This was exactly what I wanted to have.

Is there by any chance also the possibility of having the output run with a frequency
output or is this only available on other hardware models?

Thanks

Re: Analog Out enabled on bit 0 value for Analog2

Posted: Mon 5. Oct 2015, 13:55
by M.Maidhof
Hello,

the Analog2 MicroMod don“t have frequency outputs. Only the Digital1/2 and Mix MicroMod modules offers frequency outputs. Please see product info on our website for more details.

regards

Michael