[.Net][RPi] 將.NET 8搬上Raspberry Pi 3的操作指南
2024-01-18
最近很訝異,因為我在 一台舊舊的 Raspberry Pi 3 上面執行起來一個 .net 8 的程式
雖然玩 Pi 也是有些年頭了,但是我沒有在上面面跑過 .Net 到是 Chromebook 我之前有在上面寫過 ASP.net 的小專案
重點是 因為我跑的機器是 Pi 3 ,我比較訝異,因為到了 Pi 4 性能上都有爆發成長都可以裝 Win11 了
這次我測是跑的專案是 這個 之前寫的 Console ,然後就放到 Pi3 上面跑跑看竟然成功了
所以分享一下步驟
1. 在 Raspberry Pi 中的系統 輸入
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget -O - https://raw.githubusercontent.com/pjgpetecodes/dotnet8pi/main/install.sh | sudo bash | |
接下來就安裝畫面

2. 重新開機 ,我在 console 中,因為我專案 名稱是 TheLastMnemonic ,所以輸入指令
dotnet TheLastMnemonic.dll
注意,不是 .exe
接下來,應該沒意外的話就執行成功了
如果有遇到其他問題可以參考這篇文章
https://www.petecodes.co.uk/install-and-use-microsoft-dot-net-8-with-the-raspberry-pi/
標籤: .Net8 , Native AOT , Raspberry Pi , RPi
--
Yesterday I wrote down the code. I bet I could be your hero. I am a mighty little programmer.
如果這篇文章有幫助到您,簡單留個言,或是幫我按個讚,讓我有寫下去的動力...