fixed includes

This commit is contained in:
Hamza 2024-05-27 13:46:49 +02:00
parent fc24a34740
commit 07f11db3f0
4 changed files with 11 additions and 7 deletions

View File

@ -11,7 +11,6 @@
#include "ADBMS_Abstraction.h"
#include "ADBMS_CMD_MAKROS.h"
#include "ADBMS_LL_Driver.h"
#include "can.h"
typedef enum {
AMSDEACTIVE,

View File

@ -1,5 +1,5 @@
#ifndef INC_PWM_CONTROL_H_
#define INC_PWM_CONTROL_H_
#ifndef INC_PWM_CONTROL_H
#define INC_PWM_CONTROL_H
#include "stm32f3xx_hal.h"
#include "ADBMS_LL_Driver.h"
@ -28,4 +28,4 @@ void PWM_control_init(TIM_HandleTypeDef powerground1, TIM_HandleTypeDef powergro
void PWM_powerground_control(uint8_t percent);
void PWM_battery_cooling_control(uint8_t percent);
#endif /* INC_CHANNEL_CONTROL_H_ */
#endif /* INC_CHANNEL_CONTROL_H */

View File

@ -1,9 +1,12 @@
#ifndef INC_CAN_H
#define INC_CAN_H
#include "stm32f3xx_hal.h"
#include <stdint.h>
#include "main.h"
#include "AMS_HighLevel.h"
#include "can-halal.h"
#include "state_machine.h"
#include "can-halal.h"
#define CAN_ID_IN 0x501
#define CAN_ID_OUT 0x502
@ -13,3 +16,5 @@ void can_init(CAN_HandleTypeDef* hcan);
void can_handle_send_status();
void can_handle_recieve_command(const uint8_t *data);
#endif /* "INC_CAN_H" */

View File

@ -25,7 +25,7 @@ void PWM_control_init(TIM_HandleTypeDef powerground1, TIM_HandleTypeDef powergro
controls the duty cycle of the fans by setting the CCR of the channel percent/100 = x/ARR
*/
void PWM_powerground_control(uint8_t percent){
if (percent > 100 || percent < 0)
if (percent > 100) //something went wrong
return;
powerground_status = percent/100;