image/svg+xml
Brteve's API for EveApps
Version 0.0.1
The reference document for common folder of EveApps project.
 
Loading...
Searching...
No Matches
Platform.h
Go to the documentation of this file.
1
32#ifndef _PLATFORM_H_
33#define _PLATFORM_H_
34
35#define ARDUINO_PLATFORM
36
37/* Module specific configurations */
38#define VM800P43_50
39//#define VM800P35
40//#define VM801P43_50
41//#define VM800B43_50
42//#define VM800B35
43//#define VM801B43_50
44
45#ifdef VM800P43_50
46
47#define DISPLAY_RESOLUTION_WQVGA (1)
48#define FT800_ENABLE (1)
49#define ENABLE_SPI_SINGLE (1)
50#define ARDUINO_ATMEGA328P_I2C (1)
51#define RTC_PRESENT (1)
52#define FT800_CS (9)
53#define SDCARD_CS (8)
54#define FT800_INT (3)
55#define FT800_PD_N (4)
56#define ARDUINO_PRO_SPI_CS FT800_CS
57#define ARDUINO_PLATFORM_SPI (1)
58#define ARDUINO_PLATFORM_COCMD_BURST (1)
59#define RESISTANCE_THRESHOLD (1800)
60#endif
61
62#ifdef VM800P35
63
64#define DISPLAY_RESOLUTION_QVGA (1)
65#define FT800_ENABLE (1)
66#define ENABLE_SPI_SINGLE (1)
67#define ARDUINO_ATMEGA328P_I2C (1)
68#define RTC_PRESENT (1)
69#define FT800_CS (9)
70#define SDCARD_CS (8)
71#define FT800_INT (3)
72#define FT800_PD_N (4)
73#define ARDUINO_PRO_SPI_CS FT800_CS
74#define ARDUINO_PLATFORM_SPI (1)
75#define ARDUINO_PLATFORM_COCMD_BURST (1)
76#define RESISTANCE_THRESHOLD (1800)
77#endif
78
79#ifdef VM801P43_50
80
81#define DISPLAY_RESOLUTION_WQVGA (1)
82#define FT801_ENABLE (1)
83#define ENABLE_SPI_SINGLE (1)
84#define ARDUINO_ATMEGA328P_I2C (1)
85#define RTC_PRESENT (1)
86#define FT800_CS (9)
87#define SDCARD_CS (8)
88#define FT800_INT (3)
89#define FT800_PD_N (4)
90#define ARDUINO_PRO_SPI_CS FT800_CS
91#define ARDUINO_PLATFORM_SPI (1)
92#define ARDUINO_PLATFORM_COCMD_BURST (1)
93
94#endif
95
96#ifdef VM800B43_50
97
98#define DISPLAY_RESOLUTION_WQVGA (1)
99#define FT800_ENABLE (1)
100#define ENABLE_SPI_SINGLE (1)
101#define FT800_INT (3)
102#define FT800_PD_N (4)
103#define SDCARD_CS (5)
104#define FT800_CS (10)
105#define ARDUINO_PRO_SPI_CS FT800_CS
106#define ARDUINO_PLATFORM_SPI (1)
107#define ARDUINO_PLATFORM_COCMD_BURST (1)
108#define RESISTANCE_THRESHOLD (1800)
109#endif
110
111#ifdef VM800B35
112
113#define DISPLAY_RESOLUTION_QVGA (1)
114#define FT800_ENABLE (1)
115#define ENABLE_SPI_SINGLE (1)
116#define FT800_INT (3)
117#define FT800_PD_N (4)
118#define SDCARD_CS (5)
119#define FT800_CS (10)
120#define ARDUINO_PRO_SPI_CS FT800_CS
121#define ARDUINO_PLATFORM_SPI (1)
122#define ARDUINO_PLATFORM_COCMD_BURST (1)
123#define RESISTANCE_THRESHOLD (1800)
124#endif
125
126#ifdef VM801B43_50
127
128#define DISPLAY_RESOLUTION_WQVGA (1)
129#define FT801_ENABLE (1)
130#define ENABLE_SPI_SINGLE (1)
131#define FT800_INT (3)
132#define FT800_PD_N (4)
133#define SDCARD_CS (5)
134#define FT800_CS (10)
135#define ARDUINO_PRO_SPI_CS FT800_CS
136#define ARDUINO_PLATFORM_SPI (1)
137#define ARDUINO_PLATFORM_COCMD_BURST (1)
138
139#endif
140
141/* Custom configuration set by the user */
142#if (!defined(VM800P43_50) && !defined(VM800P35) &&!defined(VM801P43_50) &&!defined(VM800B43_50) &&!defined(VM800B35) &&!defined(VM801B43_50))
143#define DISPLAY_RESOLUTION_QVGA (1)
144#define DISPLAY_RESOLUTION_WQVGA (1)
145#define DISPLAY_RESOLUTION_WVGA (1)
146#define DISPLAY_RESOLUTION_HVGA_PORTRAIT (1)
147
148/* Chip configuration specific macros */
149#define FT800_ENABLE (1)
150#define FT801_ENABLE (1)
151#define FT810_ENABLE (1)
152#define FT811_ENABLE (1)
153#define FT812_ENABLE (1)
154#define FT813_ENABLE (1)
155
156/* SPI specific macros - compile time switches for SPI single, dial and quad use cases */
157#define ENABLE_SPI_SINGLE (1)
158#define ENABLE_SPI_DUAL (1)
159#define ENABLE_SPI_QUAD (1)
160
161#define FT800_PD_N (4)
162#define FT800_CS (10)
163
164/* Display driver configurations - mainly for ME900EV1 modules */
165#define ENABLE_ILI9488_HVGA_PORTRAIT (1)
166#define ARDUINO_PLATFORM_SPI
167
168/* Threshold for resistance */
169#define RESISTANCE_THRESHOLD (1200)
170
171#endif
172
173#if (defined(FT800_ENABLE) || defined(FT801_ENABLE))
174#define FT80X_ENABLE (1)
175#endif
176
177#if (defined(FT810_ENABLE) || defined(FT811_ENABLE) || defined(FT812_ENABLE) || defined(FT813_ENABLE))
178#define FT81X_ENABLE (1)
179#endif
180
181/* Type of file to load from SDCard or Windows file system */
182#define LOADIMAGE 1 //loadimage command takes destination address and options before the actual bitmap data
183#define INFLATE 2 //inflate command takes destination address before the actual bitmap
184#define LOAD 3 //load bitmaps directly
185
186/* Standard C libraries */
187#include <stdio.h>
188/* Standard Arduino libraries */
189#include <Arduino.h>
190#include <EEPROM.h>
191#include <SPI.h>
192#include <avr/pgmspace.h>
193#include <stdint.h>
194typedef float float_t;
195
196typedef boolean bool_t;
197#define TRUE (1)
198#define FALSE (0)
199
200typedef char char8_t;
201typedef unsigned char uchar8_t;
202typedef signed char schar8_t;
203
204typedef PROGMEM const unsigned char prog_uchar8_t;
205typedef PROGMEM const char prog_char8_t;
212/* HAL inclusions */
213#include "Gpu_Hal.h"
214#include "Gpu.h"
215#include "CoPro_Cmds.h"
216#include "Hal_Utils.h"
217
218#define FT800_SEL_PIN FT800_CS
219
220#endif /*_PLATFORM_H_*/
221/* Nothing beyond this*/
222
unsigned short uint16_t
int int32_t
unsigned int uint32_t
short int16_t
unsigned char uint8_t
signed char int8_t
GPU APIs.
This file defines the generic APIs of phost access layer for the FT800 or EVE compatible silicon....
#define PROGMEM
Definition Gpu_Hal.h:72
signed char schar8_t
Definition Platform.h:202
PROGMEM const int8_t prog_int8_t
Definition Platform.h:207
unsigned char uchar8_t
Definition Platform.h:201
float float_t
Definition Platform.h:194
PROGMEM const uint16_t prog_uint16_t
Definition Platform.h:208
PROGMEM const char prog_char8_t
Definition Platform.h:205
PROGMEM const int32_t prog_int32_t
Definition Platform.h:211
PROGMEM const int16_t prog_int16_t
Definition Platform.h:209
char char8_t
Definition Platform.h:200
PROGMEM const unsigned char prog_uchar8_t
Definition Platform.h:204
boolean bool_t
Definition Platform.h:196
PROGMEM const uint32_t prog_uint32_t
Definition Platform.h:210
PROGMEM const uint8_t prog_uint8_t
Definition Platform.h:206