desi77 0.1.12 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1092 -46
- package/dist/pgdsvg/capsule_nose.svg +1 -0
- package/dist/pgdsvg/capsule_side.svg +2 -1
- package/dist/pgdsvg/capsule_top.svg +1 -0
- package/dist/pgdsvg/capsule_wall.svg +1 -0
- package/dist/pgdsvg/capsule_wheels.svg +1 -0
- package/dist/pgdsvg/rccar_all_xy.svg +3 -0
- package/dist/pgdsvg/rccar_all_xz.svg +1 -0
- package/dist/pgdsvg/rccar_bone.svg +1 -0
- package/dist/pgdsvg/rccar_motor_xz.svg +1 -0
- package/dist/pgdsvg/rccar_one_xy.svg +1 -0
- package/dist/pgdsvg/rccar_platform_xz.svg +1 -0
- package/dist/pgdsvg/src_capsule.svg +2 -1
- package/dist/pgdsvg/src_rccar.svg +3 -1
- package/package.json +6 -6
- package/dist/pgdsvg/rccar_angles.svg +0 -1
package/dist/index.js
CHANGED
|
@@ -4121,11 +4121,20 @@ var heliostatDef = {
|
|
|
4121
4121
|
|
|
4122
4122
|
// src/rccar/rccar.ts
|
|
4123
4123
|
import {
|
|
4124
|
+
withinHPiHPi,
|
|
4125
|
+
ShapePoint as ShapePoint2,
|
|
4126
|
+
point as point7,
|
|
4127
|
+
contour as contour14,
|
|
4128
|
+
contourCircle as contourCircle11,
|
|
4124
4129
|
ctrRectangle as ctrRectangle6,
|
|
4125
4130
|
figure as figure11,
|
|
4131
|
+
degToRad as degToRad6,
|
|
4126
4132
|
ffix as ffix14,
|
|
4127
4133
|
pNumber as pNumber13,
|
|
4134
|
+
pCheckbox as pCheckbox8,
|
|
4135
|
+
pDropdown as pDropdown7,
|
|
4128
4136
|
pSectionSeparator as pSectionSeparator13,
|
|
4137
|
+
transform3d,
|
|
4129
4138
|
EExtrude as EExtrude10,
|
|
4130
4139
|
EBVolume as EBVolume10,
|
|
4131
4140
|
initGeom as initGeom13
|
|
@@ -4134,23 +4143,80 @@ var pDef13 = {
|
|
|
4134
4143
|
partName: "rccar",
|
|
4135
4144
|
params: [
|
|
4136
4145
|
//pNumber(name, unit, init, min, max, step)
|
|
4137
|
-
pNumber13("
|
|
4138
|
-
pNumber13("L1", "mm",
|
|
4139
|
-
|
|
4146
|
+
pNumber13("N1", "unit", 4, 1, 12, 1),
|
|
4147
|
+
pNumber13("L1", "mm", 300, 10, 2e3, 1),
|
|
4148
|
+
pNumber13("W1", "mm", 1200, 10, 2e3, 1),
|
|
4149
|
+
pSectionSeparator13("General"),
|
|
4150
|
+
pDropdown7("gen3D", ["all", "platform", "bone", "hand", "motor", "wheel"]),
|
|
4151
|
+
pNumber13("T1", "mm", 10, 1, 100, 1),
|
|
4140
4152
|
pNumber13("E1", "mm", 10, 1, 100, 1),
|
|
4153
|
+
pNumber13("E2", "mm", 10, 1, 500, 1),
|
|
4154
|
+
pNumber13("E3", "mm", 30, 1, 500, 1),
|
|
4155
|
+
pSectionSeparator13("Platform"),
|
|
4156
|
+
pNumber13("H1", "mm", 230, 10, 2e3, 1),
|
|
4157
|
+
pNumber13("W2", "mm", 100, 10, 2e3, 1),
|
|
4158
|
+
pCheckbox8("triangleInt", true),
|
|
4159
|
+
pCheckbox8("triangleExt", false),
|
|
4160
|
+
pSectionSeparator13("Bone"),
|
|
4161
|
+
pNumber13("D1", "mm", 20, 1, 200, 1),
|
|
4162
|
+
pNumber13("D2", "mm", 40, 1, 200, 1),
|
|
4163
|
+
pNumber13("W3", "mm", 30, 1, 200, 1),
|
|
4164
|
+
pNumber13("L2", "mm", 150, 1, 200, 1),
|
|
4165
|
+
pSectionSeparator13("Unit"),
|
|
4166
|
+
pNumber13("F1", "mm", 180, 1, 1e3, 1),
|
|
4167
|
+
pNumber13("Dwheel", "mm", 250, 10, 2e3, 1),
|
|
4168
|
+
pNumber13("Z1", "mm", 100, 10, 2e3, 1),
|
|
4169
|
+
pNumber13("Z2", "mm", 160, 10, 2e3, 1),
|
|
4170
|
+
pNumber13("Lwheel", "mm", 100, 10, 2e3, 1),
|
|
4171
|
+
pNumber13("Lmotor", "mm", 140, 10, 1e3, 1),
|
|
4172
|
+
pNumber13("Dsteering", "mm", 40, 1, 500, 1),
|
|
4173
|
+
pNumber13("Daxis", "mm", 20, 1, 500, 1),
|
|
4141
4174
|
pSectionSeparator13("Angles"),
|
|
4142
|
-
pNumber13("
|
|
4143
|
-
pNumber13("
|
|
4175
|
+
pNumber13("aBoneMin", "degree", -40, -80, 0, 1),
|
|
4176
|
+
pNumber13("aBoneMax", "degree", 20, -80, 80, 1),
|
|
4177
|
+
pNumber13("aBoneLeft", "%", 0, 0, 100, 1),
|
|
4178
|
+
pNumber13("aBoneRight", "%", 0, 0, 100, 1),
|
|
4179
|
+
pDropdown7("wheel", ["straight", "turn"]),
|
|
4180
|
+
pNumber13("ra", "degree", 0, -90, 90, 1),
|
|
4181
|
+
pNumber13("rx", "cm", 0, -1e3, 1e3, 1),
|
|
4182
|
+
pNumber13("ry", "cm", 0, -1e3, 1e3, 1)
|
|
4144
4183
|
],
|
|
4145
4184
|
paramSvg: {
|
|
4146
|
-
|
|
4147
|
-
L1: "
|
|
4148
|
-
|
|
4149
|
-
|
|
4150
|
-
|
|
4185
|
+
N1: "rccar_all_xy.svg",
|
|
4186
|
+
L1: "rccar_all_xy.svg",
|
|
4187
|
+
W1: "rccar_all_xz.svg",
|
|
4188
|
+
gen3D: "rccar_all_xy.svg",
|
|
4189
|
+
T1: "rccar_one_xy.svg",
|
|
4190
|
+
E1: "rccar_one_xy.svg",
|
|
4191
|
+
E2: "rccar_motor_xz.svg",
|
|
4192
|
+
E3: "rccar_motor_xz.svg",
|
|
4193
|
+
H1: "rccar_platform_xz.svg",
|
|
4194
|
+
W2: "rccar_platform_xz.svg",
|
|
4195
|
+
triangleInt: "rccar_all_xy.svg",
|
|
4196
|
+
triangleExt: "rccar_all_xy.svg",
|
|
4197
|
+
D1: "rccar_bone.svg",
|
|
4198
|
+
D2: "rccar_bone.svg",
|
|
4199
|
+
W3: "rccar_bone.svg",
|
|
4200
|
+
L2: "rccar_bone.svg",
|
|
4201
|
+
F1: "rccar_one_xy.svg",
|
|
4202
|
+
Dwheel: "rccar_motor_xz.svg",
|
|
4203
|
+
Z1: "rccar_motor_xz.svg",
|
|
4204
|
+
Z2: "rccar_motor_xz.svg",
|
|
4205
|
+
Lwheel: "rccar_motor_xz.svg",
|
|
4206
|
+
Lmotor: "rccar_motor_xz.svg",
|
|
4207
|
+
Dsteering: "rccar_motor_xz.svg",
|
|
4208
|
+
Daxis: "rccar_motor_xz.svg",
|
|
4209
|
+
aBoneMin: "rccar_all_xz.svg",
|
|
4210
|
+
aBoneMax: "rccar_all_xz.svg",
|
|
4211
|
+
aBoneLeft: "rccar_all_xz.svg",
|
|
4212
|
+
aBoneRight: "rccar_all_xz.svg",
|
|
4213
|
+
wheel: "rccar_all_xy.svg",
|
|
4214
|
+
ra: "rccar_all_xy.svg",
|
|
4215
|
+
rx: "rccar_all_xy.svg",
|
|
4216
|
+
ry: "rccar_all_xy.svg"
|
|
4151
4217
|
},
|
|
4152
4218
|
sim: {
|
|
4153
|
-
tMax:
|
|
4219
|
+
tMax: 200,
|
|
4154
4220
|
tStep: 0.5,
|
|
4155
4221
|
tUpdate: 500
|
|
4156
4222
|
// every 0.5 second
|
|
@@ -4159,37 +4225,629 @@ var pDef13 = {
|
|
|
4159
4225
|
function pGeom13(t, param, suffix = "") {
|
|
4160
4226
|
const rGeome = initGeom13(pDef13.partName + suffix);
|
|
4161
4227
|
const figPlatform = figure11();
|
|
4228
|
+
const figTriangle = figure11();
|
|
4229
|
+
const figPFfixation = figure11();
|
|
4230
|
+
const figBones = figure11();
|
|
4231
|
+
const figHandFixation = figure11();
|
|
4232
|
+
const figHandPlateR = figure11();
|
|
4233
|
+
const figHandPlateL = figure11();
|
|
4234
|
+
const figHandBackR = figure11();
|
|
4235
|
+
const figHandBackL = figure11();
|
|
4236
|
+
const figMotorBulkR = figure11();
|
|
4237
|
+
const figMotorBulkL = figure11();
|
|
4238
|
+
const figMFoot = figure11();
|
|
4239
|
+
const figWheel = figure11();
|
|
4240
|
+
const figTop = figure11();
|
|
4241
|
+
const figSide = figure11();
|
|
4162
4242
|
rGeome.logstr += `${rGeome.partName} simTime: ${t}
|
|
4163
4243
|
`;
|
|
4164
4244
|
try {
|
|
4245
|
+
let calcPercent2 = function(aInit) {
|
|
4246
|
+
const percent2 = (aInit + t) % 200;
|
|
4247
|
+
const rP = percent2 > 100 ? 200 - percent2 : percent2;
|
|
4248
|
+
return rP / 100;
|
|
4249
|
+
}, adjustWheelAngle2 = function(dY, dX, ref) {
|
|
4250
|
+
const rawA = Math.atan2(dY, dX);
|
|
4251
|
+
const rA = ref + withinHPiHPi(rawA - ref);
|
|
4252
|
+
return rA;
|
|
4253
|
+
}, makePFfixExt2 = function(sign, tpA, tpL) {
|
|
4254
|
+
const dW22 = sign * (W22 - param.T1);
|
|
4255
|
+
const dW22b = -sign * (W22 + 2 * (param.E2 + R2) + param.T1);
|
|
4256
|
+
const dW22c = tpL > 0 ? dW22b : dW22;
|
|
4257
|
+
const dx1 = sign * (param.E2 + R2);
|
|
4258
|
+
const dx2 = sign * param.T1 + dx1;
|
|
4259
|
+
const dR2 = sign * R2;
|
|
4260
|
+
const dW22d = tpL > 0 ? -dW22 - dx2 : dW22 + dx2;
|
|
4261
|
+
const rCtrExt = contour14(dW22c, 0, "green").addSegStrokeR(dx2, 0).addPointR(dR2, R2).addPointR(0, 2 * R2).addSegArc2().addSegStrokeR(-dx1, 0).addSegStrokeR(0, Z2b).addSegStrokeR(dx1, 0).addPointR(dR2, R2).addPointR(0, 2 * R2).addSegArc2().addSegStrokeR(-dx2, 0).closeSegStroke().translatePolar(tpA, tpL);
|
|
4262
|
+
const rCtr1 = contourCircle11(dW22d, R2, R1).translatePolar(tpA, tpL);
|
|
4263
|
+
const rCtr2 = contourCircle11(dW22d, Z2b + 3 * R2, R1).translatePolar(tpA, tpL);
|
|
4264
|
+
return [rCtrExt, rCtr1, rCtr2];
|
|
4265
|
+
}, makeHandPlate2 = function(az, addL, ipX, ipY) {
|
|
4266
|
+
const rCtrExt = contour14(ipX, ipY + F12).addPointR(-F12, -F12).addPointR(0, -2 * F12).addSegArc2().addSegStrokeR(F12 + addL, 0).addSegStrokeR(0, 2 * F12).closeSegStroke().rotate(ipX, ipY, az);
|
|
4267
|
+
const rCtrHole = contourCircle11(ipX, ipY, Rsteering);
|
|
4268
|
+
return [rCtrExt, rCtrHole];
|
|
4269
|
+
}, makeMFoot2 = function(itx, ity) {
|
|
4270
|
+
const rCtrExt = contour14(itx - mFootR, ity, "green").addPointR(mFootR, -mFootR).addPointR(2 * mFootR, 0).addSegArc2().addSegStrokeR(F12 - mFootR, param.Z1 + param.T1 + param.E1).addSegStrokeR(0, motorHeight).addSegStrokeR(-2 * F12, 0).addSegStrokeR(0, -motorHeight).closeSegStroke();
|
|
4271
|
+
const rCtrHole = contourCircle11(itx, ity, Raxis + param.E1);
|
|
4272
|
+
return [rCtrExt, rCtrHole];
|
|
4273
|
+
}, makeCtrWheel2 = function(xSign, ia, itx, ity) {
|
|
4274
|
+
const rCtr = contour14(itx, ity).addSegStrokeR(xSign * Raxis, 0).addSegStrokeR(0, mFootWidth + param.E3).addSegStrokeR(xSign * dWheelAxis, 0).addCornerRounded(roundedWheel).addSegStrokeR(0, param.Lwheel).addCornerRounded(roundedWheel).addSegStrokeR(-xSign * Rwheel, 0).closeSegStroke().rotate(itx, ity, ia);
|
|
4275
|
+
return rCtr;
|
|
4276
|
+
}, makeTopWheel2 = function(itx, ity, ia) {
|
|
4277
|
+
const tL = param.Lmotor - mFootWidth;
|
|
4278
|
+
const tCos = tL * Math.cos(ia);
|
|
4279
|
+
const tSin = tL * Math.sin(ia);
|
|
4280
|
+
const ctrWheel1 = makeCtrWheel2(1, -pi2 + ia, itx + tCos, ity + tSin);
|
|
4281
|
+
const ctrWheel2 = makeCtrWheel2(-1, -pi2 + ia, itx + tCos, ity + tSin);
|
|
4282
|
+
const ctrMFootPre = ctrRectangle6(itx + tL, ity - F12, mFootWidth, 2 * F12);
|
|
4283
|
+
const ctrMFoot = ctrMFootPre.rotate(itx, ity, ia);
|
|
4284
|
+
return [ctrWheel1, ctrWheel2, ctrMFoot];
|
|
4285
|
+
}, extrudeTriangle2 = function(posZ, idx) {
|
|
4286
|
+
const rVol = {
|
|
4287
|
+
outName: `subpax_${designName}_platformTriangle${idx}`,
|
|
4288
|
+
face: `${designName}_faceTriangle`,
|
|
4289
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4290
|
+
length: param.T1,
|
|
4291
|
+
rotate: [0, 0, 0],
|
|
4292
|
+
translate: [0, 0, posZ]
|
|
4293
|
+
};
|
|
4294
|
+
return rVol;
|
|
4295
|
+
}, extrudePFfixation2 = function(posZ, idx) {
|
|
4296
|
+
const rVol = {
|
|
4297
|
+
outName: `subpax_${designName}_PFfixation${idx}`,
|
|
4298
|
+
face: `${designName}_facePFfixation`,
|
|
4299
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4300
|
+
length: param.T1,
|
|
4301
|
+
rotate: [0, 0, 0],
|
|
4302
|
+
translate: [0, 0, posZ]
|
|
4303
|
+
};
|
|
4304
|
+
return rVol;
|
|
4305
|
+
}, extrudeBones2 = function(posZ, idx) {
|
|
4306
|
+
const rVol = {
|
|
4307
|
+
outName: `subpax_${designName}_bones${idx}`,
|
|
4308
|
+
face: `${designName}_faceBones`,
|
|
4309
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4310
|
+
length: param.T1,
|
|
4311
|
+
rotate: [0, 0, 0],
|
|
4312
|
+
translate: [0, 0, posZ]
|
|
4313
|
+
};
|
|
4314
|
+
return rVol;
|
|
4315
|
+
}, extrudeHandFixation2 = function(posZ, idx) {
|
|
4316
|
+
const rVol = {
|
|
4317
|
+
outName: `subpax_${designName}_handFixation${idx}`,
|
|
4318
|
+
face: `${designName}_faceHandFixation`,
|
|
4319
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4320
|
+
length: param.T1,
|
|
4321
|
+
rotate: [0, 0, 0],
|
|
4322
|
+
translate: [0, 0, posZ]
|
|
4323
|
+
};
|
|
4324
|
+
return rVol;
|
|
4325
|
+
}, extrudeHandPlate2 = function(posY, iRL, idx) {
|
|
4326
|
+
const rVol = {
|
|
4327
|
+
outName: `subpax_${designName}_handPlate${iRL}${idx}`,
|
|
4328
|
+
face: `${designName}_faceHandPlate${iRL}`,
|
|
4329
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4330
|
+
length: param.T1,
|
|
4331
|
+
rotate: [pi2, 0, 0],
|
|
4332
|
+
translate: [0, posY + param.T1, 0]
|
|
4333
|
+
};
|
|
4334
|
+
return rVol;
|
|
4335
|
+
}, extrudeHandBack2 = function(posY, iRL) {
|
|
4336
|
+
const rVol = {
|
|
4337
|
+
outName: `subpax_${designName}_handBack${iRL}`,
|
|
4338
|
+
face: `${designName}_faceHandBack${iRL}`,
|
|
4339
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4340
|
+
length: param.Z2,
|
|
4341
|
+
rotate: [pi2, 0, 0],
|
|
4342
|
+
translate: [0, posY + param.T1, 0]
|
|
4343
|
+
};
|
|
4344
|
+
return rVol;
|
|
4345
|
+
}, extrudeMotorBulk2 = function(posY, iRL) {
|
|
4346
|
+
const rVol = {
|
|
4347
|
+
outName: `subpax_${designName}_motorBulk${iRL}`,
|
|
4348
|
+
face: `${designName}_faceMotorBulk${iRL}`,
|
|
4349
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4350
|
+
length: motorHeight,
|
|
4351
|
+
rotate: [pi2, 0, 0],
|
|
4352
|
+
translate: [0, posY - param.E1, 0]
|
|
4353
|
+
};
|
|
4354
|
+
return rVol;
|
|
4355
|
+
}, extrudeMFoot2 = function(posX, posY, posZ, az, idx) {
|
|
4356
|
+
const tL = param.Lmotor - mFootWidth;
|
|
4357
|
+
const tCos = tL * Math.cos(az);
|
|
4358
|
+
const tSin = tL * Math.sin(az);
|
|
4359
|
+
const tm = transform3d().addRotation(0, pi2 - az, 0).addTranslation(posX + tCos, posY, posZ + tSin);
|
|
4360
|
+
const rVol = {
|
|
4361
|
+
outName: `subpax_${designName}_mFoot${idx}`,
|
|
4362
|
+
face: `${designName}_faceMFoot`,
|
|
4363
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4364
|
+
length: mFootWidth,
|
|
4365
|
+
rotate: tm.getRotation(),
|
|
4366
|
+
translate: tm.getTranslation()
|
|
4367
|
+
};
|
|
4368
|
+
return rVol;
|
|
4369
|
+
}, extrudeWheel2 = function(posX, posY, posZ, az, idx) {
|
|
4370
|
+
const tL = param.Lmotor - mFootWidth;
|
|
4371
|
+
const tCos = tL * Math.cos(az);
|
|
4372
|
+
const tSin = tL * Math.sin(az);
|
|
4373
|
+
const tm = transform3d().addRotation(0, pi2 - az, 0).addTranslation(posX + tCos, posY, posZ + tSin);
|
|
4374
|
+
const rVol = {
|
|
4375
|
+
outName: `subpax_${designName}_wheel${idx}`,
|
|
4376
|
+
face: `${designName}_faceWheel`,
|
|
4377
|
+
extrudeMethod: EExtrude10.eRotate,
|
|
4378
|
+
rotate: tm.getRotation(),
|
|
4379
|
+
translate: tm.getTranslation()
|
|
4380
|
+
};
|
|
4381
|
+
return rVol;
|
|
4382
|
+
};
|
|
4383
|
+
var calcPercent = calcPercent2, adjustWheelAngle = adjustWheelAngle2, makePFfixExt = makePFfixExt2, makeHandPlate = makeHandPlate2, makeMFoot = makeMFoot2, makeCtrWheel = makeCtrWheel2, makeTopWheel = makeTopWheel2, extrudeTriangle = extrudeTriangle2, extrudePFfixation = extrudePFfixation2, extrudeBones = extrudeBones2, extrudeHandFixation = extrudeHandFixation2, extrudeHandPlate = extrudeHandPlate2, extrudeHandBack = extrudeHandBack2, extrudeMotorBulk = extrudeMotorBulk2, extrudeMFoot = extrudeMFoot2, extrudeWheel = extrudeWheel2;
|
|
4384
|
+
const pi = Math.PI;
|
|
4385
|
+
const pi2 = pi / 2;
|
|
4165
4386
|
const W12 = param.W1 / 2;
|
|
4166
|
-
const
|
|
4167
|
-
|
|
4168
|
-
|
|
4387
|
+
const W22 = param.W2 / 2;
|
|
4388
|
+
const H1b = param.H1 - param.T1;
|
|
4389
|
+
const W22b = W12 - W22;
|
|
4390
|
+
const W2c = param.W2 - 2 * param.T1;
|
|
4391
|
+
const H1c = param.H1 - 2 * param.T1;
|
|
4392
|
+
const Ltotal = param.N1 * (param.L1 + param.T1) + param.T1;
|
|
4393
|
+
const platSurface = Ltotal * param.W1 / 10 ** 6;
|
|
4394
|
+
const R2 = param.D2 / 2;
|
|
4395
|
+
const R1 = param.D1 / 2;
|
|
4396
|
+
const F12 = param.F1 / 2;
|
|
4397
|
+
const LF2 = (param.L1 - param.F1) / 2;
|
|
4398
|
+
const LF2b = LF2 + param.T1 + param.E1;
|
|
4399
|
+
const LF23 = LF2 + 2 * (param.T1 + param.E1);
|
|
4400
|
+
const LF24 = LF23 + param.T1;
|
|
4401
|
+
const F1b = param.F1 - 6 * param.T1 - 4 * param.E1;
|
|
4402
|
+
const LF25 = LF24 + F1b;
|
|
4403
|
+
const LF25b = LF25 + param.T1 + param.E1;
|
|
4404
|
+
const LF28 = LF25 + 2 * (param.T1 + param.E1);
|
|
4405
|
+
const Rwheel = param.Dwheel / 2;
|
|
4406
|
+
const Raxis = param.Daxis / 2;
|
|
4407
|
+
const Rsteering = param.Dsteering / 2;
|
|
4408
|
+
const Z2b = param.Z2 - 4 * R2;
|
|
4409
|
+
const Z2c = param.Z2 - param.T1;
|
|
4410
|
+
const AbMin = degToRad6(param.aBoneMin);
|
|
4411
|
+
const AbMax = degToRad6(param.aBoneMax);
|
|
4412
|
+
const posZplatform = Rwheel + param.Z1 + param.L2 * Math.sin(AbMin);
|
|
4413
|
+
const Hplatform = posZplatform + param.H1;
|
|
4414
|
+
const W32 = param.W3 / 2;
|
|
4415
|
+
if (R2 < W32) {
|
|
4416
|
+
throw `err152: D2 ${ffix14(param.D2)} is too small compare to W3 ${ffix14(param.W3)} mm`;
|
|
4417
|
+
}
|
|
4418
|
+
const W32X = Math.sqrt(R2 ** 2 - W32 ** 2);
|
|
4419
|
+
const L2b = param.L2 - 2 * W32X;
|
|
4420
|
+
const aBR = AbMin + calcPercent2(param.aBoneRight) * (AbMax - AbMin);
|
|
4421
|
+
const aBL = pi - AbMin - calcPercent2(param.aBoneLeft) * (AbMax - AbMin);
|
|
4422
|
+
const boneTopxRs = param.L2 * Math.cos(aBR);
|
|
4423
|
+
const boneTopxLs = param.L2 * Math.cos(aBL);
|
|
4424
|
+
const boneTopxR = 2 * R2 + boneTopxRs;
|
|
4425
|
+
const boneTopxL = 2 * R2 - boneTopxLs;
|
|
4426
|
+
const boneSideyRs = param.L2 * Math.sin(aBR);
|
|
4427
|
+
const boneSideyLs = param.L2 * Math.sin(aBL);
|
|
4428
|
+
const boneSideyR = 2 * R2 * Math.sign(aBR) + boneSideyRs;
|
|
4429
|
+
const ra = degToRad6(param.ra);
|
|
4430
|
+
const rx10 = 10 * param.rx;
|
|
4431
|
+
const ry10 = 10 * param.ry;
|
|
4432
|
+
const hPlen = 2 * F12 + param.E2 + param.T1;
|
|
4433
|
+
const hFposR = W22 + param.E2 + R2 + boneTopxRs - R2;
|
|
4434
|
+
const hFposL = -W22 - param.E2 - R2 + boneTopxLs - R2 - param.E2;
|
|
4435
|
+
const hBposR = W22 + 2 * (param.E2 + R2) + boneTopxRs;
|
|
4436
|
+
const hBposL = -W22 - 2 * (param.E2 + R2) + boneTopxLs;
|
|
4437
|
+
const hPposR = W22 + 2 * (param.E2 + R2) + boneTopxRs + param.T1 + param.E2 + F12;
|
|
4438
|
+
const hPposL = -W22 - 2 * (param.E2 + R2) + boneTopxLs - param.T1 - param.E2 - F12;
|
|
4439
|
+
let wheelRA = new Array(param.N1).fill(ra);
|
|
4440
|
+
let wheelLA = new Array(param.N1).fill(pi + ra);
|
|
4441
|
+
if (param.wheel === 1) {
|
|
4442
|
+
const tWheelRA = [];
|
|
4443
|
+
const tWheelLA = [];
|
|
4444
|
+
const bTxs = param.L2 * Math.cos(AbMin);
|
|
4445
|
+
const XpR = W22 + 2 * (param.E2 + R2) + bTxs + param.T1 + param.E2 + F12;
|
|
4446
|
+
const XpL = -W22 - 2 * (param.E2 + R2) - bTxs - param.T1 - param.E2 - F12;
|
|
4447
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4448
|
+
const Yp = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4449
|
+
tWheelRA.push(adjustWheelAngle2(Yp - ry10, XpR - rx10, 0));
|
|
4450
|
+
tWheelLA.push(adjustWheelAngle2(Yp - ry10, XpL - rx10, pi));
|
|
4451
|
+
}
|
|
4452
|
+
wheelRA = tWheelRA;
|
|
4453
|
+
wheelLA = tWheelLA;
|
|
4454
|
+
}
|
|
4455
|
+
const motorExtraL = param.Lmotor - F12;
|
|
4456
|
+
const motorHeight = param.Z2 - 2 * (param.T1 + param.E1);
|
|
4457
|
+
const motorLen = F12 + param.Lmotor;
|
|
4458
|
+
const mFootWidth = motorExtraL - param.E2;
|
|
4459
|
+
const mFootR = Raxis + param.E1 + param.T1;
|
|
4460
|
+
const mFootHeight = motorHeight + param.E1 + param.T1 + param.Z1 + mFootR;
|
|
4461
|
+
const dWheelAxis = Rwheel - Raxis;
|
|
4462
|
+
const roundedWheel = Math.min(param.Lwheel / 3, dWheelAxis / 2);
|
|
4463
|
+
if (LF2 < 0.1) {
|
|
4464
|
+
throw `err176: L1 ${ffix14(param.L1)} is too small compare to F1 ${ffix14(param.F1)} mm`;
|
|
4465
|
+
}
|
|
4466
|
+
if (param.H1 < param.Z2 + param.T1) {
|
|
4467
|
+
throw `err130: H1 ${ffix14(param.H1)} is too small compare to Z2 ${ffix14(param.Z2)} and T1 ${ffix14(param.T1)} mm`;
|
|
4468
|
+
}
|
|
4469
|
+
if (Z2b < 0.1) {
|
|
4470
|
+
throw `err149: Z2 ${ffix14(param.Z2)} is too small compare to D2 ${ffix14(param.D2)} mm`;
|
|
4471
|
+
}
|
|
4472
|
+
if (W2c < 0.1) {
|
|
4473
|
+
throw `err153: W2 ${ffix14(param.W2)} is too small compare to T1 ${ffix14(param.T1)} mm`;
|
|
4474
|
+
}
|
|
4475
|
+
if (H1c < 0.1) {
|
|
4476
|
+
throw `err156: H1c ${ffix14(param.H1)} is too small compare to T1 ${ffix14(param.T1)} mm`;
|
|
4477
|
+
}
|
|
4478
|
+
if (F1b < 0.1) {
|
|
4479
|
+
throw `err167: F1 ${ffix14(param.F1)} is too small compare to T1 ${ffix14(param.T1)} and E1 ${ffix14(param.E1)} mm`;
|
|
4480
|
+
}
|
|
4481
|
+
if (AbMax < AbMin) {
|
|
4482
|
+
throw `err181: aBoneMax ${ffix14(param.aBoneMax)} is too small compare to aBoneMin ${ffix14(param.BoneMin)} degree`;
|
|
4169
4483
|
}
|
|
4170
|
-
|
|
4484
|
+
if (mFootWidth < param.T1) {
|
|
4485
|
+
throw `err218: Lmotor ${ffix14(param.Lmotor)} is too small compare to F1 ${ffix14(param.F1)}`;
|
|
4486
|
+
}
|
|
4487
|
+
if (motorHeight < param.T1) {
|
|
4488
|
+
throw `err226: Z2 ${ffix14(param.Z2)} is too small compare to T1 ${ffix14(param.T1)} and E1 ${ffix14(param.E1)} mm`;
|
|
4489
|
+
}
|
|
4490
|
+
if (param.Z1 < mFootR) {
|
|
4491
|
+
throw `err256: Z1 ${ffix14(param.Z1)} is too small compare to mFootR ${ffix14(mFootR)} mm`;
|
|
4492
|
+
}
|
|
4493
|
+
if (Rwheel < mFootR) {
|
|
4494
|
+
throw `err259: Dwheel ${ffix14(param.Dwheel)} is too small compare to mFootR ${ffix14(mFootR)} mm`;
|
|
4495
|
+
}
|
|
4496
|
+
rGeome.logstr += `Platform Ltotal ${ffix14(Ltotal / 1e3)} m, surface ${ffix14(platSurface)} m2
|
|
4497
|
+
`;
|
|
4498
|
+
rGeome.logstr += `Hplatform ${ffix14(Hplatform)} mm
|
|
4171
4499
|
`;
|
|
4172
|
-
|
|
4500
|
+
const ctrPlatformMain = contour14(-W22, 0).addSegStrokeR(param.W2, 0).addSegStrokeR(0, H1b).addSegStrokeR(W22b, 0).addSegStrokeR(0, param.T1).addSegStrokeR(-param.W1, 0).addSegStrokeR(0, -param.T1).addSegStrokeR(W22b, 0).closeSegStroke();
|
|
4501
|
+
const ctrPlatformInt = ctrRectangle6(-W22 + param.T1, param.T1, W2c, H1c);
|
|
4502
|
+
figPlatform.addMainOI([ctrPlatformMain, ctrPlatformInt]);
|
|
4503
|
+
const ctrTriangleL = contour14(-W22, 0).addSegStrokeR(param.T1, 0).addSegStrokeR(0, param.H1).addSegStrokeR(-W22b - param.T1, 0).addSegStrokeR(0, -param.T1).closeSegStroke();
|
|
4504
|
+
const ctrTriangleR = contour14(W22, 0).addSegStrokeR(W22b, H1b).addSegStrokeR(0, param.T1).addSegStrokeR(-W22b - param.T1, 0).addSegStrokeR(0, -param.H1).closeSegStroke();
|
|
4505
|
+
figTriangle.addMainO(ctrTriangleL);
|
|
4506
|
+
figTriangle.addMainO(ctrTriangleR);
|
|
4507
|
+
figPlatform.addSecond(ctrTriangleL);
|
|
4508
|
+
figPlatform.addSecond(ctrTriangleR);
|
|
4509
|
+
figPFfixation.addMainOI(makePFfixExt2(1, 0, 0));
|
|
4510
|
+
figPFfixation.addMainOI(makePFfixExt2(-1, 0, 0));
|
|
4511
|
+
figPlatform.mergeFigure(figPFfixation, true);
|
|
4512
|
+
const ctrBone = contour14(W32X, W32).addPointR(-W32X - R2, -W32).addPointR(0, -2 * W32).addSegArc2().addSegStrokeR(L2b, 0).addPointR(W32X + R2, W32).addPointR(0, 2 * W32).addSegArc2().closeSegStroke();
|
|
4513
|
+
const ctrBoneR = ctrBone.rotate(0, 0, aBR);
|
|
4514
|
+
const ctrBoneL = ctrBone.rotate(0, 0, aBL);
|
|
4515
|
+
const ptR1 = point7(W22 + param.E2 + R2, R2);
|
|
4516
|
+
const ptR1b = ptR1.translatePolar(aBR, param.L2);
|
|
4517
|
+
const ptR2 = point7(W22 + param.E2 + R2, Z2b + 3 * R2);
|
|
4518
|
+
const ptR2b = ptR2.translatePolar(aBR, param.L2);
|
|
4519
|
+
const ptL1 = point7(-W22 - param.E2 - R2, R2);
|
|
4520
|
+
const ptL1b = ptL1.translatePolar(aBL, param.L2);
|
|
4521
|
+
const ptL2 = point7(-W22 - param.E2 - R2, Z2b + 3 * R2);
|
|
4522
|
+
const ptL2b = ptL2.translatePolar(aBL, param.L2);
|
|
4523
|
+
figBones.addMainOI([
|
|
4524
|
+
ctrBoneR.translate(ptR1.cx, ptR1.cy),
|
|
4525
|
+
contourCircle11(ptR1.cx, ptR1.cy, R1),
|
|
4526
|
+
contourCircle11(ptR1b.cx, ptR1b.cy, R1)
|
|
4527
|
+
]);
|
|
4528
|
+
figBones.addMainOI([
|
|
4529
|
+
ctrBoneR.translate(ptR2.cx, ptR2.cy),
|
|
4530
|
+
contourCircle11(ptR2.cx, ptR2.cy, R1),
|
|
4531
|
+
contourCircle11(ptR2b.cx, ptR2b.cy, R1)
|
|
4532
|
+
]);
|
|
4533
|
+
figBones.addMainOI([
|
|
4534
|
+
ctrBoneL.translate(ptL1.cx, ptL1.cy),
|
|
4535
|
+
contourCircle11(ptL1.cx, ptL1.cy, R1),
|
|
4536
|
+
contourCircle11(ptL1b.cx, ptL1b.cy, R1)
|
|
4537
|
+
]);
|
|
4538
|
+
figBones.addMainOI([
|
|
4539
|
+
ctrBoneL.translate(ptL2.cx, ptL2.cy),
|
|
4540
|
+
contourCircle11(ptL2.cx, ptL2.cy, R1),
|
|
4541
|
+
contourCircle11(ptL2b.cx, ptL2b.cy, R1)
|
|
4542
|
+
]);
|
|
4543
|
+
figPlatform.mergeFigure(figBones, true);
|
|
4544
|
+
figHandFixation.addMainOI(makePFfixExt2(-1, aBR, param.L2));
|
|
4545
|
+
figHandFixation.addMainOI(makePFfixExt2(1, aBL, param.L2));
|
|
4546
|
+
figPlatform.mergeFigure(figHandFixation, true);
|
|
4547
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4548
|
+
const tPosY = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4549
|
+
figHandPlateR.addMainOI(makeHandPlate2(pi, param.T1 + param.E2, hPposR, tPosY));
|
|
4550
|
+
figHandPlateL.addMainOI(makeHandPlate2(0, param.T1 + param.E2, hPposL, tPosY));
|
|
4551
|
+
}
|
|
4552
|
+
figPlatform.addSecond(ctrRectangle6(hBposR, boneSideyRs, hPlen, param.T1));
|
|
4553
|
+
figPlatform.addSecond(ctrRectangle6(hBposR, boneSideyRs + Z2c, hPlen, param.T1));
|
|
4554
|
+
figPlatform.addSecond(ctrRectangle6(hBposL - hPlen, boneSideyLs, hPlen, param.T1));
|
|
4555
|
+
figPlatform.addSecond(ctrRectangle6(hBposL - hPlen, boneSideyLs + Z2c, hPlen, param.T1));
|
|
4556
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4557
|
+
const tPosY = ii * (param.L1 + param.T1) + param.T1 + LF2;
|
|
4558
|
+
figHandBackR.addMainO(ctrRectangle6(hBposR, tPosY, param.T1, 2 * F12));
|
|
4559
|
+
figHandBackL.addMainO(ctrRectangle6(hBposL - param.T1, tPosY, param.T1, 2 * F12));
|
|
4560
|
+
}
|
|
4561
|
+
figPlatform.addSecond(ctrRectangle6(hBposR, boneSideyRs, param.T1, param.Z2));
|
|
4562
|
+
figPlatform.addSecond(ctrRectangle6(hBposL - param.T1, boneSideyLs, param.T1, param.Z2));
|
|
4563
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4564
|
+
const tPosY = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4565
|
+
figMotorBulkR.addMainOI(makeHandPlate2(wheelRA[ii], motorExtraL, hPposR, tPosY));
|
|
4566
|
+
figMotorBulkL.addMainOI(makeHandPlate2(wheelLA[ii], motorExtraL, hPposL, tPosY));
|
|
4567
|
+
}
|
|
4568
|
+
const mBRpX = hBposR + param.T1 + param.E2;
|
|
4569
|
+
const mBRpY = boneSideyRs + param.T1 + param.E1;
|
|
4570
|
+
const mBLpX = hBposL - param.T1 - param.E2 - motorLen;
|
|
4571
|
+
const mBLpY = boneSideyLs + param.T1 + param.E1;
|
|
4572
|
+
figPlatform.addSecond(ctrRectangle6(mBRpX, mBRpY, motorLen, motorHeight));
|
|
4573
|
+
figPlatform.addSecond(ctrRectangle6(mBLpX, mBLpY, motorLen, motorHeight));
|
|
4574
|
+
const mFRpX = mBRpX + F12 + param.Lmotor - mFootWidth;
|
|
4575
|
+
const mFRpY = boneSideyRs - param.Z1 - mFootR;
|
|
4576
|
+
const mFLpX = mBLpX;
|
|
4577
|
+
const mFLpY = boneSideyLs - param.Z1 - mFootR;
|
|
4578
|
+
figPlatform.addSecond(ctrRectangle6(mFRpX, mFRpY, mFootWidth, mFootHeight));
|
|
4579
|
+
figPlatform.addSecond(ctrRectangle6(mFLpX, mFLpY, mFootWidth, mFootHeight));
|
|
4580
|
+
figMFoot.addMainOI(makeMFoot2(0, 0));
|
|
4581
|
+
figWheel.addMainO(makeCtrWheel2(1, 0, 0, 0));
|
|
4582
|
+
figWheel.addSecond(makeCtrWheel2(-1, 0, 0, 0));
|
|
4583
|
+
figPlatform.addSecond(makeCtrWheel2(1, -pi2, mFRpX, mFRpY + mFootR));
|
|
4584
|
+
figPlatform.addSecond(makeCtrWheel2(-1, -pi2, mFRpX, mFRpY + mFootR));
|
|
4585
|
+
figPlatform.addSecond(makeCtrWheel2(1, pi2, mFLpX + mFootWidth, mFLpY + mFootR));
|
|
4586
|
+
figPlatform.addSecond(makeCtrWheel2(-1, pi2, mFLpX + mFootWidth, mFLpY + mFootR));
|
|
4587
|
+
figTop.addMainOI([
|
|
4588
|
+
ctrRectangle6(-W12, 0, param.W1, Ltotal),
|
|
4589
|
+
ctrRectangle6(-W22 + param.T1, 0, W2c, Ltotal)
|
|
4590
|
+
]);
|
|
4591
|
+
figTop.addSecond(ctrRectangle6(-W22, 0, param.W2, Ltotal));
|
|
4592
|
+
if (param.triangleExt) {
|
|
4593
|
+
for (let ii = 0; ii < 2; ii++) {
|
|
4594
|
+
const tPosY = ii * (param.L1 + param.T1) * param.N1;
|
|
4595
|
+
figTop.addSecond(ctrRectangle6(-W12, tPosY, W22b, param.T1));
|
|
4596
|
+
figTop.addSecond(ctrRectangle6(W22, tPosY, W22b, param.T1));
|
|
4597
|
+
}
|
|
4598
|
+
}
|
|
4599
|
+
if (param.triangleInt) {
|
|
4600
|
+
for (let ii = 1; ii < param.N1; ii++) {
|
|
4601
|
+
const tPosY = ii * (param.L1 + param.T1);
|
|
4602
|
+
figTop.addSecond(ctrRectangle6(-W12, tPosY, W22b, param.T1));
|
|
4603
|
+
figTop.addSecond(ctrRectangle6(W22, tPosY, W22b, param.T1));
|
|
4604
|
+
}
|
|
4605
|
+
}
|
|
4606
|
+
const tL2 = param.E2 + 2 * R2;
|
|
4607
|
+
const tPosX2 = -W22 - tL2;
|
|
4608
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4609
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4610
|
+
for (const tPosY2 of [LF2, LF23, LF25, LF28]) {
|
|
4611
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4612
|
+
figTop.addSecond(ctrRectangle6(W22, tPosY3, tL2, param.T1));
|
|
4613
|
+
figTop.addSecond(ctrRectangle6(tPosX2, tPosY3, tL2, param.T1));
|
|
4614
|
+
}
|
|
4615
|
+
}
|
|
4616
|
+
const tPosX3 = -W22 - param.E2 - boneTopxL;
|
|
4617
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4618
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4619
|
+
for (const tPosY2 of [LF2, LF25]) {
|
|
4620
|
+
const tPosY3 = tPosY + tPosY2 + param.T1 + param.E1;
|
|
4621
|
+
figTop.addSecond(ctrRectangle6(W22 + param.E2, tPosY3, boneTopxR, param.T1));
|
|
4622
|
+
figTop.addSecond(ctrRectangle6(tPosX3, tPosY3, boneTopxL, param.T1));
|
|
4623
|
+
}
|
|
4624
|
+
}
|
|
4625
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4626
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4627
|
+
for (const tPosY2 of [LF2, LF23, LF25, LF28]) {
|
|
4628
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4629
|
+
figTop.addSecond(ctrRectangle6(hFposR, tPosY3, tL2, param.T1));
|
|
4630
|
+
figTop.addSecond(ctrRectangle6(hFposL, tPosY3, tL2, param.T1));
|
|
4631
|
+
}
|
|
4632
|
+
}
|
|
4633
|
+
figTop.mergeFigure(figHandPlateR, true);
|
|
4634
|
+
figTop.mergeFigure(figHandPlateL, true);
|
|
4635
|
+
figTop.mergeFigure(figHandBackR, true);
|
|
4636
|
+
figTop.mergeFigure(figHandBackL, true);
|
|
4637
|
+
figTop.mergeFigure(figMotorBulkR, true);
|
|
4638
|
+
figTop.mergeFigure(figMotorBulkL, true);
|
|
4639
|
+
figTop.addPoint(point7(rx10, ry10, ShapePoint2.eBigSquare));
|
|
4640
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4641
|
+
const tPosY = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4642
|
+
for (const iCtr of makeTopWheel2(hPposR, tPosY, wheelRA[ii])) {
|
|
4643
|
+
figTop.addSecond(iCtr);
|
|
4644
|
+
}
|
|
4645
|
+
for (const iCtr of makeTopWheel2(hPposL, tPosY, wheelLA[ii])) {
|
|
4646
|
+
figTop.addSecond(iCtr);
|
|
4647
|
+
}
|
|
4648
|
+
}
|
|
4649
|
+
figSide.addMainO(ctrRectangle6(0, 0, Ltotal, param.H1));
|
|
4650
|
+
figSide.addSecond(ctrRectangle6(0, H1b, Ltotal, param.T1));
|
|
4651
|
+
if (param.triangleExt) {
|
|
4652
|
+
for (let ii = 0; ii < 2; ii++) {
|
|
4653
|
+
const tPosY = ii * (param.L1 + param.T1) * param.N1;
|
|
4654
|
+
figSide.addSecond(ctrRectangle6(tPosY, 0, param.T1, H1b));
|
|
4655
|
+
}
|
|
4656
|
+
}
|
|
4657
|
+
if (param.triangleInt) {
|
|
4658
|
+
for (let ii = 1; ii < param.N1; ii++) {
|
|
4659
|
+
const tPosY = ii * (param.L1 + param.T1);
|
|
4660
|
+
figSide.addSecond(ctrRectangle6(tPosY, 0, param.T1, H1b));
|
|
4661
|
+
}
|
|
4662
|
+
}
|
|
4663
|
+
const tH2 = 2 * R2;
|
|
4664
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4665
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4666
|
+
for (const tPosY2 of [LF2, LF23, LF25, LF28]) {
|
|
4667
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4668
|
+
figSide.addSecond(ctrRectangle6(tPosY3, 0, param.T1, tH2));
|
|
4669
|
+
figSide.addSecond(ctrRectangle6(tPosY3, tH2 + Z2b, param.T1, tH2));
|
|
4670
|
+
}
|
|
4671
|
+
}
|
|
4672
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4673
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4674
|
+
for (const tPosY2 of [LF2, LF25]) {
|
|
4675
|
+
const tPosY3 = tPosY + tPosY2 + param.T1 + param.E1;
|
|
4676
|
+
if (boneSideyR > 0) {
|
|
4677
|
+
figSide.addSecond(ctrRectangle6(tPosY3, 0, param.T1, boneSideyR));
|
|
4678
|
+
figSide.addSecond(ctrRectangle6(tPosY3, 2 * R2 + Z2b, param.T1, boneSideyR));
|
|
4679
|
+
} else {
|
|
4680
|
+
const tLy = -boneSideyR;
|
|
4681
|
+
figSide.addSecond(ctrRectangle6(tPosY3, 2 * R2 - tLy, param.T1, tLy));
|
|
4682
|
+
figSide.addSecond(ctrRectangle6(tPosY3, 4 * R2 + Z2b - tLy, param.T1, tLy));
|
|
4683
|
+
}
|
|
4684
|
+
}
|
|
4685
|
+
}
|
|
4686
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4687
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4688
|
+
for (const tPosY2 of [LF2, LF23, LF25, LF28]) {
|
|
4689
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4690
|
+
figSide.addSecond(ctrRectangle6(tPosY3, boneSideyRs, param.T1, tH2));
|
|
4691
|
+
figSide.addSecond(ctrRectangle6(tPosY3, boneSideyRs + tH2 + Z2b, param.T1, tH2));
|
|
4692
|
+
}
|
|
4693
|
+
}
|
|
4694
|
+
const ZhpR = [boneSideyRs, boneSideyRs + Z2c];
|
|
4695
|
+
const ZhpL = [boneSideyLs, boneSideyLs + Z2c];
|
|
4696
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4697
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4698
|
+
const tPosY3 = tPosY + LF2;
|
|
4699
|
+
figSide.addSecond(ctrRectangle6(tPosY3, ZhpR[0], param.F1, param.T1));
|
|
4700
|
+
figSide.addSecond(ctrRectangle6(tPosY3, ZhpR[1], param.F1, param.T1));
|
|
4701
|
+
figSide.addSecond(ctrRectangle6(tPosY3, ZhpR[0], param.F1, param.Z2));
|
|
4702
|
+
figSide.addSecond(ctrRectangle6(tPosY3, mBRpY, param.F1, motorHeight));
|
|
4703
|
+
const axisX = tPosY + param.L1 / 2;
|
|
4704
|
+
const axisY = ZhpR[0] - param.Z1;
|
|
4705
|
+
for (const iCtr of makeMFoot2(axisX, axisY)) {
|
|
4706
|
+
figSide.addSecond(iCtr);
|
|
4707
|
+
}
|
|
4708
|
+
figSide.addSecond(contourCircle11(axisX, axisY, Raxis));
|
|
4709
|
+
figSide.addSecond(contourCircle11(axisX, axisY, Rwheel));
|
|
4710
|
+
}
|
|
4173
4711
|
rGeome.fig = {
|
|
4174
|
-
facePlatform: figPlatform
|
|
4712
|
+
facePlatform: figPlatform,
|
|
4713
|
+
faceTop: figTop,
|
|
4714
|
+
faceSide: figSide,
|
|
4715
|
+
faceTriangle: figTriangle,
|
|
4716
|
+
facePFfixation: figPFfixation,
|
|
4717
|
+
faceBones: figBones,
|
|
4718
|
+
faceHandFixation: figHandFixation,
|
|
4719
|
+
faceHandPlateR: figHandPlateR,
|
|
4720
|
+
faceHandPlateL: figHandPlateL,
|
|
4721
|
+
faceHandBackR: figHandBackR,
|
|
4722
|
+
faceHandBackL: figHandBackL,
|
|
4723
|
+
faceMotorBulkR: figMotorBulkR,
|
|
4724
|
+
faceMotorBulkL: figMotorBulkL,
|
|
4725
|
+
faceMFoot: figMFoot,
|
|
4726
|
+
faceWheel: figWheel
|
|
4175
4727
|
};
|
|
4176
4728
|
const designName = rGeome.partName;
|
|
4729
|
+
const list3D = [];
|
|
4730
|
+
const listPlatform = [];
|
|
4731
|
+
const volPlatformMain = {
|
|
4732
|
+
outName: `subpax_${designName}_platformMain`,
|
|
4733
|
+
face: `${designName}_facePlatform`,
|
|
4734
|
+
extrudeMethod: EExtrude10.eLinearOrtho,
|
|
4735
|
+
length: Ltotal,
|
|
4736
|
+
rotate: [0, 0, 0],
|
|
4737
|
+
translate: [0, 0, 0]
|
|
4738
|
+
};
|
|
4739
|
+
const volTriangle = [];
|
|
4740
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4741
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4742
|
+
for (const [jj, tPosY2] of [LF2, LF23, LF25, LF28].entries()) {
|
|
4743
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4744
|
+
const idx = 4 * ii + jj;
|
|
4745
|
+
volTriangle.push(extrudePFfixation2(tPosY3, idx));
|
|
4746
|
+
listPlatform.push(`subpax_${designName}_PFfixation${idx}`);
|
|
4747
|
+
}
|
|
4748
|
+
}
|
|
4749
|
+
listPlatform.push(`subpax_${designName}_platformMain`);
|
|
4750
|
+
if (param.triangleExt) {
|
|
4751
|
+
volTriangle.push(extrudeTriangle2(0, 0));
|
|
4752
|
+
volTriangle.push(extrudeTriangle2(Ltotal - param.T1, param.N1 + 1));
|
|
4753
|
+
listPlatform.push(`subpax_${designName}_platformTriangle${0}`);
|
|
4754
|
+
listPlatform.push(`subpax_${designName}_platformTriangle${param.N1 + 1}`);
|
|
4755
|
+
}
|
|
4756
|
+
if (param.triangleInt) {
|
|
4757
|
+
for (let ii = 1; ii < param.N1; ii++) {
|
|
4758
|
+
volTriangle.push(extrudeTriangle2(ii * (param.T1 + param.L1), ii + 1));
|
|
4759
|
+
listPlatform.push(`subpax_${designName}_platformTriangle${ii + 1}`);
|
|
4760
|
+
}
|
|
4761
|
+
}
|
|
4762
|
+
const listBones = [];
|
|
4763
|
+
const volBones = [];
|
|
4764
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4765
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4766
|
+
for (const [jj, tPosY2] of [LF2b, LF25b].entries()) {
|
|
4767
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4768
|
+
const idx = 2 * ii + jj;
|
|
4769
|
+
volBones.push(extrudeBones2(tPosY3, idx));
|
|
4770
|
+
listBones.push(`subpax_${designName}_bones${idx}`);
|
|
4771
|
+
}
|
|
4772
|
+
}
|
|
4773
|
+
const listHands = [];
|
|
4774
|
+
const volHands = [];
|
|
4775
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4776
|
+
const tPosY = param.T1 + ii * (param.L1 + param.T1);
|
|
4777
|
+
for (const [jj, tPosY2] of [LF2, LF23, LF25, LF28].entries()) {
|
|
4778
|
+
const tPosY3 = tPosY + tPosY2;
|
|
4779
|
+
const idx = 4 * ii + jj;
|
|
4780
|
+
volHands.push(extrudeHandFixation2(tPosY3, idx));
|
|
4781
|
+
listHands.push(`subpax_${designName}_handFixation${idx}`);
|
|
4782
|
+
}
|
|
4783
|
+
}
|
|
4784
|
+
volHands.push(extrudeHandPlate2(ZhpR[0], "R", 1));
|
|
4785
|
+
volHands.push(extrudeHandPlate2(ZhpR[1], "R", 2));
|
|
4786
|
+
volHands.push(extrudeHandPlate2(ZhpL[0], "L", 1));
|
|
4787
|
+
volHands.push(extrudeHandPlate2(ZhpL[1], "L", 2));
|
|
4788
|
+
listHands.push(`subpax_${designName}_handPlateR1`);
|
|
4789
|
+
listHands.push(`subpax_${designName}_handPlateR2`);
|
|
4790
|
+
listHands.push(`subpax_${designName}_handPlateL1`);
|
|
4791
|
+
listHands.push(`subpax_${designName}_handPlateL2`);
|
|
4792
|
+
volHands.push(extrudeHandBack2(ZhpR[1], "R"));
|
|
4793
|
+
volHands.push(extrudeHandBack2(ZhpL[1], "L"));
|
|
4794
|
+
listHands.push(`subpax_${designName}_handBackR`);
|
|
4795
|
+
listHands.push(`subpax_${designName}_handBackL`);
|
|
4796
|
+
const listMotors = [];
|
|
4797
|
+
const volMotors = [];
|
|
4798
|
+
volMotors.push(extrudeMotorBulk2(ZhpR[1], "R"));
|
|
4799
|
+
volMotors.push(extrudeMotorBulk2(ZhpL[1], "L"));
|
|
4800
|
+
listMotors.push(`subpax_${designName}_motorBulkR`);
|
|
4801
|
+
listMotors.push(`subpax_${designName}_motorBulkL`);
|
|
4802
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4803
|
+
const idx0 = (2 * ii).toString().padStart(2, "0");
|
|
4804
|
+
const idx1 = (2 * ii + 1).toString().padStart(2, "0");
|
|
4805
|
+
const tPosZ = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4806
|
+
volMotors.push(extrudeMFoot2(hPposR, ZhpR[0] - param.Z1, tPosZ, wheelRA[ii], idx0));
|
|
4807
|
+
listMotors.push(`subpax_${designName}_mFoot${idx0}`);
|
|
4808
|
+
volMotors.push(extrudeMFoot2(hPposL, ZhpL[0] - param.Z1, tPosZ, wheelLA[ii], idx1));
|
|
4809
|
+
listMotors.push(`subpax_${designName}_mFoot${idx1}`);
|
|
4810
|
+
}
|
|
4811
|
+
const listWheels = [];
|
|
4812
|
+
const volWheels = [];
|
|
4813
|
+
for (let ii = 0; ii < param.N1; ii++) {
|
|
4814
|
+
const idx0 = (2 * ii).toString().padStart(2, "0");
|
|
4815
|
+
const idx1 = (2 * ii + 1).toString().padStart(2, "0");
|
|
4816
|
+
const tPosZ = ii * (param.L1 + param.T1) + param.T1 + param.L1 / 2;
|
|
4817
|
+
volWheels.push(extrudeWheel2(hPposR, ZhpR[0] - param.Z1, tPosZ, wheelRA[ii], idx0));
|
|
4818
|
+
listWheels.push(`subpax_${designName}_wheel${idx0}`);
|
|
4819
|
+
volWheels.push(extrudeWheel2(hPposL, ZhpL[0] - param.Z1, tPosZ, wheelLA[ii], idx1));
|
|
4820
|
+
listWheels.push(`subpax_${designName}_wheel${idx1}`);
|
|
4821
|
+
}
|
|
4822
|
+
if (param.gen3D === 0 || param.gen3D === 1) {
|
|
4823
|
+
list3D.push(...listPlatform);
|
|
4824
|
+
}
|
|
4825
|
+
if (param.gen3D === 0 || param.gen3D === 2) {
|
|
4826
|
+
list3D.push(...listBones);
|
|
4827
|
+
}
|
|
4828
|
+
if (param.gen3D === 0 || param.gen3D === 3) {
|
|
4829
|
+
list3D.push(...listHands);
|
|
4830
|
+
}
|
|
4831
|
+
if (param.gen3D === 0 || param.gen3D === 4) {
|
|
4832
|
+
list3D.push(...listMotors);
|
|
4833
|
+
}
|
|
4834
|
+
if (param.gen3D === 0 || param.gen3D === 5) {
|
|
4835
|
+
list3D.push(...listWheels);
|
|
4836
|
+
}
|
|
4177
4837
|
rGeome.vol = {
|
|
4178
4838
|
extrudes: [
|
|
4179
|
-
|
|
4180
|
-
|
|
4181
|
-
|
|
4182
|
-
|
|
4183
|
-
|
|
4184
|
-
|
|
4185
|
-
translate: [0, 0, 0]
|
|
4186
|
-
}
|
|
4839
|
+
volPlatformMain,
|
|
4840
|
+
...volTriangle,
|
|
4841
|
+
...volBones,
|
|
4842
|
+
...volHands,
|
|
4843
|
+
...volMotors,
|
|
4844
|
+
...volWheels
|
|
4187
4845
|
],
|
|
4188
4846
|
volumes: [
|
|
4189
4847
|
{
|
|
4190
4848
|
outName: `pax_${designName}`,
|
|
4191
4849
|
boolMethod: EBVolume10.eUnion,
|
|
4192
|
-
inList:
|
|
4850
|
+
inList: list3D
|
|
4193
4851
|
}
|
|
4194
4852
|
]
|
|
4195
4853
|
};
|
|
@@ -4211,10 +4869,15 @@ var rccarDef = {
|
|
|
4211
4869
|
|
|
4212
4870
|
// src/capsule/capsule.ts
|
|
4213
4871
|
import {
|
|
4872
|
+
point as point8,
|
|
4873
|
+
contour as contour15,
|
|
4874
|
+
contourCircle as contourCircle12,
|
|
4214
4875
|
ctrRectangle as ctrRectangle7,
|
|
4215
4876
|
figure as figure12,
|
|
4216
4877
|
ffix as ffix15,
|
|
4217
4878
|
pNumber as pNumber14,
|
|
4879
|
+
pCheckbox as pCheckbox9,
|
|
4880
|
+
pDropdown as pDropdown8,
|
|
4218
4881
|
pSectionSeparator as pSectionSeparator14,
|
|
4219
4882
|
EExtrude as EExtrude11,
|
|
4220
4883
|
EBVolume as EBVolume11,
|
|
@@ -4224,15 +4887,106 @@ var pDef14 = {
|
|
|
4224
4887
|
partName: "capsule",
|
|
4225
4888
|
params: [
|
|
4226
4889
|
//pNumber(name, unit, init, min, max, step)
|
|
4227
|
-
pNumber14("
|
|
4228
|
-
pNumber14("
|
|
4229
|
-
|
|
4230
|
-
|
|
4890
|
+
pNumber14("L1", "mm", 5e3, 1e3, 2e4, 1),
|
|
4891
|
+
pNumber14("WW1", "mm", 1800, 100, 4e3, 1),
|
|
4892
|
+
pNumber14("E1", "mm", 10, 1, 100, 1),
|
|
4893
|
+
pSectionSeparator14("Nose"),
|
|
4894
|
+
pNumber14("H1", "mm", 300, 10, 4e3, 1),
|
|
4895
|
+
pNumber14("H2", "mm", 500, 10, 4e3, 1),
|
|
4896
|
+
pNumber14("H3", "mm", 1200, 10, 4e3, 1),
|
|
4897
|
+
pNumber14("W1", "mm", 300, 10, 4e3, 1),
|
|
4898
|
+
pNumber14("W3", "mm", 1500, 10, 4e3, 1),
|
|
4899
|
+
pNumber14("C3", "mm", 200, 1, 1e3, 1),
|
|
4900
|
+
pNumber14("R1", "mm", 100, 0, 500, 1),
|
|
4901
|
+
pNumber14("R2", "mm", 100, 0, 500, 1),
|
|
4902
|
+
pNumber14("R3", "mm", 100, 0, 500, 1),
|
|
4903
|
+
pNumber14("R4", "mm", 100, 0, 500, 1),
|
|
4904
|
+
pSectionSeparator14("Wheels"),
|
|
4905
|
+
pNumber14("H0", "mm", 600, 100, 2e3, 1),
|
|
4906
|
+
pNumber14("D7", "mm", 500, 10, 2e3, 1),
|
|
4907
|
+
pNumber14("D8", "mm", 100, 10, 2e3, 1),
|
|
4908
|
+
pNumber14("WW2", "mm", 1e3, 100, 4e3, 1),
|
|
4909
|
+
pNumber14("WW3", "mm", 100, 1, 500, 1),
|
|
4910
|
+
pSectionSeparator14("Wheels details"),
|
|
4911
|
+
pNumber14("W6", "mm", 500, 10, 2e3, 1),
|
|
4912
|
+
pNumber14("W7", "mm", 600, 10, 2e3, 1),
|
|
4913
|
+
pNumber14("W8", "mm", 300, 10, 2e3, 1),
|
|
4914
|
+
pNumber14("H6", "mm", 300, 10, 2e3, 1),
|
|
4915
|
+
pSectionSeparator14("Front window"),
|
|
4916
|
+
pNumber14("FH1", "mm", 600, 10, 3e3, 1),
|
|
4917
|
+
pNumber14("FW1", "mm", 100, 10, 3e3, 1),
|
|
4918
|
+
pNumber14("FR1", "mm", 100, 0, 500, 1),
|
|
4919
|
+
pNumber14("FH3", "mm", 100, 10, 3e3, 1),
|
|
4920
|
+
pNumber14("FW3", "mm", 300, 10, 3e3, 1),
|
|
4921
|
+
pNumber14("FR3", "mm", 100, 0, 500, 1),
|
|
4922
|
+
pSectionSeparator14("Top"),
|
|
4923
|
+
pDropdown8("topStyle", ["mirador", "sky", "roof"]),
|
|
4924
|
+
pNumber14("H5", "mm", 300, 10, 2e3, 1),
|
|
4925
|
+
pNumber14("W4", "mm", 500, 10, 5e3, 1),
|
|
4926
|
+
pNumber14("W5", "mm", 1e3, 10, 5e3, 1),
|
|
4927
|
+
pNumber14("R5", "mm", 50, 1, 500, 1),
|
|
4928
|
+
pNumber14("S5", "mm", 200, 10, 500, 1),
|
|
4929
|
+
pSectionSeparator14("Wall"),
|
|
4930
|
+
pCheckbox9("sideWall", true),
|
|
4931
|
+
pNumber14("U1", "mm", 100, 10, 1e3, 1),
|
|
4932
|
+
pNumber14("U2", "mm", 500, 10, 3e3, 1),
|
|
4933
|
+
pNumber14("U3", "mm", 400, 10, 3e3, 1),
|
|
4934
|
+
pNumber14("V1", "mm", 600, 10, 3e3, 1),
|
|
4935
|
+
pNumber14("V2", "mm", 400, 10, 3e3, 1),
|
|
4936
|
+
pNumber14("JR1", "mm", 100, 0, 2e3, 1),
|
|
4937
|
+
pNumber14("JR2", "mm", 100, 0, 2e3, 1),
|
|
4938
|
+
pNumber14("JR3", "mm", 100, 0, 2e3, 1),
|
|
4939
|
+
pNumber14("JR4", "mm", 100, 0, 2e3, 1),
|
|
4940
|
+
pNumber14("JR5", "mm", 100, 0, 2e3, 1),
|
|
4941
|
+
pNumber14("JR6", "mm", 100, 0, 2e3, 1)
|
|
4231
4942
|
],
|
|
4232
4943
|
paramSvg: {
|
|
4233
|
-
W1: "capsule_side.svg",
|
|
4234
4944
|
L1: "capsule_side.svg",
|
|
4235
|
-
|
|
4945
|
+
WW1: "capsule_top.svg",
|
|
4946
|
+
E1: "capsule_nose.svg",
|
|
4947
|
+
H1: "capsule_nose.svg",
|
|
4948
|
+
H2: "capsule_nose.svg",
|
|
4949
|
+
H3: "capsule_nose.svg",
|
|
4950
|
+
W1: "capsule_nose.svg",
|
|
4951
|
+
W3: "capsule_nose.svg",
|
|
4952
|
+
C3: "capsule_nose.svg",
|
|
4953
|
+
R1: "capsule_nose.svg",
|
|
4954
|
+
R2: "capsule_nose.svg",
|
|
4955
|
+
R3: "capsule_nose.svg",
|
|
4956
|
+
R4: "capsule_nose.svg",
|
|
4957
|
+
H0: "capsule_side.svg",
|
|
4958
|
+
D7: "capsule_side.svg",
|
|
4959
|
+
D8: "capsule_side.svg",
|
|
4960
|
+
WW2: "capsule_wheels.svg",
|
|
4961
|
+
WW3: "capsule_wheels.svg",
|
|
4962
|
+
W6: "capsule_side.svg",
|
|
4963
|
+
W7: "capsule_side.svg",
|
|
4964
|
+
W8: "capsule_side.svg",
|
|
4965
|
+
H6: "capsule_side.svg",
|
|
4966
|
+
FH1: "capsule_wheels.svg",
|
|
4967
|
+
FW1: "capsule_wheels.svg",
|
|
4968
|
+
FR1: "capsule_wheels.svg",
|
|
4969
|
+
FH3: "capsule_wheels.svg",
|
|
4970
|
+
FW3: "capsule_wheels.svg",
|
|
4971
|
+
FR3: "capsule_wheels.svg",
|
|
4972
|
+
topStyle: "capsule_side.svg",
|
|
4973
|
+
H5: "capsule_nose.svg",
|
|
4974
|
+
W4: "capsule_nose.svg",
|
|
4975
|
+
W5: "capsule_top.svg",
|
|
4976
|
+
R5: "capsule_top.svg",
|
|
4977
|
+
S5: "capsule_top.svg",
|
|
4978
|
+
sideWall: "capsule_side.svg",
|
|
4979
|
+
U1: "capsule_wall.svg",
|
|
4980
|
+
U2: "capsule_wall.svg",
|
|
4981
|
+
U3: "capsule_wall.svg",
|
|
4982
|
+
V1: "capsule_wall.svg",
|
|
4983
|
+
V2: "capsule_wall.svg",
|
|
4984
|
+
JR1: "capsule_wall.svg",
|
|
4985
|
+
JR2: "capsule_wall.svg",
|
|
4986
|
+
JR3: "capsule_wall.svg",
|
|
4987
|
+
JR4: "capsule_wall.svg",
|
|
4988
|
+
JR5: "capsule_wall.svg",
|
|
4989
|
+
JR6: "capsule_wall.svg"
|
|
4236
4990
|
},
|
|
4237
4991
|
sim: {
|
|
4238
4992
|
tMax: 180,
|
|
@@ -4243,38 +4997,330 @@ var pDef14 = {
|
|
|
4243
4997
|
};
|
|
4244
4998
|
function pGeom14(t, param, suffix = "") {
|
|
4245
4999
|
const rGeome = initGeom14(pDef14.partName + suffix);
|
|
4246
|
-
const
|
|
5000
|
+
const figBody = figure12();
|
|
5001
|
+
const figWheels = figure12();
|
|
5002
|
+
const figFront = figure12();
|
|
5003
|
+
const figTop = figure12();
|
|
5004
|
+
const figTopInt = figure12();
|
|
5005
|
+
const figTopTop = figure12();
|
|
5006
|
+
const figTopLeg = figure12();
|
|
5007
|
+
const figWall = figure12();
|
|
4247
5008
|
rGeome.logstr += `${rGeome.partName} simTime: ${t}
|
|
4248
5009
|
`;
|
|
4249
5010
|
try {
|
|
4250
|
-
|
|
4251
|
-
|
|
4252
|
-
|
|
4253
|
-
|
|
4254
|
-
|
|
4255
|
-
|
|
5011
|
+
let ctrBody2 = function(withBat) {
|
|
5012
|
+
const rCtr = contour15(-L12, param.H0);
|
|
5013
|
+
if (withBat) {
|
|
5014
|
+
rCtr.addSegStrokeR(Wwheels, 0).addSegStrokeR(0, -Hbatterie).addSegStrokeR(Lbatterie, 0).addSegStrokeR(0, Hbatterie).addSegStrokeR(Wwheels, 0);
|
|
5015
|
+
} else {
|
|
5016
|
+
rCtr.addSegStrokeR(param.L1, 0);
|
|
5017
|
+
}
|
|
5018
|
+
rCtr.addCornerRounded(param.R1).addSegStrokeR(param.W1, param.H1).addCornerRounded(param.R2).addSegStrokeR(0, param.H2).addCornerRounded(param.R3).addPointR(p1.cx, p1.cy).addPointR(-param.W3, param.H3).addSegArc2().addCornerRounded(param.R4).addSegStrokeR(-Lroof, 0).addCornerRounded(param.R4).addPointR(p2.cx, p2.cy).addPointR(-param.W3, -param.H3).addSegArc2().addCornerRounded(param.R3).addSegStrokeR(0, -param.H2).addCornerRounded(param.R2).closeSegStroke().addCornerRounded(param.R1);
|
|
5019
|
+
return rCtr;
|
|
5020
|
+
}, ctrWheels2 = function(sign) {
|
|
5021
|
+
const rCtr = contour15(0, posYwheels).addSegStrokeR(sign * R7, 0).addSegStrokeR(0, param.WW3).addSegStrokeR(sign * (R8 - R7), 0).addSegStrokeR(0, 2 * WW22).addSegStrokeR(-sign * (R8 - R7), 0).addSegStrokeR(0, param.WW3).addSegStrokeR(-sign * R7, 0).closeSegStroke();
|
|
5022
|
+
return rCtr;
|
|
5023
|
+
}, makeCtrTop2 = function(radius) {
|
|
5024
|
+
const rCtr = contour15(-L52 + topR - radius, -R52).addPointR(radius, -radius).addSegArc(radius, false, true).addSegStrokeR(L53, 0).addPointR(radius, radius).addSegArc(radius, false, true).addSegStrokeR(0, R53).addPointR(-radius, radius).addSegArc(radius, false, true).addSegStrokeR(-L53, 0).addPointR(-radius, -radius).addSegArc(radius, false, true).closeSegStroke();
|
|
5025
|
+
return rCtr;
|
|
5026
|
+
}, ctrSideWindow2 = function(sign) {
|
|
5027
|
+
const p0x = sign * (Ltotal / 2 - param.U1);
|
|
5028
|
+
const p0y = param.H0 + param.H1 + param.H2 - UH2dy;
|
|
5029
|
+
const rCtr = contour15(p0x, p0y).addCornerRounded(param.JR1).addPointR(sign * p1ub.cx, p1ub.cy).addPointR(-sign * UW3b, UH3b).addSegArc2().addCornerRounded(param.JR4).addSegStrokeR(-sign * param.U2, 0).addCornerRounded(param.JR3).addSegStrokeR(0, -UH3b).addCornerRounded(param.JR2).closeSegStroke();
|
|
5030
|
+
return rCtr;
|
|
5031
|
+
}, volWheel2 = function(posX, idx) {
|
|
5032
|
+
return {
|
|
5033
|
+
outName: `subpax_${designName}_wheel${idx}`,
|
|
5034
|
+
face: `${designName}_faceWheels`,
|
|
5035
|
+
extrudeMethod: EExtrude11.eRotate,
|
|
5036
|
+
rotate: [0, 0, 0],
|
|
5037
|
+
translate: [posX, R7, 0]
|
|
5038
|
+
};
|
|
5039
|
+
}, volTopLeg2 = function(posX, posZ, rotY, idx) {
|
|
5040
|
+
return {
|
|
5041
|
+
outName: `subpax_${designName}_topLeg${idx}`,
|
|
5042
|
+
face: `${designName}_faceTopLeg`,
|
|
5043
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5044
|
+
length: E1,
|
|
5045
|
+
rotate: [0, rotY, 0],
|
|
5046
|
+
translate: [posX, 0, posZ]
|
|
5047
|
+
};
|
|
5048
|
+
};
|
|
5049
|
+
var ctrBody = ctrBody2, ctrWheels = ctrWheels2, makeCtrTop = makeCtrTop2, ctrSideWindow = ctrSideWindow2, volWheel = volWheel2, volTopLeg = volTopLeg2;
|
|
5050
|
+
const pi2 = Math.PI / 2;
|
|
5051
|
+
const platSurface = param.L1 * param.WW1 / 10 ** 6;
|
|
5052
|
+
const L12 = param.L1 / 2;
|
|
5053
|
+
const E1 = param.E1;
|
|
5054
|
+
const E12 = 2 * E1;
|
|
5055
|
+
const Wwheels = param.W6 + param.W7 + param.W8;
|
|
5056
|
+
const Hbatterie = param.H0 - param.H6;
|
|
5057
|
+
const Lbatterie = param.L1 - 2 * Wwheels;
|
|
5058
|
+
const Lroof = param.L1 + 2 * param.W1 - 2 * param.W3;
|
|
5059
|
+
const aN1 = Math.atan2(param.H3, -param.W3);
|
|
5060
|
+
const p1 = point8(0, 0).translate(-param.W3 / 2, param.H3 / 2).translatePolar(aN1 - pi2, param.C3);
|
|
5061
|
+
const aN2 = Math.atan2(-param.H3, -param.W3);
|
|
5062
|
+
const p2 = point8(0, 0).translate(-param.W3 / 2, -param.H3 / 2).translatePolar(aN2 - pi2, param.C3);
|
|
5063
|
+
const aN3 = Math.atan2(param.H1, -param.W1);
|
|
5064
|
+
const L1dx = E1 / Math.tan(aN3 / 2);
|
|
5065
|
+
const H2dy = E1 / Math.tan((3 * pi2 - aN3) / 2);
|
|
5066
|
+
const aN4 = pi2 + Math.atan2(param.W3, param.H3);
|
|
5067
|
+
const H3dy = E1 / Math.tan(aN4 / 2);
|
|
5068
|
+
const W3dx = E1 / Math.tan((3 * pi2 - aN4) / 2);
|
|
5069
|
+
const W3b = param.W3 - E1 + W3dx;
|
|
5070
|
+
const H3b = param.H3 - E1 + H3dy;
|
|
5071
|
+
const p1b = point8(0, 0).translate(-W3b / 2, H3b / 2).translatePolar(aN1 - pi2, param.C3);
|
|
5072
|
+
const p2b = point8(0, 0).translate(-W3b / 2, -H3b / 2).translatePolar(aN2 - pi2, param.C3);
|
|
5073
|
+
const iR1 = Math.max(0, param.R1 - E1);
|
|
5074
|
+
const iR2 = Math.max(0, param.R2 - E1);
|
|
5075
|
+
const iR3 = Math.max(0, param.R3 - E1);
|
|
5076
|
+
const iR4 = Math.max(0, param.R4 - E1);
|
|
5077
|
+
const UH2dy = param.U1 / Math.tan((3 * pi2 - aN3) / 2);
|
|
5078
|
+
const UW3b = param.W3 - param.U1 + param.U1 / Math.tan((3 * pi2 - aN4) / 2);
|
|
5079
|
+
const UH3b = param.H3 - param.U1 + param.U1 / Math.tan(aN4 / 2);
|
|
5080
|
+
const p1ub = point8(0, 0).translate(-UW3b / 2, UH3b / 2).translatePolar(aN1 - pi2, param.C3);
|
|
5081
|
+
const Ltotal = param.L1 + 2 * param.W1;
|
|
5082
|
+
const Htotal = param.H1 + param.H2 + param.H3;
|
|
5083
|
+
const LwallDoor = Ltotal - 2 * (param.U1 + UW3b + param.U2 + param.U3);
|
|
5084
|
+
const HwallDoor = Htotal - param.V1 - param.V2;
|
|
5085
|
+
const R7 = param.D7 / 2;
|
|
5086
|
+
const R8 = param.D8 / 2;
|
|
5087
|
+
const posXwheel1 = L12 - param.W8;
|
|
5088
|
+
const posXwheel2 = posXwheel1 - param.W7;
|
|
5089
|
+
const WW12 = param.WW1 / 2;
|
|
5090
|
+
const WW22 = param.WW2 / 2;
|
|
5091
|
+
const posYwheels = WW12 - WW22 - param.WW3;
|
|
5092
|
+
const posXwheels = [-posXwheel1, -posXwheel2, posXwheel1, posXwheel2];
|
|
5093
|
+
const posYwheels2 = -posYwheels - WW22 - param.WW3;
|
|
5094
|
+
const L5 = Lroof - 2 * param.W4;
|
|
5095
|
+
const L52 = L5 / 2;
|
|
5096
|
+
const posYtop = param.H0 + param.H1 + param.H2 + param.H3;
|
|
5097
|
+
const posYtop2 = posYtop + param.H5;
|
|
5098
|
+
const heightTot = posYtop2 + E1;
|
|
5099
|
+
const W52 = param.W5 / 2;
|
|
5100
|
+
const R53 = param.R5 * 3;
|
|
5101
|
+
const R52 = R53 / 2;
|
|
5102
|
+
const topR = W52 - R52;
|
|
5103
|
+
const L53 = L5 - 2 * topR;
|
|
5104
|
+
const H53 = param.H5 - 4 * param.R5;
|
|
5105
|
+
const posYbatterie = param.H6 + E1;
|
|
5106
|
+
const LbatInt = Lbatterie - 2 * E1;
|
|
5107
|
+
const LbatInt2 = LbatInt / 2;
|
|
5108
|
+
const HbatInt = Hbatterie - E1;
|
|
5109
|
+
const posYH3 = param.H0 + param.H1 + param.H2;
|
|
5110
|
+
const FWL1 = param.WW1 - 2 * param.FW1;
|
|
5111
|
+
const FWL3 = param.WW1 - 2 * param.FW3;
|
|
5112
|
+
const HfrontWin = Htotal - param.FH1 - param.FH3;
|
|
5113
|
+
const Ltot2 = Ltotal + 200;
|
|
5114
|
+
if (param.L1 - 2 * Wwheels < 2 * E1) {
|
|
5115
|
+
throw `err176: L1 ${ffix15(param.L1)} is too small compare to W6 ${ffix15(param.W6)}, W7 ${ffix15(param.W7)} and W8 ${ffix15(param.W8)} mm`;
|
|
5116
|
+
}
|
|
5117
|
+
if (Hbatterie < E1) {
|
|
5118
|
+
throw `err114: Hbatterie ${ffix15(Hbatterie)} is too small compare to E1 ${ffix15(E1)} mm`;
|
|
5119
|
+
}
|
|
5120
|
+
if (Lbatterie < 2 * E1) {
|
|
5121
|
+
throw `err118: Lbatterie ${ffix15(Lbatterie)} is too small compare to E1 ${ffix15(E1)} mm`;
|
|
5122
|
+
}
|
|
5123
|
+
if (L5 < 3 * param.R5 + param.W5) {
|
|
5124
|
+
throw `err122: L5 ${ffix15(L5)} is too small compare to W5 ${ffix15(param.W5)} and R5 ${ffix15(param.R5)} mm`;
|
|
5125
|
+
}
|
|
5126
|
+
if (H53 < 0.1) {
|
|
5127
|
+
throw `err220: H5 ${ffix15(param.H5)} is too small compare to R5 ${ffix15(param.R5)} mm`;
|
|
5128
|
+
}
|
|
5129
|
+
rGeome.logstr += `Platform surface: ${ffix15(platSurface)} m2, height: ${ffix15(heightTot / 1e3)} m
|
|
5130
|
+
`;
|
|
5131
|
+
rGeome.logstr += `Lroof: ${ffix15(Lroof)}, L5: ${ffix15(L5)} mm
|
|
4256
5132
|
`;
|
|
4257
|
-
|
|
5133
|
+
rGeome.logstr += `Ltotal: ${ffix15(Ltotal / 1e3)}, Htotal: ${ffix15(Htotal / 1e3)} m
|
|
5134
|
+
`;
|
|
5135
|
+
rGeome.logstr += `Batterie: LbatInt ${ffix15(LbatInt)}, HbatInt: ${ffix15(HbatInt)}, WW1 ${ffix15(param.WW1)} mm
|
|
5136
|
+
`;
|
|
5137
|
+
const ctrBodyExt = ctrBody2(true);
|
|
5138
|
+
const ctrBodyInt = contour15(-L12 + L1dx, param.H0 + E1).addSegStrokeR(2 * L12 - 2 * L1dx, 0).addCornerRounded(iR1).addSegStrokeR(param.W1 - E1 + L1dx, param.H1 - E1 + H2dy).addCornerRounded(iR2).addSegStrokeR(0, param.H2 - 2 * H2dy).addCornerRounded(iR3).addPointR(p1b.cx, p1b.cy).addPointR(-W3b, H3b).addSegArc2().addCornerRounded(iR4).addSegStrokeR(-Lroof + 2 * W3dx, 0).addCornerRounded(iR4).addPointR(p2b.cx, p2b.cy).addPointR(-W3b, -H3b).addSegArc2().addCornerRounded(iR3).addSegStrokeR(0, -param.H2 + 2 * H2dy).addCornerRounded(iR2).closeSegStroke().addCornerRounded(iR1);
|
|
5139
|
+
const ctrBatterie = ctrRectangle7(-LbatInt2, posYbatterie, LbatInt, HbatInt);
|
|
5140
|
+
figBody.addMainOI([ctrBodyExt, ctrBodyInt, ctrBatterie]);
|
|
5141
|
+
figBody.addSecond(contourCircle12(-posXwheel1, R7, R7));
|
|
5142
|
+
figBody.addSecond(contourCircle12(-posXwheel1, R7, R8));
|
|
5143
|
+
figBody.addSecond(contourCircle12(-posXwheel2, R7, R7));
|
|
5144
|
+
figBody.addSecond(contourCircle12(-posXwheel2, R7, R8));
|
|
5145
|
+
figBody.addSecond(contourCircle12(posXwheel1, R7, R7));
|
|
5146
|
+
figBody.addSecond(contourCircle12(posXwheel1, R7, R8));
|
|
5147
|
+
figBody.addSecond(contourCircle12(posXwheel2, R7, R7));
|
|
5148
|
+
figBody.addSecond(contourCircle12(posXwheel2, R7, R8));
|
|
5149
|
+
figBody.addSecond(ctrRectangle7(-L52, posYtop, L5, param.H5));
|
|
5150
|
+
figBody.addSecond(ctrRectangle7(-L52 - param.S5, posYtop2, L5 + 2 * param.S5, E1));
|
|
5151
|
+
figWheels.addMainO(ctrWheels2(1));
|
|
5152
|
+
figWheels.addSecond(ctrWheels2(-1));
|
|
5153
|
+
const ctrFront = contour15(-FWL1 / 2, param.H0 + param.FH1).addCornerRounded(param.FR1).addSegStrokeR(FWL1, 0).addCornerRounded(param.FR1).addSegStrokeR(param.FW1 - param.FW3, HfrontWin).addCornerRounded(param.FR3).addSegStrokeR(-FWL3, 0).addCornerRounded(param.FR3).closeSegStroke();
|
|
5154
|
+
figFront.addMainO(ctrFront);
|
|
5155
|
+
figFront.addSecond(ctrWheels2(1).rotate(0, 0, pi2).translate(WW12, R7));
|
|
5156
|
+
figFront.addSecond(ctrWheels2(-1).rotate(0, 0, pi2).translate(WW12, R7));
|
|
5157
|
+
figFront.addSecond(ctrRectangle7(-WW12, param.H6, param.WW1, Hbatterie));
|
|
5158
|
+
figFront.addSecond(ctrRectangle7(-WW12, param.H0, param.WW1, param.H1));
|
|
5159
|
+
figFront.addSecond(ctrRectangle7(-WW12, param.H0 + param.H1, param.WW1, param.H2));
|
|
5160
|
+
figFront.addSecond(ctrRectangle7(-WW12, posYH3, param.WW1, param.H3));
|
|
5161
|
+
figFront.addSecond(ctrRectangle7(-W52, posYtop, param.W5, param.H5));
|
|
5162
|
+
figFront.addSecond(ctrRectangle7(-W52 - param.S5, posYtop2, param.W5 + 2 * param.S5, E1));
|
|
5163
|
+
figFront.addSecond(ctrRectangle7(-WW12 + E1, param.H0 + E1, param.WW1 - E12, Htotal - E12));
|
|
5164
|
+
const ctrTopInt = makeCtrTop2(topR - E1);
|
|
5165
|
+
const ctrTopExt = makeCtrTop2(topR);
|
|
5166
|
+
const ctrTopTop = makeCtrTop2(topR + param.S5);
|
|
5167
|
+
figTop.addMainOI([ctrTopExt, ctrTopInt]);
|
|
5168
|
+
figTop.addSecond(ctrTopTop);
|
|
5169
|
+
figTop.addSecond(ctrRectangle7(-Lroof / 2, -WW12, Lroof, 2 * WW12));
|
|
5170
|
+
figTop.addSecond(ctrRectangle7(-Ltotal / 2, -WW12, Ltotal, 2 * WW12));
|
|
5171
|
+
figTop.addSecond(ctrWheels2(1).translate(posXwheels[0], posYwheels2));
|
|
5172
|
+
figTop.addSecond(ctrWheels2(1).translate(posXwheels[1], posYwheels2));
|
|
5173
|
+
figTop.addSecond(ctrWheels2(1).translate(posXwheels[2], posYwheels2));
|
|
5174
|
+
figTop.addSecond(ctrWheels2(1).translate(posXwheels[3], posYwheels2));
|
|
5175
|
+
figTop.addSecond(ctrWheels2(-1).translate(posXwheels[0], posYwheels2));
|
|
5176
|
+
figTop.addSecond(ctrWheels2(-1).translate(posXwheels[1], posYwheels2));
|
|
5177
|
+
figTop.addSecond(ctrWheels2(-1).translate(posXwheels[2], posYwheels2));
|
|
5178
|
+
figTop.addSecond(ctrWheels2(-1).translate(posXwheels[3], posYwheels2));
|
|
5179
|
+
figTopInt.addMainO(ctrTopInt);
|
|
5180
|
+
figTopInt.mergeFigure(figTop, true);
|
|
5181
|
+
figTopTop.addMainO(ctrTopTop);
|
|
5182
|
+
figTopTop.mergeFigure(figTop, true);
|
|
5183
|
+
const ctrTopLeg = contour15(-R52, posYtop).addSegStrokeR(R53, 0).addSegStrokeR(0, param.R5).addPointR(-param.R5, param.R5).addSegArc(param.R5, false, false).addSegStrokeR(0, H53).addPointR(param.R5, param.R5).addSegArc(param.R5, false, false).addSegStrokeR(0, param.R5).addSegStrokeR(-R53, 0).addSegStrokeR(0, -param.R5).addPointR(param.R5, -param.R5).addSegArc(param.R5, false, false).addSegStrokeR(0, -H53).addPointR(-param.R5, -param.R5).addSegArc(param.R5, false, false).closeSegStroke();
|
|
5184
|
+
figTopLeg.addMainO(ctrTopLeg);
|
|
5185
|
+
figFront.addSecond(ctrTopLeg);
|
|
5186
|
+
const ctrDoor = contour15(-LwallDoor / 2, param.H0 + param.V1).addCornerRounded(param.JR5).addSegStrokeR(LwallDoor, 0).addCornerRounded(param.JR5).addSegStrokeR(0, HwallDoor).addCornerRounded(param.JR6).addSegStrokeR(-LwallDoor, 0).addCornerRounded(param.JR6).closeSegStroke();
|
|
5187
|
+
figWall.addMainOI([ctrBody2(false), ctrSideWindow2(1), ctrSideWindow2(-1), ctrDoor]);
|
|
5188
|
+
figWall.mergeFigure(figBody, true);
|
|
4258
5189
|
rGeome.fig = {
|
|
4259
|
-
|
|
5190
|
+
faceBody: figBody,
|
|
5191
|
+
faceWheels: figWheels,
|
|
5192
|
+
faceFront: figFront,
|
|
5193
|
+
faceTop: figTop,
|
|
5194
|
+
faceTopInt: figTopInt,
|
|
5195
|
+
faceTopTop: figTopTop,
|
|
5196
|
+
faceTopLeg: figTopLeg,
|
|
5197
|
+
faceWall: figWall
|
|
4260
5198
|
};
|
|
4261
5199
|
const designName = rGeome.partName;
|
|
5200
|
+
const miradorList = [];
|
|
5201
|
+
if (param.topStyle === 0) {
|
|
5202
|
+
miradorList.push(
|
|
5203
|
+
...[
|
|
5204
|
+
`subpax_${designName}_top1`,
|
|
5205
|
+
`subpax_${designName}_top2`,
|
|
5206
|
+
`subpax_${designName}_topTop`,
|
|
5207
|
+
`subpax_${designName}_topLeg1`,
|
|
5208
|
+
`subpax_${designName}_topLeg2`,
|
|
5209
|
+
`subpax_${designName}_topLeg3`,
|
|
5210
|
+
`subpax_${designName}_topLeg4`,
|
|
5211
|
+
`subpax_${designName}_topLeg5`,
|
|
5212
|
+
`subpax_${designName}_topLeg6`
|
|
5213
|
+
]
|
|
5214
|
+
);
|
|
5215
|
+
}
|
|
5216
|
+
const roofHoleList = [];
|
|
5217
|
+
if (param.topStyle !== 2) {
|
|
5218
|
+
roofHoleList.push(`subpax_${designName}_topInt`);
|
|
5219
|
+
}
|
|
5220
|
+
const wallList = [];
|
|
5221
|
+
if (param.sideWall === 1) {
|
|
5222
|
+
wallList.push(...[`subpax_${designName}_wall1`, `subpax_${designName}_wall2`]);
|
|
5223
|
+
}
|
|
4262
5224
|
rGeome.vol = {
|
|
4263
5225
|
extrudes: [
|
|
4264
5226
|
{
|
|
4265
|
-
outName: `subpax_${designName}
|
|
4266
|
-
face: `${designName}
|
|
5227
|
+
outName: `subpax_${designName}_body`,
|
|
5228
|
+
face: `${designName}_faceBody`,
|
|
5229
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5230
|
+
length: param.WW1,
|
|
5231
|
+
rotate: [0, 0, 0],
|
|
5232
|
+
translate: [0, 0, 0]
|
|
5233
|
+
},
|
|
5234
|
+
volWheel2(posXwheels[0], "1"),
|
|
5235
|
+
volWheel2(posXwheels[1], "2"),
|
|
5236
|
+
volWheel2(posXwheels[2], "3"),
|
|
5237
|
+
volWheel2(posXwheels[3], "4"),
|
|
5238
|
+
{
|
|
5239
|
+
outName: `subpax_${designName}_frontWin`,
|
|
5240
|
+
face: `${designName}_faceFront`,
|
|
5241
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5242
|
+
length: Ltot2,
|
|
5243
|
+
rotate: [0, pi2, 0],
|
|
5244
|
+
translate: [-Ltot2 / 2, 0, WW12]
|
|
5245
|
+
},
|
|
5246
|
+
{
|
|
5247
|
+
outName: `subpax_${designName}_topInt`,
|
|
5248
|
+
face: `${designName}_faceTopInt`,
|
|
5249
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5250
|
+
length: 3 * E1,
|
|
5251
|
+
rotate: [-pi2, 0, 0],
|
|
5252
|
+
translate: [0, posYtop - 2 * E1, WW12]
|
|
5253
|
+
},
|
|
5254
|
+
{
|
|
5255
|
+
outName: `subpax_${designName}_top1`,
|
|
5256
|
+
face: `${designName}_faceTop`,
|
|
5257
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5258
|
+
length: param.R5,
|
|
5259
|
+
rotate: [-pi2, 0, 0],
|
|
5260
|
+
translate: [0, posYtop, WW12]
|
|
5261
|
+
},
|
|
5262
|
+
{
|
|
5263
|
+
outName: `subpax_${designName}_top2`,
|
|
5264
|
+
face: `${designName}_faceTop`,
|
|
5265
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5266
|
+
length: param.R5,
|
|
5267
|
+
rotate: [-pi2, 0, 0],
|
|
5268
|
+
translate: [0, posYtop2 - param.R5, WW12]
|
|
5269
|
+
},
|
|
5270
|
+
{
|
|
5271
|
+
outName: `subpax_${designName}_topTop`,
|
|
5272
|
+
face: `${designName}_faceTopTop`,
|
|
4267
5273
|
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
4268
|
-
length:
|
|
5274
|
+
length: E1,
|
|
5275
|
+
rotate: [-pi2, 0, 0],
|
|
5276
|
+
translate: [0, posYtop2, WW12]
|
|
5277
|
+
},
|
|
5278
|
+
volTopLeg2(-L52, WW12, pi2, "1"),
|
|
5279
|
+
volTopLeg2(L52 - E1, WW12, pi2, "2"),
|
|
5280
|
+
volTopLeg2(-L53 / 2 + R52, WW12 - W52, 0, "3"),
|
|
5281
|
+
volTopLeg2(-L53 / 2 + R52, WW12 + W52 - E1, 0, "4"),
|
|
5282
|
+
volTopLeg2(L53 / 2 - R52, WW12 - W52, 0, "5"),
|
|
5283
|
+
volTopLeg2(L53 / 2 - R52, WW12 + W52 - E1, 0, "6"),
|
|
5284
|
+
{
|
|
5285
|
+
outName: `subpax_${designName}_wall1`,
|
|
5286
|
+
face: `${designName}_faceWall`,
|
|
5287
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5288
|
+
length: E1,
|
|
4269
5289
|
rotate: [0, 0, 0],
|
|
4270
5290
|
translate: [0, 0, 0]
|
|
5291
|
+
},
|
|
5292
|
+
{
|
|
5293
|
+
outName: `subpax_${designName}_wall2`,
|
|
5294
|
+
face: `${designName}_faceWall`,
|
|
5295
|
+
extrudeMethod: EExtrude11.eLinearOrtho,
|
|
5296
|
+
length: E1,
|
|
5297
|
+
rotate: [0, 0, 0],
|
|
5298
|
+
translate: [0, 0, param.WW1 - E1]
|
|
4271
5299
|
}
|
|
4272
5300
|
],
|
|
4273
5301
|
volumes: [
|
|
4274
5302
|
{
|
|
4275
|
-
outName: `
|
|
5303
|
+
outName: `ipax_${designName}_plus`,
|
|
4276
5304
|
boolMethod: EBVolume11.eUnion,
|
|
4277
|
-
inList: [
|
|
5305
|
+
inList: [
|
|
5306
|
+
`subpax_${designName}_body`,
|
|
5307
|
+
`subpax_${designName}_wheel1`,
|
|
5308
|
+
`subpax_${designName}_wheel2`,
|
|
5309
|
+
`subpax_${designName}_wheel3`,
|
|
5310
|
+
`subpax_${designName}_wheel4`,
|
|
5311
|
+
...miradorList,
|
|
5312
|
+
...wallList
|
|
5313
|
+
]
|
|
5314
|
+
},
|
|
5315
|
+
{
|
|
5316
|
+
outName: `ipax_${designName}_minus`,
|
|
5317
|
+
boolMethod: EBVolume11.eUnion,
|
|
5318
|
+
inList: [`subpax_${designName}_frontWin`, ...roofHoleList]
|
|
5319
|
+
},
|
|
5320
|
+
{
|
|
5321
|
+
outName: `pax_${designName}`,
|
|
5322
|
+
boolMethod: EBVolume11.eSubstraction,
|
|
5323
|
+
inList: [`ipax_${designName}_plus`, `ipax_${designName}_minus`]
|
|
4278
5324
|
}
|
|
4279
5325
|
]
|
|
4280
5326
|
};
|