VSF Documented
vsf_disp_solomon_systech_common.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright(C)2009-2022 by VSF Team *
3 * *
4 * Licensed under the Apache License, Version 2.0 (the "License"); *
5 * you may not use this file except in compliance with the License. *
6 * You may obtain a copy of the License at *
7 * *
8 * http://www.apache.org/licenses/LICENSE-2.0 *
9 * *
10 * Unless required by applicable law or agreed to in writing, software *
11 * distributed under the License is distributed on an "AS IS" BASIS, *
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. *
13 * See the License for the specific language governing permissions and *
14 * limitations under the License. *
15 * *
16 ****************************************************************************/
17#ifndef __VSF_DISP_SOLOMON_SYSTECH_COMMON_H__
18#define __VSF_DISP_SOLOMON_SYSTECH_COMMON_H__
19
20/*============================ INCLUDES ======================================*/
21
23
24#if VSF_USE_UI == ENABLED \
25 && ( (VSF_DISP_USE_SSD1306 == ENABLED) \
26 || (VSF_DISP_USE_SSD1316 == ENABLED))
27
28// TODO: osa_hal has been removed, update below
29#include "osa_hal/driver/customised/multiplex_hal/iic/vsf_multiplex_iic.h"
30
31#ifdef __cplusplus
32extern "C" {
33#endif
34
35/*============================ MACROS ========================================*/
36/*============================ MACROFIED FUNCTIONS ===========================*/
37
38#define VSF_DISP_SOLOMON_SYSTECH_IIC_WRITE_I(__INSTR) \
39 0x80, (__INSTR)
40#define VSF_DISP_SOLOMON_SYSTECH_IIC_WRITE_D(__DATA) \
41 0xC0, (__DATA)
42
43/*============================ TYPES =========================================*/
44
46 void *port;
48
50 void *port;
51 struct {
53 int8_t pin; // -1 for unused
54 } cs;
55 struct {
58 } dc;
60
62 void *addr;
63 struct {
65 int8_t pin; // -1 for unused
66 } cs;
67 struct {
70 } dc;
72
73/*============================ GLOBAL VARIABLES ==============================*/
74/*============================ PROTOTYPES ====================================*/
75
76#ifdef __cplusplus
77}
78#endif
79
80#endif // VSF_USE_UI
81#endif // __VSF_DISP_SOLOMON_SYSTECH_COMMON_H__
unsigned char uint8_t
Definition stdint.h:5
signed char int8_t
Definition stdint.h:4
Definition vsf_disp_solomon_systech_common.h:61
uint8_t pin
Definition vsf_disp_solomon_systech_common.h:69
vsf_gpio_t * port
Definition vsf_disp_solomon_systech_common.h:64
int8_t pin
Definition vsf_disp_solomon_systech_common.h:65
struct vsf_disp_solomon_systech_hw_ebi_t::@124 dc
void * addr
Definition vsf_disp_solomon_systech_common.h:62
struct vsf_disp_solomon_systech_hw_ebi_t::@123 cs
Definition vsf_disp_solomon_systech_common.h:45
void * port
Definition vsf_disp_solomon_systech_common.h:46
Definition vsf_disp_solomon_systech_common.h:49
void * port
Definition vsf_disp_solomon_systech_common.h:50
struct vsf_disp_solomon_systech_hw_spi_t::@121 cs
int8_t pin
Definition vsf_disp_solomon_systech_common.h:53
struct vsf_disp_solomon_systech_hw_spi_t::@122 dc
uint8_t pin
Definition vsf_disp_solomon_systech_common.h:57
vsf_gpio_t * port
Definition vsf_disp_solomon_systech_common.h:52
Definition vsf_template_gpio.h:471