Jump to content

ShaunR

Members
  • Posts

    4,942
  • Joined

  • Days Won

    308

Posts posted by ShaunR

  1. Is this correct?

     

    No.

    What you are describing is merely prepending a sub domain name. Whilst sometimes people put a proxy on a sub domain, it's not a requirement. Besides, you may need to authenticate with the proxy.

     

    Under normal conditions, the GET request URI is usually a relative path (doesn't have to be but is usually the case) and the HOST field of the HTTP header contains the domain of the target page. It's is slightly different with a Proxy.

     

    The GET URI is the full URI of the target page (including the http:// and the domain name of the target page). The HOST field is the domain name of the proxy server and you connect to the proxy server, not the server that has the page.

     

    A proxy may also require authentication and these parameters are also sent in the HTTP header fields (see section 2).

     

    I don't believe any of the LabVIEW web oriented VIs support Forwarding Proxies (the sort I think you are describing) out of the box. I may be wrong and they added them in later versions, but  I haven't come across any. You might try Rolfs HTTP VIs, I can't remember off-hand if they support proxies and the OpenG site is down ATM so can't check, Apart from that I expect you will have to hand craft these headers and handle the responses the old fashioned way (and you will be stuffed if it is SSL/TLS).

  2. I think perhaps the design, style and documentation should be worth more. I have a pretty high level of coding standard (i.e. block diagram neatness, comments etc) that I always try and aim for. This is ingrained in me after more than 15000 hours of doing LabVIEW. As such, it is very difficult to override this instinct and code "messily" just to try and get all the functionality in.

     

    Depends on your approach, I suppose. Or, more specifically, how much time you have. I haven't met a customer yet that would say yes to me billing for more time to make the diagrams look better or fill in all the VI descriptions/labels. I tend to throw stuff at the diagram, get it working, then make it look pretty. In fact, when faced with a particularly knarly problem, I will go around and fill in descriptions, labels and make icons as a distraction. It fits with an iterative development better as you can make it look better with each iteration, as long as it works. Often, as more features are added to diagrams, they need re-prettifying as the feature list increases so making it pretty off the bat, is a bit pointless.

     

    But here we are talking about an exam which is designed to be time stressed and given that the purpose is to certify coding competence, not the examinees graphic design skills or obsessive/compulsive tendencies; I think this emphasis of marking is more fitting. If you have time at the end of the exam to make it easier to read for the examiners, great, but if it's that bad they can press THE button. However, working code is a better yard-stick for coding competence and debugging capabilities in a time constrained environment, IMO (at least for a CLED), and that's what employers want. The Architect cert is probably where how pretty it looks is more relevant (more a test of communication than CLED), once you've proved you can write the code first..

     

    But what do I know! I've no certifications at all ;):D

  3. Do you guys know if Inno Setup has an easy way to install prerequisites, like the LabVIEW Run-Time Engine? My fallback plan was to make a "base installer package" that will install the RTE through LabVIEW's builder profile. Then have another installer for my program.

     

    It's annoying, but it would only be a two-step process that first time. After that, I think people can just go directly to my latest installer for upgrades.

    Depends what you mean by "easy". Write a pascal script to check in the registry for the Run-Time and if it doesn't exist invoke the run-time installer. If you have the download plugin, you can even get it to go and fetch the installer from NI, then run it.

  4. We stopped looking at the post counts and started looking at the "likes" a few years ago - a much better outlook IMO.

     

    ......and you stopped showing the top 10 like count on the main page the day after I got to #2 :D

  5. Are you using URI filenames?

     

    Try that, with the most conservative flagset of SQLITE_OPEN_URI | SQLITE_OPEN_FULLMUTEX | SQLITE_OPEN_PRIVATECACHE and also the most permissive permissions SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE then deprivileging with the "mode" parameter on the URI. You'll also need to call sqlite3_open_v2 rather than sqlite3_open

     

    My hunch is that these settings could be sufficient without recompiling SQLite.

     

    The issue isn't so much accessing SQLite on network drives; I's concurrency. I can quite happily read and and write to my NAS boxes, but woe betide if you try and share the DB amongst clients.

     

    Just for giggles, I ran the Speed example and pointed it to my NAS box (over a wifi connection) and it achieved about 0.5 secs to insert and read 10,000 records. .

    • Like 1
  6. In my case, I am never accessing it at the same time from the Client and the Server.  The Client does it's work and then closes the connection.  The Server then connections later and does it's writes.

    I could replace this with a flat file of some type (.csv, etc) but I like the ability to query the data since I can reuse some of my SQL code I use with the regular DB server.  This is just sort of an off-line mode I am implementing for experimenting with new ideas where we dont want to pollute the central database but still want to collect data for analysis.

    Sucks that SQLite can't do this since it is such a good solution otherwise.  I hate to have to switch to MSAccess but it is the only other file based DB solution I know of.

     

    thanks for the feedback.

     

    -John

     

    Then why not have the server write to the CSV file (or whatever) then just import it to a local database for use? It'll be a one hit performance to retrieve then full SQLite performance whilst in use.

  7. This is what the SQLite peeps have to say.
     

    But if you must use a network filesystem to store SQLite database files, consider using a secondary locking mechanism to prevent simultaneous writes to the same database even if the native filesystem locking mechanism malfunctions.

     

    They are really talking about a single client, however and you will find it impossible (I think-never tried) to create a shared locking mechanism between two machines. You might as well use a proper client/server DB.

     

    There is a compile time option where you can choose the locking mechanism (file based may work better), but you would have to compile it yourself.

  8. Wow, that was incredibly trivial. Thanks Neil! Far easier to use than LabVIEW's app builder. I can see I'm going to have to tweak a few things to get it exactly how I want, but the fact that it builds a working installer on the first try (just using the GUI wizard you recommended) is huge.

     

    NI probably still has some weird behavior on their hands but now I don't have to waste any more time trying to debug it!

     

    .I have been bitten hard on all the LabVIEW installers (most recently by JKIs). Whilst I love Inno Setip and have used it for many years, I need a x-platform one and they are a bit few and far between (how I wish Inno was x-platform!!!!). Now I'm dissatisfied with all the "preferred" options I'm checking out InstallJammer to see if it is a better solution for my needs.

  9. I have to echo Rolf here.

     

    I have never found any source control software to be .adequate for LabVIEW. I just treat them all as backup and restore systems. When working with multiple developers I usually break the project into multiple sub-projects that each developer can own, so to speak. It's just a less granular way of what Rolf is describing. My advice is just avoid merging in LabVIEW altogether.You'll live longer :D.

  10. I think you will need to scale back your expectations as to what you will be able to achieve for the software aspect. How much time do you have left? I'm guessing that you have spent most of your PHD time creating the hardware and now it's "just a little bit of software to make it work" 

     

     

    Remote communications (especially for hardware)  is not a trivial subject but you can get an idea of how you might tackle it (and the complexity) from  XML-RPC Server for LabVIEW or Dispatcher in the Code Repository. There are also examples shipped with LabVIEW to show the basics of client/server communications. That is before we get to actually controlling the hardware. 

     

    Personally. If you have experience of text based programming (did you write the firmware?) and are on Linux (which I suspect from the phrasing of the question) then I would use Python.

  11. How can I put this KML files with google map on my VI?

    attachicon.gifKML files.zip

    attachicon.gifRAINFALL2 mod.vi

     

    Well. You you won't be able to use Google Maps without a lot more experience with web applications and JavaScript.

    This is the easy way, but you will have difficulty updating the map, online, programmatically from you application..

     

    Web Rainfall.vi

     

    You will have to download and install Google Earth instead of using Google Maps and use the library previously linked (if it works) to add your KML to the Google Earth interface.

  12. I made a KML file. How can I put it in Google Map and put it in LabVIEW? Should I download the packages you mentioned?

    You can use that software if you are using Google Earth (never used it, so don't know if it works or not). But if you are using Google Maps from a web browser as an activeX (or.NET) component in LabVIEW it's even easier.

    Log in to Google Maps with your google account. Click on My Places and that will take you to a page where you can create maps.

    Create a new map, add your KML overlay file and then just point your LabvIEW thing (browser?) to that map.

  13. I tried but I got confused for a bit so I erased it. So I tried changing a color of an image by replacing a new color (example, looking for a color green and changing all green to white) but I'm still not sure if I'm on the right track.

    I looked at the link you said and I have a question. If I'm going to make a KML file to load it on Google Map, will the coloring part be done through the map's coordinates?

     

    Not sure what you are asking here, but KML has the ability to define the colour of a polygon (or line). The polygon is defined by map coordinates 

     

    Here's a simple example that I found by Googling that enables you to turn on and off a coloured KML overlay.

    • Like 1
  14. Interesting, hooovahh must have done that in his version but when I loaded it, I got the warning dialog that the dependencies had changed. I thought it was just fixing the OpenG path and ignored the warning. Doh.

     

    Now I just have to work out why it doesn't actually bring the window to front. I thought it may have something to do with my desktop manager as discussed here but turning it off doesn't make a difference. Strangely, my own BringToFront.vi doesn't work anymore either.

     

    Does this (exe or Main.vi) come to front for anyone? attachicon.gifToFront.zip

    EDIT: Unfortunately, I can only build in 2013 at the moment so I haven't included 2012 code either

    Put the 3 sec delay after you set to top

×
×
  • Create New...

Important Information

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