Init
This commit is contained in:
parent
5d9516b2fd
commit
e5dd3f79f0
20
Gpios.c
20
Gpios.c
|
|
@ -26,6 +26,26 @@ void Gpios_Init() {
|
||||||
|
|
||||||
tGpios *env = &GPIOS;
|
tGpios *env = &GPIOS;
|
||||||
|
|
||||||
|
env->LIN1_NSLP = InitGpioPin(GPIOG, GPIO_PINS_7, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN1_NSLP, true);
|
||||||
|
|
||||||
|
env->LIN2_NSLP = InitGpioPin(GPIOG, GPIO_PINS_6, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN2_NSLP, true);
|
||||||
|
|
||||||
|
env->LIN3_NSLP = InitGpioPin(GPIOG, GPIO_PINS_5, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN3_NSLP, true);
|
||||||
|
|
||||||
|
env->LIN4_NSLP = InitGpioPin(GPIOG, GPIO_PINS_4, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN4_NSLP, true);
|
||||||
|
|
||||||
|
env->LIN5_NSLP = InitGpioPin(GPIOG, GPIO_PINS_3, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN5_NSLP, true);
|
||||||
|
|
||||||
|
env->LIN6_NSLP = InitGpioPin(GPIOG, GPIO_PINS_2, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
|
GpioPinSet(&env->LIN6_NSLP, true);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
env->comIntDir.transmit = InitGpioPin(GPIOD, GPIO_PINS_15, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
env->comIntDir.transmit = InitGpioPin(GPIOD, GPIO_PINS_15, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||||
env->comIntDir.receive = InitGpioPin(GPIOD, GPIO_PINS_14, GPIO_MODE_OUTPUT, GPIO_PIN_REVERSE);
|
env->comIntDir.receive = InitGpioPin(GPIOD, GPIO_PINS_14, GPIO_MODE_OUTPUT, GPIO_PIN_REVERSE);
|
||||||
|
|
||||||
|
|
|
||||||
9
Gpios.h
9
Gpios.h
|
|
@ -17,6 +17,15 @@ typedef struct {
|
||||||
tGpioPin CAN1_STB;
|
tGpioPin CAN1_STB;
|
||||||
tGpioPin CAN2_STB;
|
tGpioPin CAN2_STB;
|
||||||
tSpiChipSelectPins SpiChipSelectPins;
|
tSpiChipSelectPins SpiChipSelectPins;
|
||||||
|
|
||||||
|
tGpioPin LIN1_NSLP;
|
||||||
|
tGpioPin LIN2_NSLP;
|
||||||
|
tGpioPin LIN3_NSLP;
|
||||||
|
tGpioPin LIN4_NSLP;
|
||||||
|
tGpioPin LIN5_NSLP;
|
||||||
|
tGpioPin LIN6_NSLP;
|
||||||
|
|
||||||
|
|
||||||
tConns conns;
|
tConns conns;
|
||||||
} tGpios;
|
} tGpios;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue