bitband.h

Bit-banding support.

Functions

uint8 bb_sram_get_bit(volatile void * address, uint32 bit)

Get a bit from an address in the SRAM bit-band region.

Parameters:
  • address -

    Address in the SRAM bit-band region to read from

  • bit -

    Bit in address to read

Return:

bit’s value in address.

void bb_sram_set_bit(volatile void * address, uint32 bit, uint8 val)

Set a bit in an address in the SRAM bit-band region.

Parameters:
  • address -

    Address in the SRAM bit-band region to write to

  • bit -

    Bit in address to write to

  • val -

    Value to write for bit, either 0 or 1.

uint8 bb_peri_get_bit(volatile void * address, uint32 bit)

Get a bit from an address in the peripheral bit-band region.

Parameters:
  • address -

    Address in the peripheral bit-band region to read from

  • bit -

    Bit in address to read

Return:

bit’s value in address.

void bb_peri_set_bit(volatile void * address, uint32 bit, uint8 val)

Set a bit in an address in the peripheral bit-band region.

Parameters:
  • address -

    Address in the peripheral bit-band region to write to

  • bit -

    Bit in address to write to

  • val -

    Value to write for bit, either 0 or 1.