Ich habe es jetzt hinbekommen.
Im RXTX-Wiki habe ich ein Programmbeisspiel gefunden, das funktioniert. Ich habe das ganze getestet, indem ich meinen PC mit meinem Laptop über RS232 verbunden habe. Am Hyperterminal konnte ich dann sehen, dass mein PC den Text sendet. Aber eigentlich wollte ich mit dem Programm das RN-Motorcontrol ansteuern aber das funktioniert nicht.
Hier ist der Code vielleicht kann mir ja jemand sagen warum es nicht geht:
Code:
import java.io.*;
import java.util.*;
import gnu.io.*; 


public class RXTX {
    static Enumeration	      portList;
    static CommPortIdentifier portId;
    static String	      messageString = "##; Chr(3); Chr(2); Chr(3); Chr(100)";
    static SerialPort	      serialPort;
    static OutputStream       outputStream;
    static boolean	      outputBufferEmptyFlag = true;
   
    public static void main(String[] args) {
	boolean portFound = false;
	String  defaultPort = "COM1"; 

	if (args.length > 0) {
	    defaultPort = args[0];
	} 

	portList = CommPortIdentifier.getPortIdentifiers();

	while (portList.hasMoreElements()) {
	    portId = (CommPortIdentifier) portList.nextElement();

	    if (portId.getPortType() == CommPortIdentifier.PORT_SERIAL) {

		if (portId.getName().equals(defaultPort)) {
		    System.out.println("Found port " + defaultPort);

		    portFound = true;

		    try {
			serialPort = 
			    (SerialPort) portId.open("SimpleWrite", 2000);
		    } catch (PortInUseException e) {
			System.out.println("Port in use.");

			continue;
		    } 

		    try {
			outputStream = serialPort.getOutputStream();
		    } catch (IOException e) {}

		    try {
			serialPort.setSerialPortParams(9600, 
						       SerialPort.DATABITS_8, 
						       SerialPort.STOPBITS_1, 
						       SerialPort.PARITY_NONE);
		    } catch (UnsupportedCommOperationException e) {}
	

		    try {
		    	serialPort.notifyOnOutputEmpty(true);
		    } catch (Exception e) {
			System.out.println("Error setting event notification");
			System.out.println(e.toString());
			System.exit(-1);
		    }
		    
		    
		    System.out.println(
		    	"Writing \""+messageString+"\" to "
		    				+serialPort.getName());
		    		   
		    try {
			outputStream.write(messageString.getBytes());
			
		    } catch (IOException e) {}

		    try {
		       Thread.sleep(100);  // Be sure data is xferred before closing
		    } catch (Exception e) {}
		    serialPort.close();
		    System.exit(1);
		} 
	    } 
	} 

	if (!portFound) {
	    System.out.println("port " + defaultPort + " not found.");
	} 
    } 
}