Skip to main content

Logic Player Functions

dev.io.logic_player - wire path i\p - generated from fwMenuLogicPlayer.

setup_player

configure. Configures digital playback

Wire command: i\p\c

ArgWire type
sample_rate_nsdecU32
sample_countdecS32
pin_startdecS32
pin_stopdecS32
start_modedecS32
trigger_pindecS32
loopbool

Returns: none (Ok/Err only)

dev.io.logic_player.setup_player(sample_rate_ns: int, sample_count: int, pin_start: int, pin_stop: int, start_mode: int, trigger_pin: int, loop: bool) -> Result
ow_status ow_io_logic_player_setup_player(ow_device* dev, int32_t sample_rate_ns, int32_t sample_count, int32_t pin_start, int32_t pin_stop, int32_t start_mode, int32_t trigger_pin, bool loop);
dev.io().logic_player().setup_player(sample_rate_ns: i32, sample_count: i32, pin_start: i32, pin_stop: i32, start_mode: i32, trigger_pin: i32, loop_: bool) -> Result<(), OwError>

The C and Rust signatures above are also the WASM guest signatures - the device API surface is identical; only the transport differs (ow_open_wasm(&dev) in C, OneWili::open() in Rust).

dev.io.logic_player.setup_player(sample_rate_ns, sample_count, pin_start, pin_stop, start_mode, trigger_pin, loop) # check dev.ok

setup_analog

configure analog. Configures DAC playback

Wire command: i\p\a

ArgWire type
maskdecU32
analog_rate_nsdecS32
analog_resolutiondecS32

Returns: none (Ok/Err only)

dev.io.logic_player.setup_analog(mask: int, analog_rate_ns: int, analog_resolution: int) -> Result
ow_status ow_io_logic_player_setup_analog(ow_device* dev, int32_t mask, int32_t analog_rate_ns, int32_t analog_resolution);
dev.io().logic_player().setup_analog(mask: i32, analog_rate_ns: i32, analog_resolution: i32) -> Result<(), OwError>

The C and Rust signatures above are also the WASM guest signatures - the device API surface is identical; only the transport differs (ow_open_wasm(&dev) in C, OneWili::open() in Rust).

dev.io.logic_player.setup_analog(mask, analog_rate_ns, analog_resolution) # check dev.ok

load_file

load. Loads a raw buffer from the filesystem

Wire command: i\p\l

ArgWire type
file_pathstring

Returns: none (Ok/Err only)

dev.io.logic_player.load_file(file_path: str) -> Result
ow_status ow_io_logic_player_load_file(ow_device* dev, const char* file_path);
dev.io().logic_player().load_file(file_path: &str) -> Result<(), OwError>

The C and Rust signatures above are also the WASM guest signatures - the device API surface is identical; only the transport differs (ow_open_wasm(&dev) in C, OneWili::open() in Rust).

dev.io.logic_player.load_file(file_path) # check dev.ok

start

start. Starts playback

Wire command: i\p\s

Returns: none (Ok/Err only)

dev.io.logic_player.start() -> Result
ow_status ow_io_logic_player_start(ow_device* dev);
dev.io().logic_player().start() -> Result<(), OwError>

The C and Rust signatures above are also the WASM guest signatures - the device API surface is identical; only the transport differs (ow_open_wasm(&dev) in C, OneWili::open() in Rust).

dev.io.logic_player.start() # check dev.ok

stop

stop. Stops playback

Wire command: i\p\e

Returns: none (Ok/Err only)

dev.io.logic_player.stop() -> Result
ow_status ow_io_logic_player_stop(ow_device* dev);
dev.io().logic_player().stop() -> Result<(), OwError>

The C and Rust signatures above are also the WASM guest signatures - the device API surface is identical; only the transport differs (ow_open_wasm(&dev) in C, OneWili::open() in Rust).

dev.io.logic_player.stop() # check dev.ok