zoukankan      html  css  js  c++  java
  • A new comer playing with Raspberry Pi 3B

    there are some things to do for raspberry pi 3b for the first time:

    1, connect pi with monitor/KB/mouse, then power on it and go into its desktop(by default):
    expand system up to the whole storage of SD card(it seems to be maximum of 64G by official exclaim);
    set up the locale as US/US, from desktop to CLI when login, the timezone as Asia/Chongqing
    alternatively, we could config these parameters by command: raspi-config(need root authentication), before that, you should use a tool such as Putty to connect with SSH.

    2, update system by:
    sudo apt-get update

    3, setup vim
    install new vim(I suspect it's fake itself, many feature aren't available in its VIM!) by: sudo apt-get install vim
    add a .vimrc under your home folder and insert the following configuration:
    set nu
    syntax on
    set hlsearch
    set tabstop=4
    "set softtabstop=4
    "set shiftwidth=4
    "set cindent
    "set cinoptions={0,1s,t0,n-2,p2s,(03s,=.5s,>1s,=1s,:1s

    4, config static ip address (for wifi at least) by altering file /etc/network/interfaces:
    auto wlan0
    allow-hotplug wlan0
    iface wlan0 inet static
        address 192.168.1.60
        netmask 255.255.255.0
        gateway 192.168.1.1
        wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

    note: more details for its configuration information, refer to its manual by typing - man interfaces, other configuration files or head files such as <stdio.h>, you can do the same.

    5, install remote desktop for raspberry pi by:
    sudo apt-get install xrdp
    then you can use the default remote connecting tool of microsoft windows self to login pi

    6, how to share with pi's home folder?
    by SAMBA service:
    a, sudo apt-get install samba samba-common-bin
    b, sudo smbpasswd -a pi
    c, make changes to 'read only' as no and 'browseable' as yes in section [homes] in file /etc/samba/smb.conf
    d, sudo /etc/init.d/samba restart
    e, then windows has access to the shared home folder like \192.168.1.60pi

    7, how to use USB mass storage devices under it?
    you could use 'lsusb' to find out which usb devices are connected.
    a, mount usb disk manually
        make sure folder /mnt/udisk exists;
        mount: sudo mount -o uid=pi,gid=pi /dev/sda? /mnt/udisk (note: sda? should be seeked out accordingly)
        unmount: sudo umount /mnt/udisk
    b, mount usb disk automatically?    

    8, complete development environment update for c/c++

    for gcc: sudo apt-get install gcc-4.9-doc    (first check your version of gcc, in this case, it is 4.9)

    P.S. Win32DiskImager can backup and restore system on TF card among different cards.
    halt完成后居然有2.4瓦特的功耗!而运行时轻载也就1.7瓦特左右,负载重时也就2-3瓦特!所以要彻底关电,必须使用poweroff或shutdown now --poweroff命令,关断后其显示红指示灯常亮,而halt后是灭灯的。

  • 相关阅读:
    pig安装
    [2013.10.29][Luogu OJ P1873]砍树
    [转帖]OIer之魂、
    [转帖]我们是OIer、
    10007:[2013.10.25]P1.滚土豆(potato.pas/c/cpp)
    [2013.10.18]P2.传作业 (pass.pas/c/cpp)
    [Luogu OJ P1619]解一元二次方程的烦恼
    [Luogu OJ P1433][2013.10.18]DFS基础题-吃奶酪
    高精度加减乘法小程序 Ver 0.9.5 beta
    [2013.10.11]P3.和为零
  • 原文地址:https://www.cnblogs.com/oijen/p/5418252.html
Copyright © 2011-2022 走看看