User Tools

Site Tools


toh:raspberry_pi

Raspberry Pi

The Raspberry Pi is single-board computer without an Ethernet Network Switch. There are many more Single-board computers without one.

OpenWrt for Raspberry Pi is compiled with the ARM soft-float kernel ABI. This means that non-integer math is done in software instead of in hardware. Soft float (armel) is slower than hard float (armhf).

Supported Versions

The Raspberry Pi is supported in the brcm2708 target. Releases with support for this target are:

Release Date Version Download
2014-10-02 14.07 Barrier Breaker http://downloads.openwrt.org/barrier_breaker/14.07/brcm2708/generic/
2013-04-25 12.09 Attitude Adjustment http://downloads.openwrt.org/attitude_adjustment/12.09/brcm2708/generic/
2012-07-24 Trunk r32825 - Add support for Raspberry Pi / brcm2708 / 2835 https://dev.openwrt.org/changeset/32825

If you are not sure which file to get, download openwrt-brcm2708-sdcard-vfat-ext4.img

Hardware Specifications

All Versions

System-on-Chip CPU Serial JTag Power Connector
Broadcom BCM2835 700 MHz ARM11 ARM1176JZF-S via GPIO via GPIO MicroUSB A

Model Specific Differences

RPi Model RAM Network USB Memory Card Video Audio Power Requirements GPIO Pins
A 256 MB None 1 USB port SD Card HDMI and Composite RCA 3.5mm Stereo 5V 300mA (see below) 8
B 256 or 512 MB 10M/100M Ethernet RJ45 2 USB ports SD Card HDMI and Composite RCA 3.5mm Stereo 5V 700mA (see below) 8
B+ 512 MB 10M/100M Ethernet RJ45 4 USB ports MicroSD HDMI and shared TRSS 3.5mm Shared TRSS 3.5mm 5V 600mA (see below) 17

Power Notes

The power figures quoted are the bare minimum to run the SoC with no peripherals. Most people find at least a solid 1A is required, especially if adding USB peripherals like keyboard, mouse, or wifi.

A popular power supply is the Apple 12W iPad charger, supplying 5V 2.4A. Similar high-powered mobile phone and tablet chargers should suffice. Using cheap power supplies off eBay is not recommended, as they provide a very uneven and noisy current which can lead to unreliable operation.

It is possible to back-power some Raspberry Pi models from the USB ports, however this is not recommended, as the power in from the USB ports is not protected against surges whereas the main power supply is protected.

It is also possible to supply the required power via the GPIO pins.

Serial

Serial is available via GPIO.

Pin 6 Pin 8 Pin 10
Ground TX RX

Connect via RS232 at 3.3 Volts (not older 12V). 115200 bps 8N1.

Serial Log

