#include <Car.h>
Default constructor of class Car.
Set the car name as "Car1" and fork a thread for poke
String constructor of class Car.
Set the car name from param and fork a thread for poke
- Parameters
-
name | A string of the car name |
Default destructor of class Car.
Cancel the thread of poke
void Car::adjustDirection |
( |
| ) |
|
Adjust the car direction according to the next positon.
void Car::forkThreadForLocation |
( |
| ) |
|
void Car::forkThreadForPoke |
( |
| ) |
|
Fork a sub thread for poke.
getter function of m_map
- Returns
- the same object of the map
Motor & Car::getMotor |
( |
| ) |
|
getter function of m_motor
- Returns
- the same object of the motor
void Car::startPeek |
( |
std::string |
ptr | ) |
|
New a peek class and start to do peek.
Format the peek text, Set the params of peek, judeg if data is received
- Parameters
-
ptr | A string of what to be sent out |
void* startLocation |
( |
void * |
ptr | ) |
|
|
friend |
void* startPoke |
( |
void * |
ptr | ) |
|
|
friend |
pthread_t Car::locationThread |
|
private |
pthread_t Car::pokeThread |
|
private |
The documentation for this class was generated from the following files: