64#define PIO_PROGRAM_NOT_LOADED (-1)
void pio_sm_start(pio_t pio, pio_sm_t sm)
Start a state machine and execute the previously loaded program.
pio_sm_t pio_sm_lock(pio_t pio)
Get exclusive access to one of the state machines of PIO pio.
unsigned pio_t
PIO index type.
void pio_init(pio_t pio)
Initialize a PIO device.
void pio_start_programs(void)
Start automatically configured PIO programs.
int pio_alloc_program_sm_lock_any(pio_t *pio_ptr, pio_sm_t *sm_ptr, pio_program_t *program)
Convenience function which performs the usual PIO program resource acquisition.
void pio_free_program(pio_t pio, pio_program_t *prog)
Release the allocated instruction memory occupied by prog.
int pio_sm_t
PIO state machine index type.
void pio_sm_unlock(pio_t pio, pio_sm_t sm)
Release a previously locked state machine.
int pio_alloc_program(pio_t pio, pio_program_t *prog)
Allocate the required instruction memory to load the given PIO program into.
void pio_sm_stop(pio_t pio, pio_sm_t sm)
Stop the execution of a program.
PIO interrupt callbacks for FIFO interrupts.
Struct that models a PIO program.
int location
Program location in memory.
unsigned instr_numof
Number of instructions.
bool written
Program was already written.