Jump to content

hburd

Members
  • Content Count

    18
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by hburd


  1. Hello Jim,

     

    It used to be that older versions of VIPM could connect to the newest versions of LABVIEW. 

    Is there any particular reason why this changed?  This issue seems to have happened from the VIPM 2018 Version because it was a major update. Is this going to happen for all versions of VIPMs in the future?

    The problem is that I have a licence for VIPM 2018, and now I can't use VIPM 2018  with LABVIEW 2019 (I won't be able to generate VIPC files without the licence).

    thanks

     

    Helcio

    • Like 1
    • Upvote 1

  2. Hello all,

     

    Finally there are better clues of how to use JKI state machine for exchanging data with others jki state machines (Thanks Justin!): Here is the link of the template library for that Justin Goeres created for his presentation at CLA summit 2011 Template jki intercommunication with other jki state machines

     

    post-2790-0-34717300-1306614560_thumb.png

     

    However, as Justin Goeres mentioned in the CLA summit 2011 (VI SHOTS PODCAST), there is a problem when using his template if you need the timeout case in the event structure. Attached there is an example in labview 2010 (a little modification of what Justin Goeres' example) to try to make this problem clearer: Whenever a registered event is fired, Labview will reset the timeout event structure in the event structure where this event is registered if there is 1 or more registered events with no case to handle them in this event structure. There is a huge discussion if this is a bug or not (Lava link). But, as you can see in the template, Justin registers an entire cluster of user events all at once independently of them having a case to handle them in the event structure. This makes very practical and more maintainable code, but at the cost of having huge headache if you need the timeout case in the event structure. Hopefully NI will come up with some solution for this in the next version of labview.

     

    I am still trying to figure out how to use it. I am really very, very tired of using queues to make the JKIs state machines to intercommunicate. Please, if someone has an example of use for it, please share it.

     

    thanks

     

    Helcio

     

     

     

     

    Hi Helcio,

     

    Sorry for the delay. NIWeek is a hectic time :)

     

    We have just posted our presentation slides in a new blog post: NIWeek 2010 Recap and Technical Session Slides.

     

    Thanks,

    Event Structure Timeout Bug 2.vi

    • Upvote 1

  3. Hi Jim,

     

    This is very odd. Still, after disconecting all the type defs it continues not working. I expect not to get error 91 reading the xml file with easy xml read.

    Thanks

     

    Helcio

    post-2790-1285772916_thumb.png

     

    EASY_XML_does_not_work_NI_XML_works22.vi

    Hi Helcio,

     

    I tried your example (after disconnecting the typedefs) and it seems to work just fine.

     

    What is not working? What do you see, as compared to what you expected to see?

     

    Thanks,

     

    -Jim


  4. Hi,

     

    Easy XML has broken my heart, it refuses to parse complexer structures.

    Please, give a look in this dirty example:EASY_XML_does_not_work_NI_XML_works.vi

     

    As you can verufy, easy xml writes an XML file but is unable to parse the data.

     

    Unfortunately I will have to live with the NI XML Vis, since there is no other option for this case.

     

    Please, let me know if anybody find a solution for this.

     

    thanks

     

    Helcio


  5. Hello Jim,

     

    Yes it would be really great if Justin could put the POWER SUPPLY code available for download. It is not enough to read Justin's presentation to understand this design pattern. Please, share this example.

     

    thanks

     

    Helcio

     

     

    Howdy guys!

     

    I have a few quick questions that relate to Justin's presentation and the JKI State Machine in general (and one question on internet cats too):

     

    1. Would it be possible to post the Power Supply Project Library example from NI Week? It appears in the slides but I don't recall discussion on it (in depth anyway). I am interested in seeing the implementation of Public vs Private events for a Module. Maybe it is possible to discuss the Private Event use cases here? - Does the Module act as the sole subscriber to a separate set of events, if so why not just queue them etc...?

     

    2. How do you like to send messages to your JKI State Machine? Obviously via events, but do you send individual events per message (like the events sent out from the State Machine) or do you just like to send in State strings (both use cases wrapped in subVIs to form a Public API for protection of course) as per the example in this thread. I have used both in the past, but am wondering if you have any pros/cons to share of one over the other?

     

    Much appreciated, look forward to your reply.

     

    Regards

     

    -Jon


  6. Hi Jim,

     

    I read the GOOP chapter indicated by you in the book. Also I am trying to learn more OOP, but still I continue without a clue in how to implement the JKI producer loop to share data with other JKI producer consumer loops. Could you post an example of that when you have time?

     

    Also, there will be a presentation section in the NIWEEK 2010 dedicated to the comparison between the JKI state machine and the other types of state machine. Could you post the presentation on this website for those, like me, who won't attend the NIWEEK?

     

    Thanks

     

    Helcio

     

     

     

    Hi Helcio,

     

    You're very welcome. Yes, I think you're probably at a point where you would benefit from learning about OOP. A great place to start, even if I do say so myself, is the appendix on OOP techniques in LabVIEW for Everyone. I talk about the history of by reference OOP implementations in LabVIEW and talk a little bit about the principles of OOP.

     

    Cheers!


  7. Hi Jim,

     

    Thanks for the information. I guess I really have to start learning GOOP, it will be very useful.

     

    thanks again!

     

     

    Helcio

     

    Hi Helcio,

     

    The way that we tend to do this at JKI is to use GOOP-style objects/components. A component has a process that is a JKI state machine. Each component has a method called "Get Public Events" that outputs a cluster of its public events. Components can then easily register for the events of other components inside their own JKI State Machine process loops.

     

    We also usually have a "Get Private Events" method that can be used by the component for sending messages/commands into its own process. This gets very tricky in a hurry, especially when you need to get data back from the process after it is finished handling the message/command. This can be achieved in a variety of ways.

     

    Does that sort of answer your question?

     

    Thanks,


  8. Hi again,

     

    The jki state machine producer consumer loop is working nicely using it in the way described by you. I was wondering what would be the best way to use the jki state machine producer consumer loop to intercommunicate with other jki state machines Producer consumer loops (JKI SM PC loop) in the same project, but not in the same vi.

     

    For example, suppose I have 1 JKI SM PC loop that continuously acquire data from the serial port. What would be the best way to transfer the data from this jki sm pc loop to another jki sm pc loop in another vi which will plot the serial data acquired? Or alternatively, in the example given above (jki_producer_consumer_loop_with_events_and_data_lv_2009.zip), what if another vi sends a command for this jki state machine PC loop execute the command for displaying a certain message on the screen?

     

    Would the answer be to use notifiers? I mean, if I put a "wait on notification" in the timeout event structure of the jki sm pc loop that will execute the commands and a "send notofication" in the jki state machine PC loop that sends the commands?

     

    thanks

     

    Helcio


  9. Hi Jim,

     

    I tried to do what you have said for the producer consumer loop with events and data for the JKI state machine. I created a cluster with user all user events I needed and worked from there. I am sending the project file attached for labview version 2009 (could not be saved in Labview version 8.2 because it generates an error). I hope that this is what you had in mind.

     

    However, I have no clue how I could use LVOOP to avoid having to convert variant, therefore you will see conversions all over the code:

    post-2790-1256858174.jpg

    post-2790-1256858474_thumb.jpg

     

     

     

    regards

     

    Helcio

     

    Hi Helcio,

     

    First, I would create separate user events for every event type. If you need to pass generic data with specific events, consider using LVOOP objects as the generic data, with child classes for decoding specific data. You can group your user events in a cluster, before passing them into the Register for Events. I'll try to post an example of this, soon.

     

    Second, I like to make my event data a cluster and pass all relevant data in the cluster. Examples of this extra data are timestamp, additional data, etc. I tend not to pass "generic" string/variant data that has to be decoded programmatically. Again, I typically user LVOOP objects when I have to pass generic data.

     

    -Jim

    jki_producer_consumer_loop_with_events_and_data_lv_2009.zip


  10. Hi!

     

    Thanks for sharing the example for the JKI state machine applied to the producer consumer loop, it was very useful.

     

    However, I am not sure what is the best way to share data between the producer-consumer loop. I can send the Message from the producer to the consumer, but, for example, if I need to send together with the Message another data, for example, a Boolean (to be processed in the consumer loop), what is the best way to do it? Should I use a variant (cluster of string-message and Boolean-data) as the user event data type in the producer loop, or there is a better way?

     

     

    thanks

     

    Helcio

×
×
  • Create New...

Important Information

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