Init
This commit is contained in:
parent
689e55b9d6
commit
e26754471b
10
Gpios.c
10
Gpios.c
|
|
@ -33,11 +33,11 @@ void Gpios_Init() {
|
|||
Gpios_Led(&env->Led);
|
||||
|
||||
|
||||
env->COON_A_B9_B10.En1 = InitGpioPin(GPIOD, GPIO_PINS_7, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->COON_A_B9_B10.En2 = InitGpioPin(GPIOD, GPIO_PINS_8, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->conns.COON_A_B9_B10.En1 = InitGpioPin(GPIOD, GPIO_PINS_7, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->conns.COON_A_B9_B10.En2 = InitGpioPin(GPIOD, GPIO_PINS_8, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
|
||||
env->COON_A_B9_B10.Con.A = InitGpioPin(GPIOD, GPIO_PINS_4, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->COON_A_B9_B10.Con.B = InitGpioPin(GPIOD, GPIO_PINS_5, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->COON_A_B9_B10.Con.C = InitGpioPin(GPIOD, GPIO_PINS_6, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->conns.COON_A_B9_B10.Con.A = InitGpioPin(GPIOD, GPIO_PINS_4, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->conns.COON_A_B9_B10.Con.B = InitGpioPin(GPIOD, GPIO_PINS_5, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
env->conns.COON_A_B9_B10.Con.C = InitGpioPin(GPIOD, GPIO_PINS_6, GPIO_MODE_OUTPUT, GPIO_PIN_NOREVERSE);
|
||||
|
||||
}
|
||||
5
Gpios.h
5
Gpios.h
|
|
@ -8,7 +8,7 @@
|
|||
#include "SerialPorts.h"
|
||||
#include "GpioPin.h"
|
||||
#include "PowerManagement.h"
|
||||
#include "Sensor.h"
|
||||
#include "SensorSPI.h"
|
||||
#include "SpiPorts.h"
|
||||
|
||||
typedef struct {
|
||||
|
|
@ -17,8 +17,7 @@ typedef struct {
|
|||
tGpioPin CAN1_STB;
|
||||
tGpioPin CAN2_STB;
|
||||
tSpiChipSelectPins SpiChipSelectPins;
|
||||
tConn COON_A_B9_B10;
|
||||
|
||||
tConns conns;
|
||||
} tGpios;
|
||||
|
||||
extern tGpios GPIOS;
|
||||
|
|
|
|||
Loading…
Reference in New Issue