Keep old function as a deprecated alternative, for now

Mainly so i2c-pio-rs doesn't fail, as it is used by examples.
Should be removed once i2c-pio-rs is updated.
This commit is contained in:
Jan Niehusmann 2021-11-01 21:03:47 +00:00
parent 3756cd2fb5
commit aafa3dd587

View file

@ -519,6 +519,12 @@ impl<SM: ValidStateMachine, State> StateMachine<SM, State> {
self.sm.sm().sm_addr.read().bits()
}
#[deprecated(note = "Renamed to exec_instruction")]
///Execute the instruction immediately.
pub fn set_instruction(&mut self, instruction: u16) {
self.exec_instruction(instruction);
}
///Execute the instruction immediately.
pub fn exec_instruction(&mut self, instruction: u16) {
// This is allowed even if the state machine is running.