Jump to content

state machines with very many states


Recommended Posts

so I put a VI Snippet.

Just out of interest - the VI snippet does not include the Tagged Test VI.vi - which is the VI being statically referenced.

Do people think it should or would be a good idea if it did?

Edited by jgcode
Link to comment

It's perfect, I love it, thanks;

But I like duplicate case becase some wire can be wired automaticly, So I update a version (only alte a piece of code) that has "Duplicate Case Here" shortcut menu,^_^

(In original code, the copy case function is here ,but why has no shorcut menu?

Why I can't upoad my code?

Edited by keiranwei
Link to comment

Just out of interest - the VI snippet does not include the Tagged Test VI.vi - which is the VI being statically referenced.

Do people think it should or would be a good idea if it did?

I don't think it should be added. (I made this snippet just because I didn't have the CCT installed on my portable computer.)

Let's say you want to create a snippet of a JKI state machine (by the way, I tried and it works), would you expect all the VI's it contains to be included in the PNG? I think it could get real huge and a distribution package is probably a good idea!

Link to comment

In original code, the copy case function is here ,but why has no shorcut menu?

I haven't written it into the menu, but you can copy a case using drag & drop. I'll add it if there's enough interest, but I think it's faster using the mouse.

Jim

Link to comment

  • When you duplicate a state, you could pre-populate the new name with the old state name (or ,may be even better, use the prefix such as if the state is "Macro: Initialize" the new state pre-populate name is "Macro:")

The latest version does this. Thanks for the idea.

new features I'd like to see:

Rearrange Cases >> Alphabetically: I'd love to have a context menu item (in the tree) for "Rearrange Cases >> Alphabetically" (or similar). Note that this should ideally preserve the separators and groupings as are standard in the JKI State Machine.

This is in the new version, too.

Thanks,

Jim

Link to comment

I just noticed that if I drag/drop to reorder a section header the entire section follows it! I'm better than I thought - coding features before having the idea. :blink: I'll spend some time figuring out why this works tomorrow...

Edit - the Tree Control does this, not my program. It turns out that I'm only as good as I thought (or, perhaps, not even).

Edited by jcarmody
Link to comment

Please add download for LV 8.2 Version also :thumbup1:

I don't know what I did, but the 8.2 version isn't working. This is where the VI is broken:

post-7534-125034724221_thumb.jpg

The VI is still reentrant if I just remove this element, but the Tree Control menu has gone away. I have some work to do, sorry.

Any ideas?

Link to comment
  • 2 months later...

New Feature Request:

* I think the "Insert case here" should duplicate a separator case (a case named "---------- UI ----------" for example) so all the necessary wire are already connected (error, application data, queue, ...). Alternatively, create a new command called "Duplicate case here" that does what I explain above.

* The caseselect windows title should have the VI name in it so it is easy to know which one I am looking at when I have more than one case select editor opened. I actually think that nothing else beside the VI name is needed.

PJM

Link to comment

New Feature Request:

* I think the "Insert case here" should duplicate a separator case (a case named "---------- UI ----------" for example) so all the necessary wire are already connected (error, application data, queue, ...). Alternatively, create a new command called "Duplicate case here" that does what I explain above.

That's a good idea, but I think everyone should use linked tunnels.  That won't work for 8.2, though, so I'll do it.  The 8.6 version allows you to ctrl-drag-and-drop/copy cases in the tree.

* The caseselect windows title should have the VI name in it so it is easy to know which one I am looking at when I have more than one case select editor opened. I actually think that nothing else beside the VI name is needed.

I can't recall if I implemented it in 8.2, but 8.6 hides the CaseSelect window unless the source VI is active.  I'll do it because it seems like a natural behavior.

The support discussion is over here.  Did you look at my last post?  I had a  question I need help with.

Link to comment
  • 1 month later...

New Feature Request:

It will be nice if we can have a search state Control on the top. It could be a combo box where user will type a search string and the combo box will populate all the relevant States which contain that search string. It could be such a way that as when the user types the closest match case could be automatically shown to the user... this will be really useful when there are many states

Rajkumar

  • Like 1
Link to comment

New Feature Request:

It will be nice if we can have a search state Control on the top. [...]

It should be easy enough to implement; I've added it to my list.

How many states do you have that you even thought of this?  Do you use the JKI State Machine or state headers?  The tree will separate into sections if your states have headers like "---------- Section ----------".  You can collapse/expand the states under these headers in the CaseSelect window.  This makes it easier to find the state you need.

Regards,

Jim

Link to comment

How many states do you have that you even thought of this?  Do you use the JKI State Machine or state headers?  The tree will separate into sections if your states have headers like "---------- Section ----------".  You can collapse/expand the states under these headers in the CaseSelect window.  This makes it easier to find the state you need.

Regards,

Jim

Typically while debugging, we will be looking to someones code. We will not be really familiar with their naming convention of the State and also the way they organize the states. It will be time consuming and painful to find the states in their state machine. I always felt if there were search in the case selection it would be really useful for quickly navigating the cases. I had to debug very large state machine which had more than >30 cases.

Link to comment

Typically while debugging, we will be looking to someones code. We will not be really familiar with their naming convention of the State and also the way they organize the states. It will be time consuming and painful to find the states in their state machine. I always felt if there were search in the case selection it would be really useful for quickly navigating the cases. I had to debug very large state machine which had more than >30 cases.

Now I understand.  Stay tuned...

Link to comment
  • 2 weeks later...

Typically while debugging, we will be looking to someones code. We will not be really familiar with their naming convention of the State and also the way they organize the states. It will be time consuming and painful to find the states in their state machine. I always felt if there were search in the case selection it would be really useful for quickly navigating the cases. I had to debug very large state machine which had more than >30 cases.

Would it work for your purposes to have it search for states that begin with, rather than contain, the string being typed?  I've added this functionality, but haven't made it search inside state names.

Lemmeno.

Jim

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.