This commit is contained in:
cfif 2024-12-04 13:10:48 +03:00
commit 89d00747fd
3 changed files with 74 additions and 0 deletions

25
PwmLe910.c Normal file
View File

@ -0,0 +1,25 @@
//
// Created by xemon on 30.12.22.
//
#include "PwmLe910.h"
#include "SystemDelayInterface.h"
void PwmLe910_StartUp(tTelitPower *env) {
GpioPinEnable(&env->charge.power);
GpioPinEnable(&env->charge.onOff);
GpioPinEnable(&env->charge.ChargeC);
GpioPinEnable(&env->charge.power);
GpioPinEnable(&env->charge.onOff);
// GpioPinEnable(&env->inAnt);
}
void PwmLe910_ShutDown(tTelitPower *env) {
GpioPinDisable(&env->charge.onOff);
GpioPinDisable(&env->charge.power);
SystemDelayMs(1000);
GpioPinDisable(&env->discharge.chargeCapacitors);
GpioPinDisable(&env->discharge.chargeCapacitorsDNI);
}

27
PwmLe910.h Normal file
View File

@ -0,0 +1,27 @@
//
// Created by xemon on 30.12.22.
//
#ifndef UVEOS_ON_NATION_PWMLE910_H
#define UVEOS_ON_NATION_PWMLE910_H
#include "GpioPin.h"
typedef struct {
struct {
tGpioPin onOff;
tGpioPin power;
tGpioPin ChargeC;
} charge;
struct {
tGpioPin chargeCapacitors;
tGpioPin chargeCapacitorsDNI;
} discharge;
tGpioPin ring;
} tTelitPower;
void PwmLe910_StartUp(tTelitPower *env);
void PwmLe910_ShutDown(tTelitPower *env);
#endif //UVEOS_ON_NATION_PWMLE910_H

22
modular.json Normal file
View File

@ -0,0 +1,22 @@
{
"dep": [
{
"type": "git",
"provider": "NAVIGATOR_UVEOS_NATION_TELIT",
"repo": "GpioPinInterface"
},
{
"type": "git",
"provider": "NAVIGATOR_UVEOS_NATION_TELIT",
"repo": "SystemDelayInterface"
}
],
"cmake": {
"inc_dirs": [
"./"
],
"srcs": [
"./**.c"
]
}
}