MAX1233/MAX1234触摸屏控制器入门
时间:03-17
来源:互联网
点击:
T R GC
Test Read GPIO_control register 0x804f 0x0000
T R GD
Test Read GPIO_data register 0x800f 0x0000
T R GP
Test Read GPIO_pullup register 0x804e 0x0000
T R K1
Test Read KPDATA1 register 0x8010 0x0000
T R K2
Test Read KPDATA2 register 0x8011 0x0000
T R KB
Test Read KPD register 0x8004 0x0000
T R KC
Test Read KEY_control register 0x8041 0x0000
T R KK
Test Read KPCOLMASK register 0x8051 0x0000
T R KM
Test Read KPKEYMASK register 0x8050 0x0000
T R T1
Test Read TEMP1 register 0x8009 0x0000
T R T2
Test Read TEMP2 register 0x800a 0x0000
表21. 写入寄存器助记符DEMO1234 Command
Mnemonic SPI data in
T W AC hexValue
Test Write ADC_control register 0x0040 hexValue
T W DC hexValue
Test Write DAC_control register 0x0042 hexValue
T W DD hexValue
Test Write DAC_data register 0x000b hexValue
T W GC hexValue
Test Write GPIO_control register 0x004f hexValue
T W GD hexValue
Test Write GPIO_data register 0x000f hexValue
T W GP hexValue
Test Write GPIO_pullup register 0x004e hexValue
T W KC hexValue
Test Write KEY_control register 0x0041 hexValue
T W KK hexValue
Test Write KPCOLMASK register 0x0051 hexValue
T W KM hexValue
Test Write KPKEYMASK register 0x0050 hexValue
表22. 触摸屏测量命令序列DEMO1234 Command
Action (Triggered by A/D3210 Bits) SPI data in Sequence
T M1
Measure X,Y 0x0040 0x0701
0x8000 0x0000
0x8001 0x0000
T M2
Measure X,Y,Z1,Z2 0x0040 0x0b01
0x8000 0x0000
0x8001 0x0000
0x8002 0x0000
0x8003 0x0000
T M3
Measure X 0x0040 0x0f01
0x8000 0x0000
T M4
Measure Y 0x0040 0x1301
0x8001 0x0000
T M5
Measure Z1,Z2 0x0040 0x1701
0x8002 0x0000
0x8003 0x0000
T MD
No measurement; drive Y+,Y- 0x0040 0x3701
T ME
No measurement; drive X+,X- 0x0040 0x3b01
T MF
No measurement; drive Y+,X- 0x0040 0x3f01
6.2) 中断和状态引脚命令
表23. 引脚状态读取命令DEMO1234 Command
Action SPI data in
P R 5
Read KEYIRQ-bar pin status N/A I C 0 3
Enable KEYIRQ-bar falling-edge trigger pulse accumulator N/A I C 0 1
Enable KEYIRQ-bar rising-edge trigger pulse accumulator N/A I C 0 0
Disable KEYIRQ-bar pulse accumulator N/A I R 0
Read the number of times KEYIRQ-bar has pulsed low N/A I 0 0
Clear the KEYIRQ-bar pulse accumulator N/A P R 6
Read PENIRQ-bar pin status N/A I C 1 3
Enable PENIRQ-bar falling-edge trigger pulse accumulator N/A I C 1 1
Enable PENIRQ-bar rising-edge trigger pulse accumulator N/A I C 1 0
Disable PENIRQ-bar pulse accumulator N/A I R 1
Read the number of times PENIRQ-bar has pulsed low N/A I 0 1
Clear the PENIRQ-bar pulse accumulator N/A P R 7
Read BUSY-bar pin status N/A 6.3) 加入到更新后的MINIQUSB+固件中的命令
表24. 更新后MINIQUSB+固件01.05.40支持的SPI命令DEMO1234 Command
Action CPOL CPHA CS-Bar Control AF Length S C L0
Configure SPI for CPOL=0 0 — GPIO-K9 1 byte S C L1
Configure SPI for CPOL=1 1 — GPIO-K9 1 byte S C A0
Configure SPI for CPHA=0 — 0 GPIO-K9 1 byte S C A1
Configure SPI for CPHA=1 — 1 GPIO-K9 1 byte S C C0
Configure SPI for 8-bit — — GPIO-K9 1 byte S C C1
Configure SPI for 8-bit auto-CS-bar — — Automatic 1 byte S C C2
Configure SPI for 16-bit auto-CS-bar — — Automatic 2 bytes S C C3
Configure SPI for 24-bit auto-CS-bar — — Automatic 3 bytes S C C4
Configure SPI for 32-bit auto-CS-bar — — Automatic 4 bytes $ 2 AE 00
Configure SPI for 8-bit 0 0 GPIO-K9 1 byte $ 2 AE 01
Configure SPI for 8-bit 0 1 GPIO-K9 1 byte $ 2 AE 02
Configure SPI for 8-bit 1 0 GPIO-K9 1 byte $ 2 AE 03
Configure SPI for 8-bit 1 1 GPIO-K9 1 byte $ 2 AE 08
Configure SPI for 8-bit auto-CS-bar 0 0 Automatic 1 byte $ 2 AE 09
Configure SPI for 8-bit auto-CS-bar 0 1 Automatic 1 byte $ 2 AE 0A
Configure SPI for 8-bit auto-CS-bar 1 0 Automatic 1 byte $ 2 AE 0B
Configure SPI for 8-bit auto-CS-bar 1 1 Automatic 1 byte $ 2 AE 18
Configure SPI for 16-bit auto-CS-bar 0 0 Automatic 2 bytes $ 2 AE 19
Configure SPI for 16-bit auto-CS-bar 0 1 Automatic 2 bytes $ 2 AE 1A
Configure SPI for 16-bit auto-CS-bar 1 0 Automatic 2 bytes $ 2 AE 1B
Configure SPI for 16-bit auto-CS-bar 1 1 Automatic 2 bytes
- 声学脉冲波辨识触摸屏控制技术(09-16)
- 电容式触摸屏系统解决方案(01-19)
- 触摸屏设计日益简化(03-03)
- 将系统的阻性触摸屏更新到多点触摸屏(10-22)
- 基于嵌入式技术的智能仪器触摸屏接口设计(03-02)
- 如何解决触摸屏的电磁干扰问题(03-01)