I have a problem with my EFM8 starter kit, specifically the SLSTK2000A board.
My goal: I want to use the integrated memory display to show the user some options. The user can select an option using the integrated joystick and confirm the selection with either button. Each option will then write an I2C message to an attached GPIO exnteder IC.
Initial approach: I have inplemented the whole selection logic by starting with the rainbow blinky example project and append my functionality. This works fine until I try to integrate the SMBus0 as master. THe problem is that the ISR for the SMBus does not get called when a write or read command is issued.
Alternative approach: I started with the SMBus0 example project and implemented my I2C functionality. This again works fine. The whole project crashes when I try to integrate the memory lcd peripheral drivers. When I boot the controller it hangs up in the display initialization function. I could track down the issue to a wait function. This function rellies on the Timer 3 overflow interrupt to increment a counter variable. Once a threshold is reached the wait function returns. However, the Timer 3 ISR is never called.
As far as I can see the hardware configuration of both projects is the same. There seems to be a problem with my understanding of how to implement or register ISRs to the project. I have no idea how to proceed from here and hope for your help.
I suggest you continue the 'initial approach ', pay attention on the crossbar and double check if you assign pins to SMBus peripheral correctly.
I have actually solved the problem for the alternative approach. At least I am one step further.
Both, SMBus and the memory lcd wait utilize the Timer3 overflow. When the SMBus0 SCL timeout detection is on, Timer3 gets reset on a high input at the SMB SCL pin. This leads to Timer3 "freezing".
Check also the problem here:
So, I was finally able to get the memory display working with the alternative way. The key was to enable the Timer 2 interrupt via the device configurator.
However, I am back to the initial problem. When the memory display works the SMBus won't do so. So far I can see that after issuing an SMB_Write the SMBUS0_ISR is not triggered. It seems there is a deeper issue I do not understand right now.
Is there an example project or tutorial demonstrating the use of SMBus and memory lcd simultaneously on the SLSTK2000A?
Pardon the delayed response to this post. We don't have any examples where these parts work together, but if this is still an issue please post the initialization code generated by configurator and we can take a look for conflicts/mis-initialized interrupts.