Init prototypes
This commit is contained in:
46
Src/DS_ILI9341.c
Normal file
46
Src/DS_ILI9341.c
Normal file
@@ -0,0 +1,46 @@
|
||||
#include "../inc/DS_ILI9341.h"
|
||||
|
||||
|
||||
void DS_ILI9341_Init(DS_ILI9341 *Display, GPIO_TypeDef *Port_CS, uint16_t Pin_CS, GPIO_TypeDef *Port_D0, uint16_t Pin_D0, GPIO_TypeDef *Port_D1, uint16_t Pin_D1, GPIO_TypeDef *Port_D2, uint16_t Pin_D2, GPIO_TypeDef *Port_D3, uint16_t Pin_D3, GPIO_TypeDef *Port_D4, uint16_t Pin_D4, GPIO_TypeDef *Port_D5, uint16_t Pin_D5, GPIO_TypeDef *Port_D6, uint16_t Pin_D6, GPIO_TypeDef *Port_D7, uint16_t Pin_D7, GPIO_TypeDef *Port_RQ, uint16_t Pin_RQ, GPIO_TypeDef *Port_RS, uint16_t Pin_RS, GPIO_TypeDef *Port_RST, uint16_t Pin_RST, GPIO_TypeDef *Port_WR, uint16_t Pin_WR)
|
||||
{
|
||||
HAL_Delay(500);
|
||||
|
||||
Display->Port_CS = Port_CS;
|
||||
Display->Pin_CS = Pin_CS;
|
||||
|
||||
Display->Port_D0 = Port_D0;
|
||||
Display->Pin_D0 = Pin_D0;
|
||||
|
||||
Display->Port_D1 = Port_D1;
|
||||
Display->Pin_D1 = Pin_D1;
|
||||
|
||||
Display->Port_D2 = Port_D2;
|
||||
Display->Pin_D2 = Pin_D2;
|
||||
|
||||
Display->Port_D3 = Port_D3;
|
||||
Display->Pin_D3 = Pin_D3;
|
||||
|
||||
Display->Port_D4 = Port_D4;
|
||||
Display->Pin_D4 = Pin_D4;
|
||||
|
||||
Display->Port_D5 = Port_D5;
|
||||
Display->Pin_D5 = Pin_D5;
|
||||
|
||||
Display->Port_D6 = Port_D6;
|
||||
Display->Pin_D6 = Pin_D6;
|
||||
|
||||
Display->Port_D7 = Port_D7;
|
||||
Display->Pin_D7 = Pin_D7;
|
||||
|
||||
Display->Port_RQ = Port_RQ;
|
||||
Display->Pin_RQ = Pin_RQ;
|
||||
|
||||
Display->Port_RS = Port_RS;
|
||||
Display->Pin_RS = Pin_RS;
|
||||
|
||||
Display->Port_RST = Port_RST;
|
||||
Display->Pin_RST = Pin_RST;
|
||||
|
||||
Display->Port_WR = Port_WR;
|
||||
Display->Pin_WR = Pin_WR;
|
||||
}
|
||||
Reference in New Issue
Block a user