no-OS
Loading...
Searching...
No Matches
interface.c File Reference

User interface implementation file. More...

#include "no_os_print_log.h"
#include "state_machine.h"
#include "no_os_delay.h"
#include "common_data.h"
#include "interface.h"
Include dependency graph for interface.c:

Functions

int interface_init (struct no_os_gpio_desc **gpio_led_desc)
 Interface initialization routines.
 
int interface_led_on (struct no_os_gpio_desc *gpio_led_desc)
 Turn LED on.
 
int interface_led_off (struct no_os_gpio_desc *gpio_led_desc)
 Turn LED off.
 
int interface_toggle_led (struct no_os_gpio_desc *gpio_led_desc)
 Toggle LED.
 
int interface_disp (struct stout *stout)
 Display error code.
 
int interface_blink_time (struct stout *stout)
 Get interface blink time (multimple of 20ms)
 

Detailed Description

User interface implementation file.

Author
GMois (georg.nosp@m.e.mo.nosp@m.is@an.nosp@m.alog.nosp@m..com), REtz (radu..nosp@m.etz@.nosp@m.analo.nosp@m.g.co.nosp@m.m)

Copyright (c) 2023 Analog Devices, Inc.

SPDX-License-Identifier: BSD-3-Clause

Function Documentation

◆ interface_blink_time()

int interface_blink_time ( struct stout * stout)

Get interface blink time (multimple of 20ms)

Parameters
stout- state machine descriptor
Returns
0 in case of success, error code otherwise

◆ interface_disp()

int interface_disp ( struct stout * stout)

Display error code.

Parameters
stout- state machine descriptor
Returns
0 in case of success, error code otherwise

◆ interface_init()

int interface_init ( struct no_os_gpio_desc ** gpio_led_desc)

Interface initialization routines.

Parameters
gpio_led_desc- poionter to first LED descriptor
Returns
0 in case of success, error code otherwise

◆ interface_led_off()

int interface_led_off ( struct no_os_gpio_desc * gpio_led_desc)

Turn LED off.

Parameters
gpio_led_desc- LED descriptor
Returns
0 in case of success, error code otherwise

◆ interface_led_on()

int interface_led_on ( struct no_os_gpio_desc * gpio_led_desc)

Turn LED on.

Parameters
gpio_led_desc- LED descriptor
Returns
0 in case of success, error code otherwise

◆ interface_toggle_led()

int interface_toggle_led ( struct no_os_gpio_desc * gpio_led_desc)

Toggle LED.

Toggle Led.

Parameters
gpio_led_desc- LED descriptor
Returns
0 in case of success, error code otherwise
Parameters
gpio_led_desc- led descriptor
Returns
0 in case of success, negative error code otherwise.