Jump to content

stefanusandika

Members
  • Posts

    9
  • Joined

  • Last visited

Posts posted by stefanusandika

  1. 14 hours ago, ShaunR said:

    OK.

    So you have a number of processes that handle different IO devices/hardware/things that sit in the "Analog" directory. Most of these (I only looked at a couple) seem to be self contained applications in their own right with things like TDMS logging of data and in-line analysis. By "Applications" I don't mean executables, by the way, just that they can exist standalone.

    These applications share their data via some Functional Global Variables (FGV_Sensors, FGV_Can et. al.) which are  used to collate and store the data for reporting and stuff.  These are effectively the" Internal Process" you show in your images that your were talking about creating. Well. You already have them - sort of :P There were also some global variables in the "Globals" directory but these seemed to be concerned with UI state and list management so I didn't look too closely..

    So the question is. Are you looking to bolt on a TCPIP interface on the existing software; changing as little as possible then walk away to do more interesting stuff. Or are you looking to refactor completely for reasons like  future-proofing, identifying reuse, enlightenment, and other noble sacrifices of your time - and while you are at it, put a TCPIP interface on it?

    Or,put another way How bad do you think the current (working) code is and whats wrong with it? ;) 

    Hi @ShaunR !!

    Thanks for the reply.

    My initial tought about creating this was because there are so many hardware which grows so fast in the current time. There are some kind of 30 computers with this program running locally. Once there is a new hardware, I have to maintain 30 computers one by one, and in the future, we are planning to increase the use of this system in a new computer (also locally). So with the abstraction layer, I can easily maintain more, with less effort.

    The TCP/IP is one of the option I found out earlier. The other way are still in a try. Since abstraction layer is between the main.vi and the hardware VI, my idea was to implement the connection via localhost from hardware VI to the abstraction layer. This require a transfering program like TCP/IP, notifier, queue, etc. In the future, I hope that the abstraction layer can actually work as a windows service, which continuously monitor the hardware and sending the data, while main.vi receive a continuous real-time Data.

    Regards,

    Stefan

  2. 18 hours ago, smarlow said:

    @stefanusandika I have attached a simple example of a multiple queue program architecture.  The Main.vi creates three named queues.  There are three copies of a reentrant subvi that generate three sine waves 45 degrees out of phase to simulate your "internal process" subVI's.   The subVI enqueues a value from the sinewave very 100 ms. The Main vi reads these three queues and graphs the values.  Notice I set the wait period to 200 ms on the dequeue function calls.  This is longer than the 100 ms between enqueue operations in the subVI's.  

    Queue.llb

    Thanks for the reply @smarlow !!!

    Can you probably attached the lower version? My labview is 13.0.1f2 (32 bit) so I can't opened it. Thank you so much!

  3. Hi everyone,

    I hope you guys have a good weekend!!

    @smarlow : Thanks for your reply. There is no particular reason actually, I was trying to find the best way for the abstraction layer and TCP was the first article came up to me. I never work with LabVIEW before, therefore I took it as an option. Back to the problem, I will take a look on Notifier, however, in my case, main.vi are suppose to read the real-time (means there will be multiple data) only when the mian.vi is needed. My uderstanding on your writing is that Notifier only able to read single data (the last data from measurement). Am I correct? Do you have any example on your related work with this kind of problem? Thanks!

    @ShaunR : Thanks for the reply. I will read your suggestion further.

    I also attached the project below. The main.vi (the main program) is located under programm, the analog is analog values which are connected directly to the hardware, and the server is the initial idea for the abstraction layer.

    Once again, thanks for your reply. This is very helpful and very good for a begineer like me!!:D

    CTS Project.rar

  4. @ShaunR : Hi again Shaun, thanks for your advice. I was just thinking that it would make it easier with the program as a windows services. Most of the guy in the production areas never work with LabVIEW, so the windows service could be a pretty handy solution. However, you are right that I should be giving more attention on the program, the windows server can be created later. ;)

  5. @Bryan : At most time the computer is always ON, however, the "safely aborted" would be one of the consideration. It's kinda confusing on how to create a generalized program to monitor different VI, not necessarily the windows service itself. However, a windows service could be a very helpful system to use.

    @JamesMc86 : I'm currently reading about this. Do you have any example with you about this NSSM? Thanks

  6. Thanks for the reply ShaunR and Bryan,

    @ShaunR : These 15 VI are seperated each other and each access the single hardware. Currently there are no connection between, except with the main VI. The main Vi actually only call the 15 VI one by one, and each VI will be excecuted under main program, and the result will be displayed after (using TDMS to display the result in excel file). I presume the name of the program is FireDaemon, is it correct? Most of the site I read before shows that they use FireDaemon for windows service.

    In addition, I develop the system (using HAL) because the lower level VI like this 15 VI are always increasing all the time, so it's kinda hard to maintain the system (the system are spread all over the production area for testing purposes). With more and more Hardware, it would be easier if I have some kind of a system between both main.vi and Hardware VI.

    @Bryan : Halo, I never actually heard about that one, I will take a look on it. Is it also develop using dll or Labview as well? Thx.

    Gruß,

    Stefan

  7. Hello everyone,

    I'm really new to LabVIEW and have been working on a machine testing project. I had experience before with C++ programming using Qt Nokia.

    The machines are tested using NI hardware, connected via USB to the computer, all connection are in a local connection. There are currently 15 VI, each communicate to a single hardware. The main test program, which call the lower level VI (15 VI) based on a script. I would like to create a windows service, which could monitor these modules continuously (the program start when the computer start, and continuously monitor these 15 VI), and only send the data when the main VI ask for the value (the value suppose to be a real time value). I attached the block diagram.

    I've tried to learn how to use STM and TCP/IP multiple connection, but I'm open to any advice and suggestion to build this project.

    Thank you,

    Stefan

    Future system, using abstraction layer (windows service).PNG

    Current system.PNG

×
×
  • Create New...

Important Information

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