JKISoftware / HAL-Webinar

Webinar – Creating a Hardware Abstraction Layer in LabVIEW
BSD 3-Clause "New" or "Revised" License
37 stars 13 forks source link

Opened project in LV2019 and fixed errors. #4

Closed jhgee closed 11 months ago

jhgee commented 4 years ago

Especially the following errors had to be fixed:

CLAassistant commented 4 years ago

CLA assistant check
All committers have signed the CLA.

francois-normandin commented 4 years ago

Hi John (@jhgee), Thanks for the report. I believe IMAQdx was excluded because this is a paid add-on that not so many people have access to. As for the relinking issues, I'm wondering if a mass compile would have helped in fixing the type propagation in the in-place element structures? Lastly, the event registration being jumbled... I've seen this before and is quite an annoying but in LabVIEW, one that is now supposed to be fixed though, so I'm surprised that you've encountered it in LV2019.

I'll try to reproduce the problems you've encountered and if I do, I'll merge your code to a dedicated LV2019 branch for those who would like to start with this version. The main branch will remain in LV2013...

Thanks for your contribution!

Flydroid commented 3 years ago

Hi Francois,

I just checkout your SMO HAL and unfortunately still in Labview 2020 the event cases are still jumbled. I fixed the manually but it would great to merge this pull request.

francois-normandin commented 3 years ago

Hi @Flydroid ,

Thanks for the report. I think there is no point in keeping the example code in 2013 for backwards compatibility... It's example code after all!

I'll upgrade the base code to a newer version of LabVIEW with those things fixed. I'll probably up it to LabVIEW 2020 so that community edition users have it fully functional without recompilation, which hopefully will limit the risk of event name mangling for that category of users. Not everyone can fix those errors before giving up. I appreciate you took the time to report it.

About IMAQdx, since it's a paid add-on from NI, it won't be included. I'll make sure to create a separate lvproj file so it does not load this dependency.

Flydroid commented 11 months ago

Hi @francois-normandin,

Here am I again, looking at JKI SMO to see if it is the right for a new project. As your HAL example seems to be the only more complicated JKI SMO project available online I would like to ask if you you could have another look at saving your project in Labview 2020 (or similar)?

Thank you!

francois-normandin commented 11 months ago

@Flydroid , sure I'll give this a quick look, although I might but have access to IMAQ license anymore, but let me see if I can find some offline help and get something going.

francois-normandin commented 11 months ago

@Flydroid I modified the LV2013 code to prevent the Processes to break when upsaved to LV2020.

There are known issues with User Event mapping that, at the time, I believed had been fixed around LV2012. However, upsaving the SMO.Dictionary classes, Microscope, XYStage and Camera all broke the ordering of the events.

The fix was to wire individual User Events instead of wiring the Cluster of User Events.

As an example... This arrangement maintains the correct mapping when up-saved to LV2020: image

This arrangement did not: image

The code has been modified and saved in LabVIEW 2013 version, but I have verified that it opens and recompiles to LV2020 without breaking.

Flydroid commented 11 months ago

@francois-normandin thank you for the fixes! It's working now!