< P> Мне удалось установить ОС PI (32 -битный на PI 3B+), а также SSH, используя клавиши RSA, время выполнения .NET и отладчик, используя следующие команды: < /p>
Код: Выделить всё
# Initial Update
sudo apt-get update
sudo apt-get full-upgrade
# Configure SSH RSA Key
mkdir -p ~/.ssh
chmod 700 ~/.ssh
echo "[Contents of %USERPROFILE%\.ssh\id_rsa.pub on your PC]" >> ~/.ssh/authorized_keys
chmod 600 ~/.ssh/authorized_keys
exit
ssh admin@devpi
# DotNet 8 Runtime
wget https://dot.net/v1/dotnet-install.sh
chmod +x dotnet-install.sh
./dotnet-install.sh --channel 8.0
echo 'export DOTNET_ROOT=$HOME/.dotnet' >> ~/.bashrc
echo 'export PATH=$PATH:$HOME/.dotnet' >> ~/.bashrc
source ~/.bashrc
dotnet --info
# DotNet Debugger
curl -sSL https://aka.ms/getvsdbgsh | bash /dev/stdin -r linux-arm -v latest -l ~/vsdbg
< /code>
dotnet --infolinux-arm
true
< /code>
I've also got a post-build script setup to copy the binaries onto the Pi as follows:
scp -r ./bin/Debug/net8.0/linux-arm/* admin@devpi:/home/admin/ConsoleApp1
< /code>
Finally, the launch.json file in my project is as follows:
{
"profiles": {
"ConsoleApp1": {
"commandName": "Project",
"workingDirectory": "/home/admin/ConsoleApp1",
"remoteDebugEnabled": true,
"remoteDebugMachine": "devpi:22",
"authenticationMode": "None"
}
}
}
< /code>
Unfortunately, this is still looking for a folder on my local machine, rather than on the remote Raspberry Pi.
I'd prefer to avoid having to manually publish and deploy the software, then start the app on the pi and attach a remote debugger. Apart from being a pain in the backside, it doesn't allow me to debug the startup code.
There must be a simpler way. Can anyone point me in the right direction?
Подробнее здесь: https://stackoverflow.com/questions/792 ... spberry-pi
Мобильная версия