Questions tagged [jssc]

jSSC (Java Simple Serial Connector) - library for working with serial ports from Java

jSSC supports Win32(Win98-Win8), Win64, Linux(x86, x86-64, ARM), Solaris(x86, x86-64), Mac OS X 10.5 and higher(x86, x86-64, PPC, PPC64).

118 questions
8
votes
3 answers

Get Device Descriptor of SerialPort using jssc

How to get the Device Descriptor of a SerialPort using jssc ( java-simple-serial-connector)? The getPortName() method gives port name (e.g. COM2), but descriptor would be more helpful. If it's necessary to patch this opensource API to get the Device…
Tejas jain
  • 742
  • 7
  • 20
5
votes
1 answer

Serial port with jSSC in linux

I'm trying to work with serial port in java with jSSC. My code: import jssc.SerialPortList; .... String[] ports = SerialPortList.getPortNames(); but it always return empty array. brut@brut-Z97-D3H:~$ dmesg | grep tty [ 0.000000] console [tty0]…
brut
  • 327
  • 1
  • 11
5
votes
4 answers

Slow Arduino serial transmission

I'm testing my Arduino UNO's serial transmission speed. For my requirements I have to transfer 3KB/s from the host PC to the Arduino. I've written a very simple program which replies back the result of Serial.available() and then tested it in the…
NagyI
  • 5,907
  • 8
  • 55
  • 83
3
votes
0 answers

java - jssc can't read from a serial port using event listener

I'm trying to send byte sequences to the serial port, but I can't read the reply from the port itself. I'm sending the same messages with Realterm to handle serial port and it receives replies. I'm also monitoring with serial port monitor by…
edo1080
  • 61
  • 7
3
votes
1 answer

Java - get COM port id

I'm writing a java program, and right now I have a setup-file which contains a COM port number. which has to be changed if the device changes COM port number. This is not very user friendly. Therefore I want to be able to get a list of COM port ID's…
Zeliax
  • 4,987
  • 10
  • 51
  • 79
3
votes
1 answer

Automatic detection of Arduino COM port in JAVA (preferably via JSSC)

I wonder if there is a way to somehow automatically find a COM port which Arduino device is connected to. (Like it is done in Arduino IDE) I have a piece of code which is working with Arduino via serial communication (using JSSC library) and it is…
Mike D
  • 31
  • 2
3
votes
1 answer

RFID - Incomplete output?

I've been testing and working on my RFID scanner code and I found something weird. When I tap the card, there are some instances where the results are truncated. Examples: Tap 1: [2]1,000,007 ,000242985 Tap 2: 7[3][2]1,000,0 07,0002429 Tap…
Bumpy
  • 97
  • 11
3
votes
1 answer

Documentation for serial library in processing.py

Is there some documentation for Processing.py's Serial library? I've been able to guess some of the syntax from the Java Serial library doc. Here's what I have so far: add_library('serial') def setup(): #setup the serial port print…
ericksonla
  • 1,247
  • 3
  • 18
  • 34
3
votes
1 answer

Java Simple Serial Connector (jSSC): getInputBufferBytesCount returns zero

When using the Java Simple Serial Connector (jSSC) library, SerialPort.getInputBufferBytesCount() always returns zero, even when there are bytes in the buffer. Probably related to this, readBytes() never returns any bytes. The readBytes(byteCount)…
PaulJNewell
  • 239
  • 3
  • 9
3
votes
1 answer

JSSC Exception: no libjssc in java.library.path

I've had been using JSSC Connector for serial and I got the Next Exception: Exception in thread "main" java.lang.UnsatisfiedLinkError: no libjssc in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at…
molavec
  • 8,848
  • 1
  • 27
  • 22
2
votes
1 answer

How to add a Library in the main module [module-info.java]?

I use the jssc package to access serial port. I added it to the main module module DeskCheck { requires java.desktop; requires java.logging; requires jssc; } But I believe I am doing it wrong, because there is an error saying that module does…
user12096355
2
votes
1 answer

How to retrieve the value from the event listener from another class in java?

I have a program to get the values from a Bar code scanner(using jssc library) and it returns value as expected using event listener but I need to access that value from another class. I tried to instantiate BarcodeScanner class to main method…
sanki
  • 59
  • 2
  • 9
2
votes
0 answers

How should I declared data in Java that was captured from communication with USB?

I'm using the jSSC library to set up a connection via USB port. I used a Windows application Device Monitoring Studio to capture what a certain Windows program sends to a device. Here's screenshot of captured data: Here's my question: how should I…
menteith
  • 596
  • 14
  • 51
2
votes
0 answers

Writing data to Arduino Uno with jSSC

I'm writing a piece of code in Java using jSSC for serial communication, but I don't know what I'm doing wrong. Basically I have to send a 32k file to an Arduino Uno and the Arduino has to process the data and send all bytes to an external device. I…
Geration
  • 21
  • 1
2
votes
0 answers

Received Byte array not always correct

I have an Arduino program that sends via Bluetooth a byte array to a Java program. The Java program receives the data on JSSC. The array is 72 bytes long (18 floats a´ 4byte). How JSSC recognizes the end of transmission, or know that a new byte…
1
2 3 4 5 6 7 8