Digital Output Condition

Discuss issues and ideas you have to configuring displays with PowerVision
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Digital Output Condition

Post by Rivlin » Thu Oct 17, 2013 2:06 am

Hello

We are trying to use a button to drive the engine on PV750. There is a fire event for key down that should operate a digital output (for the starter 24V). Key up should stop the digital output (0 volt). We would like to use a condition for the output: if The engine is not driven so we want to enable the ingnition (output). The state of the condition is given through canbus. Variable "J1939.Engine.Engine Speed".
Unfortunately, the output does not change according to the engine state: our syntax in the state machine for condition to transition is “IF("J1939.Engine.Engine Speed" = 0)”
We look forward for help.
Thanks
John.
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Digital Output Condition

Post by ksaenz » Fri Oct 18, 2013 2:24 pm

Hello John,

If that is an event condition or a calculation event condition the if() is not necessary, the comparison alone will return true or false ( 1 or 0 ).

Code: Select all

"J1939.Engine.Engine Speed" = 0
If you do want to use the if() function it works like in Excel, where the first expression is the evaluation, the second expression is the result if true, and the third expression is the result is false.

Code: Select all

if( "J1939.Engine.Engine Speed" = 0, 1, 0 )
Regards,
ksaenz
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output Condition

Post by Rivlin » Sun Oct 20, 2013 6:01 am

Hello

I understand that the syntax was good, so I am asking again and attach the file of our configuration:
I am trying to use a button to drive the engine with PV750. There is a fire event for key down that should operate a digital output (for the starter 24V). Key up should stop the digital output (0 volt to starter). We would like to use a condition for the output: if The engine is not driven so we want to enable the ingnition (output). The state of the condition is given through canbus. Variable "J1939.Engine.Engine Speed".
Unfortunately, the output does not change according to the engine state: our syntax in the state machine for the condition to transition is “IF("J1939.Engine.Engine Speed" = 0)”
Key up always work no matter what is the condition of "J1939.Engine.Engine Speed".
I attached my configuration.
Programming item is "Start-Stop EngineControl" and the state machine is "Start Ignition"
We look forward for help.
Thanks
John.
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Digital Output Condition

Post by ksaenz » Mon Oct 21, 2013 8:21 am

If you tried to attach a file with a .murphyConfig extension the board's system rejected it. There were problems with incomplete downloads before so now we recommed attaching .zip files which are easier to check for completeness.

Seems that the problem wasn't the expression but the event that is happening every time even if the condition is false.
On key down are you firing the event or the event condition?
If you fire the event directly the condition will be ignored and the transition will be triggered.
If you fire the event condition the experssion will be evaluated and if it is true the transition will be triggered.

I attached an example of what shows this.

Regards,
ksaenz
Attachments
Event condition on key down - 2320006.zip
Created with PVCS 2.3.20006
(605.64 KiB) Downloaded 30 times
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output Condition

Post by Rivlin » Tue Oct 22, 2013 5:06 am

Thank you very much for your help!!
Now it's work fine.
Jon
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output

Post by Rivlin » Tue Oct 22, 2013 8:36 am

Hello ksaenz

Please I have another question:
When we operate digital output, is it possible to short to ground (instaed of having 24V?)
Regards,
Jon
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output Condition

Post by Rivlin » Thu Nov 28, 2013 1:11 am

Hello ksaenz

Please can I have an example for using a timer?
Thanks in advance

Jon
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Digital Output Condition

Post by ksaenz » Mon Dec 02, 2013 8:06 am

Here is an example for using a timer.

The new variable and state machine can be found in the "Timer" folder.

Pressing key 1 causes a transition from initial state to wait state.

On entering wait state the new timer is started.

When the timer expires it triggers the transition back to initial state.

On exiting wait state the new variable is incremented.

Regards,
ksaenz
Attachments
Timer example.zip
Created with PVCS 2.3.20006
(115.07 KiB) Downloaded 28 times
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output Condition

Post by Rivlin » Thu Dec 12, 2013 7:57 am

Hello ksaenz

When I tried to download the example, I got the message “ Selected configuration version is newer than the application version”. What should I do?

Thanks

Jon
Josh.b@ST
Posts: 18
Joined: Tue Dec 06, 2011 10:00 am

Re: Digital Output Condition

Post by Josh.b@ST » Thu Dec 12, 2013 8:02 am

Rivlin,

From personal experiance, i would say you need to update your PVCS tool.

Might be worth waiting for a Murphy employee to confirm though.

Josh
Rivlin
Posts: 10
Joined: Tue Jul 09, 2013 11:35 pm

Re: Digital Output Condition

Post by Rivlin » Thu Dec 12, 2013 9:47 am

Thanks...
I will ask a Murphy employee
Rivlin
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Digital Output Condition

Post by ksaenz » Fri Dec 13, 2013 7:45 am

Hi Rivlin,

That message does mean that you need a newer version of PowerVision Configuration Studio to open the configuration.

The posted example configuration was created using PVCS 2.3.20006 which is the latest released version.

You can download PVCS 2.3.20006 here:
viewtopic.php?f=3&t=759

It is important to upgrade to 2.3.2xxxx and you learn more about it here:
viewtopic.php?f=3&t=757

Regards,
ksaenz
ergun
Posts: 2
Joined: Tue May 03, 2011 7:43 am

Re: Digital Output Condition

Post by ergun » Mon Dec 23, 2013 2:03 am

Hello,

When we operate digital output, is it possible to short to ground (instaed of having 24V?)! İ can see that the variable İO.DigitalOut is changing the state(0/1) but nothing happens on the hardware output. İt doesn't matter if İ connect to ground or to power supply using a pullup. What am İ doing wrong?

BR
Serdar