PropWare
3.0.0.229
C++ objects and CMake build system for Parallax Propeller
Simple-Libraries
Learn
Simple Libraries
Robotics
ActivityBot360
libabdrive360
drive_encoderPins.c
1
/*
2
@file drive_encoderPins.c
3
4
@author Parallax Inc
5
6
@copyright
7
Copyright (C) Parallax Inc. 2017. All Rights MIT Licensed. See end of file.
8
9
@brief
10
*/
11
// // //
12
13
14
#include "
abdrive360.h
"
15
16
17
// Comment same as for drive_servoPins.
18
/*
19
void drive_encoderPins(int encPinLeft, int encPinRight)
20
{
21
abd360_pinFbLeft = encPinLeft;
22
abd360_pinFbRight = encPinRight;
23
}
24
*/
25
volatile
int
abd360_suppress_eeprom;
26
27
//
28
void
drive_encoderPins
(
int
encPinLeft,
int
encPinRight)
// drivePins function
29
{
30
//abd_ePinL = encPinLeft;
31
//abd_ePinR = encPinRight;
32
//if(!abd_us) abd_us = CLKFREQ/1000000;
33
34
int
eeAddr = 8 +
_AB360_EE_Start_
+ _AB360_EE_Pins_;
35
unsigned
char
pinInfo[8] = {
'e'
,
'p'
,
'L'
, 14,
' '
,
'R'
, 15,
' '
};
36
pinInfo[3] = (
char
) encPinLeft;
37
pinInfo[6] = (
char
) encPinRight;
38
39
if
(!abd360_suppress_eeprom)
40
{
41
ee_putStr
(pinInfo, 8, eeAddr);
42
}
43
44
abd360_pinFbLeft = encPinLeft;
45
abd360_pinFbRight = encPinRight;
46
47
//
48
//if(!abd_intTabSetup)
49
//{
50
// interpolation_table_setup();
51
//}
52
//
53
}
54
//
55
56
drive_encoderPins
void drive_encoderPins(int encPinLeft, int encPinRight)
Set encoder pins to values other than the default P14 for left encoder and P15 for right encoder....
Definition:
servoPins.c:208
_AB360_EE_Start_
#define _AB360_EE_Start_
ActivityBot EEPROM calibration data start address.
Definition:
abcalibrate360.h:68
ee_putStr
void ee_putStr(unsigned char *s, int n, int addr)
Store a string of byte values starting at a certain address in the Propeller Chip's dedicated EEPROM.
Definition:
eeprom_putStr.c:25
abdrive360.h
This library provides a simple set of functions for making the ActivityBot 360 go certain distances a...
char
Generated on Fri May 20 2022 16:48:04 for PropWare by
1.8.17