1. Quick Start for NanoPi
1.1 What you will need
- One NanoPi Board
- MicroSD/TF Card - Recommend an 8GB MicroSD card, you can buy a card with linux system pre-install, or install the system with the follow step.
- MicroUSB Cable
- a Host running Ubuntu and connected to the internet
1.2 Created a MicroSD Card with Debian system
- Insert your microSD card to your host running Ubuntu and check your SD card's device name.
dmesg | tail
Search the messages output by "dmesg" for similar words like "sdc: sdc1 sdc2". If you can find them it means your SD card is recognized as "/dev/sdc". Or you can check that by commanding "cat /proc/partitions".
- Flash Firmware to MicroSD Card
git clone https://github.com/friendlyarm/sd-fuse_nanopi.git
Notice: replace the /dev/sdx to your MicroSD card inode.
1.3 Run the system
- Insert the MicroSD system card into the NanoPi.
- Connect the MicroUSB cable from PC to NanoPi, the NanoPi will boot the debian system auto.
- when the NanoPi Blue LED light on, it means the NanoPi have run the system success.
2 Play with the NanoPi
2.1 Using the SSH session via USB Cable Connect
- Connect the Micro USB cable, and the NanoPi have run the system.
On the PC command line, run the dmesg command, then you will get the follow info, then it means connect success,
[12601.100339] usb 2-1.7: Product: FriendlyARM Gadget v2.4
[12601.100343] usb 2-1.7: Manufacturer: Linux 4.1.2-FriendlyARM with s3c-hsudc
[12601.103192] cdc_acm 2-1.7:2.0: This device cannot do calls on its own. It is not a modem.
[12601.103368] cdc_acm 2-1.7:2.0: ttyACM0: USB ACM device
[12601.105300] cdc_ether 2-1.7:2.2 usb0: register 'cdc_ether' at usb-0000:00:1d.0-1.7, CDC Ethernet Device, 46:a1:e7:6d:5c:32
- If you run the command "ifconfig", you will find the usb0, then you can connect it with the SSH command to login the NanoPi(192.168.100.1):
It required the password, input the password fa.
2.2 Configure the WiFi connection
- After you connect the board by SSH(The default system is Debian), then run the follow command to check the WiFi device:
If the Wlan device is wlan0, you should create the same name file "wlan0" in the /etc/network/interfaces.d/, as the follow command:
Add the follow content in wlan0
iface lo inet loopback
iface wlan0 inet dhcp
Notice: the "YourWiFiESSID" is your WiFi AP name, "YourWiFiPassword" is your WiFi Ap password, replace it. then save the file and restart the Network as the follow command:
Then it will connect the WiFi AP when boot the system.
- If you use the Rabbit linux system run the follow command the configure the WiFi.
wpa_passphrase YourWiFiESSID 'YourWiFiPassword' >> /etc/wpa.conf
wpa_cli -iwlan0 reconfigure
Notice: The WiFi Router name is YourWiFiESSID , the password is YourWiFiPassword, after you configure it, the board will save the wifi configure info, and will connect the WiFi auto when boot the system for everytime, if you want the change the WiFi saved configure, you can edit the file "/etc/wpa.conf" to reset the WiFi info.
The default WiFi connecttion configure is DHCP, if you want to configure the wifi with static IP, you can edit the /usr/sbin/wpa_action, and replace the "udhcpc" to "ifconfig" command. For the DHCP or Static IP demo in the /usr/sbin/wpa_action, click here to see the demo file.
If you want to scan the WiFi AP device, run the follow command to Scan it:
wpa_cli -iwlan0 scan
wpa_cli -iwlan0 scan_result
2.3 Install the Debian software package
- We provide the stand Debian jessie, you can run the apt-get to install the software, for the first time, you can udpate the source list as follow command:
- Then you can install the software as followŁ¬ such as install the ftp server
apt-get install vsftpd