I just compiled the rxtx v2.2pre3 library (I just call it that way, its the cvs head from 31.6.2010). There are binaries for win32, win64 (untested) and Mac OSX in the package:
1 2 3 4 5 | # file librxtxSerial.jnilib librxtxSerial.jnilib: Mach-O universal binary with 3 architectures librxtxSerial.jnilib (for architecture x86_64): Mach-O 64-bit dynamically linked shared library x86_64 librxtxSerial.jnilib (for architecture i386): Mach-O dynamically linked shared library i386 librxtxSerial.jnilib (for architecture ppc7400): Mach-O dynamically linked shared library ppc |
The maximal serial speed for MacOs X is 230400 (check the file /Developer/SDKs/MacOSX10.6.sdk/usr/include/sys/termios.h) – but I wasn’t able to communicate with my Arduino at this speed. 115200 baud works fine. Any hints how to fix this?
For your viewing pleasure, here is the changelog since v2.1.7 (Jan 29 2006):
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 | 2.2 ??? Deamon Monitor thread. http://mailman.qbang.org/pipermail/rxtx/2009-November/5481981.html Ivan Maidanski <ivmai@mail.ru> 64 bit/ 32 bit fallback of loadlibrary Nathan A. Sweet <nate@n4te.com> http://mailman.qbang.org/pipermail/rxtx/2009-November/5482004.html regenerated gnu_io_RXTXPort.h and gnu_io_RXTXCommDriver.h; changed version string returned nativeGetVersion(); moved nativeGetVersion() to RXTXVersion; added native_psmisc_report_owner() (same as for Win32); removed unnecessary GetLastError() calls; added explicit WCHAR-to-jchar casts (and vice versa) where the compiler complains (same for LPWSTR and for "const" qualifier); adjusted some debugging messages (to also print returned error code); wrapped remaining printed error messages (and MessageBeep) into IF_DEBUG(); made printj() defined only if DEBUG; replaced trailing "n" with "rn" in printj(); replaced "I" type char with "J" one for "eis" field; replaced get_java_int_var() with get_java_var_long(); changed nativeSetSerialPortParams() returned type to jboolean; added nativeClearCommInput() and readTerminatedArray() stubs (these should be implemented in future); removed "MonitorThreadCloseLock" field usage in eventLoop(); commented out unused throw_java_exception(), get_java_boolean_var2() and removed get_java_boolean_var(); replaced Sleep(0) call with Sleep(1) one in CommEventThread() ( to make yielding a bit "more reliable" among threads with different priorities); replaced named event with an unnamed one in InitialiseEventInfoStruct() (see the note below); added new JAVAXCOMM_FRONTEND macro for convenience (if defined then PortInUseException and UnsupportedCommOperationException are used "javax.comm" package (old behavior) else from "gnu.io." one (default)); commented out DllMain() definition (since it does no action, only consumes resources); updated Readme. WinCE compilation fixes an updates readArray() simplified loop/fix pointer Ivan Maidanski <ivmai@mail.ru> http://mailman.qbang.org/pipermail/rxtx/2009-November/5411487.html http://mailman.qbang.org/pipermail/rxtx/2009-November/5411492.html http://mailman.qbang.org/pipermail/rxtx/2009-November/5411490.html http://mailman.qbang.org/pipermail/rxtx/2009-November/5411496.html Windows build improvements (MinGW32, MSVC and LCC) Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-September/4822418.html Implemented return value to checking to file I/O calls Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-September/4822416.html Removed unused MathWorks MATLAB timing debug (DEBUG_MW) Fixed DEBUG_TIMING Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-September/4822414.html Fix build on Linux systems without UTS_RELEASE (linux/utsrelease.h) Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-September/4816749.html Apple Xcode 3.x project Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-September/4811084.html YACK() debug overflow fix for windows Steffen DETTMER <Steffen.DETTMER@ingenico.com> Multiport fix for Windows Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-February/3989441.html Fix for SIGSEGV at SerialImp.c Solaris/mac/*bsd Ilkka Myller <ilkka@myller.com> http://mailman.qbang.org/pipermail/rxtx/2009-February/4810504.html Let people know which port is in use on windows. WriteFile fix for Parallel ports on windows. Johnny Luong <johnny.luong@trustcommerce.com> Solaris static libgcc link configure fix. 64 bit JNI Fixes <dan.sandberg.lists@gmail.com> Dan Sandberg http://mailman.qbang.org/pipermail/rxtx/2007-June/3676251.html Maintain DTR=false during setSerialPortParams Beat Arnet <beat.arnet@gmail.com> http://mailman.qbang.org/pipermail/rxtx/2009-January/3682508.html http://bugzilla.qbang.org/show_bug.cgi?id=104 Avoid debug sprintf overflows on win32. http://mailman.qbang.org/pipermail/rxtx/2009-January/3682496.html Luis Pires <lpdev@ruabrasil.org> disable dcb.fDtrControl to avoid unexpected behavior. Beat Arnet <beat.arnet@gmail.com> http://bugzilla.qbang.org/show_bug.cgi?id=104 threshold fix Alexandre Rusev <cyberflex@mail.ru> http://bugzilla.qbang.org/show_bug.cgi?id=85 RXTX close deadlocks in REXTXPort.finalize Joachim Buechse <joachim@buechse.de> http://bugzilla.qbang.org/show_bug.cgi?id=53 Add ACM serial devices to all known ports. Duncan Pierce <duncan.pierce@syntropy.co.uk> http://bugzilla.qbang.org/show_bug.cgi?id=51 Concurrency fixes for SMP/multicore systems U. George <netbeans@gatworks.com> http://bugzilla.qbang.org/show_bug.cgi?id=100 Fixes for MAC systems with no drivers installed. 1.5 stop bit fix Enable universal library builds for Mac OS X Andre-John Mas ajmas@sympatico.ca http://mailman.qbang.org/pipermail/rxtx/2007-December/1793319.html Do not remove and ignore interrupts. Joachim Buechse <joachim@buechse.de> http://bugzilla.qbang.org/show_bug.cgi?id=45 find ports which were added after program startup on Mac OS X. Martin Oberhuber <martin.oberhuber@windriver.com> http://bugzilla.qbang.org/show_bug.cgi?id=48 Clean up CommPort Ownership code, avoid possible deadlocks, fix lost commport ownership events. Martin Oberhuber <martin.oberhuber@windriver.com> http://bugzilla.qbang.org/show_bug.cgi?id=83 rxtx does not compile against JDK-1.6 Nebojøa <nebojsa@anja.ig3.net> http://bugzilla.qbang.org/show_bug.cgi?id=84 configure script failed at line UTS_RELEASE megov <megov@mail.ru> http://bugzilla.qbang.org/show_bug.cgi?id=80 code cleanup patch (extra ';' creates bug for if statements + new String() calls removed) Xavier Le Vourch <xavier@brittanysoftware.com> http://bugzilla.qbang.org/show_bug.cgi?id=77 Wont compile on linux ppc with glibc 2.5 - no sys/io.h Brian Johnson <site-rxtx.org@sherbang.com> http://bugzilla.qbang.org/show_bug.cgi?id=72 rxtx overwrites System properties Andrew Gillett <asgillett@gmail.com> Nektarios K. Papadopoulos <npapadop@inaccessnetworks.com> Nebojøa <nebojsa@anja.ig3.net> http://bugzilla.qbang.org/show_bug.cgi?id=64 Solaris ACM port support Dave Cleal <dc@cleal.com> http://bugzilla.qbang.org/show_bug.cgi?id=59 Setting of non-standard baud rate fails. Andrew Prunicki <aprunicki@yahoo.com> http://bugzilla.qbang.org/show_bug.cgi?id=58 RXTX uses lockfiles on MacOS X (instead of ioctl TIOCEXCL) Joachim Buechse <joachim@buechse.de> http://bugzilla.qbang.org/show_bug.cgi?id=50 JavaDoc fixes Joachim Buechse <joachim@buechse.de> http://bugzilla.qbang.org/show_bug.cgi?id=49 need to review: http://bugzilla.qbang.org/show_bug.cgi?id=53 http://bugzilla.qbang.org/show_bug.cgi?id=46 http://bugzilla.qbang.org/show_bug.cgi?id=41 |
Edit 8.2.2011:
- librxtx works fine with the baudrate 921600.
- Make sure your /System/Library/Java/Extensions/ directory does not contain old versions!
- do not rename old version, delete them!!!!




