1 Introduction
2 ------------
3
4 The ben-epaper distribution provides a program, epaper, that runs on the Ben
5 NanoNote and controls the EM027AS012 display from Pervasive Displays on an
6 Embedded Artists' 2.7 inch E-paper Display module. To connect the module to
7 the Ben, the 8:10 port which is typically employed to access microSD cards is
8 instead used to hold a suitable breakout board that exposes the 8:10 port's
9 connectors to other circuits. These connectors are in turn connected to
10 specific connectors on the E-Paper Display module as follows:
11
12 Sniffer UBB EM027AS012
13 ------- ---- -----------
14 DAT2 DAT2 4 (MOSI)
15 CD DAT3 6 (SSEL)
16 CMD CMD 11 (PWM)
17 VCC VDD 13 (PANEL)
18 CLK CLK 3 (SCK)
19 GND GND
20 DAT0 DAT0 12 (RESET)
21 DAT1 DAT1 14 (DIS)
22
23 On the E-Paper Display module the socket appears as follows, with the numbered
24 pins protruding from the board:
25
26 Socket
27 --------------------
28 2 4 6 8 10 12 14
29 1 3 5 7 9 11 13
30 ---------__---------
31
32 However, it is more convenient to use standard male-to-male jumper wires to
33 connect the Sniffer or UBB breakout board to the end of a suitable cable which
34 in turn plugs into the socket on the E-Paper Display module board. The jumper
35 wires plug into the holes in the cable plug. Remember that the pin numbering
36 is "mirrored" on the end of the cable:
37
38 __
39 --------- ---------
40 1 3 5 7 9 11 13
41 2 4 6 8 10 12 14
42 --------------------
43 Cable
44
45 In addition to the Sniffer or UBB connections, additional connections for 3.3V
46 power and ground must be connected as follows:
47
48 3.3V Supply EM027AS012
49 ----------- ----------
50 GND 1 (GND)
51 3V3 2 (3V3)
52
53 Note that the VCC output of the 8:10 port is used as a "power control" signal
54 and not to power the display board.
55
56 Collecting Images for Display
57 -----------------------------
58
59 Before building the epaper program, you will first need to collect some images
60 with the following specific properties:
61
62 Width: 264 pixels
63 Height: 176 pixels
64
65 An image preparation program then needs to be run on a list of image filenames
66 to produce suitable source files incorporated into the built program. This is
67 done as follows:
68
69 python tools/bitmap.py images file1.png file2.png file3.png
70
71 Here, three PNG files are loaded, internally converted (the files are not
72 changed), and the bitmap data written out to two files:
73
74 images.c
75 images.h
76
77 Since the Makefile and epaper program references these files, it is
78 recommended that the "images" basename be retained when running the bitmap.py
79 program.
80
81 Building the Software
82 ---------------------
83
84 Before building the software, it will probably be necessary to edit the
85 Makefile to specify the locations of the cross-compilation toolchain and of
86 libubb. Obtaining a toolchain and libubb is currently beyond the scope of this
87 document.
88
89 The epaper program is built as follows:
90
91 make
92
93 Running the Software
94 --------------------
95
96 On the Ben, the epaper program can be deployed together with libubb in a
97 particular directory and invoked as follows:
98
99 LD_LIBRARY_PATH=. ./epaper
100
101 Alternatively, the library search path can be configured properly and the
102 epaper program installed in such a way that merely typing the name of the
103 program is enough to run it.
104
105 The epaper program accepts a list of options:
106
107 <image number> This indicates which image to display (where 0 is
108 the first image).
109
110 --have <image number> This indicates that the display is showing the
111 image with the given number (where 0 is the first
112 image) and is used to influence subsequent
113 options.
114
115 --blank This blanks the screen, using knowledge of the
116 current screen image if provided either by the
117 --have option or by the display of a preceding
118 image.
119
120 --wait <delay in seconds> This causes a delay between operations.
121
122 Hardware: Embedded Artists' 2.7 Inch E-paper Display Module
123 -----------------------------------------------------------
124
125 This board provides an interface to the EM027AS012 display from Pervasive
126 Displays:
127
128 http://www.embeddedartists.com/products/displays/lcd_27_epaper.php
129
130 This software has only been tested with revision A of the board, and employs
131 code from Pervasive Displays that may have been superseded upon release of new
132 revisions of this and related boards (as mentioned below).
133
134 More information and source code licensed under Free Software licences can be
135 found on the RePaper site:
136
137 http://repaper.org/
138
139 Other boards that provide an interface to the EM027AS012 display and other
140 displays from the same manufacturer also exist. For example:
141
142 http://www.adafruit.com/products/1316
143
144 This software has not been tested with such boards.
145
146 Hardware: 8:10 Port Breakout Board
147 ----------------------------------
148
149 To connect the Ben NanoNote to the E-Paper Display module, a suitable breakout
150 board is required to expose the connections inside the 8:10 slot. To achieve
151 this, the Sparkfun microSD Sniffer has been used:
152
153 https://www.sparkfun.com/products/9419
154
155 This board is apparently intended for eavesdropping on communications between
156 a "host" device with a microSD slot and a microSD-based device that can be
157 inserted into a slot mounted on the board (instead of being inserted directly
158 into the host device). However, the board-mounted slot can be ignored and the
159 exposed connections routed to the display board instead.
160
161 Another board that achieves the same purpose is the Universal Breakout Board
162 (UBB):
163
164 http://en.qi-hardware.com/wiki/UBB
165
166 The UBB is somewhat more difficult to work with as its connectors are very
167 small and, compared to the microSD Sniffer, awkward to attach things to. The
168 microSD Sniffer employs connectors situated around holes with 0.1 inch
169 spacing, meaning that commonly available connection headers can be soldered
170 onto the board.
171
172 Although the labelling of the connections is different between the microSD
173 Sniffer and UBB (see above), the layout appears to be identical.
174
175 Contact, Copyright and Licence Information
176 ------------------------------------------
177
178 The author can be contacted at the following e-mail address:
179
180 paul@boddie.org.uk
181
182 Copyright and licence information can be found in the docs directory - see
183 docs/COPYING.txt and docs/gpl-3.0.txt for more information.