Jump to content

X___

Members
  • Posts

    437
  • Joined

  • Days Won

    29

Posts posted by X___

  1. Whatever. My question was: did I understand correctly that individual VI files shared between projects were going to become hard to use. The answer was no. I then commented that in this case there was nothing new of interest, or at least I could ignore the the gll paradigm.

    As for picking a fight, why would I even bother. As you know, I left NI forums after you (AQ) summoned me by private message to stop expressing critical comments. There is a difference between engaging customers and addressing their needs, which I believe is something that would benefit from some soul searching on NI's part.

    As for me, I have no interest in wasting any time with NXG until I am forced to abandon CG. I hope that by then I will be sufficiently proficient using other programming environments that are open, free and supported on all platforms. 

  2. 43 minutes ago, JeffP said:

    Can you elaborate on your concern?

    Generally speaking - directly sharing source across multiple projects can easily lead to making changes in one project which unintentionally breaks another project. The recommendation is that if you have a piece of code that you want to reuse in multiple projects (maybe its a framework or a library) you should separate that code into its own module. The projects would then depend on the built component - a gll for example, so this enables you to maintain versioning and avoid the case I described. Alternatively you could distribute the shared component as an addon, but you would not be able to directly edit the shared dependency from the project which is dependent on it.

    You are still able to directly share GVIs between different projects, we just don't recommend that you do it.

    Thanks, this perfectly clarifies the matter. Nihil novi sub sole?

     

  3. 55 minutes ago, Rolf Kalbermatter said:

    The OpenG ZIP library is mainly an implementation of a ZIP archive reader and writer but uses at its core the zlib library for the compression and decompression, just as the ZIP library does that is included in LabVIEW. While the LabVIEW provided ZIP library only exports a few high level functions to be accessed, the OpenG version goes a lot further and basically exports a lower level API on which the whole ZIP archive handling is implemented. And in addition it also exports the according ZLIB  inflate and deflate functions that allow you to implement any compression that is based on the ZLIB compression method. It would be possible to implement GZ and similar formats on top of this without a lot of effort, by simply implementing a LabVIEW library on top of these ZLIB methods and some LAbVIEW file IO methods.

    Can't use it with 64-bit LV, AFAIK...

  4. On 5/19/2020 at 5:20 AM, hooovahh said:

    One fix I found was that after you enable the vertical scroll bar, disable it, and then enable it again. 

    Untitled.png.3ba5885729d375f7697069c1bbc6bb3d.png

    Can't get that to work systematically. Sometimes it does the trick, sometimes it doesn't. I believe this is worth reporting as a bug.

    While this could be a wrong hunch, I wonder whether this might be due to the narrow scrollbar width in the NXG graph legend. Notice that it is narrower than that of a NXG array (shown on the right below). It is definitely narrower than that of the silver style graph legend (shown second from the top left), which is narrower than the modern graph legend (shown last on the left). The latter is of the same width as the classic graph legend.

    The reason I am suspecting this is that I have seen something similar in a utility that was supposed to return the clicked element in an array (https://forums.ni.com/t5/Example-Code/Determine-Clicked-Array-Element-Index-in-LabVIEW/tac-p/4040339/highlight/true#M14360) and failed with silver and NXG arrays because the border sizes and other details of controls have changed from style to style, and the underlying routines have not been updated.

    245593348_ScreenShot2020-05-20at16_21_22.png.2b5a3f8d153ca8135d271bc5b77d10d4.png

    In any case, this is annoying enough to be reported.

  5. The NI_Unzip.lvlib VIs are all password protected (probably because underneath, they are using some .NET calls they don't want people to mess up with). So yes we don't know what they do, although the help tells us what they can't do:

    Unzips the contents of Zip file to the Target directory. Set Preview only? to TRUE to preview the list of files in Zip file before you unzip the zip file. This VI cannot unzip a zip file that is password protected.

    Why wouldn't it support password protected archives?

     

    Anyway, the compression/decompression algorithms are not necessarily particularly well described or unique for that matter and it is therefore not surprising that some implementations might be incompatible (although they shouldn't):

    .NET documentation

    https://docs.microsoft.com/en-us/dotnet/api/system.io.compression.deflatestream?view=netcore-3.1

    An old 40,000 ft description:

    https://zlib.net/feldspar.html

    quoted in this interesting "from-the-ground-up" implementation (quoting the previous reference):

    http://www.integpg.com/deflate-compression-algorithm/

    • Like 1
  6. It does seem to do exactly what I needed though, which was emulate that piece of MATLAB code:

    zipbuf = fread(fid, offset, 'uint8=>uint8');
    tmp_dir= tempname;
    [SUCCESS,MESSAGE] = mkdir(tmp_dir);
    if SUCCESS
        fnz= fullfile(tmp_dir,'temp.zip');
    else
        disp(MESSAGE);
        error('Cannot create folder.')
    end
    tmp_fid = fopen(fnz,'w');
    fwrite(tmp_fid, zipbuf);
    status = fclose(tmp_fid);
    fnu=char(unzip(fnz,tmp_dir) );
    tmp_fid = fopen(fnu, 'r');
    data = fread(tmp_fid, length, type_str);
    status = fclose(tmp_fid);
    [SUCCESS,MESSAGE] = rmdir(tmp_dir, 's');
    if ~SUCCESS
        disp(MESSAGE);
        error('Cannot delete folder.')
    end
    end
     

×
×
  • Create New...

Important Information

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