Skip to content

Commit

Permalink
Merge pull request #1 from waterloo-rocketry/thermocouple
Browse files Browse the repository at this point in the history
Thermocouple Board Firmware
  • Loading branch information
JasonBrave authored May 28, 2024
2 parents 98ca13a + 4d699b3 commit cca2c77
Show file tree
Hide file tree
Showing 62 changed files with 1,679 additions and 346,219 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @JasonBrave @DomenicHampson
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/build/
/dist/
6 changes: 6 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[submodule "canlib"]
path = canlib
url = https://github.com/waterloo-rocketry/canlib.git
[submodule "rocketlib"]
path = rocketlib
url = https://github.com/waterloo-rocketry/rocketlib.git
8 changes: 3 additions & 5 deletions board.c
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
#include <xc.h>

void LED_init(){
//initializing pins
void LED_init() {
// initializing pins
TRISB3 = 0;
TRISB4 = 0;
TRISB5 = 0;
//returns if pin is on or off
// returns if pin is on or off
LATB3 = 1;
LATB4 = 1;
LATB5 = 1;
}


24 changes: 13 additions & 11 deletions board.h
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
#ifndef BOARD_H
#define BOARD_H
#define BOARD_H

#define MAX_LOOP_TIME_DIFF_ms 250
#define MAX_BUS_DEAD_TIME_ms 1000
#define MAX_TC_TIME_DIFF_ms 200
#define MAX_HEARTBEAT_TIME_DIFF_ms 2000
#define MAX_BUS_DEAD_TIME_ms 2000

#define RED_LED_ON() (LATB3 = 0)
#define RED_LED_OFF() (LATB3 = 1)
#define ORANGE_LED_ON() (LATB4 = 0)
#define RED_LED_ON() (LATB3 = 0)
#define RED_LED_OFF() (LATB3 = 1)
#define RED_LED_TOGGLE() (LATB3 ^= 1)
#define ORANGE_LED_ON() (LATB4 = 0)
#define ORANGE_LED_OFF() (LATB4 = 1)
#define YELLOW_LED_ON() (LATB5 = 0)
#define YELLOW_LED_OFF() (LATB5 = 1)

#define ORANGE_LED_TOGGLE() (LATB4 ^= 1)
#define YELLOW_LED_ON() (LATB5 = 0)
#define YELLOW_LED_OFF() (LATB5 = 1)
#define YELLOW_LED_TOGGLE() (LATB5 ^= 1)

void LED_init();

#endif /* BOARD_H */

#endif /* BOARD_H */

This file was deleted.

Loading

0 comments on commit cca2c77

Please sign in to comment.