简体   繁体   中英

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 quite frustrating I have to manually set COM port number every time. Is there a way of either autodetect of the correct Arudino COM port or maybe communicate with Arduino via other ways, like HID device communication? (Dunno.)

Thanks in advance for your answers/ideas.

Serial communication manager have APIs to find serial port names like COMxx dynamically. Just connect your USB-USRT IC and SCM library will tell you the device node for it. Just google for Serial communication manager. It is hosted on github.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM