20. Raspberry Pi Model A
21
USB Ports
Ethernet
GPIO
3.5mm Audio &
Composite Output Jack
HDMI Out5V Micro USB
Power
CSI Camera
connector
SMSC LAN9514 USB
Ethernet controller
DSI Display
connector
MicroSD Card
slot (??)
Less power
consumption
Power Regulator
Pi reset
Run Header
Broadcom
BCM2835
RaspberryPi
21. Raspberry Pi 2 Model B v1.1
22
4 USB Ports
Ethernet
GPIO
3.5mm Audio &
Composite Output JackHDMI Out5V Micro USB
Power
CSI Camera
connector
SMSC LAN9514 USB
Ethernet controller
DSI Display
connector
(??) MicroSD
Card Slot
Less power
consumption
Power Regulator
Pi reset
Run Header
Broadcom
BCM2836
RaspberryPi
?? http://elinux.org/RPi_Hardware
22. Raspberry Pi 2 Model B v1.2
23
Serial In (Rx)
4 USB Ports
Ethernet
GPIO
3.5mm Audio &
Composite Output JackHDMI Out5V Micro USB
Power
CSI Camera
connector
SMSC LAN9514 USB
Ethernet controller
DSI Display
connector
(??)
MicroSD Slot
Less power
consumption
Power Regulator
Pi reset
Run Header
Broadcom
BCM2837
23. Raspberry Pi 3 Model B
24
Serial In (Rx)
4 USB Ports
Ethernet
GPIO
3.5mm Audio &
Composite Output Jack
HDMI Out5V Micro USB
Power up to 2.5A
CSI Camera
connector
SMSC LAN9514 USB
Ethernet controller
DSI Display
connector
MicroSD Card
slot (??)
Less power
consumption
Power Regulator
On board
BT 4.1, WiFi
Chip Antenna
Broadcom
BCM2837 64bit
Quad core CPU
at 1.2Ghz
24. Raspberry Pi Zero
25
GPIO
Micro USBMini-HDMI 1080p
Video & Audio
Output
5V Micro USB
Power
CSI Camera
connector
Micro SDCard
Pi reset
Run Header
Broadcom BCM2835 SoC
Dual core 1Ghz
VideoCore IV GPU
512MB Onboard RAM
RCA Composite
Video Output
65 x 30 x 5 mm
25. Raspberry Pi Table
26
?? Pi 1 Model B+ Pi 2 Model B Pi Zero Pi 3 Model B Pi 2 v1.2
SoC SoC BCM 8235 SoC BCM 8236 SoC BCM 8335 SoC BCM 2837 SoC BCM 2837
CPU ARM11 @700Mhz
Quad Coretex A7
@900Mhz
ARM11 @1Ghz
Quad Coretex A53
@1.2Ghz
Quad Coretex A53
@900Mhz
IS Set ARMv6 ARMv7-A ARMv6 ARMv8-A ARMv8-A
GPU
250Mhz VideoCore
IV
250Mhz VideoCore
IV
250Mhz VideoCore
IV
400Mhz VideoCore
IV
250Mhz VideoCore
IV
Memory 512MB Ram 1GB Ram 512MB Ram 1GB Ram 1GB Ram
Network 10/100 10/100 N/A
10/100, WiFi, BL
4.1
10/100
USB 2 x USB2.0 4 x USB2.0 1 Micro USB 4 x USB2.0 4 x USB 2.0
GPIO 40 40 40 40 40
Video
640〜350 to
1920〜1200,
1080p, PAL &
NTSC
640〜350 to
1920〜1200,
1080p, PAL &
NTSC
640〜350 to
1920〜1200,
1080p, PAL &
NTSC
640〜350 to
1920〜1200,
1080p, PAL &
NTSC
640〜350 to
1920〜1200,
1080p, PAL &
NTSC
26. Raspberry Pi ARM core
Raspberry Pi 2? Broadcom BCM2836 ??? ??.
- ARMv7 Cortex-A7
- https://goo.gl/nLAhZH
- BCM2836? ??? BCM2835? ??
- https://goo.gl/IqF2TW
- BCM2835 ARM Peripherals reference
- https://goo.gl/Zh9SeO
- 32bit ??? ????? ???? ??.
Raspberry Pi 3? Broadcom BCM2837
- ARMv8 Cortex-A53
Raspberry Pi 2 v1.2? Broadcom BCM2837
- ARMv8 Cortex-A53
27
27. ????
USB 2.0 ?? ??? ??? 5V? 500mA ??
USB 3 ?? ??? ??? 5 V? 900 mA ??
28
Product
Recommended
PSU current
capacity
Maximum total
USB peripheral
current draw
Typical bare-
board active
current
consumption
Raspberry Pi Model A 700mA 500mA 200mA
Raspberry Pi Model B 1.2A 500mA 500mA
Raspberry Pi Model A+ 700mA 500mA 180mA
Raspberry Pi Model B+ 1.8A
600mA/1.2A
(switchable)
330mA
Raspberry Pi 2 Model B 1.8A
600mA/1.2A
(switchable)
Raspberry Pi 3 Model B 800mA~2.5A 1.2A ~400mA
https://www.raspberrypi.org/help/faqs/
30. ?? ?? ??
2017-03-02:
* NOOBS installs now checks for presence of 'ssh' file on the NOOBS partition
2017-01-11:
* Re-release of the 2016-11-25 image with a FAT32-formatted boot partition
2016-11-25:
* SSH disabled by default; can be enabled by creating a file with name "ssh" in boot
partition
2016-09-23:
* New PIXEL desktop environment
* RealVNC server and viewer included
31 http://downloads.raspberrypi.org/raspbian/release_notes.txt
31. Writing OS Image
Format SDCard
-SD Association ?? sdFormater
Writing image
- Etcher, Win32DiskImager
- dd command
32
jessie-raspbian Ubuntu OSMC
NOOB
RaspberryPi
SDHC Class 6 ??
52. sshfs ??
?? ???? sshfs ??
- Raspberry Pi / Linux sshfs ??
$sudo apt-get install sshfs
54
53. sshfs usage
sshfs ??? ?? ??:
sshfs -pXXXX -o [options] user@remotehost:/path /local/path/
Useful options:
-pXXXXX C tells sshfs to use port number XXXXX.
-o Ciphers=arcfour C speeds up for the connection.
-o ro C read only.
-o nonempty C allow nonempty mount point.
-o cache_timeout=N C set default cache timeout (in seconds)
-o cache=no C disable cache.
-o intr C allows to interrupt file access.
-o reconnect C automatically reconnect
-o idmap=user C helps with file ownership conflicts
55
76. ssh pi@192.168.0.20
nmap, arp ??? IP ??? ssh ???.
$ ssh pi@192.168.11.100
The authenticity of host '192.168.11.100 (192.168.11.100)' can't be established.
ECDSA key fingerprint is SHA256:G8MGJDNGJeYqF123aYlKj4MMQF9aevRhF/aO2ldWo6E.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.11.100' (ECDSA) to the list of known hosts.
pi@192.168.11.100's password:
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Fri Mar 3 16:24:26 2017
SSH is enabled and the default password for the 'pi' user has not been changed.
This is a security risk - please login as the 'pi' user and type 'passwd' to set a
new password.79
92. bluetoothctl
$ bluetoothctl
[NEW] Controller B8:27:EB:62:F5:E1 homepi [default]
[bluetooth]# help
Available commands:
list List available controllers
show [ctrl] Controller information
select <ctrl> Select default controller
devices List available devices
paired-devices List paired devices
power <on/off> Set controller power
pairable <on/off> Set controller pairable mode
discoverable <on/off> Set controller discoverable mode
agent <on/off/capability> Enable/disable agent with given capability
default-agent Set agent as the default one
scan <on/off> Scan for devices
info <dev> Device information
pair <dev> Pair with device
trust <dev> Trust device
untrust <dev> Untrust device
block <dev> Block device
unblock <dev> Unblock device
remove <dev> Remove device
connect <dev> Connect device
disconnect <dev> Disconnect device
version Display version
quit Quit program
[bluetooth]#95
bluetoothctl? ???
???? ??? ???
? ??.
94. bluetoothctl
bluetoothctl?? ??? ?? ??? ? ??.
[bluetooth]# power on
Changing power on succeeded
[bluetooth]# agent on
Agent registered
[bluetooth]# scan on
Discovery started
[CHG] Controller A8:27:EB:62:D5:E1 Discovering: yes
97
Raspberry Pi ?? on
scan ?? on
???/???
paring
101. ??? SysFS ??
?? ??
CPU Max frequency
Debian ?? ??? ??:
104
$ cat /sys/firmware/devicetree/base/model
Raspberry Pi 3 Model B Rev 1.2
$ cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq
1200000
$ getconf -a
109. ???? ??
112
Push Button Digital Input Switch - Closes or
opens circuit
Polarized, needs
resistor
Trim
potentiometer
Analog Input Variable resistor Also called a
Trimpot.
Photoresistor Analog Input Light Dependent
Resistor (LDR)
Resistance varies
with light.
Relay Digital Output Switch driven by
a small signal
Used to control
larger voltages
Temp Sensor Analog Input Temp Dependent
Resistor
Flex Sensor Analog Input Variable resistor
Soft Trimpot Analog Input Variable resistor Careful of shorts
RGB LED Dig & Analog
Output
16,777,216
different colors
Ooh... So pretty.
Name Image Type Function Notes
126. sysfs ? ??
sysfs_23.sh
129
# the pin to control
PIN=23
# make this pin available through the SysFS
echo $PIN > /sys/class/gpio/export
# now, set this pin to output
echo out > /sys/class/gpio/gpio${PIN}/direction
# write a value to this pin
echo 1 > /sys/class/gpio/gpio${PIN}/value
# wait for some seconds
sleep 3s
# write a value to this pin
echo 0 > /sys/class/gpio/gpio${PIN}/value
# make this pin unavailable through the SysFS
echo $PIN > /sys/class/gpio/unexport
131. Creat My Own Parts
http://fritzing.org/learning/tutorials/creating-custom-parts/
https://embeddist.wordpress.com/2014/10/24/create-my-
part-on-fritzing/
134