Changeset - a6d6bff160f8
[Not reviewed]
default
0 4 0
matthewreed - 8 years ago 2017-03-30 13:39:18

Minor changes
4 files changed with 9 insertions and 23 deletions:
0 comments (0 inline, 0 general)
inc/can.h
Show inline comments
 
#ifndef __CAN_H
 
#define __CAN_H
 
#ifndef _CAN_H_
 
#define _CAN_H_
 
 
#include <stdbool.h>
 
#include <string.h>
 
#include "stm32f0xx_hal.h"
 
 
#include "config.h"
 
@@ -15,7 +15,7 @@ void can_init(void);
 
void can_send_test(uint16_t id);
 
bool can_send(uint32_t id, uint32_t ide, uint8_t dlc, uint8_t data[8]);
 
void can_set_receive_mask(uint32_t mask);
 
void can_set_receive_id(uint32_t id);
 
bool can_silence_bus(bool value);
 
 
#endif //__CAN_H
 
#endif //_CAN_H_
inc/led.h
Show inline comments
 
/*
 
 * led.h
 
 *
 
 *  Created on: Mar 30, 2017
 
 *      Author: Matthew Reed
 
 */
 
 
#ifndef INC_LED_H_
 
#define INC_LED_H_
 
#ifndef _LED_H_
 
#define _LED_H_
 
 
#include "stm32f0xx_hal.h"
 
#include <stdbool.h>
 
#include <string.h>
 
 
typedef enum {
 
@@ -26,7 +19,7 @@ void led_update_all(void);
 
void led_set(led_name_t led, bool value);
 
void led_toggle(led_name_t led);
 
 
__weak bool gpio_set_led(led_name_t led, bool value);
 
__weak bool gpio_toggle_led(led_name_t led);
 
 
#endif /* INC_LED_H_ */
 
#endif /* _LED_H_ */
inc/protocol.h
Show inline comments
 
#ifndef _PROTOCOL_H
 
#define _PROTOCOL_H
 
#ifndef _PROTOCOL_H_
 
#define _PROTOCOL_H_
 
 
#include <stdbool.h>
 
 
#include "config.h"
 
#include "can.h"
 
 
@@ -55,7 +55,7 @@ bool protocol_process_message(protocol_m
 
 
__weak bool protocol_estop(bool value);
 
__weak bool protocol_set_output(protocol_message_t* message);
 
__weak bool protocol_get_data(protocol_message_t* message);
 
__weak bool protocol_config(protocol_message_t* message);
 
 
#endif //_PROTOCOL_H
 
#endif //_PROTOCOL_H_
src/led.c
Show inline comments
 
/*
 
 * led.c
 
 *
 
 *  Created on: Mar 30, 2017
 
 *      Author: Matthew Reed
 
 */
 
 
#include "led.h"
 
 
#define LED_CYCLE_STATUS 2000
 
#define LED_CYCLE_CAN 0
 
#define LED_CYCLE_ERROR 0
 
0 comments (0 inline, 0 general)