# FAST and Bladed-DLL 64bit

**URL:** <https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267>\
**Category:** Computer-Aided Engineering Software Tools\
**Created:** [July 6, 2010, 11:34pm UTC](https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267 "2010-07-06T23:34:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brian.Resor](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@Brian.Resor](https://forums.nlr.gov/u/Brian.Resor)\
**Post date:** [July 6, 2010, 11:34pm UTC](https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267/1 "2010-07-06T23:34:32Z")

</div>

Hello, I seem to be stuck. I’m trying to convince myself that I can compile FAST to call the DLL files for control. My next step is to get it all working together with ADAMS. I’m using IVF 11.1.048.

I am able to use IVF to compile FAST and it works, both 32-bit and 64-bit. I am also able to compile FAST to call the DLL on 32-bit.

When I compile FAST to call DLL on 64-bit, I get the following error (which initiates several others)

C:\DesignCodes\FAST\_v7.00\Source\BladedDLLInterface.f90(120): error #6284: There is no matching specific function for this generic function reference. [GETPROCADDRESS]  
DLL%ProcAddr = GetProcAddress( DLL%FileAddr, TRIM(DLL%ProcName)//CHAR(0) )

I did some looking into what the above error means, and thought that the following changes to BladedDLLInterface.f90 might help, which they do. I get no errors during compile.

INTEGER(4) :: FileAddr  
INTEGER(4) :: ProcAddr  
To:  
INTEGER( INT\_PTR\_KIND() ) :: FileAddr  
INTEGER( INT\_PTR\_KIND() ) :: ProcAddr

But then, when I go to use the resulting FAST\_dll.exe and DISCON.dll, I get the following (DISCON is in same directory as all my other files and exe’s)

The DLL DISCON.dll could not be loaded.  
Aborting FAST.  
C:\ADMS2008\Test\_NRELOffshrBsline5MW\_Onshore\>pause  
Press any key to continue . . .

Does anyone have advice for me? Thanks in advance.  
Brian

---

<div class="post-metadata">

**Author:** ![Brian.Resor](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@Brian.Resor](https://forums.nlr.gov/u/Brian.Resor)\
**Post date:** [July 7, 2010, 3:58pm UTC](https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267/2 "2010-07-07T15:58:17Z")

</div>

I looked into this a little more. I’m learning that 32-bit dll’s are not supposed to be compatible with code compiled for 64-bit. If this is true, then the question is whether there is a way to compile the DISCON.f90 into a 64-bit dll. I can’t seem to find much documentation for this.

In the mean time, I installed 32-bit ADAMS 2008r1 and followed compile instructions in the post to Felix.Hess July 2. I was successful getting it all working. That bat file for Felix was key. Thanks very much.

I’d still be interested in the 64-bit route, if it is practical at all.

Brian

---

<div class="post-metadata">

**Author:** ![Marshall.Buhl](https://avatars.discourse-cdn.com/v4/letter/m/f14d63/32.png) [@Marshall.Buhl](https://forums.nlr.gov/u/Marshall.Buhl)\
**Post date:** [July 9, 2010, 9:47pm UTC](https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267/3 "2010-07-09T21:47:01Z")

</div>

> [@Brian.Resor](#):
>
> I’m learning that 32-bit dll’s are not supposed to be compatible with code compiled for 64-bit.

This is not intuitively obvious to me, but I really do not know that much about DLLs.

---

<div class="post-metadata">

**Author:** ![Justin.Madsen](https://avatars.discourse-cdn.com/v4/letter/j/b9e5f3/32.png) [@Justin.Madsen](https://forums.nlr.gov/u/Justin.Madsen)\
**Post date:** [July 9, 2010, 10:36pm UTC](https://forums.nlr.gov/t/fast-and-bladed-dll-64bit/267/4 "2010-07-09T22:36:14Z")

</div>

Since I work with Brian, I’ve been looking into this problem as well. It does seem that 32-bit DLLs are not compatible with 64-bit programs, but there are workarounds. Some information about that is available here:

[dnjonline.com/article.aspx?i … access3264](http://www.dnjonline.com/article.aspx?id=jun07_access3264)

One problem is that pointers, that can be seen in the BladedDLLinterface.f90 code, have different amount of memory associated with them depending on the 32 or 64-bit build chosen (as Brian said).

The real odd thing is that I am able to use the IVF 11.0 64-bit compiler to re-compile the DISCON.dll successfully and without errors. However, I am still unable to run FAST or ADAMS with the re-compiled DLL, and I only get the generic ‘the DLL could not be loaded’ error. Since the Bladed-type DLL uses certain memory spaces to pass data back and forth between the simulator and controller, I’m worried that maybe the memory spaces are unaligned, and the compiler does not pick up on it.

If anyone with DLL experience could comment on this or give us a pointer, it would be greatly appreciated.

-Justin
