return new BicycleCar(x0, B->y(), B->h());
}
+BicycleCar *ParallelSlot::getFPf()
+{
+ this->setAll();
+ float x = this->slot().bnodes().front()->x();
+ float y = this->slot().bnodes().front()->y();
+ float h = this->slotHeading();
+ float nx;
+ float ny;
+ if (this->slotSide() == LEFT) {
+ h += M_PI / 2;
+ nx = x + (BCAR_LENGTH - BCAR_WHEEL_BASE) / 2
+ * cos(h);
+ ny = y + (BCAR_LENGTH - BCAR_WHEEL_BASE) / 2
+ * sin(h);
+ x = nx + (BCAR_DIAG_RRADI) * cos(h - M_PI / 2);
+ y = ny + (BCAR_DIAG_RRADI) * sin(h - M_PI / 2);
+ } else {
+ h -= M_PI / 2;
+ nx = x + (BCAR_LENGTH - BCAR_WHEEL_BASE) / 2
+ * cos(h);
+ ny = y + (BCAR_LENGTH - BCAR_WHEEL_BASE) / 2
+ * sin(h);
+ x = nx + (BCAR_DIAG_RRADI) * cos(h + M_PI / 2);
+ y = ny + (BCAR_DIAG_RRADI) * sin(h + M_PI / 2);
+ }
+ return new BicycleCar(x, y, h);
+}
+
bool ParallelSlot::isInside(BicycleCar *c)
{
bool inside = true;
BicycleCar *getEPC();
/** Return start pose for fipr method */
BicycleCar *getFP();
+ BicycleCar *getFPf(); // parked forward, only for perpendicular
/** In slot perpendicular pose getter
This method returns a pose of perpendicular parking slot from