Files
modeling-app/rust/kcl-lib/e2e/executor/inputs/fillet-and-shell.kcl
Jess Frazelle c3bdc6f106 Move the wasm lib, and cleanup rust directory and all references (#5585)
* git mv src/wasm-lib rust

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* mv wasm-lib to workspace

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* mv kcl-lib

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* mv derive docs

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* resolve file paths

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* clippy

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* move more shit

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix more paths

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* make yarn build:wasm work

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix scripts

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fixups

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* better references

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix cargo ci

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix reference

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix more ci

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix tests

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* cargo sort

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix script

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fmt

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fix a dep

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* sort

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* remove unused deps

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* Revert "remove unused deps"

This reverts commit fbabdb062e275fd5cbc1476f8480a1afee15d972.

* updates

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* deps;

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* fixes

Signed-off-by: Jess Frazelle <github@jessfraz.com>

* updates

Signed-off-by: Jess Frazelle <github@jessfraz.com>

---------

Signed-off-by: Jess Frazelle <github@jessfraz.com>
2025-03-01 21:59:01 +00:00

82 lines
2.1 KiB
Plaintext

const rpizWidth = 30
const rpizLength = 65
const caseThickness = 1
const border = 4
const screwHeight = 4
const caseWidth = rpizWidth + border * 2
const caseLength = rpizLength + border * 2
const caseHeight = 8
const widthBetweenScrews = 23
const lengthBetweenScrews = 29 * 2
const miniHdmiDistance = 12.4
const microUsb1Distance = 41.4
const microUsb2Distance = 54
const miniHdmiWidth = 11.2
const microUsbWidth = 7.4
const connectorPadding = 4
const miniHdmiHole = startSketchAt([
0,
border + miniHdmiDistance - (miniHdmiWidth / 2)
])
|> lineTo([
0,
border + miniHdmiDistance + miniHdmiWidth / 2
], %)
|> lineTo([
1,
border + miniHdmiDistance + miniHdmiWidth / 2
], %)
|> lineTo([
1,
border + miniHdmiDistance - (miniHdmiWidth / 2)
], %)
|> close()
const case = startSketchOn('XY')
|> startProfileAt([0, 0], %)
|> line(endAbsolute = [caseWidth, 0], $edge1)
|> line(endAbsolute = [caseWidth, caseLength], $edge2)
|> line(endAbsolute = [0, caseLength], $edge3)
|> close(tag = $edge4)
|> extrude(length = caseHeight)
|> fillet(
radius = 1,
tags = [
getNextAdjacentEdge(edge1),
getNextAdjacentEdge(edge2),
getNextAdjacentEdge(edge3),
getNextAdjacentEdge(edge4)
],
)
fn m25Screw = (x, y, height) => {
const screw = startSketchOn("XY")
|> startProfileAt([0, 0], %)
|> circle(center= [x, y], radius=2.5)
|> hole(circle(center= [x, y], radius = 1.25), %)
|> extrude(length = height)
return screw
}
m25Screw(border + rpizWidth / 2 - (widthBetweenScrews / 2), 0 + border + rpizLength / 2 - (lengthBetweenScrews / 2), screwHeight)
m25Screw(border + rpizWidth / 2 - (widthBetweenScrews / 2), 0 + border + rpizLength / 2 + lengthBetweenScrews / 2, screwHeight)
m25Screw(border + rpizWidth / 2 + widthBetweenScrews / 2, 0 + border + rpizLength / 2 + lengthBetweenScrews / 2, screwHeight)
m25Screw(border + rpizWidth / 2 + widthBetweenScrews / 2, 0 + border + rpizLength / 2 - (lengthBetweenScrews / 2), screwHeight)
shell(
faces = ['end'],
thickness = caseThickness
)