Skip to content

Instantly share code, notes, and snippets.

@kamiyaowl
Created February 13, 2014 14:30
Show Gist options
  • Save kamiyaowl/8975992 to your computer and use it in GitHub Desktop.
Save kamiyaowl/8975992 to your computer and use it in GitHub Desktop.
rasberry pi環境構築まとめ
## gpio ##
#http://elinux.org/RPi_Low-level_peripherals
#gpio7でled点灯
root@raspberrypi:~# echo 7 > /sys/class/gpio/export
root@raspberrypi:~# echo out > /sys/class/gpio/gpio7/direction
root@raspberrypi:~# echo 1 > /sys/class/gpio/gpio7/value
root@raspberrypi:~# echo 0 > /sys/class/gpio/gpio7/value
## 無線LAN ##
$lsusb
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
Bus 001 Device 004: ID 2019:ed17 PLANEX GW-USValue-EZ 802.11n Wireless Adapter [Realtek RTL8188CUS]#←きちんと認識してるみたい
Bus 001 Device 005: ID 05e3:0608 Genesys Logic, Inc. USB-2.0 4-Port HUB
Bus 001 Device 006: ID 04f3:0103 Elan Microelectronics Corp.
Bus 001 Device 007: ID 046d:c52b Logitech, Inc. Unifying Receiver
$sudo iwlist scan
#お好みのESSIDにつないでね
#kamiyapi.localって名前でアクセスできるようにする(固定IPは滅んだ
$cat /etc/hostname
kamiyapi
$cat /etc/hosts
127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
127.0.1.1 kamiyapi
$sudo apt-get update
$sudo apt-get install avahi-daemon
$ping kamiyapi
PING kamiyapi (127.0.1.1) 56(84) bytes of data.
64 bytes from kamiyapi (127.0.1.1): icmp_req=1 ttl=64 time=0.164 ms
64 bytes from kamiyapi (127.0.1.1): icmp_req=2 ttl=64 time=0.161 ms
64 bytes from kamiyapi (127.0.1.1): icmp_req=3 ttl=64 time=0.197 ms
^C
--- kamiyapi ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2002ms
rtt min/avg/max/mdev = 0.161/0.174/0.197/0.016 ms
#幸せ
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment