CMSIS QEI Example

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

CMSIS QEI Example

2,390 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by amadeu placido on Thu Sep 06 16:03:01 MST 2012
Greetings,

Lately I've been trying to make the quadrature encoder interface work, unfortunatelly all I've felt was frustration. I'm using the LPC4350-DB1 board, and have configured the pins using the SCU. However I'm not sure where the problem is.
I am also currently using an encoder that has no INDEX channel (only A and B channels). No matter how hard I try, I keep reading 0 from the position register.
And to make it worse, there was no sample code of this driver, so I'd like know if anyone used this peripheral with any luck, or have noticed any detail related to this and would be willing to share the knowledge.

Cheers!

Labels (1)
0 Kudos
Reply
7 Replies

2,123 Views
williambonsmann
Contributor II

Thank you for the reply soledad. To make this driver relevant to the LPC4357, is it just a case of changing the definitions in the header file?

0 Kudos
Reply

2,123 Views
williambonsmann
Contributor II

The link to this CMSIS driver no longer works, does anyone have this driver and would it be possible to link it to me? Thanks

0 Kudos
Reply

2,123 Views
soledad
NXP Employee
NXP Employee

Please check the below link:

CMSIS Hardware Driver Code: QEI


Have a great day,
Sol

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

2,123 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by amadeu placido on Thu Sep 13 14:58:35 MST 2012
Nevermind, I already solved the problem. Some parameters of the QEI were being rewritten upon the call of QEI_Init(), therefore it took me a while to realize it...
0 Kudos
Reply

2,123 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by amadeu placido on Tue Sep 11 13:48:21 MST 2012
Yes, I was aware of that repository and I am using it. However, despite my best efforts, the QEI still refuses to work.
I have already gotten the timers to work, but had problems with UART (couldn't make it work either). The CPU halts on some math operations.
I'm currently using the free GCC toolchain, Eclipse IDE, OpenOCD and the Olimex Tiny JTAG. Nothing until now was straight-forward. Most of the work on that MCU was done on Keil uVision or IAR EWARM.
Has anyone here been able to make all (or most of) the peripherals to work using the same tools I do? Am I missing something?

Thanks for the replies!
0 Kudos
Reply

2,123 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wellsk on Fri Sep 07 08:24:00 MST 2012
>http://git.lpcware.com/lpc43xx.git
You can clone using GIT from that address, the 43xx repo is also viewable via your browser at sw.lpcware.com
0 Kudos
Reply

2,123 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by starblue on Fri Sep 07 01:06:58 MST 2012
There is some QEI driver code in CMSIS, see http://git.lpcware.com/lpc43xx.git .

Hope this helps

Jürgen
0 Kudos
Reply