microsoft / vscode-iot-workbench

Azure IoT Device Workbench for Visual Studio Code
170 stars 74 forks source link

Setting the Device Connection String doesn't work through vscode on MacOS #437

Closed JosephPaulAntonetti closed 5 years ago

JosephPaulAntonetti commented 6 years ago

macOS Mojave on MacBook Pro 2016.

When I attempt to set the connection string on the device through the IoT Device menu, the connection string is not set. However, manually setting the connection string by connecting via serial and stepping through configuration does work.

Sneezry commented 6 years ago

This is a known issue on macOS. We use screen command to connect to serial port on macOS. Sometimes, screen doesn't connect to serial port correctly. This issue may be related with macOS. And we do not have a good solution currently, yet.

lirenhe commented 6 years ago

Could you open command line and type screen /dev/cu.usbserial 115200 and check the result? Please replace /dev/cu.usbserial with the serial port of IoT Devkit.

JosephPaulAntonetti commented 6 years ago

@lirenhe - The result of the command shows me a list of things I can do (configure WiFi, set connection string, etc.).

@Sneezry - That's fair. Maybe add something in the docs to note the workaround (going into terminal and manually changing the connectionString)?

wgcv commented 5 years ago

Connect the board and try in the terminal:

ls /dev/cu.usbmodem*
screen /dev/cu.usbmodemXXXX 115200 –L
set_az_iothub [device connection string ]

The Device connection string is in azure azure: Home -> All resources -> XXX- IoT devices -> Device details

lirenhe commented 5 years ago

We will provide the workaround for MacOS serial port problem in DevKit-SDK. https://github.com/Microsoft/devkit-sdk/issues/931

Sneezry commented 5 years ago

Fixed https://github.com/Microsoft/vscode-iot-workbench/pull/495