Jump to content

ShaunR

Members
  • Posts

    4,905
  • Joined

  • Days Won

    299

Everything posted by ShaunR

  1. Ah. right. (Sorry Daklu). I'll go and fix that in a bit OK. Fixed. Don't have to register (I'm always logged in so didn't notice you had to).
  2. It looks on the surface like you have the LabVIEW equivalent of mixed metaphors. The general method for a singleton pattern is to check in and out rather than for loop memory and semaphores (which is a classic LabVIEW kind of thing you might do in an action engine, although all VIs by default are singletons so you wouldn't need the semaphore) This may help as may the singleton pattern example in the examples dir. You don't have to worry about "threads" or "thread safety" in labview. I think you mean "race free" singletons..
  3. Well. That's not obvious since I can't find out how much I'm using and the error message is "You can upload up to Uploading is not allowed of files (Max. single file size: 50MB)" It was fine before the downtime yesterday and I've just deleted 2 of my CR submissions (>1 MB) and it still won't work (the example is only 75KB). So I don't think that is the problem (unless you are just intimating that I have to pay to help someone-bleh).
  4. @Daklu. I downloaded the lapdog and it looks like I was mistaken as to what it was (my fault for jumping in-apologies). From this and previous conversations, I had somehow got into my head that it was a messaging system (kind of like the Actor Framework or Data Broadcasting Library). It looks, however, like it is a queue wrapper which is functionally identical to my queue.vi (but I don't bother with types). @ AlexA So I've taken the lapdog stuff, ignored all the types and written a cut-down version of my stringy messaging using the lapdog as the core rather than my queue.vi.(they are virtually interchangeable). The messaging itself is fairly topology agnostic (onion, chained, star etc) since it basically depends on how you put the strings together and how you disassemble them (just concatenate to onion route). I cobbled together an example in light of your requirements to so you could see how I would put Lapdog to use for message forwarding accross TCPIP. From this point, it becomes the programmers preference as to what to do next (I, for example have a COMMS.vi instead of TCPIP.vi which uses the transport.lvlib to give me TCPIP, UDP, Bluetooth and websockets and the UI would communicate with an additional layer rather than directly so that sequencing and application state can be accounted for). The routing, mechanism, however, is there in it's entirety (you will see that VI names are used to provide unique queue name/message routes). That's the easy stuff. The hard stuff is responses if they are required (for which I use events).. (Hmmm. For some reason I cannot upload the example-something to do with the downtime today? Here's a download link instead: Stringy Lapdog Example)
  5. Spotted this on UK TV. LabVIEW used for cat tracking (Horizon BBC)
  6. From Daklu? (pretty much my position on LVPOOP even though it's python). Only a quick hijack......apologies.
  7. The IP to string defaults to looking up the domain name (which the cRIO probably doesn't have). You are probably seeing the domain lookup timeout. Set the "dot notation" to true and it should be OK.
  8. +1 That's why I wrote transport.lvlib and dispatcher (which uses the former). I've never liked NSVs. Fine in theory (event driven) but too bloated and difficult to manage/maintain even if they did work properly all the time.
  9. Silly question that has to be asked. Have you checked the firewall?
  10. I think you'll find I didn't comment on your suggestion before at all. I just shut up because I was told to stop reading because it was POOP. They are talking about Onion and Chain Routing of messages. The former is (in your terminology) an envelope inside an envelope inside an envelope ...ad nauseum. The latter is an envelope with a friends address with a "please forward to this other friend ".....ad nauseum. I'm just suggesting they just send it directly to the recipient by using a dispatcher. I have no idea how it would be implemented or what your "envelopes" do. I'm sure Daklu would come up with an elegant solution given the description if it was viable. For me, it's just a case of using a keyword in a string and making sure something is listening for it but the principle is the same. Therefore it is Chain Routing with a fixed 2 level depth.
  11. Don't know much about this API so may be missing a fundamental implementation aspect here. But if you have a "RouteTo7813R message" (which you presumably you must have for a reciprocal receive case). Is there a reason you cannot have just one wrapper layer (lets call it "Router") and all it does is, well, route? The arguments could be Target, Sender and Payload Message.
  12. Rule 36 & 38 You have a timeout of 5000ms in two locations, so it's not definite that the open is failing from that. But if you follow rule #36 and #38, you will have a better idea what is happening and you can show the error with the Simple Error Handler at the end..
  13. 1) I am very smart for very short periods with very small pieces of code and have a FIFO memory retention(without google ). Therefore my LV utils toolkit is very smart and I just have to be clever enough on a daily basis to remember which part of the toolkit solved that problem last time. It's the difference between being smart and being experienced 2) I architect my code at a level well below my abilities since debugging is twice as hard as writing code and therefore I'm not competent enough to debug code written to my ability (to contextually quote Brian Kernighan). Oh. and a framework is an architecture without the important bits (quote: ShaunR)
  14. My definition of "Code Smell" is completely different to that in the article. To me it is a behaviour that indicates a particular bug or type of bug. They are already here if you are talking about pre-processor commands - Conditional Disable. But I feel your pain, not necessarily with FORTRAN, but certainly C where everyone has their own definition of INT and "macros" that can be considered cryptographically secure.
  15. Ditto what hooovahh said (for right click menu). If you just want to copy the text from one location to another, use the edit/cut/paste in the labview main menu which are mapped to Ctrl+C, Ctrl+V etc. It may seem a pain for things like a text control where you are used to windows copy and paste on a right click menu, but it makes more sense when you are copying entire arrays or clusters.
  16. Hi Ton As I understand it, 17025 (like the old ISO 9000) is really a quality documentation exercise. So as long long as you can "argue" the case with documentary evidence, I don't really see that you cannot be compliant. Of course, if you normally rely on proxy validation (our box is certified and within the certification date, therefore this measurement is certified) or you usually use an accepted standard procedure, then it is a lot more work as you have to detail the methods, quantify measurement errors and get them signed off by an accreditation authority. In your case, the key here is probably: Source (Section 7.2)
  17. That has been my experience with the entire Linux community. When you get the answer "install linux" in answer to any windows question - You just wonder what they do as a real job.
  18. 50 feet should be fine. The "rule of thumb" is Less than 100 feet is "usually" OK for most thermocouples. Ignoring interference, impedance matching and cold junction compensation, It basically boils down to the total loop resistance. The total loop resistance is a calculation based on the diameter and length of the thermocouple wires. Thermocouples usually have an impedance per foot/meter parameter and the thermocouple loop resistance should be less than about 50 ohms (don't forget 1 foot off a thermocouple spool is 2m of loop wire). You will notice in the NI-9211 spec there are compensation values for impedances greater than 50 ohms so it doesn't mean you cannot use greater, just that compensation must be applied. There is of course a maximum limit due to the sensitivity of the input circuitry, but you should be fine as long as you are not using wires the size of a gnats whisker. So which idiot didn't order RTD if the temp range is 0-60 degC?
  19. OK. Maybe you have taken a colour image, but you have taken a colour picture of a grey object against a grey background. The dominant colour will still be "GREY". A quick and dirty (although not foolproof) method is to just look at the mean of each colour component. A better but much more complicated method is to use K-means clustering. I don't know of any LabVIEW examples off-hand, but here is one you can translate from Python.
  20. Mid-life crisis?
  21. It was a joke. It is a grey-scale image, therefore it can only be grey
  22. Well. The dominant colour is grey
  23. When you query for the services (Bluetooth RFCOMM Service Discovery.vi) you need to have the "Serial Port Profile" returned as one of the services available and then select that service in your Index Array to get the Channel and UUID for the Bluetooth Open the Connection.vi. If it's not in the list, you may have to enable it in the phone settings (refer to the manual) or use a 3rd party driver on the phone to give it to you over bluetooth (some phones only have it for usb connections). Also, some Android phones have a bug where the profile isn't broadcast.
×
×
  • Create New...

Important Information

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