JKI Discussion Forums
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

JKI Beginner hoping to learn

#1
User is offline   raul.ionel 

  • Group: Members
  • Posts: 3
  • Joined: 30-January 11
Hello,

I am a new user of Labview (2009) and implicitly of the JKI SM. I hope my question will be understood.

I have developed a JKI SM based application which continuously reads data from a Labview simulated device (I created the Acquire case under “New Cathegory”) and displays it in a Chart. This state is triggered by a new button (Start Acquisition) placed in the Event structure, just like in the JKI SM presentation movie.

In the Acquire state, by using a Select fed from another Front Panel button (Stop Acquisition) I can either go back to Idle (and Wait, Exit or restart the Acquire state) or continue executing the Acquire state.

My problem is as follows. The order of my execution would be: Start Acquisition and display data. If I want I could return to Idle and wait, or keep on gathering data. However, if by mistake, during the acquisition state I press the Exit button found in JKI SM by default, the vi keeps on executing the Acquire state, displays data but all buttons on the front panel are “blocked”. If I push any of them nothing happens. Is there a way to solve this?

I think the SM continuously executes the Acquire state (as it should) but due to a change in the state of the Exit button (which triggers the Idle State -> Macro:Exit) the front panel buttons do not respond to commands.

Does my explanations make sense? Is there a way to solve this?
0 kudos

#2
User is offline   Jim C 

  • Group: Members
  • Posts: 23
  • Joined: 01-November 08
  • Gender:Male
  • Location:North Carolina, USA, Earth
  • Interests:LabVIEW

View Postraul.ionel, on 30 January 2011 - 08:53 PM, said:

I think the SM continuously executes the Acquire state (as it should) but due to a change in the state of the Exit button (which triggers the Idle State -> Macro:Exit) the front panel buttons do not respond to commands.

You need to have your SM loop through the Idle state in order to respond to FP events. Something like: Start Acquisition, Display Data, Idle...
1 kudos

#3
User is offline   raul.ionel 

  • Group: Members
  • Posts: 3
  • Joined: 30-January 11
Hello,

I've managed to solve the problem by using Property Nodes-> Disable for the buttons. For example, when I am in the Acquire State, I Disable buttons which are not linked with this state. Then I can execute the state and as I exit the state, I use the same property node to re-enable all previously disabled buttons.

I do not know if the idea is the best solution, but it does the job.

Jim C., thank you for the answer. I will try to do that and see if it works.

Thank you and if there are any other suggestions please let me know.
0 kudos

#4
User is offline   Michael Aivaliotis 

  • Group: JKI Team
  • Posts: 327
  • Joined: 15-March 06
  • Gender:Male

View Postraul.ionel, on 31 January 2011 - 06:23 PM, said:

Hello,

I've managed to solve the problem by using Property Nodes-> Disable for the buttons. For example, when I am in the Acquire State, I Disable buttons which are not linked with this state. Then I can execute the state and as I exit the state, I use the same property node to re-enable all previously disabled buttons.

I do not know if the idea is the best solution, but it does the job.

Jim C., thank you for the answer. I will try to do that and see if it works.

Thank you and if there are any other suggestions please let me know.

Yes. This is the quickest way to solve this problem. You can either disable all front panel controls or display a modal dialog. Acquisition takes time and you're pretty much locked-in until it completes.

If you must have control of the front panel while the acquisition is taking place, you could place your acquisition code in a parallel loop to the main state machine. Then send messages (via notifier or user event) to that code from the main loop.

Hope this helps.
Michael Aivaliotis - VIPM Product Manager

VIPM Idea Exchange <<-- Post your VIPM Feature Requests Here
VIPM Online Documentation
JKI Product Support <<-- For urgent requests, submit a ticket
1 kudos

#5
User is offline   raul.ionel 

  • Group: Members
  • Posts: 3
  • Joined: 30-January 11

View PostMichael Aivaliotis, on 01 February 2011 - 06:47 PM, said:

Yes. This is the quickest way to solve this problem. You can either disable all front panel controls or display a modal dialog. Acquisition takes time and you're pretty much locked-in until it completes.

If you must have control of the front panel while the acquisition is taking place, you could place your acquisition code in a parallel loop to the main state machine. Then send messages (via notifier or user event) to that code from the main loop.

Hope this helps.



Thank you for your answer and have a nice day.
0 kudos

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic