-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8c88c8a
commit b2a2582
Showing
8 changed files
with
12,991 additions
and
12,951 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
#ifndef LED_H | ||
#define LED_H | ||
|
||
#define LED (*((volatile unsigned long *)0x40025038)) // use onboard three LEDs: PF321 | ||
|
||
#define RGB 0x0E // PF3, PF2, PF1 | ||
#define Dark 0x00 // --- | ||
#define Red 0x02 // R-- | ||
#define Blue 0x04 // --B | ||
#define Green 0x08 // -G- | ||
#define Yellow 0x0A // RG- | ||
#define Cran 0x0C // -GB | ||
#define White 0x0E // RGB | ||
#define Purple 0x06 // R-B | ||
|
||
#include "tm4c123gh6pm.h" | ||
|
||
void led_init(void); | ||
|
||
#endif | ||
#ifndef LED_H | ||
#define LED_H | ||
|
||
#define LED (*((volatile unsigned long *)0x40025038)) // use onboard three LEDs: PF321 | ||
|
||
#define RGB 0x0E // PF3, PF2, PF1 | ||
#define Dark 0x00 // --- | ||
#define Red 0x02 // R-- | ||
#define Blue 0x04 // --B | ||
#define Green 0x08 // -G- | ||
#define Yellow 0x0A // RG- | ||
#define Cran 0x0C // -GB | ||
#define White 0x0E // RGB | ||
#define Purple 0x06 // R-B | ||
|
||
#include "tm4c123gh6pm.h" | ||
|
||
void led_init(void); | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
#ifndef MOTORCONTROL_H | ||
#define MOTORCONTROL_H | ||
|
||
#include "LED.h" | ||
#include "tm4c123gh6pm.h" | ||
|
||
void move_forward(void); | ||
void move_backward(void); | ||
void pivot_left(void); | ||
void pivot_right(void); | ||
void turn_left(void); | ||
void turn_right(void); | ||
void stop_motors(void); | ||
|
||
#endif | ||
#ifndef MOTORCONTROL_H | ||
#define MOTORCONTROL_H | ||
|
||
#include "LED.h" | ||
#include "tm4c123gh6pm.h" | ||
|
||
void move_forward(void); | ||
void move_backward(void); | ||
void pivot_left(void); | ||
void pivot_right(void); | ||
void turn_left(void); | ||
void turn_right(void); | ||
void stop_motors(void); | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
#ifndef MOTORSETUP_H | ||
#define MOTORSETUP_H | ||
|
||
#define STOP 1 | ||
#define MAX_SPEED PERIOD - 1 | ||
#define HALF_SPEED PERIOD * 0.5 | ||
|
||
#include <stdint.h> | ||
#include "tm4c123gh6pm.h" | ||
#include "PLL.h" | ||
|
||
void motors_init(void); | ||
void pwm_duty(unsigned long dutyL, unsigned long dutyR); | ||
unsigned long get_current_duty(void); | ||
|
||
#endif | ||
#ifndef MOTORSETUP_H | ||
#define MOTORSETUP_H | ||
|
||
#define STOP 1 | ||
#define MAX_SPEED PERIOD - 1 | ||
#define HALF_SPEED PERIOD * 0.5 | ||
|
||
#include <stdint.h> | ||
#include "tm4c123gh6pm.h" | ||
#include "PLL.h" | ||
|
||
void motors_init(void); | ||
void pwm_duty(unsigned long dutyL, unsigned long dutyR); | ||
unsigned long get_current_duty(void); | ||
|
||
#endif |
Oops, something went wrong.