Re: -|EXT|- Failure to build Andor SDK3 module in win32

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: -|EXT|- Failure to build Andor SDK3 module in win32

centswu
Hi Christophe,

After patch AT_UnpackBuffer to  AT_ConvertBuffer in Windows x64, it can be compiled without error now.
But uM live window show black view (all pixel data is 0) and got some error message in uM 2.0 log

2018-04-11T17:35:02.068246 tid3440 [IFO,Core] Did load device Andor sCMOS Camera from AndorSDK3; label = Andor sCMOS Camera

2018-04-11T17:36:13.994360 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1
2018-04-11T17:36:14.029362 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

Thanks,
Cents

diff --git a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp
index 0805ae0a3..b1a53bffc 100644
--- a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp
+++ b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp
@@ -42,8 +42,10 @@
#include "ExposureProperty.h"
#ifdef _WINDOWS
+#if 0
#include "atunpacker.h"
#else
+#endif
#include "atutility.h"
#endif
#include "triggerremapper.h"
@@ -891,9 +893,11 @@ void CAndorSDK3Camera::UnpackDataWithPadding(unsigned char * _pucSrcBuffer)
    MMThreadGuard g(imgPixelsLock_);
    unsigned char * pucDstData = const_cast<unsigned char *>(img_.GetPixels());
#ifdef _WINDOWS
+#if 0
    unsigned int ret_code = AT_UnpackBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),
                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16", 0);
#else
+#endif
    unsigned int ret_code = AT_ConvertBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),
                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16");
#endif  

2017-08-07 18:50 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

This is a deprecated library indeed. AT_ConvertBuffer in ATUtility replaces AT_UnpackBuffer in ATUnpacker.

 

We will update the code of the SDK3 adapter accordingly but in the meantime you can fix the code yourself easily since the call to AT_ConvertBuffer is already there for Linux.

 

You have to first modify andorSDK3.cpp as follow:

_ remove the call to AT_UnpackBuffer and the #ifdef _WINDOWS around it. This will effectively replace it with the call to AT_ConvertBuffer.

_ remove the include of atunpacker and the #ifdef _WINDOWS around it. This will replace it with the include of atutility.

 

Finally add atutilitym.lib to the project

 

It should build from there.

 

Regards,

Christophe

 

From: cents wu [mailto:[hidden email]]
Sent: 05 August 2017 17:29
To: Micro-Manager General <[hidden email]>
Subject: -|EXT|- [micro-manager-general] Failure to build Andor SDK3 module in win32

 

Hi folks,

 

I try to build Andor SDK3 module of MM, it shows no "atunpackerlib.lib".

I have Andor SDK3.11 , there are atcorem.lib, atutilitym.lib, atmcd64m.lib in it, but no atunpackerlib.lib.

Is atunpackerlib.lib only in some old version of Andor SDK3?

 

 

Thanks,

Cents

 

Click here to report this email as spam.



___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: -|EXT|- Failure to build Andor SDK3 module in win32

AndorThirdParty

Hello Cents,

 

The error 1 from AT_ConvertBuffer indicates that the utility library was not initialised – it looks like Christophe missed one line in his instructions below. You should remove the #ifdef around this statement.

 

#ifdef linux

    AT_InitialiseUtilityLibrary();

#endif

 

Hopefully it will be working for you now.

 

Thanks,

Jack

 

From: cents wu [mailto:[hidden email]]
Sent: 13 April 2018 08:55
To: Micro-Manager General <[hidden email]>
Subject: Re: [micro-manager-general] -|EXT|- Failure to build Andor SDK3 module in win32

 

Hi Christophe,

 

After patch AT_UnpackBuffer to  AT_ConvertBuffer in Windows x64, it can be compiled without error now.

But uM live window show black view (all pixel data is 0) and got some error message in uM 2.0 log

 

2018-04-11T17:35:02.068246 tid3440 [IFO,Core] Did load device Andor sCMOS Camera from AndorSDK3; label = Andor sCMOS Camera

 

2018-04-11T17:36:13.994360 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

2018-04-11T17:36:14.029362 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

 

Thanks,

Cents

 

diff --git a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

index 0805ae0a3..b1a53bffc 100644

--- a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

+++ b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

@@ -42,8 +42,10 @@

#include "ExposureProperty.h"

#ifdef _WINDOWS

+#if 0

#include "atunpacker.h"

#else

+#endif

#include "atutility.h"

#endif

#include "triggerremapper.h"

@@ -891,9 +893,11 @@ void CAndorSDK3Camera::UnpackDataWithPadding(unsigned char * _pucSrcBuffer)

    MMThreadGuard g(imgPixelsLock_);

    unsigned char * pucDstData = const_cast<unsigned char *>(img_.GetPixels());

#ifdef _WINDOWS

+#if 0

    unsigned int ret_code = AT_UnpackBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16", 0);

#else

+#endif

    unsigned int ret_code = AT_ConvertBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16");

#endif  

 

2017-08-07 18:50 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

This is a deprecated library indeed. AT_ConvertBuffer in ATUtility replaces AT_UnpackBuffer in ATUnpacker.

 

We will update the code of the SDK3 adapter accordingly but in the meantime you can fix the code yourself easily since the call to AT_ConvertBuffer is already there for Linux.

 

You have to first modify andorSDK3.cpp as follow:

_ remove the call to AT_UnpackBuffer and the #ifdef _WINDOWS around it. This will effectively replace it with the call to AT_ConvertBuffer.

_ remove the include of atunpacker and the #ifdef _WINDOWS around it. This will replace it with the include of atutility.

 

Finally add atutilitym.lib to the project

 

It should build from there.

 

Regards,

Christophe

 

From: cents wu [mailto:[hidden email]]
Sent: 05 August 2017 17:29
To: Micro-Manager General <[hidden email]>
Subject: -|EXT|- [micro-manager-general] Failure to build Andor SDK3 module in win32

 

Hi folks,

 

I try to build Andor SDK3 module of MM, it shows no "atunpackerlib.lib".

I have Andor SDK3.11 , there are atcorem.lib, atutilitym.lib, atmcd64m.lib in it, but no atunpackerlib.lib.

Is atunpackerlib.lib only in some old version of Andor SDK3?

 

 

Thanks,

Cents

 

Click here to report this email as spam.



___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general

 

___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: -|EXT|- Failure to build Andor SDK3 module in win32

centswu
Hi Jack,

It can work now, thanks for your support.

By exposure time 10ms,  the data 28 fps and display 8fps
Is this normal live display speed for Andor Zyla 4.2 in mm2?

Thanks,
Cents 

2018-04-19 17:22 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

The error 1 from AT_ConvertBuffer indicates that the utility library was not initialised – it looks like Christophe missed one line in his instructions below. You should remove the #ifdef around this statement.

 

#ifdef linux

    AT_InitialiseUtilityLibrary();

#endif

 

Hopefully it will be working for you now.

 

Thanks,

Jack

 

From: cents wu [mailto:[hidden email]]
Sent: 13 April 2018 08:55
To: Micro-Manager General <[hidden email]>
Subject: Re: [micro-manager-general] -|EXT|- Failure to build Andor SDK3 module in win32

 

Hi Christophe,

 

After patch AT_UnpackBuffer to  AT_ConvertBuffer in Windows x64, it can be compiled without error now.

But uM live window show black view (all pixel data is 0) and got some error message in uM 2.0 log

 

2018-04-11T17:35:02.068246 tid3440 [IFO,Core] Did load device Andor sCMOS Camera from AndorSDK3; label = Andor sCMOS Camera

 

2018-04-11T17:36:13.994360 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

2018-04-11T17:36:14.029362 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

 

Thanks,

Cents

 

diff --git a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

index 0805ae0a3..b1a53bffc 100644

--- a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

+++ b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

@@ -42,8 +42,10 @@

#include "ExposureProperty.h"

#ifdef _WINDOWS

+#if 0

#include "atunpacker.h"

#else

+#endif

#include "atutility.h"

#endif

#include "triggerremapper.h"

@@ -891,9 +893,11 @@ void CAndorSDK3Camera::UnpackDataWithPadding(unsigned char * _pucSrcBuffer)

    MMThreadGuard g(imgPixelsLock_);

    unsigned char * pucDstData = const_cast<unsigned char *>(img_.GetPixels());

#ifdef _WINDOWS

+#if 0

    unsigned int ret_code = AT_UnpackBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16", 0);

#else

+#endif

    unsigned int ret_code = AT_ConvertBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16");

#endif  

 

2017-08-07 18:50 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

This is a deprecated library indeed. AT_ConvertBuffer in ATUtility replaces AT_UnpackBuffer in ATUnpacker.

 

We will update the code of the SDK3 adapter accordingly but in the meantime you can fix the code yourself easily since the call to AT_ConvertBuffer is already there for Linux.

 

You have to first modify andorSDK3.cpp as follow:

_ remove the call to AT_UnpackBuffer and the #ifdef _WINDOWS around it. This will effectively replace it with the call to AT_ConvertBuffer.

_ remove the include of atunpacker and the #ifdef _WINDOWS around it. This will replace it with the include of atutility.

 

Finally add atutilitym.lib to the project

 

It should build from there.

 

Regards,

Christophe

 

From: cents wu [mailto:[hidden email]]
Sent: 05 August 2017 17:29
To: Micro-Manager General <[hidden email]>
Subject: -|EXT|- [micro-manager-general] Failure to build Andor SDK3 module in win32

 

Hi folks,

 

I try to build Andor SDK3 module of MM, it shows no "atunpackerlib.lib".

I have Andor SDK3.11 , there are atcorem.lib, atutilitym.lib, atmcd64m.lib in it, but no atunpackerlib.lib.

Is atunpackerlib.lib only in some old version of Andor SDK3?

 

 

Thanks,

