What do you mean? As i know execution time is not affected by Lock? Initialize methods may be used during usual execution also, so interrupts of given modules may cause initialization fail. By the way initialize methods should assume arbitrary values in configuration registers, and not default values, which is not always easy and not everywhere done. Georgi Am 08/28/13, schrieb Niklas Hauser <niklas.hauser@rwth-aachen.de>:
Hi,
quick question: Is it a good idea to use
xpcc::atomic::Lock lock;
at the beginning of each and every Peripheral::initialize() method?
Since initialize is mostly called during setup, execution time is not so important, and it reduces unwanted behaviour.
What do you think? Niklas _______________________________________________ xpcc-dev mailing list xpcc-dev@lists.rwth-aachen.de http://mailman.rwth-aachen.de/mailman/listinfo/xpcc-dev