[    0.000000] Booting Linux on physical CPU 0x0                             
[    0.000000] Linux version 3.10.49 (bb@builder1) (gcc version 4.8.3 (OpenWrt/4
[    0.000000] CPU: ARMv6-compatible processor [410fb767] revision 7 (ARMv7), cd
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT nonaliasing instrue
[    0.000000] Machine: BCM2708                                              
[    0.000000] Memory policy: ECC disabled, Data cache writeback
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pa2
[    0.000000] Kernel command line: dma.dmachans=0x7f35 bcm2708_fb.fbwidth=656 t
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 448MB = 448MB total
[    0.000000] Memory: 450360k/450360k available, 8392k reserved, 0K highmem
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)                
[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)                
[    0.000000]     vmalloc : 0xdc800000 - 0xff000000   ( 552 MB)                
[    0.000000]     lowmem  : 0xc0000000 - 0xdc000000   ( 448 MB)                
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)                
[    0.000000]       .text : 0xc0008000 - 0xc03b11e8   (3749 kB)                
[    0.000000]       .init : 0xc03b2000 - 0xc03ccb58   ( 107 kB)                
[    0.000000]       .data : 0xc03ce000 - 0xc03f5224   ( 157 kB)                
[    0.000000]        .bss : 0xc03f5224 - 0xc043f018   ( 296 kB)                
[    0.000000] NR_IRQS:330                                                      
[    0.000000] sched_clock: 32 bits at 1000kHz, resolution 1000ns, wraps every s
[    0.000000] Switching to timer-based delay loop                              
[    0.000000] Console: colour dummy device 80x30                               
[    0.000000] console [tty1] enabled                                           
[    0.000801] Calibrating delay loop (skipped), value calculated using timer f)
[    0.000849] pid_max: default: 32768 minimum: 301                             
[    0.001000] Mount-cache hash table entries: 512                              
[    0.001649] CPU: Testing write buffer coherency: ok                          
[    0.002002] Setting up static identity map for 0xc000f580 - 0xc000f5dc       
[    0.003098] devtmpfs: initialized                                            
[    0.004505] NET: Registered protocol family 16                               
[    0.009308] DMA: preallocated 4096 KiB pool for atomic coherent allocations  
[    0.010217] bcm2708.uart_clock = 0                                           
[    0.011560] mailbox: Broadcom VideoCore Mailbox driver                       
[    0.011663] bcm2708_vcio: mailbox at f200b880                                
[    0.011760] bcm_power: Broadcom power driver                                 
[    0.011793] bcm_power_open() -> 0                                            
[    0.011814] bcm_power_request(0, 8)                                          
[    0.512517] bcm_mailbox_read -> 00000080, 0                                  
[    0.512551] bcm_power_request -> 0                                           
[    0.512572] Serial: AMBA PL011 UART driver                                   
[    0.512692] dev:f1: ttyAMA0 at MMIO 0x20201000 (irq = 83) is a PL011 rev3    
[    0.794598] console [ttyAMA0] enabled                                        
[    0.816767] bio: create slab <bio-0> at 0                                    
[    0.821753] SCSI subsystem initialized                                       
[    0.825778] usbcore: registered new interface driver usbfs                   
[    0.831351] usbcore: registered new interface driver hub                     
[    0.836872] usbcore: registered new device driver usb                        
[    0.843172] Switching to clocksource stc                                     
[    0.858607] NET: Registered protocol family 2                                
[    0.863760] TCP established hash table entries: 4096 (order: 3, 32768 bytes) 
[    0.871007] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)        
[    0.877548] TCP: Hash tables configured (established 4096 bind 4096)         
[    0.883979] TCP: reno registered                                             
[    0.887259] UDP hash table entries: 256 (order: 0, 4096 bytes)               
[    0.893120] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)          
[    0.899727] NET: Registered protocol family 1                                
[    0.904670] bcm2708_dma: DMA manager at f2007000                             
[    0.909467] bcm2708_gpio: bcm2708_gpio_probe c03d7658                        
[    0.914891] vc-mem: phys_addr:0x00000000 mem_base=0x1ec00000 mem_size:0x2000)
[    0.925114] msgmni has been set to 879                                       
[    0.929384] io scheduler noop registered                                     
[    0.933328] io scheduler deadline registered                                 
[    0.937706] io scheduler cfq registered (default)                            
[    0.942749] BCM2708FB: allocated DMA memory 5b8f0000                         
[    0.947793] BCM2708FB: allocated DMA channel 0 @ f2007000                    
[    0.968022] Console: switching to colour frame buffer device 82x26           
[    0.985885] brd: module loaded                                               
[    0.994450] loop: module loaded                                              
[    0.999252] vchiq: vchiq_init_state: slot_zero = 0xdc804000, is_master = 0   
[    1.008683] usbcore: registered new interface driver smsc95xx                
[    1.015985] dwc_otg: version 3.00a 10-AUG-2012 (platform bus)                
[    1.223509] Core Release: 2.80a                                              
[    1.228015] Setting default values for core params                           
[    1.234095] Finished setting default values for core params                  
[    1.440991] Using Buffer DMA mode                                            
[    1.445566] Periodic Transfer Interrupt Enhancement - disabled               
[    1.452673] Multiprocessor Interrupt Enhancement - disabled                  
[    1.459544] OTG VER PARAM: 0, OTG VER FLAG: 0                                
[    1.465147] Dedicated Tx FIFOs mode                                          
[    1.470077] dwc_otg bcm2708_usb: DWC OTG Controller                          
[    1.476241] dwc_otg bcm2708_usb: new USB bus registered, assigned bus number1
[    1.484802] dwc_otg bcm2708_usb: irq 32, io mem 0x00000000                   
[    1.491611] Init: Port Power? op_state=1                                     
[    1.496808] Init: Power Port (0)                                             
[    1.501399] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002    
[    1.509565] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber1
[    1.518134] usb usb1: Product: DWC OTG Controller                            
[    1.524126] usb usb1: Manufacturer: Linux 3.10.49 dwc_otg_hcd                
[    1.531208] usb usb1: SerialNumber: bcm2708_usb                              
[    1.537904] hub 1-0:1.0: USB hub found                                       
[    1.542992] hub 1-0:1.0: 1 port detected                                     
[    1.549016] usbcore: registered new interface driver usb-storage             
[    1.556629] mousedev: PS/2 mouse device common for all mice                  
[    1.563744] bcm2708 watchdog, heartbeat=10 sec (nowayout=0)                  
[    1.570640] cpuidle: using governor ladder                                   
[    1.575966] cpuidle: using governor menu                                     
[    1.581163] sdhci: Secure Digital Host Controller Interface driver           
[    1.588584] sdhci: Copyright(c) Pierre Ossman                                
[    1.594239] sdhci: Enable low-latency mode                                   
[    1.637235] mmc0: SDHCI controller on BCM2708_Arasan [platform] using platfoA
[    1.647538] mmc0: BCM2708 SDHC host at 0x20300000 DMA 4 IRQ 20               
[    1.654714] sdhci-pltfm: SDHCI platform and OF driver helper                 
[    1.662416] TCP: cubic registered                                            
[    1.667060] NET: Registered protocol family 17                               
[    1.672935] Bridge firewalling registered                                    
[    1.678282] 8021q: 802.1Q VLAN Support v1.8                                  
[    1.684128] VFP support v0.3: implementor 41 architecture 1 part 20 variant 5
[    1.698080] Waiting for root device /dev/mmcblk0p2...                        
[    1.758216] mmc0: new high speed SDHC card at address 1234                   
[    1.765590] mmcblk0: mmc0:1234 SA08G 7.42 GiB                                
[    1.773092]  mmcblk0: p1 p2                                                  
[    1.787350] Indeed it is in host mode hprt0 = 00021501                       
[    1.862232] EXT4-fs (mmcblk0p2): warning: mounting unchecked fs, running e2fd
[    1.967263] usb 1-1: new high-speed USB device number 2 using dwc_otg        
[    1.975378] Indeed it is in host mode hprt0 = 00001101                       
[    2.177748] usb 1-1: New USB device found, idVendor=0424, idProduct=9512     
[    2.186068] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    2.195781] hub 1-1:1.0: USB hub found                                       
[    2.201246] hub 1-1:1.0: 3 ports detected                                    
[    2.324804] EXT4-fs (mmcblk0p2): mounted filesystem without journal. Opts: ()
[    2.335324] VFS: Mounted root (ext4 filesystem) on device 179:2.             
[    2.343267] Freeing unused kernel memory: 104K (c03b2000 - c03cc000)         
[    2.487484] usb 1-1.1: new high-speed USB device number 3 using dwc_otg      
[    2.608106] usb 1-1.1: New USB device found, idVendor=0424, idProduct=ec00   
[    2.616581] usb 1-1.1: New USB device strings: Mfr=0, Product=0, SerialNumbe0
[    2.628987] smsc95xx v1.0.4                                                  
[    2.693675] smsc95xx 1-1.1:1.0 eth0: register 'smsc95xx' at usb-bcm2708_usb-0
[    6.303384] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)                    
�Please press Enter to activate this console.                                   
[    8.359868] NET: Registered protocol family 10                               
[    8.397049] nf_conntrack version 0.5.0 (7038 buckets, 28152 max)             
[    8.409659] ip6_tables: (C) 2000-2006 Netfilter Core Team                    
[    8.429746] hidraw: raw HID events driver (C) Jiri Kosina                    
[    8.456242] ip_tables: (C) 2000-2006 Netfilter Core Team                     
[    8.481873] usbcore: registered new interface driver usbhid                  
[    8.488924] usbhid: USB HID core driver                                      
[    8.511230] xt_time: kernel timezone is -0000                                
[    8.524035] PPP generic driver version 2.4.2                                 
[    8.532162] NET: Registered protocol family 24                               
[   11.991982] smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup 
[   12.001171] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready               
[   12.040476] device eth0 entered promiscuous mode                             
[   12.053357] IPv6: ADDRCONF(NETDEV_UP): br-lan: link is not ready             
[   13.511063] smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0x411
[   13.529699] br-lan: port 1(eth0) entered forwarding state                    
[   13.536589] br-lan: port 1(eth0) entered forwarding state                    
[   13.543534] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready          
[   13.553417] IPv6: ADDRCONF(NETDEV_CHANGE): br-lan: link becomes ready        
[   15.527221] br-lan: port 1(eth0) entered forwarding state

How to flash OpenWrt to an SD card

On a Linux desktop, insert your SD card and run:

dmesg

to see the latest kernel messages.

The most recent message should give you the SD card's device name, such as sdb or sdf or similar.

Download the relevant openwrt-brcm2708-sdcard-vfat-ext4.img image.

As the root user, use dd to copy the image file to the device you identified previously, for example:

dd if=/home/username/Downloads/openwrt-brcm2708-sdcard-vfat-ext4.img of=/dev/sdX bs=2M conv=fsync

Replace the sdX with your device name, such as sdb or sdf.

Raspberry Pi B+: Current Barrier Breaker image does not support Ethernet and USB due to outdated boot files contained in the image: Please fetch latest boot files "bootcode.bin", "kernel.img" & "start.elf" from Raspberry project and replace the current ones.

On a Windows desktop, use Win32DiskImager to copy the img file to your SD card's drive letter.

There are many more complex guides around the internet to flashing images to SD cards,

Resources

Tags

toh/raspberry_pi.txt · Last modified: 2015/01/25 18:27 by Aleksandar