[ell-i-developers] Re: PWM configuration

  • From: Pekka Nikander <pekka.nikander@xxxxxx>
  • To: ell-i-developers@xxxxxxxxxxxxx
  • Date: Fri, 24 Jan 2014 20:01:21 +0200

>> Then, I assume that for using the current data16 no address approach, one 
>> should write all the registers in serial fashion, with their reset values 
>> for preventing the initialization routine to write trash to the registers in 
>> between.


>> Still another problem is the array count. The system right now counts all 
>> the elements, because the macros save in a sparse array.

> About counting there is no problem, as it can be simply adjusted accordingly.


> About the problem of the garbage, is the default behaviour of the linker / 
> compiler to fill the empty elements with zeros?

The C standard guarantees that the non-initialised members of a partially 
initialised statically allocated integer array are initialised to zero.  C99 
Section subclause 2 about arithmetic types.  What comes to 
automatically allocated arrays, we should avoid them as we are running in a 
very limited RAM space.


Other related posts: