|
| 1 | +# LCD and LCD Driver |
| 2 | + |
| 3 | +## LCD screen |
| 4 | + |
| 5 | +* Dimensions: |
| 6 | + * Glass: 35mm x 32mm\* x 2mm |
| 7 | + * \* ~7mm of the top is for the driver chip and FPC connection and otherwise "empty" glass |
| 8 | + * Display area: approx. 28mm x 19.5mm |
| 9 | + * Reflector panel: approx. 34.8mm x 24.7mm |
| 10 | +* Pixels: 96 x 64 |
| 11 | +* Markings on glass (display side): |
| 12 | + * Upper left: `A` centered over `F11` |
| 13 | + * Upper right: `7680` |
| 14 | + * A `+` on either side |
| 15 | + * Dots around where the FPC connects with lines above them that match to etched lines on the FPC |
| 16 | +* Marking on FPC: `1012-90` |
| 17 | + |
| 18 | +Taped to the plastic front with clear, double-sided 3 mm wide tape in a hollow rectangle shape, the rectangle being approx. 35.4mm x 27.6mm on the outside |
| 19 | + |
| 20 | +The reflector is taped to the board with approx. 28mm (l) x 4mm (w) x 3.6mm (h) black foam tape |
| 21 | + |
| 22 | +## S1D15xxx LCD driver |
| 23 | + |
| 24 | +[S1D15000 Series Technical Manual](https://www.crystalfontz.com/controllers/uploaded/Epson%20S1D15605_SED1565_577706%20Tech%20Manual%20v1.1.pdf) |
| 25 | + |
| 26 | +* Part number: S1D15605?xxxx?? |
| 27 | + * S1 - Seiko Epson, previously SE |
| 28 | + * D - Model name: Driver |
| 29 | + * 15605 - Model number |
| 30 | + * ? - Shape (unknown) |
| 31 | + * xxxx - Specifications (unknown) |
| 32 | + * ?? - Packing specification (unknown) |
| 33 | +* Supply voltage range: 1.8 to 5.5 V |
| 34 | +* LCD voltage range: 4.5 to 16 V |
| 35 | +* Duty: 1/65 (1/7, 1/9 bias) |
| 36 | +* Segments: 132 |
| 37 | +* Commons: 65 |
| 38 | +* Display RAM: 132x65 = 8580 bits |
| 39 | +* Microprocessor interface: 8-bit parallel |
| 40 | +* Frequency: 33 KHz |
| 41 | +* Package: Chip on Glass (COG) |
| 42 | +* Built-in power circuit for LCD (DC/DCx4) |
| 43 | + |
| 44 | +The driver runs in parallel mode (P/S = HIGH), master operation (M/S = HIGH), with the internal oscillator circuit disabled (C/S = LOW). Thus the CL line takes input from the MCU via OSC1 and the FR line switching resets register $8A to 1 and increases $81's frame counter by 1 (see page 8-29 for a diagram). |
| 45 | + |
| 46 | +### Commands |
| 47 | + |
| 48 | +To simplify interaction with the LCD, try [libpmdd](https://github.com/logicplace/libpmdd) instead of direct access. |
| 49 | + |
| 50 | +LCD_CTRL is primarily used for sending commands to the LCD driver and is accessible through register $FE on the PM. |
| 51 | + |
| 52 | +LCD_DATA is primarily used for sending display data to the LCD driver and is accessible through register $FF on the PM. |
| 53 | + |
| 54 | +LCD_CTRL and LCD_DATA both write and read over the D0-D7 lines, it determines what operation is happening and whether CTRL or DATA is being read/written by the status of the A0, <u style="text-decoration:overline">RD</u>, & <u style="text-decoration:overline">WR</u> lines. |
| 55 | + |
| 56 | +| A0 | <u style="text-decoration:overline">RD</u> | <u style="text-decoration:overline">WR</u> | R/W | CTRL/DATA | |
| 57 | +|---|---|---| ----- | ---- | |
| 58 | +| 0 | 0 | 1 | Read | CTRL | |
| 59 | +| 0 | 1 | 0 | Write | CTRL | |
| 60 | +| 1 | 0 | 1 | Read | DATA | |
| 61 | +| 1 | 1 | 0 | Write | DATA | |
| 62 | + |
| 63 | +#### Command list |
| 64 | + |
| 65 | +Listed below are the commands, written to CTRL. |
| 66 | + |
| 67 | +| Cmd # | Command | Command Code | Hex range | |
| 68 | +|----------:| ------------------ | --------------- | --------- | |
| 69 | +| [1][] | Display ON/OFF | 1 0 1 0 1 1 1 x | $AE - $AF | |
| 70 | +| [2][] | Display start line | 0 1 a a a a a a | $40 - $7F | |
| 71 | +| [3][] | Set Page | 1 0 1 1 a a a a | $B0 - $BF | |
| 72 | +| [4a][4] | Set Column HI | 0 0 0 1 h h h h | $10 - $1F | |
| 73 | +| [4b][4] | Set Column LO | 0 0 0 0 l l l l | $00 - $0F | |
| 74 | +| [8][] | ADC select | 1 0 1 0 0 0 0 x | $A0 - $A1 | |
| 75 | +| [9][] | Invert | 1 0 1 0 0 1 1 x | $A6 - $A7 | |
| 76 | +| [10][] | All on | 1 0 1 0 0 1 0 x | $A4 - $A5 | |
| 77 | +| [11][] | LCD bias | 1 0 1 0 0 0 1 x | $A2 - $A3 | |
| 78 | +| [12][] | Start RMW | 1 1 1 0 0 0 0 0 | $E0 | |
| 79 | +| [13][12] | End RMW | 1 1 1 0 1 1 1 0 | $EE | |
| 80 | +| [14][] | Reset | 1 1 1 0 0 0 1 0 | $E2 | |
| 81 | +| [15][] | Row direction | 1 1 0 0 x - - - | $C0 - $CF | |
| 82 | +| [16][] | Power control | 0 0 1 0 1 m m m | $28 - $2F | |
| 83 | +| [17][] | V5 resistor ratio | 0 0 1 0 0 r r r | $20 - $27 | |
| 84 | +| [18a][18] | Contrast | 1 0 0 0 0 0 0 1 | $81 | |
| 85 | +| [18b][18] | Contrast | - - v v v v v v | $00 - $FF | |
| 86 | +| [19a][19] | Static indicator | 1 0 1 0 1 1 0 x | $AC - $AD | |
| 87 | +| [19b][19] | Static indicator | - - - - - - m m | $00 - $FF | |
| 88 | +| [20][] | Power saver | | | |
| 89 | +| [21][] | NOP | 1 1 1 0 0 0 1 1 | $E3 | |
| 90 | +| [22][] | Test | 1 1 1 1 - - - - | $F0 - $FF | |
| 91 | + |
| 92 | +[1]: cmd/1.md |
| 93 | +[2]: cmd/2.md |
| 94 | +[3]: cmd/3.md |
| 95 | +[4]: cmd/4.md |
| 96 | +[5]: cmd/5.md |
| 97 | +[6]: cmd/6.md |
| 98 | +[7]: cmd/7.md |
| 99 | +[8]: cmd/8.md |
| 100 | +[9]: cmd/9.md |
| 101 | +[10]: cmd/10.md |
| 102 | +[11]: cmd/11.md |
| 103 | +[12]: cmd/12.md |
| 104 | +[14]: cmd/14.md |
| 105 | +[15]: cmd/15.md |
| 106 | +[16]: cmd/16.md |
| 107 | +[17]: cmd/17.md |
| 108 | +[18]: cmd/18.md |
| 109 | +[19]: cmd/19.md |
| 110 | +[20]: cmd/20.md |
| 111 | +[21]: cmd/21.md |
| 112 | +[22]: cmd/22.md |
| 113 | + |
| 114 | +#### Writing to display RAM |
| 115 | + |
| 116 | +Writes the byte to display RAM at the current cursor location then increments the cursor by 1. When the cursor reaches the end of the current page, it *does not* wrap around to the next page, you must do this manually. |
| 117 | + |
| 118 | +The data sent is displayed in a column of the current page formed as 0bABCDEFGH being (when rows are...) |
| 119 | + |
| 120 | +| Normal | Reversed | |
| 121 | +|:------:|:--------:| |
| 122 | +| H | A | |
| 123 | +| G | B | |
| 124 | +| F | C | |
| 125 | +| E | D | |
| 126 | +| D | E | |
| 127 | +| C | F | |
| 128 | +| B | G | |
| 129 | +| A | H | |
| 130 | + |
| 131 | +Then moves one column to the right (if ADC is normal) or left (if ADC is reversed). |
| 132 | + |
| 133 | +#### Reading display RAM |
| 134 | + |
| 135 | +TODO: how to read reliably |
| 136 | + |
| 137 | +Reading from LCD_DATA reads the byte in display RAM where the cursor is currently. If the driver is currently operating in RMW mode, the cursor is not incremented after reading. Otherwise, it is incremented. |
| 138 | + |
| 139 | +TODO: does ADC reverse reading direction? |
| 140 | + |
| 141 | +#### Reading display status |
| 142 | + |
| 143 | +Read from LCD_CTRL. TODO: how to read reliably |
| 144 | + |
| 145 | +The returned byte contains status information in the upper nibble: |
| 146 | + |
| 147 | +* D7 - BUSY - 1 = busy, 0 = not busy |
| 148 | + * "Busy" means doing some sort of internal process or reset, during which it cannot accept commands. |
| 149 | + * There's no need to check the busy signal. |
| 150 | +* D6 - ADC - 0 = reverse, 1 = normal |
| 151 | + * This is opposite to the assignment command. |
| 152 | + * The command $A0 will cause this status bit to be 1. |
| 153 | + * The command $A1 will cause this status bit to be 0. |
| 154 | +* D5 - ON/OFF - 0 = ON 1 = OFF |
| 155 | + * This is opposite to the assignment command. |
| 156 | + * The command $AE will cause this status bit to be 0. |
| 157 | + * The command $AF will cause this status bit to be 1. |
| 158 | +* D4 - RESET - 1 = reset in progress |
| 159 | + |
| 160 | +## FPC board connector pinout |
| 161 | + |
| 162 | +TODO: orientation |
| 163 | + |
| 164 | +1. VRS |
| 165 | +2. V5 |
| 166 | +3. V4 |
| 167 | +4. V3 |
| 168 | +5. V2 |
| 169 | +6. V1 |
| 170 | +7. CAP2- |
| 171 | +8. CAP2+ |
| 172 | +9. CAP1- |
| 173 | +10. CAP1+ |
| 174 | +11. CAP3- (mislabled as CAP3+ in the block diagram) |
| 175 | +12. VOUT |
| 176 | +13. VSS (GND) |
| 177 | +14. VDD (VCC) |
| 178 | +15. D7 |
| 179 | +16. D6 |
| 180 | +17. D5 |
| 181 | +18. D4 |
| 182 | +19. D3 |
| 183 | +20. D2 |
| 184 | +21. D1 |
| 185 | +22. D0 |
| 186 | +23. <u style="text-decoration:overline">RD</u> |
| 187 | +24. <u style="text-decoration:overline">WR</u> |
| 188 | +25. A0 |
| 189 | +26. <u style="text-decoration:overline">RES</u> |
| 190 | +27. CS |
| 191 | +28. CL |
| 192 | +29. FR |
0 commit comments