Caddy
A 2005 Roborodentia entry with vision and path planning capability
Main Page
Related Pages
Data Structures
Files
File List
Globals
All
Data Structures
Files
Functions
Variables
Typedefs
Macros
Pages
src
tweak_data.h
Go to the documentation of this file.
1
/*
2
* This file is part of Caddy.
3
*
4
* Caddy is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation, either version 3 of the License, or
7
* (at your option) any later version.
8
*
9
* Caddy is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with Caddy. If not, see <http://www.gnu.org/licenses/>.
16
*/
24
#ifndef EEPROM_H_
25
#define EEPROM_H_
26
27
#include <stdint.h>
28
29
//Locations in EEPROM
30
#define EE_ADDR_LEFT_BASE 0x50
31
#define EE_ADDR_RIGHT_BASE 0x51
32
#define EE_ADDR_SLOPE_COEF 0x52 //uint16_t
33
#define EE_ADDR_OFF_COEF 0x54 //uint16_t
34
#define EE_ADDR_DAMP_COEF 0x56
35
#define EE_ADDR_LINE_X_CENTER 0x57
36
#define EE_ADDR_TURN_POINT 0x58
37
#define EE_ADDR_TURN_SUBTRACT 0x59
38
#define EE_ADDR_PAN_OFFSET 0x5A
39
#define EE_ADDR_TILT_OFFSET 0x5B
40
#define EE_ADDR_TRACTOR_OVERSHOOT_DELAY 0x5C //uint16_t
41
#define EE_ADDR_TEST_MODE 0x5E
42
#define EE_ADDR_TEMP_TWEAK1 0x5F
43
#define EE_ADDR_TEMP_TWEAK2 0x60
44
#define EE_ADDR_TEMP_TWEAK3 0x61 //uint16_t
45
#define EE_ADDR_TEMP_TWEAK4 0x63 //uint16_t
46
//next address 0x65
47
48
/*
49
// Current values - Bigger motors at 6 Volts
50
#define INIT_LEFT_BASE_SPEED 0xF7
51
#define INIT_RIGHT_BASE_SPEED 0xF0
52
#define INIT_SLOPE_COEF 0x0110 // <--- 0x110 could be tweaked
53
#define INIT_OFF_COEF 0x0001
54
#define INIT_DAMP_COEF 0x01 // <--- 0x01 could be tweaked
55
#define INIT_LINE_X_CENTER 0x25
56
#define INIT_TURN_POINT 0x15 // Turn values
57
#define INIT_TURN_SUBTRACT 0x0A
58
pan offset 0x05
59
tilt offset 0xE7
60
61
#define TRACTOR_OVERSHOOT_DELAY 5000
62
*/
63
64
#define BASE_MIN 0x60 // <--- also worked at 0xB0
65
#define BASE_MAX 0xFF
66
67
// Pickup values
68
#define BALL_CHECK_RATIO 16
69
#define PICK_UP_POINT 0x16
70
71
72
/*
73
// Old values - 6V Solarbotics before damping fix
74
#define LEFT_BASE_SPEED 0x8C
75
#define RIGHT_BASE_SPEED 0xC2
76
#define BASE_MIN 100
77
#define BASE_MAX 255
78
#define OFF_COEF 0x2
79
#define SLOPE_COEF 0x100
80
#define DAMP_COEF 0x14
81
*/
82
83
// Global variables - Runtime configurable parameters
84
extern
uint8_t l_base;
85
extern
uint8_t r_base;
86
extern
uint16_t slopeCoef;
87
extern
uint16_t offCoef;
88
extern
uint8_t dampCoef;
89
extern
uint8_t lineCenter;
90
extern
uint8_t turnPoint;
91
extern
uint8_t turnSubtract;
92
extern
int8_t panOffset;
93
extern
int8_t tiltOffset;
94
extern
uint16_t tractorOvershootDelay;
95
extern
uint8_t tempTweak1;
96
extern
int8_t tempTweak2;
97
extern
uint16_t tempTweak3;
98
extern
uint16_t tempTweak4;
99
100
extern
uint8_t lcdMode;
101
extern
uint8_t testMode;
102
103
inline
void
loadTweakValues(
void
);
104
inline
void
storeTweakValues(
void
);
105
106
#endif // #ifndef EEPROM_H_
Generated on Wed Apr 10 2013 22:02:29 for Caddy by
1.8.1.2