Chinaunix首页 | 论坛 | 博客
  • 博客访问: 276614
  • 博文数量: 91
  • 博客积分: 2105
  • 博客等级: 大尉
  • 技术积分: 1050
  • 用 户 组: 普通用户
  • 注册时间: 2009-09-14 19:30
文章分类
文章存档

2011年(11)

2010年(64)

2009年(16)

我的朋友

分类: LINUX

2010-05-13 22:07:57

最近做了sep4020 下的spi总线,对于spi下面的挂载ads7846触摸屏控制器,最近在做spi总线控制器实现触摸屏,不是原来的模拟的,做过程中发现问题很多,行才是不出数据,后来用逻辑分析仪抓数据,才发现很多的问题,现在算是实现了,但还有bug,继续调试,发帖纪念:
(具体的配置以后贴出来)
调试代码:

按屏后的dbg信息:

<7>spi_bitbang: bitbang_work: before in chipselect

<7>4020: ads7846_pendown_state: penflags = :0x0 

<7>ADS7846: ads7846_irq:  enter the  ads7846_irq

<7>4020: ads7846_pendown_state: penflags = :0x0 

<7>ADS7846: ads7846_irq: we are the end of  ads7846_irq
 
<7>ADS7846: ads7846_irq:  enter the  ads7846_irq

<7>4020: ads7846_pendown_state: penflags = :0x1 

<7>ADS7846: ads7846_irq: before  hrtimer_start
 
<7>ADS7846: ads7846_irq: we are the end of  ads7846_irq
 
<7>4020: ads7846_pendown_state: penflags = :0x1 

<7>ads7846 spi0.0: txrx: tx c1c3f033, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f03e, len 3
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=8c1

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f033, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f03e, len 3
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=8c6

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f032, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f03c, len 3
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=2a3

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f032, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f03c, len 3
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=29f

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f034, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f040, len 2
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=1c

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f034, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f040, len 2
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=1c

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f035, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f042, len 2
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=fe0

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f035, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f042, len 2
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx_val: val=fe0

<7>spi_bitbang: bitbang_work: before in chipselect

<7>ads7846 spi0.0: txrx: tx c1c3f036, rx 00000000, len 1
<7>ads7846 spi0.0: txrx: tx 00000000, rx c1c3f038, len 2
<7>spi_sep4020: sep4020_spi_txrx: 

<7>spi_sep4020: sep4020_spi_txrx: 

<7>ADS7846: ads7846_rx: we are in ads7846_rx!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

<7>ADS7846: ads7846_rx: x is 0x:29f

<7>ADS7846: ads7846_rx: y is 0x:8f8

<7>ADS7846: ads7846_rx: z1 is 0x:1c

<7>ADS7846: ads7846_rx: z2 is 0xfe0

<7>ADS7846: ads7846_rx: ----------1-------------

<7>ADS7846: ads7846_rx: likely(x && z1) is 1

<7>ADS7846: ads7846_rx: ----------2-------------

<7>ADS7846: ads7846_rx: Rt is 17710

<7>ADS7846: ads7846_rx: ----------9------------

<7>ADS7846: ads7846_rx: value of ts->pendown is 1
 
<7>evbug.c: Event. Dev: input0, Type: 3, Code: 0, Value: 671
<7>evbug.c: Event. Dev: input0, Type: 3, Code: 1, Value: 2296
<7>evbug.c: Event. Dev: input0, Type: 3, Code: 24, Value: 17710
<7>evbug.c: Event. Dev: input0, Type: 0, Code: 0, Value: 0
<7>ADS7846: ads7846_rx:  671/2296/17710

<7>spi_bitbang: bitbang_work: before in chipselect

<7>4020: ads7846_pendown_state: penflags = :0x0 

<7>ADS7846: ads7846_irq:  enter the  ads7846_irq

<7>4020: ads7846_pendown_state: penflags = :0x0 

<7>ADS7846: ads7846_irq: we are the end of  ads7846_irq
阅读(1307) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

chinaunix网友2011-04-13 16:45:42

学习了,多谢楼主分享哦!也欢迎广大linux爱好者来我的论坛一起讨论arm哦!www.lt-net.cn