简体   繁体   English

无法使用 Visual Studio 2019 ssh 调试树莓派 4

[英]Cannot use visual studio 2019 ssh debug with raspberry pi 4

I'm using Visual Studio and Raspberry PI 4 for my personal project.我将Visual StudioRaspberry PI 4用于我的个人项目。 For now, I'm making a small console application and successfully copied and ran on Raspberry PI 4 I'm following this tutorial to setup remote debugger from Visual Studio 2019 to my Raspberry PI 4 .现在,我正在制作一个小型控制台应用程序,并成功复制并在Raspberry PI 4上运行。我正在按照本教程将远程调试器从Visual Studio 2019设置到我的Raspberry PI 4

Everything seemed to be fine, until I Attach to process When I entered my Raspberry information and click on Connect, there is one error popup appeared:一切似乎都很好,直到我附加到进程当我输入我的树莓信息并单击连接时,出现了一个错误弹出窗口:

在此处输入图像描述

Unable to connect to pi@raspberrypi.无法连接到 pi@raspberrypi。 An operation is not legal in the current state .当前 state 中的操作不合法

With the input information, I can remote to my Raspberry normally.通过输入信息,我可以正常远程访问我的树莓派。

Anything wrong with my settings?我的设置有什么问题吗?

Thank you,谢谢,

Thanks to Alan Shurack (from the microsoft forums) there is a workaround for the problem of the Ssh debugging in Visual Studio 2019 [16.7.2] (It defenetly worked at version [16.5.4])感谢 Alan Shurack(来自微软论坛),有一个解决方法可以解决 Visual Studio 2019 [16.7.2] 中 Ssh 调试问题(它在 [16.5.4] 版本中确实有效)

Workaround:解决方法:

Adding and connecting to the connection under Tools->Options->Cross Platform->Connection Manager will solve the problem.在 Tools->Options->Cross Platform->Connection Manager 下添加并连接连接即可解决问题。

Search for "Edit and Set Default Remote SSH Connections" in the release notes: https://devblogs.microsoft.com/visualstudio/visual-studio-2019-v16-7-releases/在发行说明中搜索“编辑和设置默认远程 SSH 连接”: https://devblogs.microsoft.com/visualstudio/visual-studio-2019-v16-7-releases/

The issue with visual studio is being fixed and can be viewed in this thread https://developercommunity.visualstudio.com/content/problem/1161746/attach-to-process-using-ssh-not-working-visual-stu.html视觉工作室的问题正在修复中,可以在此线程中查看https://developercommunity.visualstudio.com/content/problem/1161746/attach-to-process-using-ssh-not-working-visual-stu.htmlFC

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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