Init
This commit is contained in:
parent
7aee7e7249
commit
915198c636
|
|
@ -6,13 +6,12 @@
|
||||||
|
|
||||||
tSerialLinPorts SERIAL_LIN_PORTS;
|
tSerialLinPorts SERIAL_LIN_PORTS;
|
||||||
|
|
||||||
/*
|
|
||||||
void UART4_IRQHandler(void) {
|
void UART4_IRQHandler(void) {
|
||||||
SerialPort_IrqProcessing_UartLin(&SERIAL_PORTS.LIN1_UART4);
|
SerialPort_IrqProcessing_UartLin(&SERIAL_LIN_PORTS.LIN1_UART4);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Настройка порта
|
// Настройка порта
|
||||||
static void vSerialPort_InitUSART4(tSerialPortArtery *env) {
|
static void vSerialPort_InitUSART4(tSerialPortLinArtery *env) {
|
||||||
|
|
||||||
gpio_init_type GPIO_InitStruct;
|
gpio_init_type GPIO_InitStruct;
|
||||||
gpio_default_para_init(&GPIO_InitStruct);
|
gpio_default_para_init(&GPIO_InitStruct);
|
||||||
|
|
@ -49,7 +48,6 @@ void SerialLinPorts_Init() {
|
||||||
|
|
||||||
// LIN5
|
// LIN5
|
||||||
vSerialPort_InitUSART4(&env->LIN1_UART4);
|
vSerialPort_InitUSART4(&env->LIN1_UART4);
|
||||||
SERIAL_LIN_PORTS.LIN1_UART4_IO = vSerialPortGetIo(&SERIAL_LIN_PORTS.LIN1_UART4);
|
SERIAL_LIN_PORTS.LIN1_UART4_IO = vSerialPorLinGetIo(&SERIAL_LIN_PORTS.LIN1_UART4);
|
||||||
|
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
|
|
@ -6,13 +6,14 @@
|
||||||
#define WATER_BOX_BSD_SERIALPORTSLIN_H
|
#define WATER_BOX_BSD_SERIALPORTSLIN_H
|
||||||
|
|
||||||
#include "SerialPortArtery.h"
|
#include "SerialPortArtery.h"
|
||||||
|
#include "SerialPortLinArtery.h"
|
||||||
#include "GpioPin.h"
|
#include "GpioPin.h"
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
/*
|
|
||||||
tSerialPortArtery LIN1_UART4;
|
|
||||||
tSerialPortIO LIN1_UART4_IO;
|
|
||||||
|
|
||||||
|
tSerialPortLinArtery LIN1_UART4;
|
||||||
|
tSerialPortLinIO LIN1_UART4_IO;
|
||||||
|
/*
|
||||||
tSerialPortArtery LIN2_UART5;
|
tSerialPortArtery LIN2_UART5;
|
||||||
tSerialPortIO LIN2_UART5_IO;
|
tSerialPortIO LIN2_UART5_IO;
|
||||||
|
|
||||||
|
|
@ -32,6 +33,7 @@ typedef struct {
|
||||||
|
|
||||||
} tSerialLinPorts;
|
} tSerialLinPorts;
|
||||||
|
|
||||||
|
void SerialLinPorts_Init();
|
||||||
extern tSerialLinPorts SERIAL_LIN_PORTS;
|
extern tSerialLinPorts SERIAL_LIN_PORTS;
|
||||||
|
|
||||||
#endif //WATER_BOX_BSD_SERIALPORTSLIN_H
|
#endif //WATER_BOX_BSD_SERIALPORTSLIN_H
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue