HWA
Bare metal programming with style
Class _coreb: core of the device

A class _coreb object is a core of the device.

It is used in:

Actions


configure:

hwa( configure, core0,
// Whether the `hw( wait, irq )` instruction will put the core in
// sleep mode or not
//
[ sleep, enabled,
| disabled, ]
// Wanted sleep mode
//
[ sleep_mode, idle
| adc_noise_reduction
| power_down
| power_save
| standby
| extended_standby ]
);


wait, irq: puts the core into sleeping mode

hw( wait, irq );


stat: returns the status flags of the core in a structure whose typename is given by the hw_stat_t() instruction. Available flags are

hw_stat_t( core0 ) st ;
st = hw( stat, core0 );
if ( st.wdrf ) {
n_wdresets++ ; // Increment watchdog resets count
}


clear:

hwa( clear, core0 );
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
hw_stat_t
#define hw_stat_t(object)
Declares the appropriate structure that holds the status of an object.
Definition: hwa_macros.h:711