Difference between revisions of "NanoHat OLED for NanoPi NEO2 Black/zh"

From FriendlyELEC WiKi
Jump to: navigation, search
(手动使能NanoHat-OLED)
(Play with Demo Programs)
 
(12 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
[[NanoHat OLED for NanoPi NEO2 Black|English]]
 
[[NanoHat OLED for NanoPi NEO2 Black|English]]
  
==介绍==
+
==Introduction==
 
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black.jpg|thumb|NanoHat OLED for NanoPi NEO2 Black]]
 
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black.jpg|thumb|NanoHat OLED for NanoPi NEO2 Black]]
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black_top.png|thumb|正面]]
+
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black_top.png|thumb|Front]]
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black_bot.png|thumb|背面]]
+
[[File:NanoHat_OLED_for_NanoPi_NEO2_Black_bot.png|thumb|Back]]
*NanoHat OLED for NanoPi NEO2 Black是转为NanoPi NEO2 Black定制的一款精致小巧的单色OLED显示屏,0.96英寸,分辨率是128x64,对比度高,功耗低,可以用来显示文字或图案。通过I2C和NanoPi NEO2 Black通讯。
+
*The NanoHat OLED for NanoPi NEO2 Black module is a monochrome OLED module designed and developed by FriendlyElec for the NanoPi NEO2 Black. It is 0.96" and the resolution is 128 x 64. It has high contrast and low power-consumption. It can display characters and images. It communicates with a NanoPi NEO2 Black with I2C.
*NanoHat OLED for NanoPi NEO2 Black和NanoPi NEO2 Black的外形尺寸和接口完全相同,可直接堆叠在NanoPi NEO2 Black上使用。
+
*The size of the NanoHat OLED for NanoPi NEO2 Black is the same as the size of the NanoPi NEO2 Black. The OLED module can be stacked onto a NanoPi NEO2 Black.
*板载了3个按键,用户可以自定义按键功能。
+
*The module has three programmable keys.
*板载了3.5mm音频接口插座和USB Type A接口。
+
*The module has a 3.5mm audio jack and a USB Type A port.
  
==特性==
+
==Hardware Spec==
* 屏幕尺寸:0.96英寸
+
* Size: 0.96"
* 分辨率:128x64
+
* Resolution: 128 x 64
* 高对比度,低功耗
+
* High contrast and low power consumption
* 板载3个按键
+
* 3 x onboard key
* PCB尺寸(mm):40x40
+
* PCB dimension(mm): 40 x 40
 
[[File:NanoHat_OLED_1910_dim.png|frameless|400px|NanoHat OLED for NanoPi NEO2 Black PCB]]
 
[[File:NanoHat_OLED_1910_dim.png|frameless|400px|NanoHat OLED for NanoPi NEO2 Black PCB]]
  
Line 46: Line 46:
 
|}
 
|}
  
==支持该配件的开发板型号和软件版本==
+
==Applicable Board & OS==
 
{| class="wikitable"
 
{| class="wikitable"
 
|-
 
|-
|序号 ||CPU型号|| 开发板型号 || 软件版本
+
|Index ||CPU Model|| Board Type || OS
 
|-
 
|-
|1    ||H5||NanoPi NEO2 Black || 开源社区Linux-4.x主线内核
+
|1    ||H5||NanoPi NEO2 Black || Open Source Linux-4.x Mainline Kernel
 
|-
 
|-
 
|}
 
|}
  
==硬件连接==
+
==Hardware Setup==
NanoHat OLED for NanoPi NEO2 Black模块和NanoPi NEO2 Black尺寸和接口完全相同,可直接堆叠使用。
+
The size of the NanoHat OLED for NanoPi NEO2 Black is the same as the size of the NanoPi NEO2 Black. The module can be stacked onto a NanoPi NEO2 Black.
参考下图连接模块:<br>
+
Here is a hardware setup:<br>
 
[[File:NanoHat OLED_NanoPi_NEO2_Black.jpg|frameless|500px|NanoHat_OLED_NanoPi_NEO2_Black]]
 
[[File:NanoHat OLED_NanoPi_NEO2_Black.jpg|frameless|500px|NanoHat_OLED_NanoPi_NEO2_Black]]
  
==使用默认使能NanoHat OLED for NanoPi NEO2 Black的ROM==
+
==ROM That Enables Support for NanoHat OLED for NanoPi NEO2 Black==
 
