RBE1001Lib
RBE1001Lib.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <Esp32WifiManager.h>
4 #include <WebServer.h>
5 #include <ESPmDNS.h>
6 #include <ESP32AnalogRead.h>
7 
8 #include "Rangefinder.h"
9 #include "Motor.h"
10 
11 // Pins used by a perpheral, may be re-used
12 #define BOOT_FLAG_PIN 0
13 #define I2C_SDA 21
14 #define I2C_SCL 22
15 #define SERIAL_PROGRAMMING_TX 1
16 #define SERIAL_PROGRAMMING_RX 3
17 
18 #define SPI_MOSI 23
19 #define SPI_MISO 19
20 #define SPI_SCK 18
21 #define SPI_SS 5
22 
23 // Ultrasonics
24 #define SIDE_ULTRASONIC_TRIG 16
25 #define SIDE_ULTRASONIC_ECHO 17
26 
27 //A4
28 #define LEFT_LINE_SENSE 36
29 //A3
30 #define RIGHT_LINE_SENSE 39
31 //A2
32 #define SERVO_FEEDBACK_SENSOR 34
33 
36 #define SERVO_PIN 33
37 
38 #define MOTOR_DISABLE 15
39 
43 #define MOTOR_LEFT_PWM 13
44 
47 //A5
48 #define MOTOR_LEFT_DIR 4
49 
52 #define MOTOR_RIGHT_PWM 12
53 
56 //A1
57 #define MOTOR_RIGHT_DIR 25
58 //Encoder pins
59 
60 #define MOTOR_LEFT_ENCA 27
61 //A0
62 #define MOTOR_LEFT_ENCB 26
63 
64 #define MOTOR_RIGHT_ENCA 32
65 #define MOTOR_RIGHT_ENCB 14
66 
67 class LeftMotor : public Motor
68 {
69 public:
71 };
72 
73 class RightMotor : public Motor
74 {
75 public:
77 };
#define MOTOR_LEFT_DIR
Definition: RBE1001Lib.h:48
#define MOTOR_LEFT_PWM
Definition: RBE1001Lib.h:43
#define MOTOR_RIGHT_ENCA
Definition: RBE1001Lib.h:64
#define MOTOR_RIGHT_PWM
Definition: RBE1001Lib.h:52
#define MOTOR_LEFT_ENCB
Definition: RBE1001Lib.h:62
#define MOTOR_LEFT_ENCA
Definition: RBE1001Lib.h:60
A PID Motor class using FreeRTOS threads, ESP32Encoder and ESP32PWM.
Definition: Motor.h:43
#define MOTOR_RIGHT_ENCB
Definition: RBE1001Lib.h:65
#define MOTOR_RIGHT_DIR
Definition: RBE1001Lib.h:57