2021-07-20 06:00 AM
Hi,
I am trying to interface a rotary encoder to A7 on STM32MP1.
I was able to get the CubeMx COnfiguration done and got the device tree file generated.
Also looked into this document:
https://wiki.st.com/stm32mpu/wiki/Interrupt_overview#pinctrl_irqchip
However i could not understand simply how do i detect interrupt has happened and take decision over it?
How are interrupt handler for this needs to be written?
Solved! Go to Solution.
2021-07-20 07:55 AM
Did you check the SDK environment (needed to run a script each time a new console is open), see https://wiki.st.com/stm32mpu/wiki/Install_the_SDK#Start_the_SDK_up ?
Regards.
2021-07-20 06:11 AM
Hi,
did you have a look to https://wiki.st.com/stm32mpu/wiki/IIO_overview#How_to_use_the_framework
Regards.
2021-07-20 07:43 AM
Hi @PatrickF . Thanks for your reply.
I am trying this procedure. But in due course while trying to compile the dts file while following this procedure i get error:
npal@npal-noccarc:~/STMDTB/kernel/kernel-sources$ make stm32mp157c-rotaryencoder-mx.dtb LOADADDR=0xC2000040 O="$PWD/../build"
make[1]: Entering directory '/home/npal/STMDTB/kernel/build'
make[1]: *** No rule to make target 'stm32mp157c-rotaryencoder-mx.dtb'. Stop.
make[1]: Leaving directory '/home/npal/STMDTB/kernel/build'
make: *** [Makefile:185: __sub-make] Error 2
I tried adding this manually to Makefile too. But not luck. Any suggestions?
2021-07-20 07:55 AM
Did you check the SDK environment (needed to run a script each time a new console is open), see https://wiki.st.com/stm32mpu/wiki/Install_the_SDK#Start_the_SDK_up ?
Regards.
2021-07-21 01:59 AM
hI @PatrickF : Thanks for pointing that out. Looks like it exits cleanly but not dtbs is generated. Am i missing something here ? I cannot see any dtb files generated in arch/arm/dts folder. post using alternate command make dtbs as well.