# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.2
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.

from sys import version_info as _swig_python_version_info
if _swig_python_version_info < (2, 7, 0):
    raise RuntimeError("Python 2.7 or later required")

# Import the low-level C/C++ module
if __package__ or "." in __name__:
    from . import _pyupm_ili9341
else:
    import _pyupm_ili9341

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)


def _swig_setattr_nondynamic_instance_variable(set):
    def set_instance_attr(self, name, value):
        if name == "thisown":
            self.this.own(value)
        elif name == "this":
            set(self, name, value)
        elif hasattr(self, name) and isinstance(getattr(type(self), name), property):
            set(self, name, value)
        else:
            raise AttributeError("You cannot add instance attributes to %s" % self)
    return set_instance_attr


def _swig_setattr_nondynamic_class_variable(set):
    def set_class_attr(cls, name, value):
        if hasattr(cls, name) and not isinstance(getattr(cls, name), property):
            set(cls, name, value)
        else:
            raise AttributeError("You cannot add class attributes to %s" % cls)
    return set_class_attr


def _swig_add_metaclass(metaclass):
    """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
    def wrapper(cls):
        return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
    return wrapper


class _SwigNonDynamicMeta(type):
    """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
    __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)



def getVersion():
    return _pyupm_ili9341.getVersion()
