树莓派安装魔镜功能模块

Yep, it’s definitely possible, but it’s not easy. I’ve got the server plus an auto-boot into chromium kiosk mode up and running on a Raspberry Pi 1.

Here’s some half-written notes that I was keeping as I went through the process. Hopefully somebody can take this and turn it into better documentation.

PC-side:
install WinSCP: https://winscp.net/eng/download.php
install PuTTY: http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html

Overall kiosk screen setup:
See https://www.danpurdy.co.uk/web-development/raspberry-pi-kiosk-screen-tutorial/
Important commands:

sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get install chromium x11-xserver-utils unclutter

Install node.js:
See https://www.losant.com/blog/how-to-install-nodejs-on-raspberry-pi
Important commands:

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.31.0/install.sh | bash
nvm install v6.2.1

Magic Mirror setup:
See https://github.com/MichMich/MagicMirror#usage
Important commands:

sudo apt-get install php5
curl -sL https://raw.githubusercontent.com/MichMich/MagicMirror/master/installers/raspberry.sh
(need to modify raspberry.sh to take out the Pi1 fail check)
bash raspberry.sh
git clone https://github.com/MichMich/MagicMirror
cd ~/MagicMirror
npm install
node serveronly

Raspberry Pi 1 CSS incompatibility issue
fix drawing:
nano css/custom.css

	height: 90%;
	width: 90%;

(TODO - find better fix for this)

Install wifi adapter:
See https://www.raspberrypi.org/forums/viewtopic.php?p=462982#p462982
Important commands:

lsusb
uname -a
wget https://dl.dropboxusercontent.com/u/80256631/8188eu-20160305.tar.gz
tar xzf 8188eu-20160305.tar.gz
./install.sh
sudo reboot

Create a startup script:

nano run_magicmirror.sh

echo 'removing log.txt'
rm -f /home/pi/MagicMirror/log.txt

echo 'running MagicMirror server'
/home/pi/.nvm/versions/node/v6.2.1/bin/node /home/pi/MagicMirror/serveronly > /home/pi/MagicMirror/log.txt

echo 'waiting for server to start'
sleep 20

echo 'running web browser'
chromium --noerrdialogs --kiosk --incognito http://localhost:8080

Set up autostart:
See https://github.com/MichMich/MagicMirror/wiki/Configuring-the-Raspberry-Pi
Important commands:
sudo nano /etc/xdg/lxsession/LXDE/autostart

	@xscreensaver -no-splash
	@xset s off
	@xset -dpms
	@xset s noblank
	@lxterminal -e sh /home/pi/run_magicmirror.sh

Note from admin: Please use Markdown on code snippets!


转载地址:https://forum.magicmirror.builders/topic/272/raspberry-pi-1-any-magic-mirror-setup-possible/4

  • 0
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值