HWA
Bare metal programming with style
Class _psa: clock prescaler

A class _psa object is a resettable clock prescaler connected to the I/O clock.

It is used in:

Actions


reset:

The reset action resets the prescaler immediately without stopping it:

hw( reset, prescaler0 );




hw( clear, ... ) resets the prescaler immediately without stopping it:

hw( clear, prescaler0 );

Stop

The turn action can reset and stop the prescaler:

hw( turn, prescaler0, off ); // Reset and halt the prescaler

or release it:

hw( turn, prescaler0, on ); // Release the prescaler

Configuration

_psa class prescalers are all clocked by the I/O clock.

hwa( configure, prescaler0,
clock, ioclk );
hwa
#define hwa(...)
hwa( action, object [,...] ) stores an action for an object into a HWA context.
Definition: hwa_macros.h:552
hw
#define hw(...)
hw( action, object [,...] ) executes an action immediately on an object.
Definition: hwa_macros.h:523