This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Help with CDL - controlling the RTC_PERIOD value


On Tue, 11 Oct 2011, Elad Yosef wrote:

> Hi,
> I'm trying to overwrite the CYGNUM_HAL_RTC_PERIOD user value in-case
> another option is enabled.
> 
> For example :
> if test_mode = on
> CYGNUM_HAL_RTC_PERIOD = value from ecc file
> else
> CYGNUM_HAL_RTC_PERIOD = hard coded value
> 
> Thanks
> 
> Elad
 
Hi Elad,

If I understood your question correctly then you can use the ternary
conditional operator A ? B : C  in your CDL expression

http://ecos.sourceware.org/docs-latest/cdl-guide/language.values.html#LANGUAGE.EXPRESSION

However, your target is CDL option CYGNUM_HAL_RTC_PERIOD. So, be careful
when you change its value as for some targets if the period needs to be
changed, and the clock's resolution needs to be adjusted accordingly

http://ecos.sourceware.org/docs-latest/ref/hal-clocks-and-timers.html

HTH

Sergei

> -- 
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> 

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]