• Post Reply Bookmark Topic Watch Topic
  • New Topic

Problem read Foot Pedal Action using RXTX  RSS feed

 
Fandy Akhmad
Ranch Hand
Posts: 32
Java Linux MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have foot pedal from endoscopy medical machine. And it use RS232 serial port. And i connected using USB Serial Controller. I found library RXTX that handle serial port.

I already try the sample code from RXTX wiki, like this :



But i wonder, how to handle event listener, when foot pedal is touched/clicked?

Please help me, thanks before
 
Richard Tookey
Bartender
Posts: 1166
17
Java Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't understand your question! You already are handling the events! What problem with this are you experiencing?

You should note that many USB to RS232 adaptors do not provide true RS232 signal levels and may not work with devices that do need proper RS232 signal levels. Also, you need to establish the pedal parameters such as baud rate, number of stop bits, parity and handshaking method. If , as I suspect, you don't have a data sheet for the pedal then you can determine the parameters using an oscilloscope.
 
Fandy Akhmad
Ranch Hand
Posts: 32
Java Linux MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Richard Tookey wrote:I don't understand your question! You already are handling the events! What problem with this are you experiencing?

You should note that many USB to RS232 adaptors do not provide true RS232 signal levels and may not work with devices that do need proper RS232 signal levels. Also, you need to establish the pedal parameters such as baud rate, number of stop bits, parity and handshaking method. If , as I suspect, you don't have a data sheet for the pedal then you can determine the parameters using an oscilloscope.


I am new in serial programming in Java.
I try that code, but if i click foot pedal, it not do anything.

Thank you
 
Richard Tookey
Bartender
Posts: 1166
17
Java Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Fandy Akhmad wrote:
I try that code, but if i click foot pedal, it not do anything.


Then the chances are you are not providing the correct configuration parameters and/or signal levels and/or handshaking and/or wiring and the datasheet for the device will give you the required information. As I said before, in the absence of a data sheet fo you need to examine what the device is outputting maybe using an oscilloscope. From this side of the Internet I can't really help any further!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!