Jump to content

Mark Yedinak

Members
  • Posts

    429
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Mark Yedinak

  1. QUOTE (flarn2006 @ Apr 3 2009, 03:42 PM) The difference here is that NI is changing the data type, not you the user. They have knowledge about the type of data and at this point they do not expose that level of customization to the user.
  2. QUOTE (TG @ Apr 3 2009, 02:40 PM) Most definitely. There is even some old code that I thought was pretty good back when I wrote it and when I look at it now it makes me cringe.
  3. As far as I know you can't change the appearance of the wire type for anything other than a class.
  4. QUOTE (Lorenzo @ Apr 3 2009, 03:47 AM) Unfortunately the MIB document that you posted is not syntactically correct. It would not be able to be parsed correctly by any MIB compiler. With that said I can say that the base OID for your MIB objects will be 1.3.6.1.4.1.9999.x. I should also note that unless you are with the company Zerna, Koepper & Partner (Egbert Casper, cas&zkp.de) you should not be using an enterprise number of 9999. Enterprise numbers are registered with the IANA (Internet Assigned Numbers Authority). You can request an enterprise number here. Registering a number is free. If you are on an isolated network you will not encounter any problems but it is always best to play by the rules. Anyway, manually compiling your MIB document is not very easy and it appears that some of your definitions are incomplete. Therefore I cannot give you specific OID values for items in your MIB. From what I can see I assume they want the OID for the dcIdentManufacturer to be 1.3.6.1.4.1.9999.1.1.1.0. dcIdentModel would then be 1.3.6.1.4.1.9999.1.1.2.0 and so on. dcPowerSystemBusbarVoltage is most likely 1.3.6.1.4.1.9999.1.2.1.0. I would suggest that you look at the MIB Walk (SNMP MIB Walk.vi) example that I included in the library I posted. This will walk the complete MIB of an agent and it will list al avialable OIDs for that the agent. It may not return a value for every element in the mIB since it is legal for a element to be defined but the agent not contain it. Once you see the specific elements supported by the agent you can work with the other VIs in the library to set or get specific elements. The only VIs you will need to use directly from your code are SNMP QUOTE (Lorenzo @ Apr 3 2009, 03:47 AM) Hello, I would like communicate with a system in SNMPv1. I download the files "snmp communication.zip" in this topic. My knowleadges in the SNMP communication are very limited and I don't know how I can establish a communication with the system. I attached the MIB of my system. Someone could explain me how can I communicate with my system ? Could you give me an example ? Thanks for your answers. Unfortunately the MIB document that you posted is not syntactically correct. It would not be able to be parsed correctly by any MIB compiler. With that said I can say that the base OID for your MIB objects will be 1.3.6.1.4.1.9999.x. I should also note that unless you are with the company Zerna, Koepper & Partner (Egbert Casper, cas&zkp.de) you should not be using an enterprise number of 9999. Enterprise numbers are registered with the IANA (Internet Assigned Numbers Authority). You can request an enterprise number here. Registering a number is free. If you are on an isolated network you will not encounter any problems but it is always best to play by the rules. Anyway, manually compiling your MIB document is not very easy and it appears that some of your definitions are incomplete. Therefore I cannot give you specific OID values for items in your MIB. From what I can see I assume they want the OID for the dcIdentManufacturer to be 1.3.6.1.4.1.9999.1.1.1.0. dcIdentModel would then be 1.3.6.1.4.1.9999.1.1.2.0 and so on. dcPowerSystemBusbarVoltage is most likely 1.3.6.1.4.1.9999.1.2.1.0. I would suggest that you look at the MIB Walk (SNMP MIB Walk.vi) example that I included in the library I posted. This will walk the complete MIB of an agent and it will list al avialable OIDs for that the agent. It may not return a value for every element in the mIB since it is legal for a element to be defined but the agent not contain it. Once you see the specific elements supported by the agent you can work with the other VIs in the library to set or get specific elements. The only VIs you will need to use directly from your code are SNMP QUOTE (Lorenzo @ Apr 3 2009, 03:47 AM) Hello, I would like communicate with a system in SNMPv1. I download the files "snmp communication.zip" in this topic. My knowleadges in the SNMP communication are very limited and I don't know how I can establish a communication with the system. I attached the MIB of my system. Someone could explain me how can I communicate with my system ? Could you give me an example ? Thanks for your answers. Unfortunately the MIB document that you posted is not syntactically correct. It would not be able to be parsed correctly by any MIB compiler. With that said I can say that the base OID for your MIB objects will be 1.3.6.1.4.1.9999.x. I should also note that unless you are with the company Zerna, Koepper & Partner (Egbert Casper, cas&zkp.de) you should not be using an enterprise number of 9999. Enterprise numbers are registered with the IANA (Internet Assigned Numbers Authority). You can request an enterprise number http://pen.iana.org/pen/PenApplication.page' rel='nofollow' target="_blank">here. Registering a number is free. If you are on an isolated network you will not encounter any problems but it is always best to play by the rules. Anyway, manually compiling your MIB document is not very easy and it appears that some of your definitions are incomplete. Therefore I cannot give you specific OID values for items in your MIB. From what I can see I assume they want the OID for the dcIdentManufacturer to be 1.3.6.1.4.1.9999.1.1.1.0. dcIdentModel would then be 1.3.6.1.4.1.9999.1.1.2.0 and so on. dcPowerSystemBusbarVoltage is most likely 1.3.6.1.4.1.9999.1.2.1.0. I would suggest that you look at the MIB Walk (SNMP MIB Walk.vi) example that I included in the library I posted. This will walk the complete MIB of an agent and it will list al avialable OIDs for that the agent. It may not return a value for every element in the mIB since it is legal for a element to be defined but the agent not contain it. Once you see the specific elements supported by the agent you can work with the other VIs in the library to set or get specific elements. The only VIs you will need to use directly from your code are SNMP
  5. I think you need to post a few more details about what you are trying to do. Your question is too vague to answer at this point.
  6. QUOTE (Lorenzo @ Apr 3 2009, 03:47 AM) Unfortunately the MIB document that you posted is not syntactically correct. It would not be able to be parsed correctly by any MIB compiler. With that said I can say that the base OID for your MIB objects will be 1.3.6.1.4.1.9999.x. I should also note that unless you are with the company Zerna, Koepper & Partner (Egbert Casper, cas&zkp.de) you should not be using an enterprise number of 9999. Enterprise numbers are registered with the IANA (Internet Assigned Numbers Authority). You can request an enterprise number http://pen.iana.org/pen/PenApplication.page' rel='nofollow' target="_blank">here. Registering a number is free. If you are on an isolated network you will not encounter any problems but it is always best to play by the rules. Anyway, manually compiling your MIB document is not very easy and it appears that some of your definitions are incomplete. Therefore I cannot give you specific OID values for items in your MIB. From what I can see I assume they want the OID for the dcIdentManufacturer to be 1.3.6.1.4.1.9999.1.1.1.0. dcIdentModel would then be 1.3.6.1.4.1.9999.1.1.2.0 and so on. dcPowerSystemBusbarVoltage is most likely 1.3.6.1.4.1.9999.1.2.1.0. I would suggest that you look at the MIB Walk (SNMP MIB Walk.vi) example that I included in the library I posted. This will walk the complete MIB of an agent and it will list al avialable OIDs for that the agent. It may not return a value for every element in the mIB since it is legal for a element to be defined but the agent not contain it. Once you see the specific elements supported by the agent you can work with the other VIs in the library to set or get specific elements. The only VIs you will need to use directly from your code are SNMP Get Random Port.vi (it will use the first available local UDP port which minimizes conflicts on your local machine), to open the UDP port and them SNMP Close Port.vi to close it when you are finished. Then you can use Set SNMP Item(s).vi and Get SNMP Item(s).vi to set or get specific OIDs in your agent. You can also use the basic PDU primatives of SNMP Get Next.vi, SNMP Get Request.vi, SNMP Set Request.vi, SNMP Get Response.vi and if required SNMP Get Trap.vi. The remaining VIs in the library should not be called directly. If you have other questions once you look at this let me know.
  7. QUOTE (Cat @ Apr 3 2009, 12:11 PM) The beauty of a state machine is that it is flexible and can be easily modified such as adding new states or reordering things if necessary. It also allows you to jump to a specific state such as an error handler. A sequence frame, rather flat or stacked (and stacked is definitely the nastier of the two) will force the execution, all frames MUST and WILL be executed, and they are very difficult to add new frames if the need arises. I am in the same camp as Neville that I rarely use sequence frames and when I do they tend to be the single frame variety to force data flow. I used to do the same thing as you with the init, main and exit frame sequence structure and after a while found it was difficult to extend when required. Now I prefer to use state machines and of course putting more things into subVIs.
  8. QUOTE (Phillip Brooks @ Apr 3 2009, 10:45 AM) Can you please post a version saved for 8.5. We haven't updated yet to 8.6. I would appreciate taking a look at your X-Control. QUOTE (rolfk @ Apr 3 2009, 02:04 AM) Are you sure you have really enabled "Defer Front Panel Updates". 3.2 ms for an Add Item Tree element sounds fairly long although I don't have specific numbers. Or was this 3.2 ms with an already heavily populated tree? I do think the suggestion to built up an internal data structure first that represents your tree as an array of clusters and after that populate the tree from that is probably not a bad one. It also gives you better performance check abilities to see if the file enumerating or the tree population is really munching up the big part of your processing time. The other suggestion to only update the tree as it is getting needed (when a folder item is expanded) would be my first approach anyhow. No need to go through a lengthy recursive folder enumeration when the user newer will look at 99% of those items anyhow. Rolf Kalbermatter Yes, the FP updates are definitely defered and I have confirmed that the delay is isolated to the Add Item and Check Tag subVis. I did see better performance on smaller trees but it seems that once the tree gets fairly large the performance really drops off. I will need to experiment with a few of the suggestions provided here. I would like to see the tree control's performance improved and some additional features added. It would be nice if you could add multiple items to the tree at any location given a parent tag rather than only at the end of the tree. Thanks again for the suggestions.
  9. QUOTE (MJE @ Apr 2 2009, 10:00 PM) Yes I have run the profile tool as well as other timings and verified that the bottle neck is in the tree processing. Specifically the Add Item and Check Tag subVis. I have looked at the code for these subVIs and they do very little besides check the tree for the presence of a tag or add a single item. the Add Item was taking an average of 3.2 ms per call and it was getting called over 10000 times. as I said there are lots of files which comprise this test. I could possibly populate the tree dynamically as particular branches are opened. This could imporve the overall performance. I could also try the array method as well. Thanks for the suggestions and input. Designing the UI for presenting these tests is certainly challenging. As I mentioned this particular test consists of over 10000 data files. Presenting this to the user and allowing them to select and set of files for a single execution is a nontrivial problem.
  10. I am working on a test application that will literally have thousands of data files which comprise a test. The user would like to have the ability to select specific files to include in the test. The files will be stored on the hard drive in various folders. Obviously a tree control is the best choice for presenting the data files to the user and allowing them to select or deselect the desired folders/files to include in the test. The problem I am running into is adding the files to the tree control once they select a base path. At least the problem is that the current method is not very efficient. I have disabled front panel updates to help minimize the time however it is still taking considerable time to add all of the files to tree control. I am recursively traversing the directory structure and adding the sub-folders to the tree. The current method I am using is adding the files to the tree individually. This is incredibly slow and for the tree structure that I am working with (472 folders and 11000 files under the base directory) it is taking approximately 110 seconds to fill the tree. This is an unacceptably long time for the user. I do know that multiple items can be added to the tree at one time which significantly improves the performance however the problem with this approach is that I am limited to adding the files at the end of the tree only. As I traverse the directory structure I need to be able to insert the file list under a specific sub-folder name (which translate to a specific parent tag in the tree) and from what I can see I don't have this option. Does anyone have any suggestions on how to achieve a fast method for updating the tree efficiently?
  11. Are the server and client running on the same machine? Do you have access to a network sniffer like Wireshark to look at the network traffic? Also, 100 ms can be a bit short in terms of network timeouts depending on your network topology. In addition, your wait on listener will only wait for 100 ms and then stop listening. You should have your server (the listener) be always waiting for connections and service connection as they come in. How large is the data that you will be sending? If you are sending large amounts of data you will not be able to send it all in a single packet and depending on what else is happening on the PC it could delay the transmission of the entire data set with the 100 ms window that you have established. Though you are timing out on the intial two bytes of data. Would it be possible for you to post your code?
  12. QUOTE (rolfk @ Mar 29 2009, 02:31 AM) The LPR protocol as defined by RFC 1179 is one such protocol. According to the RFC the source port must be between port 721 and 731 inclusively. This particular aspect of the RFC is ignored by virtually every implementation I have seen and I have yet to find a LPR server that cares about the source port but it is in the RFC.
  13. This can't be answered without more information about what you will be using to actually read the voltage. If you are asking if you can use a serial port itself to read voltages the answer is no. If you are asking if you can use the serial port to get the reading from some other piece of equipment then the answer is it depends.
  14. What are you dissatisfied with? From what you describe you have a pretty decent architecture. About the only thing I would consider changing would be to make your queues network based which would give you more flexibility in deploying your individual control programs. This would require you to actually pass program data between applications as opposed to directly referencing them via functional globals or references. Beyond that I don't see where your design is necessarily falling short.
  15. QUOTE (MJE @ Mar 24 2009, 04:23 PM) Variants are simply a type agnostic way to pass data around. They are not a reference to the data. It is simply a large binary dump of the data that you need to indicate how it should be decoded. Think of a variant like the data portion of a TCP packet. To TCP it is simply data. It doesn't care or need to know what that data represents but it does pass all of the data. It is up to the receiver of the data to know how to interpret it. The same is true for variants. A variant is just a generic way to pass data.
  16. This is good information to know. I would ask though if you find yourself only peeking at a small part regularly and only accessing the large data occasionally wouldn't it improve the design to separate the elements and their storage to improve performance? I mean if know that you will be accessing some information frequently and other parts only once in a while (at least when talking about large data sets), why store them together. This is one of the basic tenants of code optimization. Regardless your findings are interesting and good to know.
  17. If you are designing this from the ground up why not spend some time implementing a standard API for your plugins? This way you wouldn't need to worry about mismatched connector panes. Design you modules to handle the implementation specific tasks but call them using the same API. Generalize the API using type indentpent items such as variants. This way you can use the same method for calling your plugins and not worry about the connector pane. Or am I missing what you are trying to accomplish. Another possibility would be to use LVOOP with inheritance. You could then overload your general class with type specific classes to handle the variations.
  18. QUOTE (Matthew Zaleski @ Mar 24 2009, 12:37 PM) We are talking to NI about it now and haven't investigated it far enough to know if this will work or not. But until this there was no option for even considering LabVIEW for actual product development. This may be changing though. I doubt we will do our entire development in LabVIEW at this point but were are certainly looking at for rapid prototyping. I could see the day though when it would be possible to design an entire system using LabVIEW.
  19. I haven't played extensively with the VI Server but are you running one of these in a project and one outside a project? If so, you would need to configure the VI Server for the project. I haven't experimented with this but I suspect you might be able to run multiple VI Server's on a single machine provided you managed your ports properly.
  20. I would ask the question is it really necessary to save every piece of data. You are saving the history so you can look back when and if a problem occurs. Using statistical analysis you can probably determine a sufficient sample size for your historical data that would allow you to see what you want without the need for saving every bit, or more accurately byte of data. Yes it seems like reasonable to want to be able to look at every measurement you ever took but as you see it is not always practical. I am sure you could determine a reasonable sample size that you would need to save that would provide you with a high enough confidence level that you are seeing an accurate representation of your historical data. Think of polling. If you use a truly random and unbiased selection for your sample you can say with a specified degree (95%, 98%, 99.9%) of accuracy you have a accurate representation of your total population.
  21. QUOTE (Matthew Zaleski @ Mar 24 2009, 09:30 AM) From my understanding the answer is yes, LabVIEW compiles the code as you wire it. It is constantly compiling the code. Someone from NI can correct me if I am wrong but I believe they are smart enough to only require recompiling the affects pieces of code and not every clump. This is how they can achieve the constant and effectively real-time time compiling of code. QUOTE (Matthew Zaleski @ Mar 24 2009, 09:30 AM) That would not surprise me. Abstracting to a higher level than pure C++ gives new avenues for optimization. Out of curiosity, are you treating the VI akin to a .c file with a pile of functions (1 function per chunk) or are these chunks handled in a more raw form (pointer arrays to code snippets)? I still feel that the main points of my argument stand (since you can compile Python, Matlab and Java to native code). The value proposition from LabVIEW (since it isn't "free") is enhancing my productivity and allowing me to ignore the gritty details of C++/assembly most of the time. I would surmise that the performances issues that LabVIEW has are due to the higher level abstractions the language provides over C++. Remember, with LabVIEW you have built-in parallel processing as well as data flow execution. If you were to write the same execution engine entirely in C++ you would probably encounter the same performance hits. There is a lot of stuff going on under the hood that LabVIEW provides that isn't happening in C++ programs. In most cases the hit on performance is not that significant because like you say most applications are "fast enough" and the increase in programmer productivity more than makes up for the loss in performance. In the cases where the performance is an issue that other solutions need to be investigated such as the over design and architecture of the application, the alogorthm implementations, etc. And in some cases parts or possibly all of the solution will need to be written in another language. I have worked with embedded systems for over 20 years and it never ceases to amaze me how easy it is to implement parallel tasks in LabVIEW as opposed to other languages. And most embedded developers I work with who first encounter LabVIEW are amazed as well. (Note: the embedded solutions I have worked on cannot be developed in LabVIEW since NI has not provided a general purpose programming environment for LabVIEW running on custom hardware. They are starting to get there with their current RT support but I don't think we are quite at the point where you can throw an NI solution as a possible candidate for custom hardware development projects.)
  22. As Dan mentioned it is possible but not advisable. I prefer to use a producer/consumer architecture and minimize my processing within the event structure to handling UI events and some custom events. I keep processing to a minimum. For the type of processing you are describing I generally pass that off to a parallel task that will not impact my processing of events.
  23. QUOTE (neBulus @ Mar 23 2009, 01:17 PM) Don't worry Ben I didn't feel like you were directing that at me. Anyway, this does highlight a difference between formally trained SW Engineers and self taught ones. I will be the first to admit that it isn't absolutely required for someone to have formal training in order to work at the level of a good system architect nor is it a requirement in order to get certified. However, it does highlight the need to be able to talk a common language. One important thing a person learns through formal training is the language of the trade. It can vary a bit from industry to industry and there are multiple names for the same concepts in some cases but for the most part the terminology is fairly well understood. I am not sure if NI should water down the terminology or create its own. For instance, I race sailboats and we had an old crew member who used all of their own terms for everything on the boat. Worse yet they taught those new terms to new crew members she taught. In the end this was a nightmare since noone could communicate. Everything took considering longer since there was so much translation involved. Fortunately she didn't teach too many people on the boat and eventually left our crew. However the people she taught were at a significant disadvantage if they went to another boat using the standard terms. It is important the common language be used to discuss the various concepts used within SW engineering. This is true with any specialty that has its own "language". Mark
  24. QUOTE (RAJKU @ Mar 22 2009, 12:34 PM) This means that your system should be able to remember the state that it was in when you exit it and that it can restore this state when you run it again. In some cases you don't want to preserve the state and in others cases you do. However a good architecture would allow you to maintain this information between executions. In addition, your architecture should be such that different tasks within your system can obtain state information about the running system. Again, not everything needs to be exposed but there is some information that you may need to expose to all parts of your system. QUOTE (RAJKU @ Mar 22 2009, 12:34 PM) "Develop Architecture to handle Configuration Data". Can you explain this point Your system should not rely on hard coded configuration data (IP address, instrument data, timing parameters, etc.) and should provide a means of defining this information external to the application. Your system should allow this type of information to be loaded from a file or a database or some other means. Basically, your system should be designed in such a manner that changes to components of your system do not necessarily mean you need to change your code. QUOTE (RAJKU @ Mar 22 2009, 12:34 PM) Design a scalable interface that can ease transition from simulation? what do they mean by Scalable interface Essentially your system should be designed to allow it to grow. If you originally wrote it to work with it testing or controlling a single device then it should be relatively easy to have it work with multiple devices. Again, like the other answers this one means that your design is not so rigid that adding or changing anything in it is a difficult task. I don't mean any offence by what I am going to say next so please don't take it as such. But these are pretty basic questions when it comes to a system architect. I have to ask are you really ready for the CLA exam? Perhaps you need to get some more large scale application development experience under your belt before you are ready for this exam.
×
×
  • Create New...

Important Information

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