DQMH Consortium Toolkits Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Feature Request: add Get Queue Status method

Thanks Fab, your detailed answers are a big learning resource!

 

So, you would put both buffering and writing to file serially in the same event? Wouldn't it be better to separate (parallelize)  buffering and writing in two separate loops (e.g. buffering in the MHL and writing in the helper, or vice-versa)? I this way, the module could continue to buffer data while writing to disk, thereby reducing the event queue size. Obviously then I would need another queue (or a channel writer/reader) to send the buffered data from one loop to another.

0 Kudos
Message 11 of 14
(836 Views)

This feature that is being requested has significantly more applications than just logging.  In my use case, I want to poll an instrument as frequently as every second, however, the instrument takes about 2 seconds to scan.  I don't want to build up a queue of "scan"s so what I would like to do is only enqueue another "scan" command if the previous one has already disappeared by being dequeued.  At the moment I'm not concerned about gaps in "scans", I can deal with that.

 

It seems the best thing for me would be if the functionality to check queue status was native to DQMH, it seems a high value, low cost thing to add.

 

Since that isn't there, I ended up creating a VI that does what I need, belongs to the class, but is stored in one of our project folders.

0 Kudos
Message 12 of 14
(422 Views)

@carlos_camargo wrote:

This feature that is being requested has significantly more applications than just logging.  In my use case, I want to poll an instrument as frequently as every second, however, the instrument takes about 2 seconds to scan.  I don't want to build up a queue of "scan"s so what I would like to do is only enqueue another "scan" command if the previous one has already disappeared by being dequeued.  At the moment I'm not concerned about gaps in "scans", I can deal with that. Since that isn't there, I ended up creating a VI that does what I need, belongs to the class, but is stored in one of our project folders.


I'm curious - is reading from the instrument a synchronous process, i.e. do you know when the scan command returns?

 

And how (and where from) do you call or trigger the scan? Is it a request from outside the module? Or a message being enqueued from with the MHL or some other loop inside the module?




DSH Pragmatic Software Development Workshops (Fab, Steve, Brian and me)
Release Automation Tools for LabVIEW (CI/CD integration with LabVIEW)
HSE Discord Server (Discuss our free and commercial tools and services)
DQMH® (The Future of Team-Based LabVIEW Development)


0 Kudos
Message 13 of 14
(417 Views)

The instrument returns data and broadcasts it when it returns from a scan. 

I suppose my helper look could be set up to queue up another request when it receives a broadcast.🤔 

 

I call for a scan from a helper loop within the DQMH module's main.vi.

 

Thanks Joerg, your questions were very instructive.

 

P.S.  I think it would still be good to have the ability to check the queue's status and contents.

0 Kudos
Message 14 of 14
(396 Views)