341 lines
17 KiB
TeX
341 lines
17 KiB
TeX
\hypertarget{group__lowerleveldrivesmeths}{}\section{Methods}
|
|
\label{group__lowerleveldrivesmeths}\index{Methods@{Methods}}
|
|
\subsection*{Functions}
|
|
\begin{DoxyCompactItemize}
|
|
\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga5812df751da5b480240ccd633c515b83}{Code\+Racer\+::drives\+\_\+settings} (uint8\+\_\+t drive\+\_\+left\+\_\+speed, uint8\+\_\+t drive\+\_\+right\+\_\+speed, unsigned long turn\+\_\+left\+\_\+ms, unsigned long turn\+\_\+right\+\_\+ms)
|
|
\begin{DoxyCompactList}\small\item\em Overwrites some drive settings. This will replace the defaults set by the values in the header file. \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga61ed9e0415a62a290cc5c59a0f740304}{Code\+Racer\+::set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right} ()
|
|
\begin{DoxyCompactList}\small\item\em Stopps both drives. \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga802d2646d9cc0d766e1ac799c7917fa8}{Code\+Racer\+::set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right} (drivestate stateleft, drivestate stateright)
|
|
\begin{DoxyCompactList}\small\item\em Sets both of the drives to a specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK) \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga1eeb3cb47503c3011562f9c42828fab9}{Code\+Racer\+::set\+\_\+drive\+\_\+left\+\_\+state} (drivestate state)
|
|
\begin{DoxyCompactList}\small\item\em Sets the left side drive to the specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK) \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga1b34ec9cee1f21cd15db310167a2faa5}{Code\+Racer\+::set\+\_\+drive\+\_\+right\+\_\+state} (drivestate state)
|
|
\begin{DoxyCompactList}\small\item\em Sets the right side drive to the specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK) \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga3b69cf4a718c842fbe758d3f4267214e}{Code\+Racer\+::set\+\_\+drive\+\_\+state} (drivestate state, uint8\+\_\+t frwdpin, uint8\+\_\+t backpin)
|
|
\begin{DoxyCompactList}\small\item\em Sets the specified drivestate for the drive connected to the sepecified pins (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK) \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga3d3ffb41783d34589e33cf61fed46c70}{Code\+Racer\+::set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right} (uint8\+\_\+t speedleft, uint8\+\_\+t speedright)
|
|
\begin{DoxyCompactList}\small\item\em Sets the speed for both of the drives. \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga1ee3da20ec98a821ab97ced070974861}{Code\+Racer\+::set\+\_\+drive\+\_\+left\+\_\+speed} (uint8\+\_\+t speed)
|
|
\begin{DoxyCompactList}\small\item\em Sets the speed for the left side drive. \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_gaf8805d0d620a2fb78c576f36a2c81073}{Code\+Racer\+::set\+\_\+drive\+\_\+right\+\_\+speed} (uint8\+\_\+t speed)
|
|
\begin{DoxyCompactList}\small\item\em Sets the speed for the right side drive. \end{DoxyCompactList}\item
|
|
void \hyperlink{group__lowerleveldrivesmeths_ga5d67c84606d5b39996a99fcd6e7eb314}{Code\+Racer\+::set\+\_\+drive\+\_\+speed} (uint8\+\_\+t speed, uint8\+\_\+t enablepin)
|
|
\begin{DoxyCompactList}\small\item\em Sets the speed for the drive of the enable pin connected to the specified pin. \end{DoxyCompactList}\end{DoxyCompactItemize}
|
|
|
|
|
|
\subsection{Detailed Description}
|
|
|
|
|
|
\subsection{Function Documentation}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga5812df751da5b480240ccd633c515b83}\label{group__lowerleveldrivesmeths_ga5812df751da5b480240ccd633c515b83}}
|
|
\index{Methods@{Methods}!drives\+\_\+settings@{drives\+\_\+settings}}
|
|
\index{drives\+\_\+settings@{drives\+\_\+settings}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{drives\+\_\+settings()}{drives\_settings()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::drives\+\_\+settings (\begin{DoxyParamCaption}\item[{uint8\+\_\+t}]{drive\+\_\+left\+\_\+speed, }\item[{uint8\+\_\+t}]{drive\+\_\+right\+\_\+speed, }\item[{unsigned long}]{turn\+\_\+left\+\_\+for\+\_\+ms, }\item[{unsigned long}]{turn\+\_\+right\+\_\+for\+\_\+ms }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Overwrites some drive settings. This will replace the defaults set by the values in the header file.
|
|
|
|
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em drive\+\_\+left\+\_\+speed} & Speed of the left side drive \\
|
|
\hline
|
|
{\em drive\+\_\+right\+\_\+speed} & Speed of the right side drive \\
|
|
\hline
|
|
{\em turn\+\_\+left\+\_\+for\+\_\+ms} & Time in ms the racer will turn to the left around its center if turn\+\_\+left() is called \\
|
|
\hline
|
|
{\em turn\+\_\+right\+\_\+for\+\_\+ms} & Time in ms the racer will turn to the right around its center if turn\+\_\+right() is called \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 878 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
879 \{
|
|
880 \_drive\_left\_speed = drive\_left\_speed;
|
|
881 \_drive\_right\_speed = drive\_right\_speed;
|
|
882 \_turn\_left\_for\_ms = turn\_left\_for\_ms;
|
|
883 \_turn\_right\_for\_ms = turn\_right\_for\_ms;
|
|
884 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga61ed9e0415a62a290cc5c59a0f740304}\label{group__lowerleveldrivesmeths_ga61ed9e0415a62a290cc5c59a0f740304}}
|
|
\index{Methods@{Methods}!set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right}}
|
|
\index{set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right()}{set\_drives\_stop\_left\_right()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drives\+\_\+stop\+\_\+left\+\_\+right (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Stopps both drives.
|
|
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 889 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
889 \{
|
|
890 set\_drive\_left\_state(DRIVESTOP);
|
|
891 set\_drive\_right\_state(DRIVESTOP);
|
|
892 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga802d2646d9cc0d766e1ac799c7917fa8}\label{group__lowerleveldrivesmeths_ga802d2646d9cc0d766e1ac799c7917fa8}}
|
|
\index{Methods@{Methods}!set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right}}
|
|
\index{set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right()}{set\_drives\_states\_left\_right()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drives\+\_\+states\+\_\+left\+\_\+right (\begin{DoxyParamCaption}\item[{drivestate}]{stateleft, }\item[{drivestate}]{stateright }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets both of the drives to a specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK)
|
|
|
|
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em stateleft} & drivestate to set for the left side drive \\
|
|
\hline
|
|
{\em stateright} & drivestate to set for the right side drive \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 899 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
899 \{
|
|
900 set\_drive\_left\_state(stateleft);
|
|
901 set\_drive\_right\_state(stateright);
|
|
902 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga1eeb3cb47503c3011562f9c42828fab9}\label{group__lowerleveldrivesmeths_ga1eeb3cb47503c3011562f9c42828fab9}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+left\+\_\+state@{set\+\_\+drive\+\_\+left\+\_\+state}}
|
|
\index{set\+\_\+drive\+\_\+left\+\_\+state@{set\+\_\+drive\+\_\+left\+\_\+state}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+left\+\_\+state()}{set\_drive\_left\_state()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+left\+\_\+state (\begin{DoxyParamCaption}\item[{drivestate}]{state }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the left side drive to the specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK)
|
|
|
|
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em state} & drivestate to set for the left side drive \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 908 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
908 \{
|
|
909 set\_drive\_state(state, \_drive\_left\_frwd\_pin, \_drive\_left\_back\_pin);
|
|
910 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga1b34ec9cee1f21cd15db310167a2faa5}\label{group__lowerleveldrivesmeths_ga1b34ec9cee1f21cd15db310167a2faa5}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+right\+\_\+state@{set\+\_\+drive\+\_\+right\+\_\+state}}
|
|
\index{set\+\_\+drive\+\_\+right\+\_\+state@{set\+\_\+drive\+\_\+right\+\_\+state}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+right\+\_\+state()}{set\_drive\_right\_state()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+right\+\_\+state (\begin{DoxyParamCaption}\item[{drivestate}]{state }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the right side drive to the specified drivestate (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK)
|
|
|
|
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em state} & drivestate to set for the right side drive \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 916 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
916 \{
|
|
917 set\_drive\_state(state, \_drive\_right\_frwd\_pin, \_drive\_right\_back\_pin);
|
|
918 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga3b69cf4a718c842fbe758d3f4267214e}\label{group__lowerleveldrivesmeths_ga3b69cf4a718c842fbe758d3f4267214e}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+state@{set\+\_\+drive\+\_\+state}}
|
|
\index{set\+\_\+drive\+\_\+state@{set\+\_\+drive\+\_\+state}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+state()}{set\_drive\_state()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+state (\begin{DoxyParamCaption}\item[{drivestate}]{state, }\item[{uint8\+\_\+t}]{frwdpin, }\item[{uint8\+\_\+t}]{backpin }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the specified drivestate for the drive connected to the sepecified pins (D\+R\+I\+V\+E\+S\+T\+OP, D\+R\+I\+V\+E\+F\+R\+WD, D\+R\+I\+V\+E\+B\+A\+CK)
|
|
|
|
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em state} & drivestate to set for the connected drive \\
|
|
\hline
|
|
{\em frwdpin} & Pin the forward signal of the drive device driver is connected at \\
|
|
\hline
|
|
{\em backpin} & Pin the backward signal of the drive device driver is connected at \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 926 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
926 \{
|
|
927 \textcolor{keywordflow}{switch} (state) \{
|
|
928 \textcolor{keywordflow}{case} DRIVESTOP:
|
|
929 digitalWrite(frwdpin, LOW);
|
|
930 digitalWrite(backpin, LOW);
|
|
931 \textcolor{keywordflow}{break};
|
|
932 \textcolor{keywordflow}{case} DRIVEFRWD:
|
|
933 digitalWrite(frwdpin, HIGH);
|
|
934 digitalWrite(backpin, LOW);
|
|
935 \textcolor{keywordflow}{break};
|
|
936 \textcolor{keywordflow}{case} DRIVEBACK:
|
|
937 digitalWrite(frwdpin, LOW);
|
|
938 digitalWrite(backpin, HIGH);
|
|
939 \textcolor{keywordflow}{break};
|
|
940 \}
|
|
941 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga3d3ffb41783d34589e33cf61fed46c70}\label{group__lowerleveldrivesmeths_ga3d3ffb41783d34589e33cf61fed46c70}}
|
|
\index{Methods@{Methods}!set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right}}
|
|
\index{set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right@{set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right()}{set\_drives\_speed\_left\_right()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drives\+\_\+speed\+\_\+left\+\_\+right (\begin{DoxyParamCaption}\item[{uint8\+\_\+t}]{speedleft, }\item[{uint8\+\_\+t}]{speedright }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the speed for both of the drives.
|
|
|
|
The drive will run with that speed afterwards. The direction of the drive has to be specfied with one of the set\+\_\+drive\+\_\+state methods before
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em speedleft} & speed of the left side drive. 0$<$=speed$<$=255 \\
|
|
\hline
|
|
{\em speedright} & speed of the right side drive. 0$<$=speed$<$=255 \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 950 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
950 \{
|
|
951 set\_drive\_left\_speed(speedleft);
|
|
952 set\_drive\_right\_speed(speedright);
|
|
953 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga1ee3da20ec98a821ab97ced070974861}\label{group__lowerleveldrivesmeths_ga1ee3da20ec98a821ab97ced070974861}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+left\+\_\+speed@{set\+\_\+drive\+\_\+left\+\_\+speed}}
|
|
\index{set\+\_\+drive\+\_\+left\+\_\+speed@{set\+\_\+drive\+\_\+left\+\_\+speed}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+left\+\_\+speed()}{set\_drive\_left\_speed()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+left\+\_\+speed (\begin{DoxyParamCaption}\item[{uint8\+\_\+t}]{speed }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the speed for the left side drive.
|
|
|
|
The drive will run with that speed afterwards. The direction of the drive has to be specfied with one of the set\+\_\+drive\+\_\+state methods before
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em speed} & speed of the left side drive. 0$<$=speed$<$=255 \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 961 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
961 \{
|
|
962 set\_drive\_speed(speed, \_drive\_left\_enable\_pin);
|
|
963 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_gaf8805d0d620a2fb78c576f36a2c81073}\label{group__lowerleveldrivesmeths_gaf8805d0d620a2fb78c576f36a2c81073}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+right\+\_\+speed@{set\+\_\+drive\+\_\+right\+\_\+speed}}
|
|
\index{set\+\_\+drive\+\_\+right\+\_\+speed@{set\+\_\+drive\+\_\+right\+\_\+speed}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+right\+\_\+speed()}{set\_drive\_right\_speed()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+right\+\_\+speed (\begin{DoxyParamCaption}\item[{uint8\+\_\+t}]{speed }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the speed for the right side drive.
|
|
|
|
The drive will run with that speed afterwards. The direction of the drive has to be specfied with one of the set\+\_\+drive\+\_\+state methods before
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em speed} & speed of the right side drive. 0$<$=speed$<$=255 \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 971 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
971 \{
|
|
972 set\_drive\_speed(speed, \_drive\_right\_enable\_pin);
|
|
973 \}
|
|
\end{DoxyCode}
|
|
\mbox{\Hypertarget{group__lowerleveldrivesmeths_ga5d67c84606d5b39996a99fcd6e7eb314}\label{group__lowerleveldrivesmeths_ga5d67c84606d5b39996a99fcd6e7eb314}}
|
|
\index{Methods@{Methods}!set\+\_\+drive\+\_\+speed@{set\+\_\+drive\+\_\+speed}}
|
|
\index{set\+\_\+drive\+\_\+speed@{set\+\_\+drive\+\_\+speed}!Methods@{Methods}}
|
|
\subsubsection{\texorpdfstring{set\+\_\+drive\+\_\+speed()}{set\_drive\_speed()}}
|
|
{\footnotesize\ttfamily void Code\+Racer\+::set\+\_\+drive\+\_\+speed (\begin{DoxyParamCaption}\item[{uint8\+\_\+t}]{speed, }\item[{uint8\+\_\+t}]{enablepin }\end{DoxyParamCaption})}
|
|
|
|
|
|
|
|
Sets the speed for the drive of the enable pin connected to the specified pin.
|
|
|
|
The drive will run with that speed afterwards. The direction of the drive has to be specfied with one of the set\+\_\+drive\+\_\+state methods before
|
|
\begin{DoxyParams}{Parameters}
|
|
{\em speed} & speed of the drive. 0$<$=speed$<$=255 \\
|
|
\hline
|
|
{\em enablepin} & Pin the drives device driver enable pin is connected at \\
|
|
\hline
|
|
\end{DoxyParams}
|
|
\begin{DoxyReturn}{Returns}
|
|
nothing
|
|
\end{DoxyReturn}
|
|
|
|
|
|
Definition at line 982 of file Code\+Racer.\+cpp.
|
|
|
|
|
|
\begin{DoxyCode}
|
|
982 \{
|
|
983 \_analog\_write(enablepin, (\textcolor{keywordtype}{int})speed);
|
|
984 \}
|
|
\end{DoxyCode}
|