On both Windows and OS X we current force users to use 32Bit Java.
On OS X, only Apple's Java 5 and 6 support 32Bit and 64Bit. Oracle's Java 7 for OS X only supports 64Bit. Apple's Java is difficult to install on newer OS X versions. On 64Bit Windows, users usually install Java 64Bit. But the installer helps in forcing them to use Java 32 Bit. However, they also need to install Eclipse 32Bit.
The lack of 64Bit support stems from the fact that the
fantom.dll and the Fantom framework on OS X only come in 32Bit. Note, that the fantom driver is based on NI-VISA on both Windows and OS X. NI-VISA is the VISA implementation by National Instruments.
fantom.dll is just a wrapper around
visa32.dll. Newer versions of NI-VISA (current is 5.4) come with a
visa64.dll which is the 64Bit equivalent of
visa32.dll. On OS X, newer versions of NI-VISA framework support i386 and x86_64 (but neither ppc nor ppc64).
Also, leJOS has problems with the
fantom.dll as simultanious I/O on multiple connections if not supported. This is a limitation of the
fantom.dll which uses the synchronous I/O functions of the VISA API.
fantom.dll uses the following VISA functions:
viFindRsrc viFindNext viOpen viClose viGetAttribute viSetAttribute viOpenDefaultRM viLock viUnlock viRead viWrite
Instead of basing our JNI wrapper on
fantom.dll, use the VISA layer directly. Users would have to install the Fantom driver and then the latest NI-VISA runtime which upgrades the VISA implementation to support both 32 and 64Bit.
A first step would be to write something that is based on the synchronous read/write functions
viWrite. It would suffer from the same limitation as the current fantom-based driver, but it will show whether it's possible to access the NXT through the 64Bit VISA library.
THe second step would be to switch from synchronous I/O via
viWrite to asynchronous I/O via
viWriteAsync. This could allow for simultanious I/O on multiple connections.
Since version 1.2.0, the Fantom driver is based on a NI-VISA version which itself is based on WinUSB, both on 32Bit and 64Bit Windows. WinUSB is a general purpose USB API by Microsoft, very much similar (conceptionally) to libusb on Linux. WinUSB can thus be used to access the NXT. However, this does not provide a solution for OS X.