[...] used my Processing library and some custom Java code (using rxtx library) to display animations (amongst others is use the blinkenlights library) on the rainbowduino. This [...]
your 64-bit works fine but you need to update RXTX Version in the jar file. Currently a warning is given as follows:
WARNING: RXTX Version mismatch
Jar version = RXTX-2.2
native lib Version = RXTX-2.2pre3
It would be nice if this is corrected. Keep me updated please.
I know – it’s because the native library is not yet final but the java lib is. So no need to fix this.
For some reason when I try to use the 2.2 library my JVM crashes when it goes to initialize the RXTX drivers. Any Idea what would cause this? This is on Win32 XP.
I am using 2.1.7 Ok.
Hi, I am having problems with rxtx 2.2pre2 when i have more than two open serial ports at the same time. The system crashes and closes:
A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000005cbc71cd, pid=2924, tid=3880
#
# JRE version: 6.0_16-b01
# Java VM: Java HotSpot(TM) 64-Bit Server VM (14.2-b01 mixed mode windows-amd64 )
# Problematic frame:
# C [rxtxSerial.dll+0x71cd]
I tried to update to your 2.2pre3 version but it didn’t solve the problem. Do you have any idea what could be happening?
Its a bug in the c part of the library- try to send the bug report to the rxtx mailing list.
[...] are you still afraid? This is another rxtx library release based on my previous release. This new version improves the “serial event callback function” and thus reduce the [...]