{"id":2805,"date":"2012-08-20T08:00:21","date_gmt":"2012-08-20T07:00:21","guid":{"rendered":"http:\/\/www.blaess.fr\/christophe\/?p=2805"},"modified":"2012-11-30T13:32:38","modified_gmt":"2012-11-30T12:32:38","slug":"essai-de-la-distribution-raspian-pour-raspberry-pi","status":"publish","type":"post","link":"https:\/\/www.blaess.fr\/christophe\/2012\/08\/20\/essai-de-la-distribution-raspian-pour-raspberry-pi\/","title":{"rendered":"Essai de la distribution Raspbian pour Raspberry Pi"},"content":{"rendered":"<p style=\"text-align: justify;\"><a href=\"http:\/\/www.blaess.fr\/christophe\/2012\/08\/20\/essai-de-la-distribution-raspian-pour-raspberry-pi\/\"><img loading=\"lazy\" decoding=\"async\" class=\"alignright size-full wp-image-2813\" title=\"Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/Raspbian.png\" alt=\"Raspbian\" width=\"150\" height=\"150\" \/><\/a>J&rsquo;ai re\u00e7u il y a quelques semaines un exemplaire du fameux Raspberry Pi, une carte \u00e0 processeur Arm \u00e0 faible co\u00fbt (environ 33&nbsp;\u00a3, soit 42&nbsp;\u20ac). Je l&rsquo;ai explor\u00e9 en d\u00e9tail pour r\u00e9diger quelques articles \u00e0 para\u00eetre prochainement dans <em>Gnu\/Linux Magazine France<\/em> sur la cr\u00e9ation d&rsquo;un syst\u00e8me \u00ab\u00a0<em>from scratch<\/em>\u00a0\u00bb pour le Raspberry Pi.<\/p>\n<p style=\"text-align: justify;\">Il existe d\u00e9j\u00e0 plusieurs distributions pr\u00eates \u00e0 l&#8217;emploi (ArchLinux, QtOnPi, etc.) mais l&rsquo;une d&rsquo;elles semble plus compl\u00e8te que les autres, il s&rsquo;agit de <a title=\"Raspbian\" href=\"http:\/\/www.raspbian.org\/\" target=\"_blank\">Raspbian Wheezy<\/a> un projet bas\u00e9 sur la distribution <em>Debian Testing<\/em> actuelle port\u00e9e sur Raspberry Pi. Je l&rsquo;ai parcourue rapidement pour me faire une id\u00e9e de ses caract\u00e9ristiques.<\/p>\n<p>\n<!--more-->\n<\/p>\n<h1>Installation<\/h1>\n<p style=\"text-align: justify;\">Le principe d&rsquo;installation consiste \u00e0 copier directement le contenu d&rsquo;une image t\u00e9l\u00e9charg\u00e9e sur une carte SD puis \u00e0 l&rsquo;ins\u00e9rer dans le Raspberry Pi avant de le d\u00e9marrer. Cela se fait tr\u00e8s facilement depuis un poste de travail Linux (\u00e0 l&rsquo;aide de la commande <code>dd<\/code>)\u00a0 mais c&rsquo;est \u00e9galement possible sous Windows avec <em>Win32DiskImager<\/em>.<\/p>\n<p style=\"text-align: justify;\">T\u00e9l\u00e9chargeons <a title=\"http:\/\/downloads.raspberrypi.org\/download.php?file=\/images\/raspbian\/2012-07-15-wheezy-raspbian\/2012-07-15-wheezy-raspbian.zip\" href=\"http:\/\/downloads.raspberrypi.org\/download.php?file=\/images\/raspbian\/2012-07-15-wheezy-raspbian\/2012-07-15-wheezy-raspbian.zip\" target=\"_blank\">l&rsquo;image<\/a> depuis le site officiel de la Raspberry Pi Foundation et d\u00e9compressons-la.<\/p>\n<pre>[~]$ <strong>ls -l 2012-07-15-wheezy-raspbian.zip <\/strong>\n-rw-rw-r-- 1 cpb cpb 461001289 ao\u00fbt  15 10:05 2012-07-15-wheezy-raspbian.zip\n[~]$ <strong>unzip 2012-07-15-wheezy-raspbian.zip<\/strong> \nArchive:  2012-07-15-wheezy-raspbian.zip\n  inflating: 2012-07-15-wheezy-raspbian.img  \n[~]$ ls -l 2012-07-15-wheezy-raspbian.img \n-rw-r--r-- 1 cpb cpb 1939865600 juil. 15 21:45 2012-07-15-wheezy-raspbian.img\n[~]$<\/pre>\n<p style=\"text-align: justify;\">Le fichier image p\u00e8se un peu moins de 2Gio. Ins\u00e9rons sur notre PC une carte SD de 2Go vierge, l&rsquo;automonteur la rend disponible et nous pouvons rechercher son identifiant en observant le contenu du r\u00e9pertoire <code>\/dev\/disk\/by-id<\/code>. Je vous conseille d&rsquo;utiliser une carte SD de bonne qualit\u00e9, classe 4 ou 6, cela vous \u00e9vitera de nombreux d\u00e9boires que l&rsquo;on peut observer dans les t\u00e9moignages d&rsquo;utilisateurs.<\/p>\n<pre>[~]$ <strong>ls \/dev\/disk\/by-id\/ -l<\/strong>\ntotal 0\nlrwxrwxrwx 1 root root  9 ao\u00fbt  16 22:42 ata-Optiarc_DVD+_-RW_AD-5170S -&gt; ..\/..\/sr0\nlrwxrwxrwx 1 root root  9 ao\u00fbt  16 22:42 ata-WDC_WD5000AAVS-00ZTB0_WD-WCASU0125171 -&gt; ..\/..\/sda\nlrwxrwxrwx 1 root root 10 ao\u00fbt  16 22:42 ata-WDC_WD5000AAVS-00ZTB0_WD-WCASU0125171-part1 -&gt; ..\/..\/sda1\nlrwxrwxrwx 1 root root 10 ao\u00fbt  16 22:42 ata-WDC_WD5000AAVS-00ZTB0_WD-WCASU0125171-part2 -&gt; ..\/..\/sda2\nlrwxrwxrwx 1 root root  9 ao\u00fbt  16 22:42 scsi-SATA_WDC_WD5000AAVS-_WD-WCASU0125171 -&gt; ..\/..\/sda\nlrwxrwxrwx 1 root root 10 ao\u00fbt  16 22:42 scsi-SATA_WDC_WD5000AAVS-_WD-WCASU0125171-part1 -&gt; ..\/..\/sda1\nlrwxrwxrwx 1 root root 10 ao\u00fbt  16 22:42 scsi-SATA_WDC_WD5000AAVS-_WD-WCASU0125171-part2 -&gt; ..\/..\/sda2\nlrwxrwxrwx 1 root root  9 ao\u00fbt  18 07:36 usb-USB_2.0_SD_MMC_Reader_835000000505-0:0 -&gt; ..\/..\/sdb\nlrwxrwxrwx 1 root root 10 ao\u00fbt  18 07:36 usb-USB_2.0_SD_MMC_Reader_835000000505-0:0-part1 -&gt; ..\/..\/sdb1\n[...]\n[~]$<\/pre>\n<p style=\"text-align: justify;\">Il s&rsquo;agit ici du seul disque commen\u00e7ant par <code>usb-<\/code>, soit le disque <code>sdb<\/code>. Comme sa seule partition <code>sdb1<\/code> a \u00e9t\u00e9 mont\u00e9e, nous devons la d\u00e9monter avant de copier l&rsquo;image brute sur la carte.<\/p>\n<pre>[~]$ <strong>sudo umount \/dev\/sdb1<\/strong>\n[~]$ <strong>sudo dd if=2012-07-15-wheezy-raspbian.img of=\/dev\/sdb<\/strong>\n3788800+0 enregistrements lus\n3788800+0 enregistrements \u00e9crits\n1939865600 octets (1,9 GB) copi\u00e9s, 1689,13 s, 1,1 MB\/s\n[~]$<\/pre>\n<p style=\"text-align: justify;\">Armez-vous de patience, le transfert peut \u00eatre long. Dans mon essai ci-dessus, il a dur\u00e9 pr\u00e8s d&rsquo;une demi-heure&nbsp;!<\/p>\n<p style=\"text-align: justify;\">Ins\u00e9rons notre carte SD dans le Raspberry Pi, et branchons-le pour le voir booter.<\/p>\n<h1>Premier boot<\/h1>\n<p style=\"text-align: justify;\">Le premier boot s&rsquo;effectue en mode console. Une framboise (<em>raspberry<\/em>) s&rsquo;affiche en haut de l&rsquo;\u00e9cran pendant que d\u00e9filent les traces du noyau.<\/p>\n<pre>[    0.000000] Initializing cgroup subsys cpu\n[    0.000000] Linux version 3.1.9+ (dc4@dc4-arm-01) (gcc version 4.5.1 (Broadcom-2708) ) #168 PREEMPT Sat Jul 14 18:56:31 BST 2012\n[    0.000000] CPU: ARMv6-compatible processor [410fb767] revision 7 (ARMv7), cr=00c5387d\n[    0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache\n[    0.000000] Machine: BCM2708\n[    0.000000] Memory policy: ECC disabled, Data cache writeback\n[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 48768\n[    0.000000] Kernel command line: dma.dmachans=0x3c bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416 bcm2708.boardrev=0x2 bcm2708.serial=0xa033012b smsc95xx.macaddr=B8:27:EB:33:01:2B dwc_otg.lpm_enabt\n[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)\n[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)\n[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)\n[    0.000000] Memory: 192MB = 192MB total\n[    0.000000] Memory: 187880k\/187880k available, 8728k reserved, 0K highmem\n[    0.000000] Virtual kernel memory layout:\n[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)\n[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)\n[    0.000000]     DMA     : 0xffc00000 - 0xffe00000   (   2 MB)\n[    0.000000]     vmalloc : 0xcc800000 - 0xd8000000   ( 184 MB)\n[    0.000000]     lowmem  : 0xc0000000 - 0xcc000000   ( 192 MB)\n[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)\n[    0.000000]       .text : 0xc0008000 - 0xc05943d0   (5681 kB)\n[    0.000000]       .init : 0xc0595000 - 0xc05c7000   ( 200 kB)\n[    0.000000]       .data : 0xc05c8000 - 0xc05f93b8   ( 197 kB)\n[    0.000000]        .bss : 0xc05f93dc - 0xc06c7504   ( 825 kB)\n[    0.000000] NR_IRQS:245\n[    0.000000] timer_set_mode: unhandled mode:1\n[    0.000000] timer_set_mode: unhandled mode:3\n[    0.000000] Console: colour dummy device 80x30\n[    0.000000] console [tty1] enabled\n[    3.239537] Calibrating delay loop... 697.95 BogoMIPS (lpj=3489792)\n[    3.298490] pid_max: default: 32768 minimum: 301\n[    3.299120] Mount-cache hash table entries: 512\n[    3.299780] Initializing cgroup subsys cpuacct\n[    3.299896] Initializing cgroup subsys devices\n[    3.299947] Initializing cgroup subsys freezer\n[    3.299989] Initializing cgroup subsys blkio\n[    3.300107] CPU: Testing write buffer coherency: ok\n[    3.300240] ftrace: allocating 14801 entries in 44 pages\n[    3.373228] hw perfevents: enabled with v6 PMU driver, 3 counters available\n[    3.375222] devtmpfs: initialized\n[    3.383000] NET: Registered protocol family 16\n[    3.384922] vc-mem: mm_vc_mem_phys_addr = 0x00000000\n[    3.384988] vc-mem: mm_vc_mem_size      = 0x10000000 (256 MiB)\n[    3.385510] hw-breakpoint: found 6 breakpoint and 1 watchpoint registers.\n[    3.385583] hw-breakpoint: maximum watchpoint size is 4 bytes.\n[    3.385631] mailbox: Broadcom VideoCore Mailbox driver\n[    3.385745] bcm2708_vcio: mailbox at f200b880\n[    3.385852] bcm_power: Broadcom power driver\n[    3.385900] bcm_power_open() -&gt; 0\n[    3.385931] bcm_power_request(0, 8)\n[    3.886624] bcm_mailbox_read -&gt; 00000080, 0\n[    3.886671] bcm_power_request -&gt; 0\n[    3.886704] Serial: AMBA PL011 UART driver\n[    3.886896] dev:f1: ttyAMA0 at MMIO 0x20201000 (irq = 83) is a PL011 rev3\n[    4.192606] console [ttyAMA0] enabled\n[    4.218407] bio: create slab  at 0\n[    4.223974] SCSI subsystem initialized\n[    4.228021] usbcore: registered new interface driver usbfs\n[    4.233815] usbcore: registered new interface driver hub\n[    4.239452] usbcore: registered new device driver usb\n[    4.245609] Switching to clocksource stc\n[    4.254667] Switched to NOHz mode on CPU #0\n[    4.268352] FS-Cache: Loaded\n[    4.271746] CacheFiles: Loaded\n[    4.293311] NET: Registered protocol family 2\n[    4.298261] IP route cache hash table entries: 2048 (order: 1, 8192 bytes)\n[    4.306833] TCP established hash table entries: 8192 (order: 4, 65536 bytes)\n[    4.314358] TCP bind hash table entries: 8192 (order: 3, 32768 bytes)\n[    4.321065] TCP: Hash tables configured (established 8192 bind 8192)\n[    4.327450] TCP reno registered\n[    4.330662] UDP hash table entries: 256 (order: 0, 4096 bytes)\n[    4.336554] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)\n[    4.343421] NET: Registered protocol family 1\n[    4.348782] RPC: Registered named UNIX socket transport module.\n[    4.354965] RPC: Registered udp transport module.\n[    4.359740] RPC: Registered tcp transport module.\n[    4.364468] RPC: Registered tcp NFSv4.1 backchannel transport module.\n[    4.371308] bcm2708_dma: DMA manager at cc808000\n[    4.376073] bcm2708_gpio: bcm2708_gpio_probe c05d00e0\n[    4.381738] vc-mem: Videocore memory driver\n[    4.386836] audit: initializing netlink socket (disabled)\n[    4.392402] type=2000 audit(0.780:1): initialized\n[    4.504592] VFS: Disk quotas dquot_6.5.2\n[    4.508801] Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)\n[    4.516824] FS-Cache: Netfs 'nfs' registered for caching\n[    4.523530] msgmni has been set to 366\n[    4.530087] io scheduler noop registered\n[    4.534064] io scheduler deadline registered (default)\n[    4.539424] io scheduler cfq registered\n[    4.543738] BCM2708FB: registering framebuffer (656x416@16)\n[    4.550095] bcm2708_fb_set_par info(cb8ec400) 656x416 (656x416), 0, 16\n[    4.552358] BCM2708FB: start = cc900000,4d385000 width=656, height=416, bpp=16, pitch=1312 size=545792 success=0\n[    4.556290] Console: switching to colour frame buffer device 82x26\n[    4.591143] BCM2708FB: register framebuffer (0)\n[    4.598693] kgdb: Registered I\/O driver kgdboc.\n[    4.617798] brd: module loaded\n[    4.629665] loop: module loaded\n[    4.636082] vcos: [1]: vchiq_init_state: slot_zero = 0xffd80000, is_master = 0\n[    4.645996] vcos: [1]: vchiq_init_state: called\n[    4.653928] vcos: [1]: vchiq: initialised - version 2 (min 2), device 253.0\n[    4.664154] usbcore: registered new interface driver smsc95xx\n[    4.672396] cdc_ncm: 04-Aug-2011\n[    4.678087] usbcore: registered new interface driver cdc_ncm\n[    4.686161] dwc_otg: version 2.90b 6-MAY-2010 (platform bus)\n[    4.694608] Core Release: 2.80a\n[    4.700180] Setting default values for core params\n[    4.707306] Finished setting default values for core params\n[    4.715628] cc840008 -&gt; 1\n[    4.920723] Using Buffer DMA mode\n[    4.926332] Periodic Transfer Interrupt Enhancement - disabled\n[    4.934563] Multiprocessor Interrupt Enhancement - disabled\n[    4.942611] dwc_otg bcm2708_usb: DWC OTG Controller\n[    4.950052] dwc_otg bcm2708_usb: new USB bus registered, assigned bus number 1\n[    4.959754] dwc_otg bcm2708_usb: irq 75, io mem 0x00000000\n[    4.967503] Init: Port Power? op_state=1\n[    4.973700] Init: Power Port (0)\n[    4.979252] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002\n[    4.988463] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1\n[    4.998044] usb usb1: Product: DWC OTG Controller\n[    5.005108] usb usb1: Manufacturer: Linux 3.1.9+ dwc_otg_hcd\n[    5.013121] usb usb1: SerialNumber: bcm2708_usb\n[    5.021078] hub 1-0:1.0: USB hub found\n[    5.027054] hub 1-0:1.0: 1 port detected\n[    5.034428] usbcore: registered new interface driver uas\n[    5.042065] Initializing USB Mass Storage driver...\n[    5.049341] usbcore: registered new interface driver usb-storage\n[    5.057617] USB Mass Storage support registered.\n[    5.064783] usbcore: registered new interface driver libusual\n[    5.073343] mousedev: PS\/2 mouse device common for all mice\n[    5.081324] cpuidle: using governor ladder\n[    5.087607] cpuidle: using governor menu\n[    5.093849] sdhci: Secure Digital Host Controller Interface driver\n[    5.102278] sdhci: Copyright(c) Pierre Ossman\n[    5.108941] bcm_power_open() -&gt; 1\n[    5.115283] mmc0: SDHCI controller on BCM2708_Arasan [platform] using platform's DMA\n[    5.127606] mmc0: BCM2708 SDHC host at 0x20300000 DMA 2 IRQ 77\n[    5.136067] sdhci-pltfm: SDHCI platform and OF driver helper\n[    5.145986] usbcore: registered new interface driver usbhid\n[    5.154046] usbhid: USB HID core driver\n[    5.169290] TCP cubic registered\n[    5.174920] Initializing XFRM netlink socket\n[    5.183612] NET: Registered protocol family 17\n[    5.192569] Registering the dns_resolver key type\n[    5.201779] VFP support v0.3: implementor 41 architecture 1 part 20 variant b rev 5\n[    5.221615] Waiting for root device \/dev\/mmcblk0p2...\n[    5.256806] mmc0: new high speed SD card at address 0002\n[    5.279841] mmcblk0: mmc0:0002 00000 1.86 GiB \n[    5.290880]  mmcblk0: p1 p2\n[    5.358001] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)\n[    5.371208] VFS: Mounted root (ext4 filesystem) on device 179:2.\n[    5.381223] Freeing init memory: 200K\n[    5.429741] usb 1-1: new high speed USB device number 2 using dwc_otg\n[    5.640291] usb 1-1: New USB device found, idVendor=0424, idProduct=9512\n[    5.649570] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0\n[    5.661452] hub 1-1:1.0: USB hub found\n[    5.667961] hub 1-1:1.0: 3 ports detected\n[    5.950049] usb 1-1.1: new high speed USB device number 3 using dwc_otg\n[    6.060405] usb 1-1.1: New USB device found, idVendor=0424, idProduct=ec00\n[    6.073660] usb 1-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0\n[    6.088491] smsc95xx v1.0.4\n[    6.155557] smsc95xx 1-1.1:1.0: eth0: register 'smsc95xx' at usb-bcm2708_usb-1.1, smsc95xx USB 2.0 Ethernet, b8:27:eb:33:01:2b\n[   15.109842] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)\n[   15.487388] ### snd_bcm2835_alsa_probe c05d07a0 ############### PROBING FOR bcm2835 ALSA device (0):(1) ###############\n[   15.503443] Creating card...\n[   15.508885] Creating device\/chip ..\n[   15.515522] Adding controls ..\n[   15.521075] Registering card ....\n[   15.535931] bcm2835 ALSA CARD CREATED!\n[   15.547976] ### BCM2835 ALSA driver init OK ### \n[...]<\/pre>\n<p style=\"text-align: justify;\">Puis le prompt de connexion habituel s&rsquo;affiche<\/p>\n<pre>raspberrypi login:<\/pre>\n<p style=\"text-align: justify;\">Vous avez deux possibilit\u00e9s&nbsp;:<\/p>\n<ul>\n<li style=\"text-align: justify;\">login \u00ab\u00a0<code>root<\/code>\u00a0\u00bb sans mot de passe<\/li>\n<li style=\"text-align: justify;\">login \u00ab\u00a0<code>pi<\/code>\u00a0\u00bb avec mot de passe \u00ab\u00a0<code>raspberry<\/code>\u00a0\u00bb (attention le clavier est en configuration Azerty&#8230;<\/li>\n<\/ul>\n<p style=\"text-align: justify;\">Je vous conseille tout d&rsquo;abord de vous connecter sous l&rsquo;identit\u00e9 root, afin de terminer le param\u00e9trage du syst\u00e8me. D\u00e8s votre connexion, l&rsquo;\u00e9cran semi-graphique suivant appara\u00eet.<\/p>\n<pre>+------------------------------------------------------------------------------+\n|                                                                              |\n|           info               Information about this tool                     |\n|           expand_rootfs      Expand root partition to fill SD card           |\n|           overscan           Change overscan                                 |\n|           configure_keyboard Set keyboard layout                             |\n|           change_pass        Change password for 'pi' user                   |\n|           change_locale      Set locale                                      |\n|           change_timezone    Set timezone                                    |\n|           memory_split       Change memory split                             |\n|           ssh                Enable or disable ssh server                    |\n|           boot_behaviour     Start desktop on boot?                          |\n|           update             Try to upgrade raspi-config                     |\n|                                                                              |\n|                                                                              |\n|                     &lt;Select&gt;                     &lt;Finish&gt;                    |\n+------------------------------------------------------------------------------+<\/pre>\n<p style=\"text-align: justify;\">Il est possible de le rappeler \u00e0 tout moment en invoquant la commande <code>raspi-config<\/code>.<\/p>\n<p style=\"text-align: justify;\">Ce menu permet entre autres de modifier l&rsquo;<em>overscan<\/em> (l&rsquo;utilisation ou non de marges sur l&rsquo;\u00e9cran, \u00e0 modifier si les premiers et derniers caract\u00e8res de chaque ligne d&rsquo;\u00e9cran disparaissent), la disposition du clavier, le mot de passe de l&rsquo;utilisateur <code>pi<\/code> et le boot en mode console ou graphique.<\/p>\n<p style=\"text-align: justify;\">Apr\u00e8s avoir effectu\u00e9 les modifications d\u00e9sir\u00e9es et quitt\u00e9 le menu de <code>raspi-config<\/code>, nous retrouvons le prompt du shell. Certaines modifications (d\u00e9coupage m\u00e9moire, option <em>overscan<\/em>, etc.) demandent un red\u00e9marrage du syst\u00e8me. J&rsquo;ai profit\u00e9 de ce moment pour ex\u00e9cuter quelques commandes afin d&rsquo;obtenir des informations sur la distribution Raspbian.<\/p>\n<pre>root@raspberrypi:~# <strong>uname -a<\/strong>\nLinux raspberrypi 3.1.9+ #168 PREEMPT Sat Jul 14 18:56:31 BST 2012 armv6l GNU\/Linux\nroot@raspberrypi:~#<\/pre>\n<p style=\"text-align: justify;\">Le noyau est assez r\u00e9cent, et compil\u00e9 avec l&rsquo;option <em>Preemptible Kernel<\/em> qui am\u00e9liore son temps de r\u00e9ponse aux sollicitations externes. Le noyau n&rsquo;est pas compil\u00e9 en SMP, ce qui est logique car le processeur du Raspberry Pi n&rsquo;est pas multi-c\u0153urs.<\/p>\n<pre>root@raspberrypi:~# <strong>free<\/strong>\n             total       used       free     shared    buffers     cached\nMem:        188080      63988     124092          0      10532      35160\n-\/+ buffers\/cache:      18296     169784\nSwap:       102396          0     102396\nroot@raspberrypi:~#<\/pre>\n<p style=\"text-align: justify;\">La r\u00e9partition de la m\u00e9moire se fait ainsi&nbsp;: 192 Mio de m\u00e9moire pour le processeur et 64 Mo pour le contr\u00f4leur graphique. Ceci peut se r\u00e9gler avec <code>raspi-config<\/code>. Je remarque la pr\u00e9sence d&rsquo;une zone de swap, ce qui n&rsquo;est pas courannt sur les syst\u00e8mes embarqu\u00e9s.<\/p>\n<pre>root@raspberrypi:~# <strong>cat \/proc\/swaps <\/strong>\nFilename                                Type            Size    Used    Priority\n\/var\/swap                               file            102396  0       -1\nroot@raspberrypi:~# <strong>ls -l \/var\/swap<\/strong> \n-rw------- 1 root root 104857600 Jul 15 19:42 \/var\/swap\nroot@raspberrypi:~#<\/pre>\n<p style=\"text-align: justify;\">Il s&rsquo;agit d&rsquo;un fichier de swap, et non d&rsquo;une partition. J&rsquo;ai tendance \u00e0 d\u00e9conseiller son usage sur un syst\u00e8me o\u00f9 l&rsquo;arborescence des fichiers r\u00e9side sur une m\u00e9moire flash.<\/p>\n<pre>root@raspberrypi:~# <strong>df<\/strong>\nFilesystem     1K-blocks    Used Available Use% Mounted on\nrootfs           1804128 1366288    346192  80% \/\n\/dev\/root        1804128 1366288    346192  80% \/\ntmpfs              18808     200     18608   2% \/run\ntmpfs               5120       0      5120   0% \/run\/lock\ntmpfs              37616       0     37616   0% \/tmp\ntmpfs              10240       0     10240   0% \/dev\ntmpfs              37616       0     37616   0% \/run\/shm\n\/dev\/mmcblk0p1     57288   34512     22776  61% \/boot\nroot@raspberrypi:~#<\/pre>\n<p style=\"text-align: justify;\">Le syst\u00e8me de fichiers est d\u00e9j\u00e0 bien rempli. Nous pouvons utiliser une carte SD de plus grande capacit\u00e9, et demander \u00e0 <code>raspi-config<\/code> d&rsquo;agrandir la partition principale pour qu&rsquo;elle utilise tout l&rsquo;espace disponible.<\/p>\n<pre>root@raspberrypi:~# <strong>lsmod<\/strong>\nModule                  Size  Used by\njoydev                  9804  0 \nevdev                   8922  0 \nsnd_bcm2835            21485  0 \nsnd_pcm                82208  1 snd_bcm2835\nsnd_seq                59808  0 \nsnd_timer              21905  2 snd_seq,snd_pcm\nsnd_seq_device          6920  1 snd_seq\nsnd                    57668  5 snd_seq_device,snd_timer,snd_seq,snd_pcm,snd_bcm2835\nsnd_page_alloc          5383  1 snd_pcm\nroot@raspberrypi:~# <strong>find \/lib\/modules\/$(uname -r)\/ -name '*.ko' | wc -l<\/strong>\n872\nroot@raspberrypi:~#<\/pre>\n<p style=\"text-align: justify;\">Peu de modules du kernel (9) sont charg\u00e9s pour le moment, mais il y en a plus de 800 directement disponibles.<\/p>\n<h1>Environnement graphique<\/h1>\n<p style=\"text-align: justify;\">On peut demander dans <code>raspi-config<\/code> \u00e0 booter directement en mode graphique (auquel cas nous sommes directement connect\u00e9s sous l&rsquo;identit\u00e9 <code>pi<\/code>). M\u00eame depuis une connexion en mode console, on deut d\u00e9marrer l&rsquo;environnement graphique en tapant <code>startx<\/code>. L&rsquo;\u00e9cran qui s&rsquo;affiche alors est le suivant&nbsp;:<br \/>\n<a href=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-01.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-2818\" title=\"Environnement graphique de Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-01-300x161.png\" alt=\"Environnement graphique de Raspbian\" width=\"300\" height=\"161\" \/><\/a><br \/>\nSi vous ne voyez pas int\u00e9gralement les ic\u00f4nes lat\u00e9rales ou la barre d&rsquo;outils en bas de l&rsquo;\u00e9cran, il vous faut modifier le param\u00e8tre <em>overscan<\/em> dans <code>raspi-config<\/code>.<\/p>\n<p style=\"text-align: justify;\">L&rsquo;environnement graphique est bas\u00e9 sur un serveur X11 all\u00e9g\u00e9 <a title=\"http:\/\/lxde.org\/\" href=\"http:\/\/lxde.org\/\" target=\"_blank\">LXDE<\/a> et un gestionnaire de fen\u00eatres <a title=\"http:\/\/openbox.org\/\" href=\"http:\/\/openbox.org\/\" target=\"_blank\">OpenBox<\/a>. Les applications pr\u00e9-install\u00e9es sont choisies en fonction de crit\u00e8res de rapidit\u00e9 et de l\u00e9g\u00e8ret\u00e9. Par exemple le navigateur web <a title=\"http:\/\/fr.wikipedia.org\/wiki\/Midori_%28navigateur%29\" href=\"http:\/\/fr.wikipedia.org\/wiki\/Midori_%28navigateur%29\" target=\"_blank\">Midori<\/a> est disponible directement depuis le bureau.<br \/>\n<a href=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-02.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-2820\" title=\"Navigateur Midori sur Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-02-300x202.png\" alt=\"Navigateur Midori sur Raspbian\" width=\"300\" height=\"202\" \/><\/a><\/p>\n<p>Nous avons acc\u00e8s \u00e0 la biblioth\u00e8que Debian pour Arm habituelle. Pour s\u00e9lectionner confortablement les applications \u00e0 installer, je commence g\u00e9n\u00e9ralement par installer <a title=\"http:\/\/fr.wikipedia.org\/wiki\/Synaptic\" href=\"http:\/\/fr.wikipedia.org\/wiki\/Synaptic\" target=\"_blank\"><em>Synaptic<\/em><\/a>.<\/p>\n<pre>$ <strong>apt-get install synaptic<\/strong><\/pre>\n<p style=\"text-align: justify;\">Puis on peut choisir les applications depuis une interface utilisateur conviviale.<br \/>\n<a href=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-03.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-2821\" title=\"Synaptic sur Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-03-300x259.png\" alt=\"Synaptic sur Raspbian\" width=\"300\" height=\"259\" \/><\/a><\/p>\n<p style=\"text-align: justify;\">Plusieurs outils de d\u00e9veloppement sont pr\u00e9install\u00e9s, notamment la cha\u00eene de compilation Gnu <a title=\"http:\/\/fr.wikipedia.org\/wiki\/GNU_Compiler_Collection\" href=\"http:\/\/fr.wikipedia.org\/wiki\/GNU_Compiler_Collection\" target=\"_blank\">GCC<\/a>. Je lui ajoute souvent un petit environnement de d\u00e9veloppement comme <a title=\"http:\/\/fr.wikipedia.org\/wiki\/Geany\" href=\"http:\/\/fr.wikipedia.org\/wiki\/Geany\" target=\"_blank\">Geany<\/a>:<br \/>\n<a href=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-04.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-2822\" title=\"Geany sur Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-04-300x200.png\" alt=\"Geany sur Raspbian\" width=\"300\" height=\"200\" \/><\/a><\/p>\n<p style=\"text-align: justify;\">Enfin, la vocation p\u00e9dagogique du projet de la Raspberry Pi Foundation se retrouve dans la distribution Raspbian, puisque d\u00e8s le d\u00e9marrage nous trouvons sur le bureau <a title=\"http:\/\/info.scratch.mit.edu\/fr\/About_Scratch\" href=\"http:\/\/info.scratch.mit.edu\/fr\/About_Scratch\" target=\"_blank\">Scratch<\/a>, un environnement permettant de s&rsquo;initier \u00e0 la programmation de mani\u00e8re ludique comme le faisait autrefois le langage <a title=\"http:\/\/fr.wikipedia.org\/wiki\/Logo_%28langage%29\" href=\"http:\/\/fr.wikipedia.org\/wiki\/Logo_%28langage%29\" target=\"_blank\">Logo<\/a>.<\/p>\n<p style=\"text-align: justify;\"><a href=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-05.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-2831\" title=\"Scratch sur Raspbian\" src=\"http:\/\/www.blaess.fr\/christophe\/wp-content\/uploads\/2012\/08\/screen-05-300x224.png\" alt=\"Scratch sur Raspbian\" width=\"300\" height=\"224\" \/><\/a><\/p>\n<h1>Conclusion<\/h1>\n<p style=\"text-align: justify;\">La distribution Raspbian est sympathique et bien construite. J&rsquo;ai un peu de mal \u00e0 imaginer une utilisation prolong\u00e9e de l&rsquo;environnement graphique (r\u00e9activit\u00e9 un peu faible, lenteur de certaines applications, etc.) d&rsquo;autant que la quantit\u00e9 de m\u00e9moire Ram disponible est limit\u00e9e et faible (256 Mo \u00e0 r\u00e9partir entre le processeur et le contr\u00f4leur graphique).<\/p>\n<p style=\"text-align: justify;\">Ma vision personnelle du Raspberry Pi est plut\u00f4t celle d&rsquo;un syst\u00e8me embarqu\u00e9 (assurant discr\u00e8tement une t\u00e2che programm\u00e9e sans pilotage direct par l&rsquo;utilisateur) que celle d&rsquo;un poste de travail avec environnement graphique complet. Pour cela je pense que l&rsquo;interface console directe (clavier et souris USB, \u00e9cran HDMI), par liaison s\u00e9rie (RS-232 et adaptateur de niveaux d&rsquo;entr\u00e9e) ou via le r\u00e9seau (SSH) est plus adapt\u00e9e pour ce type de mat\u00e9riel. Dans cette optique, l&rsquo;int\u00e9r\u00eat de la distribution Raspbian est de mettre directement \u00e0 disposition de l&rsquo;utilisateur de nombreux outils en ligne de commande pr\u00e9compil\u00e9s, pour tous les projets susceptibles d&#8217;embarquer un Raspberry Pi (serveurs r\u00e9seau, players multim\u00e9dia, interfa\u00e7age et robotique, hacks avec les GPIO, etc.)<\/p>","protected":false},"excerpt":{"rendered":"<p>J&rsquo;ai re&ccedil;u il y a quelques semaines un exemplaire du fameux Raspberry Pi, une carte &agrave; processeur Arm &agrave; faible co&ucirc;t (environ 33&nbsp;&pound;, soit 42&nbsp;&euro;). Je l&rsquo;ai explor&eacute; en d&eacute;tail pour r&eacute;diger quelques articles &agrave; para&icirc;tre prochainement dans Gnu\/Linux Magazine France sur la cr&eacute;ation d&rsquo;un syst&egrave;me &laquo;&nbsp;from scratch&nbsp;&raquo; pour le Raspberry Pi. Il existe d&eacute;j&agrave; [&hellip;]<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,5,8],"tags":[],"class_list":["post-2805","post","type-post","status-publish","format-standard","hentry","category-actualite","category-embarque","category-linux-2"],"_links":{"self":[{"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/posts\/2805","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/comments?post=2805"}],"version-history":[{"count":2,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/posts\/2805\/revisions"}],"predecessor-version":[{"id":3260,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/posts\/2805\/revisions\/3260"}],"wp:attachment":[{"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/media?parent=2805"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/categories?post=2805"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.blaess.fr\/christophe\/wp-json\/wp\/v2\/tags?post=2805"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}