class GFX(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined - class is abstract")
    __repr__ = _swig_repr
    __swig_destroy__ = _pyupm_ili9341.delete_GFX

    def drawPixel(self, x, y, color):
        return _pyupm_ili9341.GFX_drawPixel(self, x, y, color)

    def drawLine(self, x0, y0, x1, y1, color):
        return _pyupm_ili9341.GFX_drawLine(self, x0, y0, x1, y1, color)

    def drawFastVLine(self, x, y, h, color):
        return _pyupm_ili9341.GFX_drawFastVLine(self, x, y, h, color)

    def drawFastHLine(self, x, y, w, color):
        return _pyupm_ili9341.GFX_drawFastHLine(self, x, y, w, color)

    def drawRect(self, x, y, w, h, color):
        return _pyupm_ili9341.GFX_drawRect(self, x, y, w, h, color)

    def fillRect(self, x, y, w, h, color):
        return _pyupm_ili9341.GFX_fillRect(self, x, y, w, h, color)

    def fillScreen(self, color):
        return _pyupm_ili9341.GFX_fillScreen(self, color)

    def invertDisplay(self, i):
        return _pyupm_ili9341.GFX_invertDisplay(self, i)

    def drawCircle(self, x0, y0, r, color):
        return _pyupm_ili9341.GFX_drawCircle(self, x0, y0, r, color)

    def drawCircleHelper(self, x0, y0, r, cornername, color):
        return _pyupm_ili9341.GFX_drawCircleHelper(self, x0, y0, r, cornername, color)

    def fillCircle(self, x0, y0, r, color):
        return _pyupm_ili9341.GFX_fillCircle(self, x0, y0, r, color)

    def fillCircleHelper(self, x0, y0, r, cornername, delta, color):
        return _pyupm_ili9341.GFX_fillCircleHelper(self, x0, y0, r, cornername, delta, color)

    def drawTriangle(self, x0, y0, x1, y1, x2, y2, color):
        return _pyupm_ili9341.GFX_drawTriangle(self, x0, y0, x1, y1, x2, y2, color)

    def fillTriangle(self, x0, y0, x1, y1, x2, y2, color):
        return _pyupm_ili9341.GFX_fillTriangle(self, x0, y0, x1, y1, x2, y2, color)

    def drawRoundRect(self, x0, y0, w, h, radius, color):
        return _pyupm_ili9341.GFX_drawRoundRect(self, x0, y0, w, h, radius, color)

    def fillRoundRect(self, x0, y0, w, h, radius, color):
        return _pyupm_ili9341.GFX_fillRoundRect(self, x0, y0, w, h, radius, color)

    def drawChar(self, x, y, c, color, bg, size):
        return _pyupm_ili9341.GFX_drawChar(self, x, y, c, color, bg, size)

    def getCursorX(self):
        return _pyupm_ili9341.GFX_getCursorX(self)

    def getCursorY(self):
        return _pyupm_ili9341.GFX_getCursorY(self)

    def setCursor(self, x, y):
        return _pyupm_ili9341.GFX_setCursor(self, x, y)

    def setTextColor(self, *args):
        return _pyupm_ili9341.GFX_setTextColor(self, *args)

    def setTextSize(self, s):
        return _pyupm_ili9341.GFX_setTextSize(self, s)

    def setTextWrap(self, w):
        return _pyupm_ili9341.GFX_setTextWrap(self, w)

    def getRotation(self):
        return _pyupm_ili9341.GFX_getRotation(self)

    def setRotation(self, r):
        return _pyupm_ili9341.GFX_setRotation(self, r)

    def cp437(self, x):
        return _pyupm_ili9341.GFX_cp437(self, x)

    def write(self, c):
        return _pyupm_ili9341.GFX_write(self, c)

    def _print(self, msg):
        return _pyupm_ili9341.GFX__print(self, msg)

    def width(self):
        return _pyupm_ili9341.GFX_width(self)

    def height(self):
        return _pyupm_ili9341.GFX_height(self)

# Register GFX in _pyupm_ili9341:
_pyupm_ili9341.GFX_swigregister(GFX)

ILI9341_TFTWIDTH = _pyupm_ili9341.ILI9341_TFTWIDTH
ILI9341_TFTHEIGHT = _pyupm_ili9341.ILI9341_TFTHEIGHT
SPI_FREQ = _pyupm_ili9341.SPI_FREQ
ILI9341_NOP = _pyupm_ili9341.ILI9341_NOP
ILI9341_SWRESET = _pyupm_ili9341.ILI9341_SWRESET
ILI9341_RDDID = _pyupm_ili9341.ILI9341_RDDID
ILI9341_RDDST = _pyupm_ili9341.ILI9341_RDDST
ILI9341_SLPIN = _pyupm_ili9341.ILI9341_SLPIN
ILI9341_SLPOUT = _pyupm_ili9341.ILI9341_SLPOUT
ILI9341_PTLON = _pyupm_ili9341.ILI9341_PTLON
ILI9341_NORON = _pyupm_ili9341.ILI9341_NORON
ILI9341_RDMODE = _pyupm_ili9341.ILI9341_RDMODE
ILI9341_RDMADCTL = _pyupm_ili9341.ILI9341_RDMADCTL
ILI9341_RDPIXFMT = _pyupm_ili9341.ILI9341_RDPIXFMT
ILI9341_RDIMGFMT = _pyupm_ili9341.ILI9341_RDIMGFMT
ILI9341_RDSELFDIAG = _pyupm_ili9341.ILI9341_RDSELFDIAG
ILI9341_INVOFF = _pyupm_ili9341.ILI9341_INVOFF
ILI9341_INVON = _pyupm_ili9341.ILI9341_INVON
ILI9341_GAMMASET = _pyupm_ili9341.ILI9341_GAMMASET
ILI9341_DISPOFF = _pyupm_ili9341.ILI9341_DISPOFF
ILI9341_DISPON = _pyupm_ili9341.ILI9341_DISPON
ILI9341_CASET = _pyupm_ili9341.ILI9341_CASET
ILI9341_PASET = _pyupm_ili9341.ILI9341_PASET
ILI9341_RAMWR = _pyupm_ili9341.ILI9341_RAMWR
ILI9341_RAMRD = _pyupm_ili9341.ILI9341_RAMRD
ILI9341_PTLAR = _pyupm_ili9341.ILI9341_PTLAR
ILI9341_MADCTL = _pyupm_ili9341.ILI9341_MADCTL
ILI9341_PIXFMT = _pyupm_ili9341.ILI9341_PIXFMT
ILI9341_FRMCTR1 = _pyupm_ili9341.ILI9341_FRMCTR1
ILI9341_FRMCTR2 = _pyupm_ili9341.ILI9341_FRMCTR2
ILI9341_FRMCTR3 = _pyupm_ili9341.ILI9341_FRMCTR3
ILI9341_INVCTR = _pyupm_ili9341.ILI9341_INVCTR
ILI9341_DFUNCTR = _pyupm_ili9341.ILI9341_DFUNCTR
ILI9341_PWCTR1 = _pyupm_ili9341.ILI9341_PWCTR1
ILI9341_PWCTR2 = _pyupm_ili9341.ILI9341_PWCTR2
ILI9341_PWCTR3 = _pyupm_ili9341.ILI9341_PWCTR3
ILI9341_PWCTR4 = _pyupm_ili9341.ILI9341_PWCTR4
ILI9341_PWCTR5 = _pyupm_ili9341.ILI9341_PWCTR5
ILI9341_VMCTR1 = _pyupm_ili9341.ILI9341_VMCTR1
ILI9341_VMCTR2 = _pyupm_ili9341.ILI9341_VMCTR2
ILI9341_RDID1 = _pyupm_ili9341.ILI9341_RDID1
ILI9341_RDID2 = _pyupm_ili9341.ILI9341_RDID2
ILI9341_RDID3 = _pyupm_ili9341.ILI9341_RDID3
ILI9341_RDID4 = _pyupm_ili9341.ILI9341_RDID4
ILI9341_GMCTRP1 = _pyupm_ili9341.ILI9341_GMCTRP1
ILI9341_GMCTRN1 = _pyupm_ili9341.ILI9341_GMCTRN1
MADCTL_MY = _pyupm_ili9341.MADCTL_MY
MADCTL_MX = _pyupm_ili9341.MADCTL_MX
MADCTL_MV = _pyupm_ili9341.MADCTL_MV
MADCTL_ML = _pyupm_ili9341.MADCTL_ML
MADCTL_RGB = _pyupm_ili9341.MADCTL_RGB
MADCTL_BGR = _pyupm_ili9341.MADCTL_BGR
MADCTL_MH = _pyupm_ili9341.MADCTL_MH
HIGH = _pyupm_ili9341.HIGH
LOW = _pyupm_ili9341.LOW
DELAY = _pyupm_ili9341.DELAY
ILI9341_BLACK = _pyupm_ili9341.ILI9341_BLACK
ILI9341_NAVY = _pyupm_ili9341.ILI9341_NAVY
ILI9341_DARKGREEN = _pyupm_ili9341.ILI9341_DARKGREEN
ILI9341_DARKCYAN = _pyupm_ili9341.ILI9341_DARKCYAN
ILI9341_MAROON = _pyupm_ili9341.ILI9341_MAROON
ILI9341_PURPLE = _pyupm_ili9341.ILI9341_PURPLE
ILI9341_OLIVE = _pyupm_ili9341.ILI9341_OLIVE
ILI9341_LIGHTGREY = _pyupm_ili9341.ILI9341_LIGHTGREY
ILI9341_DARKGREY = _pyupm_ili9341.ILI9341_DARKGREY
ILI9341_BLUE = _pyupm_ili9341.ILI9341_BLUE
ILI9341_GREEN = _pyupm_ili9341.ILI9341_GREEN
ILI9341_CYAN = _pyupm_ili9341.ILI9341_CYAN
ILI9341_RED = _pyupm_ili9341.ILI9341_RED
ILI9341_MAGENTA = _pyupm_ili9341.ILI9341_MAGENTA
ILI9341_YELLOW = _pyupm_ili9341.ILI9341_YELLOW
ILI9341_WHITE = _pyupm_ili9341.ILI9341_WHITE
ILI9341_ORANGE = _pyupm_ili9341.ILI9341_ORANGE
ILI9341_GREENYELLOW = _pyupm_ili9341.ILI9341_GREENYELLOW
ILI9341_PINK = _pyupm_ili9341.ILI9341_PINK
class ILI9341(GFX):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, csLCD, csSD, dc, rst):
        _pyupm_ili9341.ILI9341_swiginit(self, _pyupm_ili9341.new_ILI9341(csLCD, csSD, dc, rst))

    def name(self):
        return _pyupm_ili9341.ILI9341_name(self)

    def initModule(self):
        return _pyupm_ili9341.ILI9341_initModule(self)

    def configModule(self):
        return _pyupm_ili9341.ILI9341_configModule(self)

    def setAddrWindow(self, x0, y0, x1, y1):
        return _pyupm_ili9341.ILI9341_setAddrWindow(self, x0, y0, x1, y1)

    def drawPixel(self, x, y, color):
        return _pyupm_ili9341.ILI9341_drawPixel(self, x, y, color)

    def drawFastVLine(self, x, y, h, color):
        return _pyupm_ili9341.ILI9341_drawFastVLine(self, x, y, h, color)

    def drawFastHLine(self, x, y, w, color):
        return _pyupm_ili9341.ILI9341_drawFastHLine(self, x, y, w, color)

    def fillRect(self, x, y, w, h, color):
        return _pyupm_ili9341.ILI9341_fillRect(self, x, y, w, h, color)

    def fillScreen(self, color):
        return _pyupm_ili9341.ILI9341_fillScreen(self, color)

    def setRotation(self, r):
        return _pyupm_ili9341.ILI9341_setRotation(self, r)

    def invertDisplay(self, i):
        return _pyupm_ili9341.ILI9341_invertDisplay(self, i)

    def color565(self, r, g, b):
        return _pyupm_ili9341.ILI9341_color565(self, r, g, b)

    def executeCMDList(self, addr):
        return _pyupm_ili9341.ILI9341_executeCMDList(self, addr)

    def writecommand(self, c):
        return _pyupm_ili9341.ILI9341_writecommand(self, c)

    def writedata(self, d):
        return _pyupm_ili9341.ILI9341_writedata(self, d)

    def lcdCSOn(self):
        return _pyupm_ili9341.ILI9341_lcdCSOn(self)

    def lcdCSOff(self):
        return _pyupm_ili9341.ILI9341_lcdCSOff(self)

    def sdCSOn(self):
        return _pyupm_ili9341.ILI9341_sdCSOn(self)

    def sdCSOff(self):
        return _pyupm_ili9341.ILI9341_sdCSOff(self)

    def dcHigh(self):
        return _pyupm_ili9341.ILI9341_dcHigh(self)

    def dcLow(self):
        return _pyupm_ili9341.ILI9341_dcLow(self)

    def rstHigh(self):
        return _pyupm_ili9341.ILI9341_rstHigh(self)

    def rstLow(self):
        return _pyupm_ili9341.ILI9341_rstLow(self)
    __swig_destroy__ = _pyupm_ili9341.delete_ILI9341

# Register ILI9341 in _pyupm_ili9341:
_pyupm_ili9341.ILI9341_swigregister(ILI9341)



