百科.dev
全部条目AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
R

RasPiArduino

> 编程语言
开源

RaspberryPI 专用 Arduino 框架

355 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

RaspberryPI 专用 Arduino 框架

RasPiArduino

Includes raspberry_pi_revision from Andrew Duncan

Arduino Framework for RaspberryPI

Features

  • The familiar Arduino API
  • pinMode/digitalRead/digitalWrite/analogWrite
  • Full SPI, Wire and Serial compatibility
  • Access to STDIN/STDOUT through the Console class
  • Access to system tty through the TTY library
  • Process, FileIO, Client, Server and UDP implementations through the Bridge library

Instructions for Arduino IDE

  • Open the installation folder of Arduino IDE
  • Create a folder named "RaspberryPi" inside "hardware" and clone the repository to a folder named "piduino"
mkdir hardware/RaspberryPi
cd hardware/RaspberryPi
git clone https://github.com/me-no-dev/RasPiArduino piduino
  • Download , extract and copy the toolchain to piduino/tools/arm-linux-gnueabihf
    • Windows: gnutoolchains.com
      • The toolchain for Jessie will work ONLY on RaspberryPi 2
      • The toolchain for Wheezy will work on ALL RaspberryPi boards (recommended)
      • Video Instructions
    • Linux 64: arm-linux-gnueabihf
    • Linux 32: arm-linux-gnueabihf
    • Mac OS X: arm-linux-gnueabihf
  • Restart Arduino IDE and select the RaspberryPI from the list of boards
  • Compile a sketch
  • Select the RaspberryPi from the list of Ports (will show the IP address)
  • Upload your sketch and see it go

Instructions for the PI

  • Install Raspbian Jessie on your RaspberryPI
  • Gain root permissions
sudo su
  • Enable password login for root
passwd
  • enter the new root password twice
  • Edit /etc/ssh/sshd_config and make sure that the following lines exist and are not commented
PermitRootLogin yes
PasswordAuthentication yes
  • Disable Serial Console on boot by removing console=/dev/ttyAMA0 from /boot/cmdline.txt (or through raspi-config)

  • Disable Serial tty

systemctl disable serial-getty@ttyAMA0
  • Disable loading sound kernel module
sed -i "s/dtparam=audio=on/#dtparam=audio=on/" /boot/config.txt
  • Change the hostname for your Pi (optional) (also through raspi-config)
hostnamectl set-hostname piduino
  • Setup WiFi (optional)
cat > /etc/wpa_supplicant/wpa_supplicant.conf  /etc/avahi/services/arduino.service 

  %h
  
    _arduino._tcp
    22
    board=bplus
  

EOL

service avahi-daemon restart
  • Install telnet and git
apt-get update
apt-get install telnet git
  • Copy all files from tools/arpi_bins to /usr/local/bin
git clone https://github.com/me-no-dev/RasPiArduino.git piduino
chmod +x piduino/tools/arpi_bins/*
cp piduino/tools/arpi_bins/* /usr/local/bin
rm -rf piduino
  • Create symbolic link for run-avrdude
ln -s /usr/local/bin/run-avrdude /usr/bin/run-avrdude
  • Synchronize time and start sketch on boot (optional)
apt-get install ntpdate
cat > /etc/rc.local  /dev/null
# Start Sketch
/usr/local/bin/run-sketch > /dev/null

exit 0
EOL
  • Prevent some RealTek USB WiFi from sleep (optional) (EU)
echo "options 8192cu rtw_power_mgnt=0 rtw_enusbss=1 rtw_ips_mode=1" > /etc/modprobe.d/8192cu.conf
echo "options r8188eu rtw_power_mgnt=0 rtw_enusbss=1 rtw_ips_mode=1" > /etc/modprobe.d/r8188eu.conf
  • Disable screen blank (optional)
sed -i "s/BLANK_TIME=30/BLANK_TIME=0/" /etc/kbd/config
sed -i "s/POWERDOWN_TIME=30/POWERDOWN_TIME=0/" /etc/kbd/config
  • Do not load I2C UART or SPI kernel drivers

  • reboot

If everything went well

Selecting the board from the list of ports

Password prompt before upload

Monitoring the sketch

Links to external tutorials

  • VIDEO: Setup Arduino IDE for Windows

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

C++

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言