# Serial.list() not showing USB ports (available serial ports)

**URL:** <https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429>\
**Category:** Electronics (Arduino, etc.)\
**Created:** [May 23, 2025, 2:43am UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429 "2025-05-23T02:43:57Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![newuser](https://avatars.discourse-cdn.com/v4/letter/n/3e96dc/32.png) [@newuser](https://discourse.processing.org/u/newuser)\
**Post date:** [May 23, 2025, 2:43am UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/1 "2025-05-23T02:43:57Z")

</div>

Windows 11 (auto update)  
Processing 4.4.4

I have two USB ports available, and both work with other hardware not related to Processing (mouse, USB printer, USB memory, battery tester, audio player, Arduino, ESP). Using this sketch, I expected to see both ports, but see nothing in the “console” or “errors” windows of the Processing IDE.

```auto
import processing.serial.*;
printArray(Serial.list());

```

The Reference Page for `Serial.list()` says to use `println();`, so I tried that, too, but the same results: nothing in the command line. I copied the command line and pasted it into the IDE as well as Notepad (hoping for inverse color text) but that only showed ten, empty, `CRLF`.

I tried searching the forum, but found nothing pointing me to my error, for example, did I neglect to configure my IDE for using `Serial` or `import` a library?

The IDE:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/d/e/de56efab9ae76dcab7f0b115eb639014e2840576.png)  
The output window:  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/9/e/9e6174fd895c851db4fedee8232d4893ce548a3c.png)

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [May 23, 2025, 11:30am UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/3 "2025-05-23T11:30:14Z")

</div>

Works ok on MacOS. Output is in console.

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [May 24, 2025, 4:27pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/4 "2025-05-24T16:27:37Z")

</div>

Hello,

It works on W10 and W11 with Processing 4.4.4

`:)`

---

<div class="post-metadata">

**Author:** ![George](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/george/32/5858_2.png) [@George](https://discourse.processing.org/u/George)\
**Post date:** [May 26, 2025, 12:47pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/5 "2025-05-26T12:47:58Z")

</div>

@newuser What operating system (including version) and CPU architecture (x86/ARM) is your system using ?

Have you double checked the serial ports show up correctly using the OS/terminal ?  
(This would help isolate the issue (e.g. is with Processing or with the OS (e.g. permissions to access serial devices, etc.))

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [May 26, 2025, 3:51pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/6 "2025-05-26T15:51:02Z")

</div>

`Have you double checked the serial ports show up correctly using the OS/terminal ?`  
Good idea; on a mac you would type `ls /dev/tty/.*` on the command line in Terminal if you don’t already know.

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [May 27, 2025, 12:32am UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/7 "2025-05-27T00:32:48Z")

</div>

Hello folks,

Some additional ways to check for COM ports on Windows systems.  
If the COM port exists then Processing (Java) should be able to see it.

@newuser ,  
Looking forward to how you resolved this.

_ **Windows** _

PowerShell:

> Get-WmiObject Win32\_SerialPort | Select-Object Name,Description

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/8/c/8c9e460f8eb3073058ed86a71654e2f01919666a.png)

Command Prompt:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/3/d/3d9298c8568e60502ee692944de69c40a7f73886.png)

Device Manager:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/c/5/c55edc7d6be4b686139b5789df91b9f855d93d9e.png)

Windows Settings:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/8/2/82c2c6a85f28422eb829836cd19007b9645cd024.png)

I miss any for Windows?

_ **Processing** _

