02-29-2024 07:27 AM
wiebe@CARYA wrote:Grokking Simplicity: Taming complex software with functional thinking: Normand, Eric (Amazon) is about functional programming, but applies to any kind of programming
I've lost some text there.
The book explains very well how internal state and external resources effect complexity in both usage and testing. It has lots of exercises\examples to show this.
If I had to recommend only 2 books one programming, it would probably be Grokking Simplicity and Object-Oriented Analysis and Design with Applications - (Google Books).
02-29-2024 08:47 AM
@MogaRaghu wrote:
- On the SUB VIs - Is it OK to have one large SUB VI for all four stations and run four distinct State Machines in one common While Loop ( or ) have independent SUB VI for each station and call as required.
An additional issue that I didn't see explicitly mentioned is that if your four state machines are all running in the same loop then you'll always be running at the rate of what happens to be the slowest state machine at that time.
Even if everything is running as expected you could easily have 3 state machines ready to move onto the next state but they may have to wait for that last state machine to finish some long measurement or calculation. In an error state it could get much worse where 3 stations are paused because one station lost connection to some hardware and you're essentially waiting for it to time out.
02-29-2024 09:01 AM
I used to be a fan of Functional Globals but the thing with them is that they TOTALLY do not scale!
This application will never scale ! And even it does its going to be another contract.
Don't do Tolkien! "A single state machine to rule them all" is an architectural fiasco waiting. A state machine with 150 or so states?
Could you please elaborate ? Thanks
And I could see some responses that doubt my skill level in LV. Agreed I am not an expert or anywhere near that . A mechanical engineer by profession and embedded electronics and LV are my hobbies and must say that have been at it doing reasonably well going by the "no complaint " test rigs that have been running with my code over a decade plus. May not the most efficient code ( by the levels here ) but gets the job done as LV is very tolerant !! ( Thanks for that )
02-29-2024 09:05 AM
In this particular case safety is limited to test failure and possible retest. Even if all go wonky there are enough protection and safeguard that there is no danger to any human.
Choice of hardware is mostly decided by client preference of inventory control. They already have been running a similar machine for a long time with no issues.
thanks for the sugestion.
02-29-2024 10:44 AM
@MogaRaghu wrote:
In this particular case safety is limited to test failure and possible retest. Even if all go wonky there are enough protection and safeguard that there is no danger to any human.
It's not just safety, there can also be loss of time and data.
You can judge that best. and it seems you thought about it...
02-29-2024 03:27 PM
If you can afford it, I would suggest this is a great opportunity to hire a NI Alliance partner to at least consult with you, if not just completely code the software for you. At my last company we needed to completely re-factor our test sequencer which was running about 50 test stations. We hired consultants to do the job and my LabVIEW co-worker and I learned more about LabVIEW (all actor framework), test sequencers and SQL Server in 3 months than we EVER could have on our own. Plus, we had a reliable system we could trust from the start and a fall back of technical support if we got in over our heads. Caveat: It was NOT cheap (although a big part of the cost was that we also jumped to a NI Enterprise customer at the same time).
Yes, a lot of money, but I felt it was well spent. Just my too sense! 😉
02-29-2024 08:09 PM
@NIquist
Thanks so much for your response. I don't know which country you are from but here in India and my city Chennai the support from NI Alliance Partner is just limited to some very basic support and most times they quote from Forum posts. You get the idea. 😀
I know it sounds like complaining but that is the reality ( and if there does exists a good support for coding locally and that person sees this post he can contact me !!) To be honest the very reason I decided to jump into coding was because of this - my company core strength is in oil hydraulics and I can easily outsource software if only I had reliable teams. On test equipment's , unlike OE items, there is no big cost aspect to get concerned.
Tried a few times but the amount of documentation I needed to generate to explain my requirement was tiring. And the end result even more despairing. The programmers have an idea that there is no engineering outside of software !! And Industrial Hydraulics is a niche segment and has a steep learning curve.
Sorry for my rant 🙁
02-29-2024 08:26 PM - edited 02-29-2024 08:28 PM
@Jacobson
Good point on clubbing all four SM into one while loop.
Already had planned to test out all logic on one station and then reuse that for rest three stations. Sequence remains same but only hardware I/O references change - about 38 of them .
Maybe I will have enumerated list for such items and call the right one for the relevant station. Something like this and I can then reuse the same sequence for all stations.
02-29-2024 09:05 PM
@MogaRaghu wrote:
@Jacobson
Good point on clubbing all four SM into one while loop.
Already had planned to test out all logic on one station and then reuse that for rest three stations. Sequence remains same but only hardware I/O references change - about 38 of them .
Maybe I will have enumerated list for such items and call the right one for the relevant station. Something like this and I can then reuse the same sequence for all stations.
Using TestStand Semiconductor Module helps you to scale easily and not hard code your instrument references within your code.
This is typically used for massive multi-site parallel testing of semiconductor chips by writing a code to deal for one-site (one DUT) and easily scale it to work with N DUTs
03-02-2024 12:20 AM
Have put together a simple code to explain the concept that i want to use in this project. Just enter any command value and choose the Station and Parameter to see it being posted in the Out Cluster
The Sub Vi - AO_CMND_SWITCHER will be asynchronously called by four sub VIs. I am hence planning to set the Re-Entrancy to Pre-allocated Clone.
Any suggestions welcome !