AnsweredAssumed Answered

Need clarification between clock and enable

Question asked by Argail on Nov 8, 2013
Latest reply on Nov 11, 2013 by Argail

I don't understand well how the STM8L works, when enabling a module we have to enable the clock sourcing the module and then enable the module itself, that's OK.

For module configuration (register access) it seems that the module has to be disabled and the clock enabled.

If I want to disable a module for a while without loosing the configuration, how do I proceed?

For example I enable the LCD to display a message, after some time I want to disable it to spare power. Should I:
- Stop the clock (PCKEN23=0) but let the module enabled (LCD_CR3_LCDEN=1)?
- Stop the clock (PCKEN23=0) and disable (LCD_CR3_LCDEN=0)?
- Or let the clock (PCKEN23=1) and disable (LCD_CR3_LCDEN=0)?

This is the same question for all module, which is the global principle for the STM8L?

Hoping someone will help me;)