Initial import of NFC GNSS SDK project
This commit is contained in:
@@ -0,0 +1,79 @@
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure variable
|
||||
#-------------------------------------------------------------------------------
|
||||
TOP_DIR:=${TOP_DIR}
|
||||
MAKEFILE_PATH :=$(subst $(strip \),/,$(abspath $(lastword $(MAKEFILE_LIST))))
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure source code files
|
||||
#-------------------------------------------------------------------------------
|
||||
SRC_FILES+= \
|
||||
ql_spi.c \
|
||||
quec_spi.c \
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# the include directories
|
||||
#-------------------------------------------------------------------------------
|
||||
INC_DIRS+= \
|
||||
-I${TOP_DIR}\ \
|
||||
-I${TOP_DIR}\common\include \
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure compile flag for C
|
||||
#-------------------------------------------------------------------------------
|
||||
ifneq (,$(findstring 1606,${ASR_PLATFORM}))
|
||||
U_FLAGS+= \
|
||||
|
||||
endif
|
||||
ifneq (,$(findstring 1602,${ASR_PLATFORM}))
|
||||
U_FLAGS+= \
|
||||
|
||||
endif
|
||||
ifneq (,$(findstring 1605,${ASR_PLATFORM}))
|
||||
U_FLAGS+= \
|
||||
|
||||
endif
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure compile flag for C++
|
||||
#-------------------------------------------------------------------------------
|
||||
U_CPPFLAGS+=
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure default macro define
|
||||
#-------------------------------------------------------------------------------
|
||||
ifneq (,$(findstring 1606,${ASR_PLATFORM}))
|
||||
DFLAGS+= \
|
||||
-D"NO_APLP=0" \
|
||||
-D"GPRS_MULTISLOT_CLASS=12" \
|
||||
-D"EGPRS_MULTISLOT_CLASS=12" \
|
||||
|
||||
endif
|
||||
ifneq (,$(findstring 1602,${ASR_PLATFORM}))
|
||||
DFLAGS+= \
|
||||
-D"NO_APLP=0" \
|
||||
-D"GPRS_MULTISLOT_CLASS=12" \
|
||||
-D"EGPRS_MULTISLOT_CLASS=12" \
|
||||
|
||||
endif
|
||||
ifneq (,$(findstring 1605,${ASR_PLATFORM}))
|
||||
DFLAGS+= \
|
||||
-D"NO_APLP=0" \
|
||||
-D"GPRS_MULTISLOT_CLASS=12" \
|
||||
-D"EGPRS_MULTISLOT_CLASS=12" \
|
||||
|
||||
endif
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Configure link library
|
||||
#-------------------------------------------------------------------------------
|
||||
U_LIBS:=
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# include mk file
|
||||
#-------------------------------------------------------------------------------
|
||||
include ${TOP_DIR}\config\common\makefile.mk
|
||||
@@ -0,0 +1,45 @@
|
||||
/*================================================================
|
||||
Copyright (c) 2021, Quectel Wireless Solutions Co., Ltd. All rights reserved.
|
||||
Quectel Wireless Solutions Proprietary and Confidential.
|
||||
=================================================================*/
|
||||
#include <stdio.h>
|
||||
#include "global_types.h"
|
||||
#include "ql_spi.h"
|
||||
|
||||
|
||||
int ql_spi_init(SPI_PORT_E port, SPI_MODE_E spimode, SPI_CLK_E spiclk)
|
||||
{
|
||||
return quec_spi_init(port,spimode,spiclk);
|
||||
}
|
||||
|
||||
int ql_spi_write(SPI_PORT_E port, unsigned char *buf, unsigned int len)
|
||||
{
|
||||
return quec_spi_write(port,buf,len);
|
||||
}
|
||||
|
||||
int ql_spi_read(SPI_PORT_E port, unsigned char *buf, unsigned int len)
|
||||
{
|
||||
|
||||
return quec_spi_read(port,buf,len);
|
||||
}
|
||||
|
||||
int ql_spi_write_read(SPI_PORT_E port, unsigned char *inbuf, unsigned char *outbuf, unsigned int len)
|
||||
{
|
||||
|
||||
return quec_spi_write_read(port,inbuf,outbuf,len);
|
||||
}
|
||||
|
||||
int ql_spi_pio_width_write(SPI_PORT_E port, unsigned int *buf, unsigned int len, int bit_width)
|
||||
{
|
||||
return quec_spi_pio_width_write(port,buf,len,bit_width);
|
||||
}
|
||||
|
||||
int ql_spi_pio_width_read(SPI_PORT_E port, unsigned int *buf, unsigned int len, int bit_width)
|
||||
{
|
||||
return quec_spi_pio_width_read(port,buf,len,bit_width);
|
||||
}
|
||||
|
||||
int ql_spi_pio_width_write_read(SPI_PORT_E port, unsigned int *inbuf, unsigned int *outbuf, unsigned int len, int bit_width)
|
||||
{
|
||||
return quec_spi_pio_width_write_read(port,inbuf,outbuf,len,bit_width);
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user