List the COM ports using the _jSerialComm library_ :  
_[More details about COM ports - #3 by glv](https://discourse.processing.org/t/more-details-about-com-ports/43714/3)_

List the COM ports using the Processing Serial Library:  
_[list() / Libraries / Processing.org](https://processing.org/reference/libraries/serial/Serial_list_.html)_

`:)`

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [May 27, 2025, 10:46pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/9 "2025-05-27T22:46:34Z")

</div>

> [@George](#):
>
> Have you double checked the serial ports show up correctly using the OS/terminal ?

Hi George!

I was not connecting the dots right away when you said terminal since I mostly use Windows and not used Linux in a while. Was thinking of old school HyperTerminal as the “terminal software\emulator” for connecting to COM ports.

All is clear now for Windows environment:

> **[Command Prompt and Windows Powershell - Microsoft Support](https://support.microsoft.com/en-us/windows/command-prompt-and-windows-powershell-6453ce98-da91-476f-8651-5c14d5777c20)**

I have a brand new W11 PC and slowly migrating over to it.

Windows Terminal does not connect to a COM port but I can use everything from my last post easily enough!

`:)`

---

<div class="post-metadata">

**Author:** ![PhilHaw](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/philhaw/32/8221_2.png) [@PhilHaw](https://discourse.processing.org/u/PhilHaw)\
**Post date:** [May 28, 2025, 12:52pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/10 "2025-05-28T12:52:11Z")

</div>

The example code (or if using println) does show the results in the Processing **console** window, though not in the output window.

---

<div class="post-metadata">

**Author:** ![George](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/george/32/5858_2.png) [@George](https://discourse.processing.org/u/George)\
**Post date:** [May 28, 2025, 2:58pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/11 "2025-05-28T14:58:25Z")

</div>

Great work providing detailed steps with images: this will be super helpful for other users as well! 🙌

FWIW, when doing basic serial tests (e.g. outside of Processing) I used [CoolTerm](https://freeware.the-meiers.org/):

- it has executables for multiple operating systems
- you can scan/check ports of course
- once connected, you can send messages (`Ctrl/CMD + T`) and see the output, but also switch between ASCII and bytes (HEX view) which super useful when debugging binary serial protocols.

(Alternatively, if Python is an option [PySerial’s `python -m serial.tools.list_ports`](https://pyserial.readthedocs.io/en/latest/tools.html) is handy (and the grep option can be handy to get consistent ports using Vendor ID (VID) and Product ID (PID) info on OSes where the name of the port may change))

HTH

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [May 28, 2025, 5:27pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/12 "2025-05-28T17:27:48Z")

</div>

> [@PhilHaw](#):
>
> The example code (or if using println) does show the results in the Processing **console** window, though not in the output window.

Hello @PhilHaw,

Terminology can be challenging, especially for users who are new to this environment.

Reference:

> **[list() / Libraries](https://processing.org/reference/libraries/serial/serial_list_)**
>
> Gets a list of all available serial ports. Use println() to write the information to the text window.

The description may not be clear for a new user.

The “text window” should be the \*console" which is a panel at the bottom of the PDE (Processing Development Environment) which is also referred to as the Processing IDE (Integrated Development Environment).

Code to display to _ **console** _ and _ **display/sketch/output window** _:

Output:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/2/f/2f55f0ce994dce42d5f41f3067201812610a6dba.png)  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/7/c/7c405e0fab7816e28753473f5768768a8c8ccdcd.png)

`:)`

---

<div class="post-metadata">

**Author:** ![newuser](https://avatars.discourse-cdn.com/v4/letter/n/3e96dc/32.png) [@newuser](https://discourse.processing.org/u/newuser)\
**Post date:** [June 1, 2025, 1:47am UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/13 "2025-06-01T01:47:43Z")

</div>

> [@George](#):
>
> CPU

Lenovo laptop Intel CPU.  
Processing works great. I have not yet learned enough to do comms (put on hold) or console stuff.

Permissions for hardware seem “admin” level. I run various hardware on the USB ports. Usually shows COM3.

Thank you for the help. It gives me places to look.

---

<div class="post-metadata">

**Author:** ![newuser](https://avatars.discourse-cdn.com/v4/letter/n/3e96dc/32.png) [@newuser](https://discourse.processing.org/u/newuser)\
**Post date:** [July 7, 2025, 2:51pm UTC](https://discourse.processing.org/t/serial-list-not-showing-usb-ports-available-serial-ports/46429/14 "2025-07-07T14:51:15Z")

</div>

> [@glv](#):
>
> how you resolved this.

Thank you for all your replies!

The solution is: an “ardiuono” type device must be in the COM port.

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/8/1/81d761df2298760508733fc646aaec0e257f7356.png)

I wrongly thought the USB wifi device I use for my mouse would suffice to give me a COM output from Processing.

I still to not get a list of all the possible ports… maybe this is a way for the OS (WIN11) to save memory or cycles… and when I am in the Arduino IDE, this COM3 shows as COM5… so there is could some OS magic involved.

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/f/6/f62ce5883b760b3c6bbccb5aadb215866cf06933.png)

> [@glv](#):
>
> PowerShell:

This command (with Nano inserted) yielded no response (not like post # May26):

```auto
PS C:\Users\newuser> Get-WmiObject Win32_SerialPort | Select-Object Name,Description
PS C:\Users\newuser>

```

… and using ‘mode’…

```auto
PS C:\Users\newuser> mode

Status for device COM3:
-----------------------
    Baud: 19200
    Parity: None
    Data Bits: 8
    Stop Bits: 1
    Timeout: OFF
    XON/XOFF: OFF
    CTS handshaking: OFF
    DSR handshaking: OFF
    DSR sensitivity: OFF
    DTR circuit: ON
    RTS circuit: ON

Status for device CON:
----------------------
    Lines: 30
    Columns: 120
    Keyboard rate: 31
    Keyboard delay: 1
    Code page: 437

```

> [@George](#):
>
> Python is an option

Python is beyond the scope of my brain… sorry.

Thank you for all the help. Here is my second sketch (first = `helloworld.pde`, of course) which I was tinkering with in my long absence, learning primative shapes by displaying the shape inside a given boundary (stroke width, shape, diameter do not cause boundary overlap)

```auto
// draw "primatives" in specific quadrants

int cols = 3; // grid columns
int rows = 2; // grid rows
float colWidth, rowHeight, halfWidth, halfHeight;

void setup() {
  //size(280, 320); // tft
  size(800, 800);
  fill(255, 256 * .3); // shape transparency

  colWidth = width / cols;
  rowHeight = height / rows;
  halfWidth = colWidth / 2; // to calculate offset from center
  halfHeight = rowHeight / 2;

  drawGrid(cols, rows);
}

void drawGrid(int c, int r) {
  stroke(256 * .7); // border darkness
  for (int i = 0; i < c; i++)
    line(colWidth * i, 0, colWidth * i, height); // vertical lines
  for (int i = 0; i < r; i++)
    line(0, rowHeight * i, width, rowHeight * i); // horizontal lines
}

void draw() {
  stroke(random(256), random(256), random(256));
  qPoint(0, 11); // (quadrant, pointWidth)
  qLine(1); // (quadrant)
  qRect(2); // (quadrant)
  qTri(3); // (quadrant)
  qEllipse(4); // ellipse
  // q6(); // arc
  // q7(); // quad
}

void qEllipse(int quadrant) { // ellipse
  float colNum = quadrant % cols; // remainder = column
  float rowNum = quadrant / cols; // quotient = row
  float startX = colNum * colWidth;
  float startY = rowNum * rowHeight;

  float ex = random ((startX ) + 1, (colNum + 1) * colWidth); // (+1 pixel, +1 column)
  float dx = random (halfWidth - abs(halfWidth - (ex - (colNum * colWidth))));

  float ey = random ((startY) + 1, (rowNum + 1) * rowHeight); // (+1 pixel, +1 row)
  float dy = random (halfHeight - abs(halfHeight - (ey - (rowNum * rowHeight))));

  ellipse(ex, ey, dx, dy);
}

void qTri(int quadrant) { // triangle
  float colNum = quadrant % cols; // remainder = column
  float rowNum = quadrant / cols; // quotient = row
  float startX = colNum * colWidth;
  float startY = rowNum * rowHeight;

  float tx0 = random (startX + 1, colWidth * (colNum + 1)); // (+1 pixel, +1 column)
  float ty0 = random (startY + 1, rowHeight * (rowNum + 1)); // (+1 pixel, +1 row)
  float tx1 = random (startX + 1, colWidth * (colNum + 1)); // (+1 pixel, +1 column)
  float ty1 = random (startY + 1, rowHeight * (rowNum + 1)); // (+1 pixel, +1 row)
  float tx2 = random (startX + 1, colWidth * (colNum + 1)); // (+1 pixel, +1 column)
  float ty2 = random (startY + 1, rowHeight * (rowNum + 1)); // (+1 pixel, +1 row)
  triangle(tx0, ty0, tx1, ty1, tx2, ty2);
}

void qRect(int quadrant) { // rect
  float colNum = quadrant % cols; // remainder = column
  float rowNum = quadrant / cols; // quotient = row
  float startX = colNum * colWidth;
  float startY = rowNum * rowHeight;

  float rx = random (startX + 1, colWidth * (colNum + 1)); // (+1 pixel, +1 column)
  float ry = random (startY + 1, rowHeight * (rowNum + 1)); // (+1 pixel, +1 row)
  float rw = random (colWidth - (rx - (startX)));
  float rh = random (rowHeight - (ry - (startY)));
  rect(rx, ry, rw, rh);
}

void qLine(int quadrant) { // line
  float colNum = quadrant % 2;
  float rowNum = quadrant / 2;
  float startX = colNum * colWidth;
  float startY = rowNum * rowHeight;

  float lx0 = random(startX + 1, (colNum + 1) * colWidth);
  float ly0 = random(startY + 1, (rowNum + 1) * rowHeight);
  float lx1 = random(startX + 1, (colNum + 1) * colWidth);
  float ly1 = random(startY + 1, (rowNum + 1) * rowHeight);
  line(lx0, ly0, lx1, ly1);
}

void qPoint(int quadrant, int pointWidth) { // point
  strokeWeight(pointWidth);
  float halfStroke = pointWidth / 2;
  float colNum = quadrant % 2;
  float rowNum = quadrant / 2;
  float startX = colNum * colWidth;
  float startY = rowNum * rowHeight;

  float px = random(startX + halfStroke + 1, (colNum + 1) * colWidth - halfStroke);
  float py = random(startY + halfStroke + 1, (rowNum + 1) * rowHeight - halfStroke);
  point(px, py);
  strokeWeight(1);
}

void pad (int val) { // print values in column alignment
  //if (val < 1000 && val > -100) print(" ");
  if (val < 100 && val > -10) print(" ");
  if (val > -1 && val < 10) print(" ");
  print(int(val));
}

```

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/3/c/3c394ad00d5f7f8ce88376a90a926682748dec0b.jpeg)

This “random shapes inside the adjustable grid” exercise was to learn how to place an object anywhere on a given-size screen (or portion of the screen), so when I get the comms between Arduino and Processing working, I can present the data in graphical form.

Thank you, again!
