2018年12月27日 星期四

[RPi] PiM25

這幾個專案值得參考
https://github.com/raspberrypi-tw/PiM25
https://github.com/ypwhs/PM2.5

2018年12月26日 星期三

[Tips] 縮網址

代辦事項,縮網址
https://www.sitepoint.com/building-your-own-url-shortener/

2018年12月23日 星期日

[RPi] 忘記密碼

之前的方法在八百年前就不能用了。只好參考這篇。對了這要在 console 下使用鍵盤和螢幕才行 QQ

1. 先備份這兩個檔案。
1) /boot/cmdline.txt
2) /etc/fstab

2. 修改 /boot/cmdline.txt
原本
dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=********-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait

改為(root 掛到 /dev/mmcblk0p2,行末多了 init=/bin/sh)
dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait init=/bin/sh

3. 修改 /etc/fstab
原本
PARTUUID=********-02 / ext4 defaults,noatime 0 1

改為
/dev/mmcblk0p2 / ext4 defaults,noatime 0 1

4. 插上 SD 卡,會直接登入不需要密碼。
先切成 root
su

掛載 /dev/mmcblk0p2
mount -o rw,remount /dev/mmcblk0p2 /

同步 shadow
pwconv

修改 pi 的密碼
passwd pi

5. 重開機只能拔電源,這要看人品好不好了,運氣不好沒有 sync 成功又要重做了...

6. 重開機前記得把剛剛備份的 cmdline.txt 和 fstab 倒回去

2018年12月18日 星期二

[RPi] 安裝EW-7822ULC/UTC無線網卡

這篇寫得很清楚,但我忘記要先紀錄步驟了 QQ

https://edimax.freshdesk.com/support/solutions/articles/14000062079-how-to-install-ew-7822ulc-utc-adapter-on-raspberry-pi

2018年12月15日 星期六

[RPi] RPi won't boot, no ACT LED blinking

在一連串的機瘟崩潰,只好努力爬文。

Pi 3B+ 無法開機的確認狀態為,1 號腳位(3.3V)量不到電壓(0V)。
https://www.raspberrypi.org/forums/viewtopic.php?t=223923

最常出現的原因是 3.3V 和 5V 短路到,應該是 5V 的電灌到 3.3V 腳位造成。

目前看來似乎解決方法可以試著換 PMIC,運氣好可以救活?
https://www.raspberrypi.org/blog/pi-power-supply-chip/
https://www.raspberrypi.org/forums/viewtopic.php?t=213604


2018年12月14日 星期五

[Tips] DOT

今天聽到的新東西
dot graph description language

[RPi] How to Run a Raspberry Pi Program on Startup

和我的內容好像
https://learn.sparkfun.com/tutorials/how-to-run-a-raspberry-pi-program-on-startup