Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
duo-buildroot-sdk
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
duo-buildroot-sdk
Commits
ecba0439
Commit
ecba0439
authored
Sep 08, 2023
by
carbon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
buildroot/wiringX: support SPI and UART
parent
5d8774d1
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
35 additions
and
26 deletions
+35
-26
buildroot-2021.05/package/wiringx/src/libwiringx.so
buildroot-2021.05/package/wiringx/src/libwiringx.so
+0
-0
buildroot-2021.05/package/wiringx/src/wiringx.h
buildroot-2021.05/package/wiringx/src/wiringx.h
+35
-25
buildroot-2021.05/package/wiringx/wiringx.mk
buildroot-2021.05/package/wiringx/wiringx.mk
+0
-1
No files found.
buildroot-2021.05/package/wiringx/src/libwiringx.so
View file @
ecba0439
No preview for this file type
buildroot-2021.05/package/wiringx/src/wiringx.h
View file @
ecba0439
...
@@ -66,42 +66,52 @@ typedef struct wiringXSerial_t {
...
@@ -66,42 +66,52 @@ typedef struct wiringXSerial_t {
unsigned
int
flowcontrol
;
unsigned
int
flowcontrol
;
}
wiringXSerial_t
;
}
wiringXSerial_t
;
void
delayMicroseconds
(
unsigned
int
);
int
pinMode
(
int
,
enum
pinmode_t
);
int
wiringXSetup
(
char
*
name
,
void
(
*
func
)(
int
,
char
*
,
int
,
const
char
*
,
...));
int
wiringXSetup
(
char
*
name
,
void
(
*
func
)(
int
,
char
*
,
int
,
const
char
*
,
...));
int
wiringXGC
(
void
);
int
wiringXGC
(
void
);
void
delayMicroseconds
(
unsigned
int
howLong
);
int
wiringXValidGPIO
(
int
pin
);
int
pinMode
(
int
pin
,
enum
pinmode_t
mode
);
int
digitalWrite
(
int
pin
,
enum
digital_value_t
value
);
int
digitalRead
(
int
pin
);
int
waitForInterrupt
(
int
pin
,
int
ms
);
int
wiringXISR
(
int
pin
,
enum
isr_mode_t
mode
);
// int analogRead(int channel);
// int analogRead(int channel);
int
digitalWrite
(
int
,
enum
digital_value_t
);
int
digitalRead
(
int
);
int
wiringXI2CRead
(
int
fd
);
int
waitForInterrupt
(
int
,
int
);
int
wiringXI2CReadReg8
(
int
fd
,
int
reg
);
int
wiringXISR
(
int
,
enum
isr_mode_t
);
int
wiringXI2CReadReg16
(
int
fd
,
int
reg
);
int
wiringXI2CWrite
(
int
fd
,
int
data
);
int
wiringXI2CRead
(
int
);
int
wiringXI2CWriteReg8
(
int
fd
,
int
reg
,
int
data
);
int
wiringXI2CReadReg8
(
int
,
int
);
int
wiringXI2CWriteReg16
(
int
fd
,
int
reg
,
int
data
);
int
wiringXI2CReadReg16
(
int
,
int
);
int
wiringXI2CSetup
(
const
char
*
path
,
int
addr
);
int
wiringXI2CWrite
(
int
,
int
);
int
wiringXI2CWriteReg8
(
int
,
int
,
int
);
int
wiringXI2CWriteReg16
(
int
,
int
,
int
);
int
wiringXI2CSetup
(
const
char
*
,
int
);
int
wiringXSPIGetFd
(
int
channel
);
int
wiringXSPIGetFd
(
int
channel
);
int
wiringXSPIDataRW
(
int
channel
,
unsigned
char
*
data
,
int
len
);
int
wiringXSPIDataRW
(
int
channel
,
unsigned
char
*
data
,
int
len
);
int
wiringXSPISetup
(
int
channel
,
int
speed
);
int
wiringXSPISetup
(
int
channel
,
int
speed
);
int
wiringXSerialOpen
(
const
char
*
,
struct
wiringXSerial_t
);
int
wiringXSerialOpen
(
const
char
*
device
,
struct
wiringXSerial_t
serial
);
void
wiringXSerialFlush
(
int
);
void
wiringXSerialFlush
(
int
fd
);
void
wiringXSerialClose
(
int
);
void
wiringXSerialClose
(
int
fd
);
void
wiringXSerialPutChar
(
int
,
unsigned
char
);
void
wiringXSerialPutChar
(
int
fd
,
unsigned
char
c
);
void
wiringXSerialPuts
(
int
,
const
char
*
);
void
wiringXSerialPuts
(
int
fd
,
const
char
*
s
);
void
wiringXSerialPrintf
(
int
,
const
char
*
,
...);
void
wiringXSerialPrintf
(
int
fd
,
const
char
*
message
,
...);
int
wiringXSerialDataAvail
(
int
);
int
wiringXSerialDataAvail
(
int
fd
);
int
wiringXSerialGetChar
(
int
);
int
wiringXSerialGetChar
(
int
fd
);
int
wiringXSetPWMPeriod
(
int
pin
,
long
period
);
int
wiringXSetPWMPolarity
(
int
pin
,
int
polarity
);
int
wiringXSetPWMDuty
(
int
pin
,
int
duty_cycle
);
int
wiringXPWMEnable
(
int
pin
,
int
enable
);
char
*
wiringXPlatform
(
void
);
char
*
wiringXPlatform
(
void
);
int
wiringXValidGPIO
(
int
);
int
wiringXSelectableFd
(
int
gpio
);
int
wiringXSelectableFd
(
int
);
int
wiringXSupportedPlatforms
(
char
***
out
);
int
wiringXSupportedPlatforms
(
char
***
);
#ifdef __cplusplus
#ifdef __cplusplus
}
}
...
...
buildroot-2021.05/package/wiringx/wiringx.mk
View file @
ecba0439
...
@@ -10,7 +10,6 @@ define WIRINGX_INSTALL_STAGING_CMDS
...
@@ -10,7 +10,6 @@ define WIRINGX_INSTALL_STAGING_CMDS
endef
endef
define
WIRINGX_INSTALL_TARGET_CMDS
define
WIRINGX_INSTALL_TARGET_CMDS
$(INSTALL)
-D
-m
0644
$(@D)/src/wiringx.h
$(TARGET_DIR)/usr/include/
$(INSTALL)
-D
-m
0644
$(@D)/src/libwiringx.so
$(TARGET_DIR)/usr/lib/
$(INSTALL)
-D
-m
0644
$(@D)/src/libwiringx.so
$(TARGET_DIR)/usr/lib/
endef
endef
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment