discovery icon indicating copy to clipboard operation
discovery copied to clipboard

Serial Communication now working on MacOS

Open kianenigma opened this issue 5 years ago • 2 comments

  • MacOS 10.15.4
  • my board is new revision; I needed to connect BP3 is explained here to enable itdump.
$ ls -l /dev/cu.*
crw-rw-rw-  1 root  wheel    9,   7 May  2 16:45 /dev/cu.usbmodem143403

and I actually have both tty.x and cu.x

ls /dev | rg "usbmodem143403"
cu.usbmodem143403
tty.usbmodem143403
  • board connected via USB-STLINK.
  • echo-ing into either of the above just hangs, and the terminal never exits anymore, even with ctrl-c.
  • During all stages, I have openocd open.
  • also, when minicom is connected to the tty variant above, with the loopback enabled (shorting PC4 and PC5), I cannot see anything as I type. Consequently, I've tried section 11.1 and the one byte is not transmitted back to the host

Perhaps something with the macos setup is broken?

kianenigma avatar May 02 '20 15:05 kianenigma

I'm also stuck at section 10. I think at this step we just need the USB to serial module plugged in, nothing to the discovery board. However, it's just hanging for me as well.

The echo/minicom commands freeze the terminal forever whether I'm using the cu or tty file under /dev.

Mine dev usb devices look like this:

❯ ls -l /dev | grep usb
crw-rw-rw-  1 root  wheel           18,   5 May  9 09:23 cu.usbserial-0001
crw-rw-rw-  1 root  wheel           18,   4 May  9 09:23 tty.usbserial-0001

Edit: I jumped ahead to the loopback step and it no longer hangs. Seems like MacOS might be doing something extra.

mlh758 avatar May 09 '20 14:05 mlh758

OK so I followed @mlh758's advice and I jumped ahead to the loopback section of the book. Once I shorted PC4 and PC5 my terminal successfully returned after issuing the echo:

echo 'Hello, world!' > /dev/cu.usbmodem14403

wbuck avatar Dec 10 '20 19:12 wbuck