Types Module

Common types for use with FreeWili API.

Serial Module API

Common data types and constants.

class freewili.types.ButtonColor(value)

Bases: Enum

Free-Wili Physical Button Color.

Blue = 5
Green = 4
Red = 6
Unknown = 1
White = 2
Yellow = 3
class freewili.types.FreeWiliProcessorType(value)

Bases: Enum

Processor type of the Free-Wili.

Display = 2
ESP32 = 4
FTDI = 3
Main = 1
Unknown = 5
class freewili.types.IOMenuCommand(value)

Bases: Enum

Free-Wili IO menu representation.

Get = 6
High = 1
Low = 2
Pwm = 4
Stream = 5
Toggle = 3
classmethod from_string(value: str) Self

Convert a string value to an IOMenuCommand.

Arguments:

value: str

string value to convert to an enum. Case Insensitive.

Returns:

str:

FreeWili menu command character.

Raises:
ValueError:

When invalid enum isn’t matched against provided string value.

property menu_character: str

Convert IOMenuCommand to a FreeWili menu command character.

Arguments:

None

Returns:

str:

FreeWili menu command character.

Raises:
ValueError:

When invalid enum isn’t found.