::{| class="wikitable"
 
::{| class="wikitable"
 
|-
 
|-
 
|Board Type||CPU Model||Download Link to Image File||Image File
 
|Board Type||CPU Model||Download Link to Image File||Image File
 
|-
 
|-
|NanoPi NEO2 Black|| H5 ||[http://download.friendlyarm.com/nanopineo2 Download] || official-ROMs/nanopi-neo2_ubuntu-oled_4.x.y_YYYYMMDD.img.zip
+
|NanoPi NEO2 Black|| H5 ||[http://download.friendlyarm.com/nanopineo2black Download] || official-ROMs/accessory-ROMs/nanopi-neo2-black_ubuntu-oled_4.x.y_YYYYMMDD.img.zip
 
|-
 
|-
 
|}
 
|}
  
==手动使能NanoHat OLED for NanoPi NEO2 Black==
+
==Manually Enable Support for NanoHat OLED for NanoPi NEO2 Black==
NanoHat OLED for NanoPi NEO2 Black的演示程序包含在 NanoHatOLED 软件仓库里,启动系统,执行以下命令进行安装:<br />
+
FriendlyElec developed some demo programs for the NanoHat OLED for NanoPi NEO2 Black and these demo programs are contained in the NanoHatOLED's github. You can download and install these programs by running the following commands after you boot a NanoPi NEO2 Black:<br />
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
git clone https://github.com/friendlyarm/NanoHatOLED.git
 
git clone https://github.com/friendlyarm/NanoHatOLED.git
Line 77: Line 77:
 
</syntaxhighlight>
 
</syntaxhighlight>
 
<br />
 
<br />
安装脚本会在线下载并安装一系列的软件包,安装时间视网络环境而定,国内大陆的用户为了获得更快的安装速度,可以在安装之前先将软件包的源设置为国内源,执行以下命令,使用我们提供的脚本进行设置:<br />
+
Running the installation script will download necessary packages. You can set the download source to your preferred one to speed up the process. To change the download source run the following command:<br />
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
wget http://112.124.9.243/aptsouce.sh
 
wget http://112.124.9.243/aptsouce.sh
Line 84: Line 84:
 
sudo apt-get update
 
sudo apt-get update
 
</syntaxhighlight>
 
</syntaxhighlight>
操作完成后,再执行NanoHatOLED的 ./install.sh 安装脚本安装即可。
+
After the download steps are done run the "NanoHatOLED的 ./install.sh" script to install them.
 
<br />
 
<br />
  
==演示程序的操作说明==
+
==Play with Demo Programs==
  
演示程序在安装后会在开机时自动运行,并默认显示 日期与时间 画面。<br />
+
The demo programs will be automatically run and show date, time and GUI after the OS loads.<br />
NanoHat OLED配件上的三个按键功能如下:<br />
+
The NanoHat OLED module has three keys and their functions are defined as follows:<br />
K1 -> 显示日期时间; <br />
+
K1 -> Shows date and time; <br />
K2 -> 显示开发板的运行状态,例如 IP地址, 负载, 存储状态,CPU温度等信息; <br />
+
K2 -> Shows system status such as IP address, CPU usage, storage usage, CPU temperature and etc;<br />
K3 -> 关机操作,并不会立即关机,而是先弹出询问画面,在询问画面的状态下,用 K1 切换 Yes和No选项,K2进行确认; <br />
+
K3 -> Powers off the system. When this key is pressed the system will not immediately be turned off and instead it will pop up a confirmation window with a Yes and a No options. You can press the K2 key to select Yes or No;<br />
 
<br />
 
<br />
  
==相关资料==
+
==Resources==
  
*[Schematic]([http://wiki.friendlyarm.com/wiki/images/d/df/Schematic_NanoHat_OLED_for_NanoPi_NEO2_Black.pdf NanoHat_OLED_for_NanoPi_NEO2_Black原理图pdf文件])
+
*[Schematic]([http://wiki.friendlyarm.com/wiki/images/d/df/Schematic_NanoHat_OLED_for_NanoPi_NEO2_Black.pdf NanoHat_OLED_for_NanoPi_NEO2_Black Schematic file in pdf format])
*[Dimension]([http://wiki.friendlyarm.com/wiki/index.php/File:Dimension_NanoHat_OLED_for_NanoPi_NEO2_Black_PCB.rar NanoHat_OLED_for_NanoPi_NEO2_Black_PCB的DXF文件])
+
*[Dimension]([http://wiki.friendlyarm.com/wiki/index.php/File:Dimension_NanoHat_OLED_for_NanoPi_NEO2_Black_PCB.rar NanoHat_OLED_for_NanoPi_NEO2_Black_PCB file in DXF format])
 
*[Datasheet]([http://wiki.friendlyarm.com/wiki/images/a/af/096-30-SPEC_QG-2864KLBEG01_VER_C.pdf NanoHat OLED Datasheet.pdf])
 
*[Datasheet]([http://wiki.friendlyarm.com/wiki/images/a/af/096-30-SPEC_QG-2864KLBEG01_VER_C.pdf NanoHat OLED Datasheet.pdf])

Latest revision as of 08:52, 7 January 2020

English

1 Introduction

NanoHat OLED for NanoPi NEO2 Black
Front
Back
  • The NanoHat OLED for NanoPi NEO2 Black module is a monochrome OLED module designed and developed by FriendlyElec for the NanoPi NEO2 Black. It is 0.96" and the resolution is 128 x 64. It has high contrast and low power-consumption. It can display characters and images. It communicates with a NanoPi NEO2 Black with I2C.
  • The size of the NanoHat OLED for NanoPi NEO2 Black is the same as the size of the NanoPi NEO2 Black. The OLED module can be stacked onto a NanoPi NEO2 Black.
  • The module has three programmable keys.
  • The module has a 3.5mm audio jack and a USB Type A port.

2 Hardware Spec

  • Size: 0.96"
  • Resolution: 128 x 64
  • High contrast and low power consumption
  • 3 x onboard key
  • PCB dimension(mm): 40 x 40

NanoHat OLED for NanoPi NEO2 Black PCB

  • GPIO1(I2C/UART/GPIO)
Pin# Name Linux gpio Pin# Name Linux gpio
1 GPIOA0 0 2 5V in or out -
3 I2C_SDA0 - 4 5V in or out -
5 I2C_SCL0 - 6 GND -
7 GPIOA2 2 8 UART1_TX -
9 GND - 10 UART1_RX -
  • GPIO2(USB/Audio OUT)
Pin# Name Linux gpio Pin# Name Linux gpio
1 Line out Right - 2 USB DM -
3 Line out Left - 4 USB DP -
5 Audio GND - 6 GPIOA3 3

3 Applicable Board & OS

Index CPU Model Board Type OS
1 H5 NanoPi NEO2 Black Open Source Linux-4.x Mainline Kernel

4 Hardware Setup

The size of the NanoHat OLED for NanoPi NEO2 Black is the same as the size of the NanoPi NEO2 Black. The module can be stacked onto a NanoPi NEO2 Black. Here is a hardware setup:
NanoHat_OLED_NanoPi_NEO2_Black

5 ROM That Enables Support for NanoHat OLED for NanoPi NEO2 Black

Board Type CPU Model Download Link to Image File Image File
NanoPi NEO2 Black H5 Download official-ROMs/accessory-ROMs/nanopi-neo2-black_ubuntu-oled_4.x.y_YYYYMMDD.img.zip

6 Manually Enable Support for NanoHat OLED for NanoPi NEO2 Black

FriendlyElec developed some demo programs for the NanoHat OLED for NanoPi NEO2 Black and these demo programs are contained in the NanoHatOLED's github. You can download and install these programs by running the following commands after you boot a NanoPi NEO2 Black:

git clone https://github.com/friendlyarm/NanoHatOLED.git
cd NanoHatOLED
sudo -H ./install.sh


Running the installation script will download necessary packages. You can set the download source to your preferred one to speed up the process. To change the download source run the following command:

wget http://112.124.9.243/aptsouce.sh
chmod 755 aptsouce.sh
sudo -H ./aptsouce.sh
sudo apt-get update

After the download steps are done run the "NanoHatOLED的 ./install.sh" script to install them.

7 Play with Demo Programs

The demo programs will be automatically run and show date, time and GUI after the OS loads.
The NanoHat OLED module has three keys and their functions are defined as follows:
K1 -> Shows date and time;
K2 -> Shows system status such as IP address, CPU usage, storage usage, CPU temperature and etc;
K3 -> Powers off the system. When this key is pressed the system will not immediately be turned off and instead it will pop up a confirmation window with a Yes and a No options. You can press the K2 key to select Yes or No;

8 Resources