Cents

 

Click here to report this email as spam.



___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general

 

___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: -|EXT|- Failure to build Andor SDK3 module in win32

AndorThirdParty

Hi Cents,

 

Yes, this is a general issue. It seems to be typical that the displayed frame rate lags behind the acquired speed.

 

Nico Stuurman suggested in the past that the problem is caused by using ImageJ to draw the images. He suggested that using binning could increase the displayed rate, if your experiments allow for the use of increased binning.

 

Thanks,

Jack

 

From: cents wu [mailto:[hidden email]]
Sent: 20 April 2018 08:21
To: Micro-Manager General <[hidden email]>
Subject: Re: [micro-manager-general] -|EXT|- Failure to build Andor SDK3 module in win32

 

Hi Jack,

 

It can work now, thanks for your support.

 

By exposure time 10ms,  the data 28 fps and display 8fps

Is this normal live display speed for Andor Zyla 4.2 in mm2?

 

Thanks,

Cents 

 

2018-04-19 17:22 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

The error 1 from AT_ConvertBuffer indicates that the utility library was not initialised – it looks like Christophe missed one line in his instructions below. You should remove the #ifdef around this statement.

 

#ifdef linux

    AT_InitialiseUtilityLibrary();

#endif

 

Hopefully it will be working for you now.

 

Thanks,

Jack

 

From: cents wu [mailto:[hidden email]]
Sent: 13 April 2018 08:55
To: Micro-Manager General <[hidden email]>
Subject: Re: [micro-manager-general] -|EXT|- Failure to build Andor SDK3 module in win32

 

Hi Christophe,

 

After patch AT_UnpackBuffer to  AT_ConvertBuffer in Windows x64, it can be compiled without error now.

But uM live window show black view (all pixel data is 0) and got some error message in uM 2.0 log

 

2018-04-11T17:35:02.068246 tid3440 [IFO,Core] Did load device Andor sCMOS Camera from AndorSDK3; label = Andor sCMOS Camera

 

2018-04-11T17:36:13.994360 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

2018-04-11T17:36:14.029362 tid5328 [IFO,dev:Andor sCMOS Camera] [UnpackDataWithPadding] failed with code: 1

 

Thanks,

Cents

 

diff --git a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

index 0805ae0a3..b1a53bffc 100644

--- a/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

+++ b/DeviceAdapters/AndorSDK3/AndorSDK3.cpp

@@ -42,8 +42,10 @@

#include "ExposureProperty.h"

#ifdef _WINDOWS

+#if 0

#include "atunpacker.h"

#else

+#endif

#include "atutility.h"

#endif

#include "triggerremapper.h"

@@ -891,9 +893,11 @@ void CAndorSDK3Camera::UnpackDataWithPadding(unsigned char * _pucSrcBuffer)

    MMThreadGuard g(imgPixelsLock_);

    unsigned char * pucDstData = const_cast<unsigned char *>(img_.GetPixels());

#ifdef _WINDOWS

+#if 0

    unsigned int ret_code = AT_UnpackBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16", 0);

#else

+#endif

    unsigned int ret_code = AT_ConvertBuffer(_pucSrcBuffer, pucDstData, aoi_property_->GetWidth(), aoi_property_->GetHeight(),

                                           aoi_property_->GetStride(), ws_pixelEncoding.c_str(), L"Mono16");

#endif  

 

2017-08-07 18:50 GMT+08:00 3rdPartySupport <[hidden email]>:

Hello Cents,

 

This is a deprecated library indeed. AT_ConvertBuffer in ATUtility replaces AT_UnpackBuffer in ATUnpacker.

 

We will update the code of the SDK3 adapter accordingly but in the meantime you can fix the code yourself easily since the call to AT_ConvertBuffer is already there for Linux.

 

You have to first modify andorSDK3.cpp as follow:

_ remove the call to AT_UnpackBuffer and the #ifdef _WINDOWS around it. This will effectively replace it with the call to AT_ConvertBuffer.

_ remove the include of atunpacker and the #ifdef _WINDOWS around it. This will replace it with the include of atutility.

 

Finally add atutilitym.lib to the project

 

It should build from there.

 

Regards,

Christophe

 

From: cents wu [mailto:[hidden email]]
Sent: 05 August 2017 17:29
To: Micro-Manager General <[hidden email]>
Subject: -|EXT|- [micro-manager-general] Failure to build Andor SDK3 module in win32

 

Hi folks,

 

I try to build Andor SDK3 module of MM, it shows no "atunpackerlib.lib".

I have Andor SDK3.11 , there are atcorem.lib, atutilitym.lib, atmcd64m.lib in it, but no atunpackerlib.lib.

Is atunpackerlib.lib only in some old version of Andor SDK3?

 

 

Thanks,

Cents

 

Click here to report this email as spam.



___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general

 

___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general

 

___________________________________________________________________________
This e-mail is confidential and is for the addressee only.   Please refer to
www.oxinst.com/email-statement for regulatory information.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general