Compare commits

...

9 Commits

Author SHA1 Message Date
e5091ebfcb turn on/off react-perf rules
Signed-off-by: Jess Frazelle <github@jessfraz.com>
2025-04-04 17:21:26 -07:00
8e4c5fb24d Add test for #5799: "Only showing axis planes when there are no errors" (#6007)
* first pass at adding test for Only showing axis planes when there are no errors

* fix test Only show axis planes when there are no errors

* PR feedback
2025-04-04 23:41:09 +02:00
6993893600 Wait for export button to make test more reliable (#6143) 2025-04-04 16:53:57 -04:00
bfdf8babed sketching on a mirror2d thats been extruded fixed! (#6149)
* updates

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

* snap

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

* fixes

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

* add sample

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

* updates

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

* updates

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

* updates

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

* fixes

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

* snap

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

---------

Signed-off-by: Jess Frazelle <github@jessfraz.com>
2025-04-04 12:55:21 -07:00
4d31fb890d Bump vite from 5.4.16 to 5.4.17 in /packages/codemirror-lang-kcl in the security group (#6150)
Bump vite in /packages/codemirror-lang-kcl in the security group

Bumps the security group in /packages/codemirror-lang-kcl with 1 update: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 5.4.16 to 5.4.17
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.17/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.17/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 5.4.17
  dependency-type: indirect
  dependency-group: security
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-04 18:57:20 +00:00
ef451fd8f7 Bump vite from 5.4.16 to 5.4.17 in the security group (#6151)
Bumps the security group with 1 update: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 5.4.16 to 5.4.17
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.17/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.17/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 5.4.17
  dependency-type: direct:development
  dependency-group: security
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-04 18:40:35 +00:00
656eb0abec Update all KCL-Samples to be more ME friendly (#6132)
* update all kcl-samples

* updates

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>

* updates

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

* Update kcl-samples simulation test output

---------

Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-04-04 11:03:13 -07:00
a7896329f7 Shorten feedback cycle for legitimate failures (#6146)
Stop sooner with legitimate failures
2025-04-04 17:29:29 +00:00
b9e11ac201 Remove the camera projection toggle from the UI (#6077)
* Remove E2E test behavior for projection toggle UI

Even though the test is `fixme`'d this should make it easier to
ressurect. The test is still flaky but it runs now.

* Remove projection toggle from the UI
2025-04-04 16:41:56 +00:00
214 changed files with 34612 additions and 35403 deletions

View File

@ -17,9 +17,13 @@
"extends": [ "extends": [
"plugin:css-modules/recommended", "plugin:css-modules/recommended",
"plugin:jsx-a11y/recommended", "plugin:jsx-a11y/recommended",
"plugin:react-hooks/recommended" "plugin:react-hooks/recommended",
"plugin:react-perf/recommended"
], ],
"rules": { "rules": {
"react-perf/jsx-no-new-object-as-prop": "off", // We don't think this helps anything.
"react-perf/jsx-no-new-function-as-prop": "off", // We don't think this helps anything.
"react-perf/jsx-no-new-array-as-prop": "off", // We don't think this helps anything.
"no-array-constructor": "off", // This is wrong; use the @typescript-eslint one instead. "no-array-constructor": "off", // This is wrong; use the @typescript-eslint one instead.
"@typescript-eslint/no-array-constructor": "error", "@typescript-eslint/no-array-constructor": "error",
"@typescript-eslint/no-array-delete": "error", "@typescript-eslint/no-array-delete": "error",

View File

@ -370,8 +370,8 @@ jobs:
with: with:
shell: bash shell: bash
command: .github/ci-cd-scripts/playwright-electron.sh ${{matrix.shardIndex}} ${{matrix.shardTotal}} ${{ env.OS_NAME }} command: .github/ci-cd-scripts/playwright-electron.sh ${{matrix.shardIndex}} ${{matrix.shardTotal}} ${{ env.OS_NAME }}
timeout_minutes: 45 timeout_minutes: 30
max_attempts: 15 max_attempts: 9
env: env:
FAIL_ON_CONSOLE_ERRORS: true FAIL_ON_CONSOLE_ERRORS: true
token: ${{ secrets.KITTYCAD_API_TOKEN_DEV }} token: ${{ secrets.KITTYCAD_API_TOKEN_DEV }}

File diff suppressed because one or more lines are too long

View File

@ -32,53 +32,44 @@ test(
}) })
await page.setBodyDimensions({ width: 1200, height: 500 }) await page.setBodyDimensions({ width: 1200, height: 500 })
page.on('console', console.log)
await test.step('on open of project', async () => { await test.step('on open of project', async () => {
await expect(page.getByText(`bracket`)).toBeVisible() // Open the project
const projectName = page.getByText(`bracket`)
await expect(projectName).toBeVisible()
await projectName.click()
await scene.waitForExecutionDone()
await page.waitForTimeout(1_000) // wait for panel buttons to be available
// open the project // Expect zero errors in gutter
await page.getByText(`bracket`).click()
// expect zero errors in guter
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible() await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
// export the model // Click the export button
const exportButton = page.getByTestId('export-pane-button') const exportButton = page.getByTestId('export-pane-button')
await expect(exportButton).toBeVisible() await expect(exportButton).toBeVisible()
await scene.waitForExecutionDone()
const gltfOption = page.getByText('glTF')
const submitButton = page.getByText('Confirm Export')
const exportingToastMessage = page.getByText(`Exporting...`)
const errorToastMessage = page.getByText(`Error while exporting`)
const engineErrorToastMessage = page.getByText(`Nothing to export`)
const alreadyExportingToastMessage = page.getByText(`Already exporting`)
// The open file's name is `main.kcl`, so the export file name should be `main.gltf`
const exportFileName = `main.gltf`
// Click the export button
await exportButton.click() await exportButton.click()
await page.waitForTimeout(1_000) // wait for export options to be available
// Select the first format option
const gltfOption = page.getByText('glTF')
const exportFileName = `main.gltf` // source file is named `main.kcl`
await expect(gltfOption).toBeVisible() await expect(gltfOption).toBeVisible()
await expect(page.getByText('STL')).toBeVisible()
await page.keyboard.press('Enter') await page.keyboard.press('Enter')
// Click the checkbox // Click the checkbox
const submitButton = page.getByText('Confirm Export')
await expect(submitButton).toBeVisible() await expect(submitButton).toBeVisible()
await page.waitForTimeout(500) await page.waitForTimeout(500)
await page.keyboard.press('Enter') await page.keyboard.press('Enter')
// Find the toast.
// Look out for the toast message // Look out for the toast message
const exportingToastMessage = page.getByText(`Exporting...`)
const alreadyExportingToastMessage = page.getByText(`Already exporting`)
await expect(exportingToastMessage).toBeVisible() await expect(exportingToastMessage).toBeVisible()
await expect(alreadyExportingToastMessage).not.toBeVisible() await expect(alreadyExportingToastMessage).not.toBeVisible()
// Expect it to succeed. // Expect it to succeed
const errorToastMessage = page.getByText(`Error while exporting`)
const engineErrorToastMessage = page.getByText(`Nothing to export`)
await expect(errorToastMessage).not.toBeVisible() await expect(errorToastMessage).not.toBeVisible()
await expect(engineErrorToastMessage).not.toBeVisible() await expect(engineErrorToastMessage).not.toBeVisible()
@ -86,6 +77,7 @@ test(
await expect(successToastMessage).toBeVisible() await expect(successToastMessage).toBeVisible()
await expect(exportingToastMessage).not.toBeVisible() await expect(exportingToastMessage).not.toBeVisible()
// Check for the exported file
const firstFileFullPath = path.resolve( const firstFileFullPath = path.resolve(
getPlaywrightDownloadDir(tronApp.projectDirName), getPlaywrightDownloadDir(tronApp.projectDirName),
exportFileName exportFileName
@ -112,60 +104,53 @@ test(
const u = await getUtils(page) const u = await getUtils(page)
await u.openFilePanel() await u.openFilePanel()
// Click on the other file
const otherKclButton = page.getByRole('button', { name: 'other.kcl' }) const otherKclButton = page.getByRole('button', { name: 'other.kcl' })
// Click the file
await otherKclButton.click() await otherKclButton.click()
// Close the file pane // Close the file pane
await u.closeFilePanel() await u.closeFilePanel()
await scene.waitForExecutionDone()
await page.waitForTimeout(1_000) // wait for panel buttons to be available
// FIXME: await scene.waitForExecutionDone() does not work. The modeling indicator stays in -receive-reliable and not execution done // Expect zero errors in gutter
await page.waitForTimeout(10000)
// expect zero errors in guter
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible() await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
// export the model // Click the export button
const exportButton = page.getByTestId('export-pane-button') const exportButton = page.getByTestId('export-pane-button')
await expect(exportButton).toBeVisible() await expect(exportButton).toBeVisible()
const gltfOption = page.getByText('glTF')
const submitButton = page.getByText('Confirm Export')
const exportingToastMessage = page.getByText(`Exporting...`)
const errorToastMessage = page.getByText(`Error while exporting`)
const engineErrorToastMessage = page.getByText(`Nothing to export`)
const alreadyExportingToastMessage = page.getByText(`Already exporting`)
// The open file's name is `other.kcl`, so the export file name should be `other.gltf`
const exportFileName = `other.gltf`
// Click the export button
await exportButton.click() await exportButton.click()
await page.waitForTimeout(1_000) // wait for export options to be available
// Select the first format option
const gltfOption = page.getByText('glTF')
const exportFileName = `other.gltf` // source file is named `other.kcl`
await expect(gltfOption).toBeVisible() await expect(gltfOption).toBeVisible()
await expect(page.getByText('STL')).toBeVisible()
await page.keyboard.press('Enter') await page.keyboard.press('Enter')
// Click the checkbox // Click the checkbox
const submitButton = page.getByText('Confirm Export')
await expect(submitButton).toBeVisible() await expect(submitButton).toBeVisible()
await page.waitForTimeout(500)
await page.keyboard.press('Enter') await page.keyboard.press('Enter')
// Find the toast.
// Look out for the toast message // Look out for the toast message
const exportingToastMessage = page.getByText(`Exporting...`)
const alreadyExportingToastMessage = page.getByText(`Already exporting`)
await expect(exportingToastMessage).toBeVisible() await expect(exportingToastMessage).toBeVisible()
await expect(alreadyExportingToastMessage).not.toBeVisible()
// Expect it to succeed
const errorToastMessage = page.getByText(`Error while exporting`)
const engineErrorToastMessage = page.getByText(`Nothing to export`)
await expect(errorToastMessage).not.toBeVisible()
await expect(engineErrorToastMessage).not.toBeVisible()
const successToastMessage = page.getByText(`Exported successfully`) const successToastMessage = page.getByText(`Exported successfully`)
await test.step('Check the success toast message shows and nothing else', async () => await expect(successToastMessage).toBeVisible()
Promise.all([ await expect(exportingToastMessage).not.toBeVisible()
expect(alreadyExportingToastMessage).not.toBeVisible(),
expect(errorToastMessage).not.toBeVisible(),
expect(engineErrorToastMessage).not.toBeVisible(),
expect(successToastMessage).toBeVisible(),
expect(exportingToastMessage).not.toBeVisible(),
]))
// Check for the exported file=
const secondFileFullPath = path.resolve( const secondFileFullPath = path.resolve(
getPlaywrightDownloadDir(tronApp.projectDirName), getPlaywrightDownloadDir(tronApp.projectDirName),
exportFileName exportFileName

View File

@ -1315,4 +1315,38 @@ sketch001 = startSketchOn(XZ)
const element = page.locator('[data-overlay-index="1"]') const element = page.locator('[data-overlay-index="1"]')
await expect(element).toHaveAttribute('data-overlay-visible', 'true') await expect(element).toHaveAttribute('data-overlay-visible', 'true')
}) })
test(`Only show axis planes when there are no errors`, async ({
page,
homePage,
scene,
cmdBar,
}) => {
await page.addInitScript(async () => {
localStorage.setItem(
'persistCode',
`sketch001 = startSketchOn(XZ)
profile001 = circle(sketch001, center = [-100.0, -100.0], radius = 50.0)
sketch002 = startSketchOn(XZ)
profile002 = circle(sketch002, center = [-100.0, 100.0], radius = 50.0)
extrude001 = extrude(profile002, length = 0)` // length = 0 is causing the error
)
})
const viewportSize = { width: 1200, height: 800 }
await page.setBodyDimensions(viewportSize)
await homePage.goToModelingScene()
await scene.connectionEstablished()
await scene.settled(cmdBar)
await scene.expectPixelColor(
TEST_COLORS.DARK_MODE_BKGD,
// This is a position where the blue part of the axis plane is visible if its rendered
{ x: viewportSize.width * 0.75, y: viewportSize.height * 0.2 },
15
)
})
}) })

View File

@ -80,7 +80,8 @@ export const TEST_SETTINGS_CORRUPTED = {
}, },
} satisfies Partial<SaveSettingsPayload> } satisfies Partial<SaveSettingsPayload>
export const TEST_CODE_GIZMO = `part001 = startSketchOn(XZ) export const TEST_CODE_GIZMO = `@settings(defaultLengthUnit = in)
part001 = startSketchOn(XZ)
|> startProfileAt([20, 0], %) |> startProfileAt([20, 0], %)
|> line(end = [7.13, 4 + 0]) |> line(end = [7.13, 4 + 0])
|> angledLine({ angle: 3 + 0, length: 3.14 + 0 }, %) |> angledLine({ angle: 3 + 0, length: 3.14 + 0 }, %)

View File

@ -8,37 +8,37 @@ test.describe('Testing Gizmo', { tag: ['@skipWin'] }, () => {
const cases = [ const cases = [
{ {
testDescription: 'top view', testDescription: 'top view',
clickPosition: { x: 951, y: 347 }, clickPosition: { x: 951, y: 385 },
expectedCameraPosition: { x: 800, y: -152, z: 4886.02 }, expectedCameraPosition: { x: 800, y: -152, z: 4886.02 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },
{ {
testDescription: 'bottom view', testDescription: 'bottom view',
clickPosition: { x: 951, y: 391 }, clickPosition: { x: 951, y: 429 },
expectedCameraPosition: { x: 800, y: -152, z: -4834.02 }, expectedCameraPosition: { x: 800, y: -152, z: -4834.02 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },
{ {
testDescription: 'right view', testDescription: 'right view',
clickPosition: { x: 929, y: 379 }, clickPosition: { x: 929, y: 417 },
expectedCameraPosition: { x: 5660.02, y: -152, z: 26 }, expectedCameraPosition: { x: 5660.02, y: -152, z: 26 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },
{ {
testDescription: 'left view', testDescription: 'left view',
clickPosition: { x: 974, y: 359 }, clickPosition: { x: 974, y: 397 },
expectedCameraPosition: { x: -4060.02, y: -152, z: 26 }, expectedCameraPosition: { x: -4060.02, y: -152, z: 26 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },
{ {
testDescription: 'back view', testDescription: 'back view',
clickPosition: { x: 967, y: 383 }, clickPosition: { x: 967, y: 421 },
expectedCameraPosition: { x: 800, y: 4708.02, z: 26 }, expectedCameraPosition: { x: 800, y: 4708.02, z: 26 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },
{ {
testDescription: 'front view', testDescription: 'front view',
clickPosition: { x: 935, y: 355 }, clickPosition: { x: 935, y: 393 },
expectedCameraPosition: { x: 800, y: -5012.02, z: 26 }, expectedCameraPosition: { x: 800, y: -5012.02, z: 26 },
expectedCameraTarget: { x: 800, y: -152, z: 26 }, expectedCameraTarget: { x: 800, y: -152, z: 26 },
}, },

View File

@ -2,7 +2,11 @@ import { getUtils, orRunWhenFullSuiteEnabled } from '@e2e/playwright/test-utils'
import { expect, test } from '@e2e/playwright/zoo-test' import { expect, test } from '@e2e/playwright/zoo-test'
test.describe('Test toggling perspective', () => { test.describe('Test toggling perspective', () => {
test('via command palette and toggle', async ({ page, homePage }) => { test('via command palette and toggle', async ({
page,
homePage,
toolbar,
}) => {
test.fixme(orRunWhenFullSuiteEnabled()) test.fixme(orRunWhenFullSuiteEnabled())
const u = await getUtils(page) const u = await getUtils(page)
@ -14,7 +18,7 @@ test.describe('Test toggling perspective', () => {
y: screenHeight * 0.2, y: screenHeight * 0.2,
} }
const backgroundColor: [number, number, number] = [29, 29, 29] const backgroundColor: [number, number, number] = [29, 29, 29]
const xzPlaneColor: [number, number, number] = [82, 55, 96] const xzPlaneColor: [number, number, number] = [72, 55, 96]
const locationToHaveColor = async (color: [number, number, number]) => { const locationToHaveColor = async (color: [number, number, number]) => {
return u.getGreatestPixDiff(checkedScreenLocation, color) return u.getGreatestPixDiff(checkedScreenLocation, color)
} }
@ -26,9 +30,29 @@ test.describe('Test toggling perspective', () => {
const commandToast = page.getByText( const commandToast = page.getByText(
`Set camera projection to "orthographic"` `Set camera projection to "orthographic"`
) )
const projectionToggle = page.getByRole('switch', {
name: 'Camera projection: ', const checkSettingValue = async () => {
}) const settingsButton = page.getByRole('link', {
name: 'Settings',
exact: false,
})
let settingValue: string | null = null
await test.step(`Check the setting value`, async () => {
await settingsButton.click()
const userTab = page.getByRole('radio', { name: 'User' })
await userTab.click()
await expect(userTab).toBeChecked()
const setting = page.locator('#cameraProjection').first()
await expect(setting).toBeAttached()
await setting.scrollIntoViewIfNeeded()
settingValue = await setting.getByRole('combobox').inputValue()
await page.getByTestId('settings-close-button').click()
})
return settingValue
}
await test.step('Setup', async () => { await test.step('Setup', async () => {
await page.setBodyDimensions({ width: screenWidth, height: screenHeight }) await page.setBodyDimensions({ width: screenWidth, height: screenHeight })
@ -39,8 +63,8 @@ test.describe('Test toggling perspective', () => {
timeout: 5000, timeout: 5000,
message: 'This spot should have the background color', message: 'This spot should have the background color',
}) })
.toBeLessThan(15) .toBeLessThan(30)
await expect(projectionToggle).toHaveAttribute('aria-checked', 'true') expect(await checkSettingValue()).toBe('perspective')
}) })
// Extremely wild note: flicking between ortho and persp actually changes // Extremely wild note: flicking between ortho and persp actually changes
@ -59,33 +83,22 @@ test.describe('Test toggling perspective', () => {
timeout: 5000, timeout: 5000,
message: 'This spot should have the XZ plane color', message: 'This spot should have the XZ plane color',
}) })
.toBeLessThan(15) .toBeLessThan(30)
await expect(projectionToggle).toHaveAttribute('aria-checked', 'false') expect(await checkSettingValue()).toBe('orthographic')
}) })
await test.step(`Refresh the page and ensure the stream is loaded in ortho`, async () => { await test.step(`Refresh the page and ensure the stream is loaded in ortho`, async () => {
await page.reload() await page.reload()
await page.waitForTimeout(1000) await expect(toolbar.startSketchBtn).toBeEnabled({ timeout: 15_000 })
await u.closeKclCodePanel() await u.closeKclCodePanel()
await expect await expect
.poll(async () => locationToHaveColor(xzPlaneColor), { .poll(async () => locationToHaveColor(xzPlaneColor), {
timeout: 5000, timeout: 5000,
message: 'This spot should have the XZ plane color', message: 'This spot should have the XZ plane color',
}) })
.toBeLessThan(15) .toBeLessThan(30)
await expect(commandToast).not.toBeVisible() await expect(commandToast).not.toBeVisible()
await expect(projectionToggle).toHaveAttribute('aria-checked', 'false') expect(await checkSettingValue()).toBe('orthographic')
})
await test.step(`Switch to perspective via toggle`, async () => {
await projectionToggle.click()
await expect(projectionToggle).toHaveAttribute('aria-checked', 'true')
await expect
.poll(async () => locationToHaveColor(backgroundColor), {
timeout: 5000,
message: 'This spot should have the background color',
})
.toBeLessThan(15)
}) })
}) })
}) })

View File

@ -233,7 +233,7 @@
"ts-node": "^10.0.0", "ts-node": "^10.0.0",
"typescript": "^5.8.2", "typescript": "^5.8.2",
"typescript-eslint": "^8.26.1", "typescript-eslint": "^8.26.1",
"vite": "^5.4.16", "vite": "^5.4.17",
"vite-plugin-package-version": "^1.1.0", "vite-plugin-package-version": "^1.1.0",
"vite-plugin-top-level-await": "^1.5.0", "vite-plugin-top-level-await": "^1.5.0",
"vite-tsconfig-paths": "^4.3.2", "vite-tsconfig-paths": "^4.3.2",

View File

@ -683,9 +683,9 @@ vite-tsconfig-paths@^4.3.2:
tsconfck "^3.0.3" tsconfck "^3.0.3"
vite@^5.0.0: vite@^5.0.0:
version "5.4.16" version "5.4.17"
resolved "https://registry.yarnpkg.com/vite/-/vite-5.4.16.tgz#471983257a890ef33f2700cbbbc2134f2d08abf1" resolved "https://registry.yarnpkg.com/vite/-/vite-5.4.17.tgz#4bf61dd4cdbf64b0d6661f5dba76954cc81d5082"
integrity sha512-Y5gnfp4NemVfgOTDQAunSD4346fal44L9mszGGY/e+qxsRT5y1sMlS/8tiQ8AFAp+MFgYNSINdfEchJiPm41vQ== integrity sha512-5+VqZryDj4wgCs55o9Lp+p8GE78TLVg0lasCH5xFZ4jacZjtqZa6JUw9/p0WeAojaOfncSM6v77InkFPGnvPvg==
dependencies: dependencies:
esbuild "^0.21.3" esbuild "^0.21.3"
postcss "^8.4.43" postcss "^8.4.43"

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define function // Create a function to make the 80-20 rail
fn rail8020(originStart, railHeight, railLength) { fn rail8020(originStart, railHeight, railLength) {
// Sketch side 1 of profile // Sketch side 1 of profile
sketch001 = startSketchOn(-XZ) sketch001 = startSketchOn(-XZ)

View File

@ -25,8 +25,6 @@ When you submit a PR to add or modify KCL samples, images and STEP files will be
--- ---
#### [80-20-rail](80-20-rail/main.kcl) ([screenshot](screenshots/80-20-rail.png)) #### [80-20-rail](80-20-rail/main.kcl) ([screenshot](screenshots/80-20-rail.png))
[![80-20-rail](screenshots/80-20-rail.png)](80-20-rail/main.kcl) [![80-20-rail](screenshots/80-20-rail.png)](80-20-rail/main.kcl)
#### [a-parametric-bearing-pillow-block](a-parametric-bearing-pillow-block/main.kcl) ([screenshot](screenshots/a-parametric-bearing-pillow-block.png))
[![a-parametric-bearing-pillow-block](screenshots/a-parametric-bearing-pillow-block.png)](a-parametric-bearing-pillow-block/main.kcl)
#### [ball-bearing](ball-bearing/main.kcl) ([screenshot](screenshots/ball-bearing.png)) #### [ball-bearing](ball-bearing/main.kcl) ([screenshot](screenshots/ball-bearing.png))
[![ball-bearing](screenshots/ball-bearing.png)](ball-bearing/main.kcl) [![ball-bearing](screenshots/ball-bearing.png)](ball-bearing/main.kcl)
#### [bench](bench/main.kcl) ([screenshot](screenshots/bench.png)) #### [bench](bench/main.kcl) ([screenshot](screenshots/bench.png))
@ -83,6 +81,8 @@ When you submit a PR to add or modify KCL samples, images and STEP files will be
[![mounting-plate](screenshots/mounting-plate.png)](mounting-plate/main.kcl) [![mounting-plate](screenshots/mounting-plate.png)](mounting-plate/main.kcl)
#### [multi-axis-robot](multi-axis-robot/main.kcl) ([screenshot](screenshots/multi-axis-robot.png)) #### [multi-axis-robot](multi-axis-robot/main.kcl) ([screenshot](screenshots/multi-axis-robot.png))
[![multi-axis-robot](screenshots/multi-axis-robot.png)](multi-axis-robot/main.kcl) [![multi-axis-robot](screenshots/multi-axis-robot.png)](multi-axis-robot/main.kcl)
#### [parametric-bearing-pillow-block](parametric-bearing-pillow-block/main.kcl) ([screenshot](screenshots/parametric-bearing-pillow-block.png))
[![parametric-bearing-pillow-block](screenshots/parametric-bearing-pillow-block.png)](parametric-bearing-pillow-block/main.kcl)
#### [pipe](pipe/main.kcl) ([screenshot](screenshots/pipe.png)) #### [pipe](pipe/main.kcl) ([screenshot](screenshots/pipe.png))
[![pipe](screenshots/pipe.png)](pipe/main.kcl) [![pipe](screenshots/pipe.png)](pipe/main.kcl)
#### [pipe-flange-assembly](pipe-flange-assembly/main.kcl) ([screenshot](screenshots/pipe-flange-assembly.png)) #### [pipe-flange-assembly](pipe-flange-assembly/main.kcl) ([screenshot](screenshots/pipe-flange-assembly.png))

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants like ball diameter, inside diamter, overhange length, and thickness // Define parameters
outsideDiameter = 1.625 outsideDiameter = 1.625
sphereDia = 0.25 sphereDia = 0.25
shaftDia = 0.75 shaftDia = 0.75
@ -95,5 +95,3 @@ outsideWallSketch = startSketchOn(offsetPlane(XY, offset = -overallThickness / 2
|> hole(circle(center = [0, 0], radius = shaftDia / 2 + wallThickness + sphereDia), %) |> hole(circle(center = [0, 0], radius = shaftDia / 2 + wallThickness + sphereDia), %)
outsideWall = extrude(outsideWallSketch, length = overallThickness) outsideWall = extrude(outsideWallSketch, length = overallThickness)
// https://www.mcmaster.com/60355K185/

View File

@ -4,8 +4,8 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import Constants // Import parameters
import caliperTolerance, caliperPadLength, caliperThickness, caliperOuterEdgeRadius, caliperInnerEdgeRadius, rotorDiameter, rotorTotalThickness, yAxisOffset from "globals.kcl" import caliperTolerance, caliperPadLength, caliperThickness, caliperOuterEdgeRadius, caliperInnerEdgeRadius, rotorDiameter, rotorTotalThickness, yAxisOffset from "parameters.kcl"
// Sketch the brake caliper profile // Sketch the brake caliper profile
brakeCaliperSketch = startSketchOn(XY) brakeCaliperSketch = startSketchOn(XY)

View File

@ -4,8 +4,8 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import Constants // Import parameters
import rotorDiameter, rotorInnerDiameter, rotorSinglePlateThickness, rotorInnerDiameterThickness, lugHolePatternDia, lugSpacing, rotorTotalThickness, spacerPatternDiameter, spacerDiameter, spacerLength, spacerCount, wheelDiameter, lugCount, yAxisOffset, drillAndSlotCount from "globals.kcl" import rotorDiameter, rotorInnerDiameter, rotorSinglePlateThickness, rotorInnerDiameterThickness, lugHolePatternDia, lugSpacing, rotorTotalThickness, spacerPatternDiameter, spacerDiameter, spacerLength, spacerCount, wheelDiameter, lugCount, yAxisOffset, drillAndSlotCount from "parameters.kcl"
rotorSketch = startSketchOn(XZ) rotorSketch = startSketchOn(XZ)
|> circle(center = [0, 0], radius = rotorDiameter / 2) |> circle(center = [0, 0], radius = rotorDiameter / 2)

View File

@ -4,8 +4,8 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import Constants // Import parameters
import tireInnerDiameter, tireOuterDiameter, tireDepth, bendRadius, tireTreadWidth, tireTreadDepth, tireTreadOffset from "globals.kcl" import tireInnerDiameter, tireOuterDiameter, tireDepth, bendRadius, tireTreadWidth, tireTreadDepth, tireTreadOffset from "parameters.kcl"
// Create the sketch of the tire // Create the sketch of the tire
tireSketch = startSketchOn(XY) tireSketch = startSketchOn(XY)

View File

@ -4,8 +4,8 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import Constants // Import parameters
import lugCount, lugSpacing, offset, backSpacing, wheelWidth, wheelDiameter, spokeCount, spokeGap, spokeAngle, spokeThickness from "globals.kcl" import lugCount, lugSpacing, offset, backSpacing, wheelWidth, wheelDiameter, spokeCount, spokeGap, spokeAngle, spokeThickness from "parameters.kcl"
// Create the wheel center // Create the wheel center
lugBase = startSketchOn(XZ) lugBase = startSketchOn(XZ)

View File

@ -4,8 +4,8 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import Constants // Import parameters
import lugDiameter, lugHeadLength, lugThreadDiameter, lugLength, lugThreadDepth, lugSpacing from "globals.kcl" import lugDiameter, lugHeadLength, lugThreadDiameter, lugLength, lugThreadDepth, lugSpacing from "parameters.kcl"
customPlane = { customPlane = {
plane = { plane = {

View File

@ -4,16 +4,24 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import parts
import "car-wheel.kcl" as carWheel import "car-wheel.kcl" as carWheel
import "car-rotor.kcl" as carRotor import "car-rotor.kcl" as carRotor
import "brake-caliper.kcl" as brakeCaliper import "brake-caliper.kcl" as brakeCaliper
import "lug-nut.kcl" as lugNut import "lug-nut.kcl" as lugNut
import "car-tire.kcl" as carTire import "car-tire.kcl" as carTire
import lugCount from "globals.kcl"
// Import parameters
import * from "parameters.kcl"
// Place the car rotor
carRotor carRotor
|> translate(x = 0, y = 0.5, z = 0) |> translate(x = 0, y = 0.5, z = 0)
// Place the car wheel
carWheel carWheel
// Place the lug nuts
lugNut lugNut
|> patternCircular3d( |> patternCircular3d(
arcDegrees = 360, arcDegrees = 360,
@ -22,6 +30,10 @@ lugNut
instances = lugCount, instances = lugCount,
rotateDuplicates = false, rotateDuplicates = false,
) )
// Place the brake caliper
brakeCaliper brakeCaliper
|> translate(x = 0, y = 0.5, z = 0) |> translate(x = 0, y = 0.5, z = 0)
// Place the car tire
carTire carTire

View File

@ -1,9 +1,9 @@
// Car wheel assembly global constants // Car wheel assembly parameters
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Car Wheel // Car wheel
export lugCount = 5 export lugCount = 5
export lugSpacing = 114.3 * mm() export lugSpacing = 114.3 * mm()
export offset = -35 * mm() export offset = -35 * mm()
@ -22,7 +22,7 @@ export lugThreadDiameter = lugDiameter / 2 * .85
export lugLength = 30 * mm() export lugLength = 30 * mm()
export lugThreadDepth = lugLength - (12.7 * mm()) export lugThreadDepth = lugLength - (12.7 * mm())
// Car Rotor // Car rotor
export rotorDiameter = 12 export rotorDiameter = 12
export rotorInnerDiameter = 6 export rotorInnerDiameter = 6
export rotorSinglePlateThickness = 0.25 export rotorSinglePlateThickness = 0.25
@ -36,7 +36,7 @@ export spacerCount = 16
export yAxisOffset = 0.5 export yAxisOffset = 0.5
export drillAndSlotCount = 5 export drillAndSlotCount = 5
// Car Tire // Car tire
export tireInnerDiameter = 19 export tireInnerDiameter = 19
export tireOuterDiameter = 24 export tireOuterDiameter = 24
export tireDepth = 11.02 export tireDepth = 11.02
@ -45,7 +45,7 @@ export tireTreadWidth = 0.39
export tireTreadDepth = 0.39 export tireTreadDepth = 0.39
export tireTreadOffset = 3.15 export tireTreadOffset = 3.15
// Brake Caliper // Brake caliper
export caliperTolerance = 0.050 export caliperTolerance = 0.050
export caliperPadLength = 1.6 export caliperPadLength = 1.6
export caliperThickness = 0.39 export caliperThickness = 0.39

View File

@ -1,10 +1,10 @@
// Color Cube // Color Cube
// This is a color cube centered about the origin. It is used to help determine orientation in the scene. // This is a color cube centered about the origin. It is used to help determine orientation in the scene.
// Set unit // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Globals referenced in drawRectangle // Parameters referenced in drawRectangle
size = 100 size = 100
halfSize = size / 2 halfSize = size / 2
extrudeLength = 1.0 extrudeLength = 1.0

View File

@ -1,9 +1,10 @@
// Cycloidal Gear // Cycloidal Gear
// A cycloidal gear is a gear with a continuous, curved tooth profile. They are used in watchmaking and high precision robotics actuation // A cycloidal gear is a gear with a continuous, curved tooth profile. They are used in watchmaking and high precision robotics actuation
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Create a function for the cycloidal gear
fn cycloidalGear(gearPitch, gearHeight, holeDiameter, helixAngle) { fn cycloidalGear(gearPitch, gearHeight, holeDiameter, helixAngle) {
// Create a function to draw the gear profile as a sketch. Rotate each profile about the gear's axis by an helix angle proportional to the total gear height // Create a function to draw the gear profile as a sketch. Rotate each profile about the gear's axis by an helix angle proportional to the total gear height
fn gearSketch(gHeight) { fn gearSketch(gHeight) {
@ -44,4 +45,5 @@ fn cycloidalGear(gearPitch, gearHeight, holeDiameter, helixAngle) {
return gearLoft return gearLoft
} }
// Call the cycloidal gear function
cycloidalGear(.3, 1.5, 0.297, -80) cycloidalGear(.3, 1.5, 0.297, -80)

View File

@ -9,19 +9,19 @@
circR = 25 circR = 25
// Calculated parameters // Calculated parameters
// thickness of the dodecahedron // Thickness of the dodecahedron
wallThickness = circR * 0.2 wallThickness = circR * 0.2
// angle between faces in radians // Angle between faces in radians
dihedral = acos(-(sqrt(5) / 5)) dihedral = acos(-(sqrt(5) / 5))
// inscribed radius // Inscribed radius
inscR = circR / 15 * sqrt(75 + 30 * sqrt(5)) inscR = circR / 15 * sqrt(75 + 30 * sqrt(5))
// pentagon edge length // Pentagon edge length
edgeL = 4 * circR / (sqrt(3) * (1 + sqrt(5))) edgeL = 4 * circR / (sqrt(3) * (1 + sqrt(5)))
// pentagon radius // Pentagon radius
pentR = edgeL / 2 / sin(toRadians(36)) pentR = edgeL / 2 / sin(toRadians(36))
// Define a plane for the bottom angled face // Define a plane for the bottom angled face
@ -69,7 +69,7 @@ bottomBowl = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// pattern the bottom to create the top face // Pattern the bottom to create the top face
patternCircular3d( patternCircular3d(
bottom, bottom,
instances = 2, instances = 2,
@ -79,7 +79,7 @@ patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// pattern the bottom angled faces to create the top // Pattern the bottom angled faces to create the top
patternCircular3d( patternCircular3d(
bottomBowl, bottomBowl,
instances = 2, instances = 2,

View File

@ -1,10 +1,10 @@
// Dual-Basin Utility Sink // Dual-Basin Utility Sink
// A stainless steel sink unit with dual rectangular basins and six under-counter storage compartments. // A stainless steel sink unit with dual rectangular basins and six under-counter storage compartments.
// set units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// globals // Define parameters
tableHeight = 850 tableHeight = 850
tableWidth = 3400 tableWidth = 3400
tableDepth = 400 tableDepth = 400

View File

@ -4,6 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define parameters
length = 175 length = 175
width = 125 width = 125
height = 70 height = 70

View File

@ -1,10 +1,10 @@
// Exhaust Manifold // Exhaust Manifold
// A welded exhaust header for an inline 4-cylinder engine // A welded exhaust header for an inline 4-cylinder engine
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define Constants // Define parameters
primaryTubeDiameter = 1.625 primaryTubeDiameter = 1.625
wallThickness = 0.080 wallThickness = 0.080
plateHeight = 0.125 plateHeight = 0.125

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
mountingHoleDia = .625 mountingHoleDia = .625
baseDia = 4.625 baseDia = 4.625
pipeDia = 1.25 pipeDia = 1.25

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// define constants in mm // define parameters
radius = 6.0 radius = 6.0
width = 144.0 width = 144.0
length = 80.0 length = 80.0
@ -15,7 +15,7 @@ tabLength = 25
tabWidth = 12 tabWidth = 12
tabThk = 4 tabThk = 4
// define a rectangular shape func // Define a rectangular shape func
fn rectShape(pos, w, l) { fn rectShape(pos, w, l) {
rr = startSketchOn('xy') rr = startSketchOn('xy')
|> startProfileAt([pos[0] - (w / 2), pos[1] - (l / 2)], %) |> startProfileAt([pos[0] - (w / 2), pos[1] - (l / 2)], %)
@ -26,7 +26,7 @@ fn rectShape(pos, w, l) {
return rr return rr
} }
// define the bracket plane // Define the bracket plane
bracketPlane = { bracketPlane = {
plane = { plane = {
origin = { x = 0, y = length / 2 + thk, z = 0 }, origin = { x = 0, y = length / 2 + thk, z = 0 },
@ -36,7 +36,7 @@ bracketPlane = {
} }
} }
// build the bracket sketch around the body // Build the bracket sketch around the body
fn bracketSketch(w, d, t) { fn bracketSketch(w, d, t) {
s = startSketchOn(bracketPlane) s = startSketchOn(bracketPlane)
|> startProfileAt([-w / 2 - t, d + t], %) |> startProfileAt([-w / 2 - t, d + t], %)
@ -51,7 +51,7 @@ fn bracketSketch(w, d, t) {
return s return s
} }
// build the body of the bracket // Build the body of the bracket
bs = bracketSketch(width, depth, thk) bs = bracketSketch(width, depth, thk)
bracketBody = bs bracketBody = bs
|> extrude(length = length + 2 * thk) |> extrude(length = length + 2 * thk)
@ -65,7 +65,7 @@ bracketBody = bs
], ],
) )
// define the tab plane // Define the tab plane
tabPlane = { tabPlane = {
plane = { plane = {
origin = { x = 0, y = 0, z = depth + thk }, origin = { x = 0, y = 0, z = depth + thk },
@ -75,7 +75,7 @@ tabPlane = {
} }
} }
// build the tabs of the mounting bracket (right side) // Build the tabs of the mounting bracket (right side)
tabsR = startSketchOn(tabPlane) tabsR = startSketchOn(tabPlane)
|> startProfileAt([width / 2 + thk, length / 2 + thk], %) |> startProfileAt([width / 2 + thk, length / 2 + thk], %)
|> line(end = [tabWidth, -tabLength / 3], tag = $edge11) |> line(end = [tabWidth, -tabLength / 3], tag = $edge11)
@ -99,7 +99,7 @@ tabsR = startSketchOn(tabPlane)
) )
|> patternLinear3d(axis = [0, -1, 0], instances = 2, distance = length + 2 * thk - (tabLength * 4 / 3)) |> patternLinear3d(axis = [0, -1, 0], instances = 2, distance = length + 2 * thk - (tabLength * 4 / 3))
// build the tabs of the mounting bracket (left side) // Build the tabs of the mounting bracket (left side)
tabsL = startSketchOn(tabPlane) tabsL = startSketchOn(tabPlane)
|> startProfileAt([-width / 2 - thk, length / 2 + thk], %) |> startProfileAt([-width / 2 - thk, length / 2 + thk], %)
|> line(end = [-tabWidth, -tabLength / 3], tag = $edge21) |> line(end = [-tabWidth, -tabLength / 3], tag = $edge21)
@ -123,7 +123,7 @@ tabsL = startSketchOn(tabPlane)
) )
|> patternLinear3d(axis = [0, -1, 0], instances = 2, distance = length + 2 * thk - (tabLength * 4 / 3)) |> patternLinear3d(axis = [0, -1, 0], instances = 2, distance = length + 2 * thk - (tabLength * 4 / 3))
// define a plane for retention bumps // Define a plane for retention bumps
retPlane = { retPlane = {
plane = { plane = {
origin = { x = -width / 2 + 20, y = 0, z = 0 }, origin = { x = -width / 2 + 20, y = 0, z = 0 },
@ -133,7 +133,7 @@ retPlane = {
} }
} }
// build the retention bump in the front // Build the retention bump in the front
retFront = startSketchOn(retPlane) retFront = startSketchOn(retPlane)
|> startProfileAt([-length / 2 - thk, 0], %) |> startProfileAt([-length / 2 - thk, 0], %)
|> line(end = [0, thk]) |> line(end = [0, thk])
@ -141,7 +141,7 @@ retFront = startSketchOn(retPlane)
|> close() |> close()
|> extrude(length = width - 40) |> extrude(length = width - 40)
// build the retention bump in the back // Build the retention bump in the back
retBack = startSketchOn(retPlane) retBack = startSketchOn(retPlane)
|> startProfileAt([length / 2 + thk, 0], %) |> startProfileAt([length / 2 + thk, 0], %)
|> line(end = [0, thk]) |> line(end = [0, thk])

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants in millimeters (mm) // Define parameters
flipperThickness = 3.5 flipperThickness = 3.5
flipperLength = 70.0 flipperLength = 70.0
handleWidth = 15.0 handleWidth = 15.0
@ -16,7 +16,7 @@ gripHeight = 20.0
gripFilletRadius = 3.0 gripFilletRadius = 3.0
gripSlotWidth = 8.0 gripSlotWidth = 8.0
// function for drawing slots on a sketch given the start and end points as well as a width // Function for drawing slots on a sketch given the start and end points as well as a width
fn slot(sketch1, start, end, width) { fn slot(sketch1, start, end, width) {
angle = if start[0] == end[0] { angle = if start[0] == end[0] {
if end[1] > start[1] { if end[1] > start[1] {
@ -43,10 +43,10 @@ fn slot(sketch1, start, end, width) {
return slotSketch return slotSketch
} }
// create a sketch on the "XY" plane // Create a sketch on the "XY" plane
sketch000 = startSketchOn(XY) sketch000 = startSketchOn(XY)
// create a profile of the flipper // Create a profile of the flipper
flipperProfile = startProfileAt([-flipperLength, -32.0], sketch000) flipperProfile = startProfileAt([-flipperLength, -32.0], sketch000)
|> line(end = [flipperLength, 2.0]) |> line(end = [flipperLength, 2.0])
|> yLine(length = 60.0, tag = $backEdge) |> yLine(length = 60.0, tag = $backEdge)
@ -58,25 +58,25 @@ flipperProfile = startProfileAt([-flipperLength, -32.0], sketch000)
}, %) }, %)
|> close() |> close()
// create a profile of the middle // Create a profile of the middle
slotProfile000 = slot(sketch000, [-25, 0], [-55, 0], flipperSlotWidth) slotProfile000 = slot(sketch000, [-25, 0], [-55, 0], flipperSlotWidth)
// create a profile of the top slot // Create a profile of the top slot
slotProfile001 = slot(sketch000, [-25, 18], [-55, 19], flipperSlotWidth) slotProfile001 = slot(sketch000, [-25, 18], [-55, 19], flipperSlotWidth)
// create a profile of the bottom slot // Create a profile of the bottom slot
slotProfile002 = slot(sketch000, [-25, -18], [-55, -19], flipperSlotWidth) slotProfile002 = slot(sketch000, [-25, -18], [-55, -19], flipperSlotWidth)
// create a profile with slots for the spatula // Create a profile with slots for the spatula
spatulaProfile = flipperProfile spatulaProfile = flipperProfile
|> hole(slotProfile000, %) |> hole(slotProfile000, %)
|> hole(slotProfile001, %) |> hole(slotProfile001, %)
|> hole(slotProfile002, %) |> hole(slotProfile002, %)
// extrude the profile to create the spatula flipper // Extrude the profile to create the spatula flipper
flipper = extrude(spatulaProfile, length = flipperThickness) flipper = extrude(spatulaProfile, length = flipperThickness)
// fillet the edges of the flipper // Fillet the edges of the flipper
fillet( fillet(
flipper, flipper,
radius = flipperFilletRadius, radius = flipperFilletRadius,
@ -86,10 +86,10 @@ fillet(
], ],
) )
// create a sketch on the "XZ" plane offset by half the thickness // Create a sketch on the "XZ" plane offset by half the thickness
sketch001 = startSketchOn(offsetPlane(XZ, offset = -handleWidth / 2)) sketch001 = startSketchOn(offsetPlane(XZ, offset = -handleWidth / 2))
// create a profile of the spatula handle // Create a profile of the spatula handle
handleProfile = startProfileAt([0.0, flipperThickness], sketch001) handleProfile = startProfileAt([0.0, flipperThickness], sketch001)
|> line(end = [31.819805, 31.819805], tag = $handleBottomEdge) |> line(end = [31.819805, 31.819805], tag = $handleBottomEdge)
|> line(end = [140.953893, 51.303021]) |> line(end = [140.953893, 51.303021])
@ -99,10 +99,10 @@ handleProfile = startProfileAt([0.0, flipperThickness], sketch001)
|> xLine(length = 7.071068) |> xLine(length = 7.071068)
|> close() |> close()
// create an extrusion extrude001 // Create an extrusion extrude001
handle = extrude(handleProfile, length = handleWidth) handle = extrude(handleProfile, length = handleWidth)
// fillet the bend of the spatula handle // Fillet the bend of the spatula handle
fillet( fillet(
handle, handle,
radius = 4, radius = 4,
@ -112,7 +112,7 @@ fillet(
], ],
) )
// define a plane which is at the end of the handle // Define a plane which is at the end of the handle
handlePlane = { handlePlane = {
plane = { plane = {
origin = [208.593833, 0.0, 75.921946], origin = [208.593833, 0.0, 75.921946],
@ -122,10 +122,10 @@ handlePlane = {
} }
} }
// create a sketch on the handle plane // Create a sketch on the handle plane
sketch002 = startSketchOn(handlePlane) sketch002 = startSketchOn(handlePlane)
// create a profile of the grip // Create a profile of the grip
gripProfile = startProfileAt([-26.806746, -10.0], sketch002) gripProfile = startProfileAt([-26.806746, -10.0], sketch002)
|> xLine(length = gripWidth - (2 * gripFilletRadius)) |> xLine(length = gripWidth - (2 * gripFilletRadius))
|> arc({ |> arc({
@ -153,14 +153,14 @@ gripProfile = startProfileAt([-26.806746, -10.0], sketch002)
}, %) }, %)
|> close() |> close()
// extrude the grip profile to create the grip // Extrude the grip profile to create the grip
grip = extrude(gripProfile, length = -gripLength) grip = extrude(gripProfile, length = -gripLength)
// create a sketch on the grip for the hole // Create a sketch on the grip for the hole
sketch003 = startSketchOn(grip, gripEdgeTop) sketch003 = startSketchOn(grip, gripEdgeTop)
// create a profile for the grip hole // Create a profile for the grip hole
gripHoleProfile = slot(sketch003, [0, 200], [0, 210], gripSlotWidth) gripHoleProfile = slot(sketch003, [0, 200], [0, 210], gripSlotWidth)
// cut a hole in the grip // Cut a hole in the grip
extrude(gripHoleProfile, length = -gripWidth - 20) extrude(gripHoleProfile, length = -gripWidth - 20)

View File

@ -4,7 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
carafeDiameter = 4.41 carafeDiameter = 4.41
carafeHeight = 7.32 carafeHeight = 7.32
handleThickness = 0.65 handleThickness = 0.65

View File

@ -1,10 +1,10 @@
// 100mm Gear Rack // 100mm Gear Rack
// A flat bar or rail that is engraved with teeth along its length. These teeth are designed to mesh with the teeth of a gear, known as a pinion. When the pinion, a small cylindrical gear, rotates, its teeth engage with the teeth on the rack, causing the rack to move linearly. Conversely, linear motion applied to the rack will cause the pinion to rotate. // A flat bar or rail that is engraved with teeth along its length. These teeth are designed to mesh with the teeth of a gear, known as a pinion. When the pinion, a small cylindrical gear, rotates, its teeth engage with the teeth on the rack, causing the rack to move linearly. Conversely, linear motion applied to the rack will cause the pinion to rotate.
// Set Units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
length = 100 length = 100
pitchHeight = 11.5 pitchHeight = 11.5
width = 5 width = 5

View File

@ -1,10 +1,10 @@
// Spur Gear // Spur Gear
// A rotating machine part having cut teeth or, in the case of a cogwheel, inserted teeth (called cogs), which mesh with another toothed part to transmit torque. Geared devices can change the speed, torque, and direction of a power source. The two elements that define a gear are its circular shape and the teeth that are integrated into its outer edge, which are designed to fit into the teeth of another gear. // A rotating machine part having cut teeth or, in the case of a cogwheel, inserted teeth (called cogs), which mesh with another toothed part to transmit torque. Geared devices can change the speed, torque, and direction of a power source. The two elements that define a gear are its circular shape and the teeth that are integrated into its outer edge, which are designed to fit into the teeth of another gear.
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
nTeeth = 21 nTeeth = 21
module = 0.5 module = 0.5
pitchDiameter = module * nTeeth pitchDiameter = module * nTeeth

View File

@ -4,7 +4,7 @@
// Set units in millimeters (mm) // Set units in millimeters (mm)
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
binLength = 42.0 binLength = 42.0
cornerRadius = 4.0 cornerRadius = 4.0
firstStep = 0.7 firstStep = 0.7
@ -21,7 +21,7 @@ countBinLength = 3
// The total height of the baseplate is a summation of the vertical heights of the baseplate steps // The total height of the baseplate is a summation of the vertical heights of the baseplate steps
height = firstStep + secondStep + thirdStep height = firstStep + secondStep + thirdStep
// define a function which builds the profile of the baseplate bin // Define a function which builds the profile of the baseplate bin
fn face(plane) { fn face(plane) {
faceSketch = startSketchOn(plane) faceSketch = startSketchOn(plane)
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
@ -33,10 +33,10 @@ fn face(plane) {
return faceSketch return faceSketch
} }
// extrude a single side of the bin // Extrude a single side of the bin
singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius)), length = binLength - (cornerRadius * 2)) singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius)), length = binLength - (cornerRadius * 2))
// create the other sides of the bin by using a circular pattern // Create the other sides of the bin by using a circular pattern
sides = patternCircular3d( sides = patternCircular3d(
singleSide, singleSide,
arcDegrees = 360, arcDegrees = 360,
@ -46,16 +46,16 @@ sides = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// define an axis axis000 // Define an axis axis000
axis000 = { axis000 = {
direction = [0.0, 1.0], direction = [0.0, 1.0],
origin = [cornerRadius, cornerRadius] origin = [cornerRadius, cornerRadius]
} }
// create a single corner of the bin // Create a single corner of the bin
singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius)), angle = -90, axis = axis000) singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius)), angle = -90, axis = axis000)
// create the corners of the bin // Create the corners of the bin
corners = patternCircular3d( corners = patternCircular3d(
singleCorner, singleCorner,
arcDegrees = 360, arcDegrees = 360,
@ -65,7 +65,7 @@ corners = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// create the baseplate by patterning sides // Create the baseplate by patterning sides
basePlateSides = patternLinear3d( basePlateSides = patternLinear3d(
sides, sides,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -74,7 +74,7 @@ basePlateSides = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength)
// create the corners of the baseplate by patterning the corners // Create the corners of the baseplate by patterning the corners
basePlateCorners = patternLinear3d( basePlateCorners = patternLinear3d(
corners, corners,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -83,7 +83,7 @@ basePlateCorners = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength)
// create the center cutout for the magnet profile // Create the center cutout for the magnet profile
fn magnetCenterCutout(plane) { fn magnetCenterCutout(plane) {
magnetSketch = startSketchOn(plane) magnetSketch = startSketchOn(plane)
|> startProfileAt([ |> startProfileAt([
@ -126,7 +126,7 @@ fn magnetCenterCutout(plane) {
return magnetSketch return magnetSketch
} }
// create the outside profile of the magnets // Create the outside profile of the magnets
fn magnetBase(plane) { fn magnetBase(plane) {
magnetBaseSketch = startSketchOn(plane) magnetBaseSketch = startSketchOn(plane)
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
@ -138,7 +138,7 @@ fn magnetBase(plane) {
return magnetBaseSketch return magnetBaseSketch
} }
// create sketch profile sketch000Profile002 // Create sketch profile sketch000Profile002
magnetsSketch = startSketchOn(XY) magnetsSketch = startSketchOn(XY)
|> circle(center = [cornerRadius * 2, cornerRadius * 2], radius = magOuterDiam / 2) |> circle(center = [cornerRadius * 2, cornerRadius * 2], radius = magOuterDiam / 2)
|> patternCircular2d( |> patternCircular2d(
@ -148,14 +148,14 @@ magnetsSketch = startSketchOn(XY)
rotateDuplicates = true, rotateDuplicates = true,
) )
// create a profile with holes for the magnets // Create a profile with holes for the magnets
magnetProfile = magnetBase(XY) magnetProfile = magnetBase(XY)
|> hole(magnetsSketch, %) |> hole(magnetsSketch, %)
// create an extrusion of the magnet cutout with holes // Create an extrusion of the magnet cutout with holes
magnetHolesExtrude = extrude(magnetProfile, length = -magDepth) magnetHolesExtrude = extrude(magnetProfile, length = -magDepth)
// add a fillet to the extrusion // Add a fillet to the extrusion
magnetHolesExtrudeFillets = fillet( magnetHolesExtrudeFillets = fillet(
magnetHolesExtrude, magnetHolesExtrude,
radius = cornerRadius, radius = cornerRadius,
@ -167,13 +167,13 @@ magnetHolesExtrudeFillets = fillet(
], ],
) )
// create a profile without the holes for the magnets // Create a profile without the holes for the magnets
magnetProfileNoMagnets = magnetBase(offsetPlane(XY, offset = -magDepth)) magnetProfileNoMagnets = magnetBase(offsetPlane(XY, offset = -magDepth))
// create an extrusion of the magnet cutout without holes // Create an extrusion of the magnet cutout without holes
magnetCutoutExtrude = extrude(magnetProfileNoMagnets, length = -magDepth) magnetCutoutExtrude = extrude(magnetProfileNoMagnets, length = -magDepth)
// add a fillet to the extrusion // Add a fillet to the extrusion
magnetCutoutExtrudeFillets = fillet( magnetCutoutExtrudeFillets = fillet(
magnetCutoutExtrude, magnetCutoutExtrude,
radius = cornerRadius, radius = cornerRadius,
@ -185,7 +185,7 @@ magnetCutoutExtrudeFillets = fillet(
], ],
) )
// pattern the magnet cutouts with holes // Pattern the magnet cutouts with holes
patternLinear3d( patternLinear3d(
magnetHolesExtrudeFillets, magnetHolesExtrudeFillets,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -194,7 +194,7 @@ patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength)
// pattern the magnet cutouts without holes // Pattern the magnet cutouts without holes
patternLinear3d( patternLinear3d(
magnetCutoutExtrudeFillets, magnetCutoutExtrudeFillets,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],

View File

@ -4,7 +4,7 @@
// Set units in millimeters (mm) // Set units in millimeters (mm)
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
binLength = 42.0 binLength = 42.0
cornerRadius = 4.0 cornerRadius = 4.0
firstStep = 0.7 firstStep = 0.7
@ -18,7 +18,7 @@ countBinLength = 3
// The total height of the baseplate is a summation of the vertical heights of the baseplate steps // The total height of the baseplate is a summation of the vertical heights of the baseplate steps
height = firstStep + secondStep + thirdStep height = firstStep + secondStep + thirdStep
// define a function which builds the profile of the baseplate bin // Define a function which builds the profile of the baseplate bin
fn face(plane) { fn face(plane) {
faceSketch = startSketchOn(plane) faceSketch = startSketchOn(plane)
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
@ -30,10 +30,10 @@ fn face(plane) {
return faceSketch return faceSketch
} }
// extrude a single side of the bin // Extrude a single side of the bin
singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius)), length = binLength - (cornerRadius * 2)) singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius)), length = binLength - (cornerRadius * 2))
// create the other sides of the bin by using a circular pattern // Create the other sides of the bin by using a circular pattern
sides = patternCircular3d( sides = patternCircular3d(
singleSide, singleSide,
arcDegrees = 360, arcDegrees = 360,
@ -43,16 +43,16 @@ sides = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// define an axis axis000 // Define an axis axis000
axis000 = { axis000 = {
direction = [0.0, 1.0], direction = [0.0, 1.0],
origin = [cornerRadius, cornerRadius] origin = [cornerRadius, cornerRadius]
} }
// create a single corner of the bin // Create a single corner of the bin
singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius)), angle = -90, axis = axis000) singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius)), angle = -90, axis = axis000)
// create the corners of the bin // Create the corners of the bin
corners = patternCircular3d( corners = patternCircular3d(
singleCorner, singleCorner,
arcDegrees = 360, arcDegrees = 360,
@ -62,7 +62,7 @@ corners = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// create the baseplate by patterning sides // Create the baseplate by patterning sides
basePlateSides = patternLinear3d( basePlateSides = patternLinear3d(
sides, sides,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -71,7 +71,7 @@ basePlateSides = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength)
// create the corners of the baseplate by patterning the corners // Create the corners of the baseplate by patterning the corners
basePlateCorners = patternLinear3d( basePlateCorners = patternLinear3d(
corners, corners,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],

View File

@ -4,7 +4,7 @@
// Set units in millimeters (mm) // Set units in millimeters (mm)
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
binLength = 41.5 binLength = 41.5
binHeight = 7.0 binHeight = 7.0
binBaseLength = 2.95 binBaseLength = 2.95
@ -33,7 +33,7 @@ countBinHeight = 1
height = firstStep + secondStep + thirdStep height = firstStep + secondStep + thirdStep
lipHeight = lipStep1 + lipStep2 + lipStep3 + lipStep4 + lipStep5 lipHeight = lipStep1 + lipStep2 + lipStep3 + lipStep4 + lipStep5
// define a function which builds the profile of the baseplate bin // Define a function which builds the profile of the baseplate bin
fn face(plane) { fn face(plane) {
faceSketch = startSketchOn(plane) faceSketch = startSketchOn(plane)
|> startProfileAt([binBaseLength + binTol, 0], %) |> startProfileAt([binBaseLength + binTol, 0], %)
@ -46,10 +46,10 @@ fn face(plane) {
return faceSketch return faceSketch
} }
// extrude a single side of the bin // Extrude a single side of the bin
singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius + binTol)), length = binLength - (cornerRadius * 2)) singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius + binTol)), length = binLength - (cornerRadius * 2))
// create the other sides of the bin by using a circular pattern // Create the other sides of the bin by using a circular pattern
sides = patternCircular3d( sides = patternCircular3d(
singleSide, singleSide,
arcDegrees = 360, arcDegrees = 360,
@ -63,7 +63,7 @@ sides = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// define an axis axis000 // Define an axis axis000
axis000 = { axis000 = {
direction = [0.0, 1.0], direction = [0.0, 1.0],
origin = [ origin = [
@ -72,10 +72,10 @@ axis000 = {
] ]
} }
// create a single corner of the bin // Create a single corner of the bin
singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius + binTol)), angle = -90, axis = axis000) singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius + binTol)), angle = -90, axis = axis000)
// create the corners of the bin // Create the corners of the bin
corners = patternCircular3d( corners = patternCircular3d(
singleCorner, singleCorner,
arcDegrees = 360, arcDegrees = 360,
@ -128,7 +128,7 @@ magCutout000 = startSketchOn(singleBinFill, "start")
) )
|> extrude(length = -magDepth) |> extrude(length = -magDepth)
// create the baseplate by patterning sides // Create the baseplate by patterning sides
binSides = patternLinear3d( binSides = patternLinear3d(
sides, sides,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -137,7 +137,7 @@ binSides = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
// create the corners of the baseplate by patterning the corners // Create the corners of the baseplate by patterning the corners
binCorners = patternLinear3d( binCorners = patternLinear3d(
corners, corners,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -146,7 +146,7 @@ binCorners = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
// create the fill of the bin by patterning the corners // Create the fill of the bin by patterning the corners
binFill = patternLinear3d( binFill = patternLinear3d(
singleBinFill, singleBinFill,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -155,7 +155,6 @@ binFill = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
//
binTop = startSketchOn(offsetPlane(XY, offset = height)) binTop = startSketchOn(offsetPlane(XY, offset = height))
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
|> xLine(length = (binLength + 2 * binTol) * countBinWidth, tag = $line010) |> xLine(length = (binLength + 2 * binTol) * countBinWidth, tag = $line010)
@ -174,7 +173,7 @@ binTop = startSketchOn(offsetPlane(XY, offset = height))
) )
|> shell(faces = ["end"], thickness = binThk) |> shell(faces = ["end"], thickness = binThk)
// define a function which builds the profile of the baseplate bin // Define a function which builds the profile of the baseplate bin
fn lipFace(plane) { fn lipFace(plane) {
faceSketch = startSketchOn(plane) faceSketch = startSketchOn(plane)
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
@ -234,13 +233,13 @@ plane002 = {
} }
} }
// extrude a single side of the lip of the bin // Extrude a single side of the lip of the bin
lipSingleLength = extrude(lipFace(plane000), length = binLength * countBinWidth - (2 * cornerRadius) + 2 * binTol * countBinWidth) lipSingleLength = extrude(lipFace(plane000), length = binLength * countBinWidth - (2 * cornerRadius) + 2 * binTol * countBinWidth)
// extrude a single side of the lip of the bin // Extrude a single side of the lip of the bin
lipSingleWidth = extrude(lipFace(plane001), length = binLength * countBinLength - (2 * cornerRadius) + 2 * binTol * countBinLength) lipSingleWidth = extrude(lipFace(plane001), length = binLength * countBinLength - (2 * cornerRadius) + 2 * binTol * countBinLength)
// create the other sides of the lips by using a circular pattern // Create the other sides of the lips by using a circular pattern
lipLengths = patternCircular3d( lipLengths = patternCircular3d(
lipSingleLength, lipSingleLength,
arcDegrees = 360, arcDegrees = 360,
@ -254,7 +253,7 @@ lipLengths = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// create the other sides of the lips by using a circular pattern // Create the other sides of the lips by using a circular pattern
lipWidths = patternCircular3d( lipWidths = patternCircular3d(
lipSingleWidth, lipSingleWidth,
arcDegrees = 360, arcDegrees = 360,
@ -268,19 +267,19 @@ lipWidths = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// define an axis axis000 // Define an axis axis000
axis001 = { axis001 = {
direction = [0.0, 1.0], direction = [0.0, 1.0],
origin = [cornerRadius, cornerRadius] origin = [cornerRadius, cornerRadius]
} }
// create a single corner of the bin // Create a single corner of the bin
lipSingleLengthCorner = revolve(lipFace(plane000), angle = -90, axis = axis001) lipSingleLengthCorner = revolve(lipFace(plane000), angle = -90, axis = axis001)
// create a single corner of the bin // Create a single corner of the bin
lipSingleWidthCorner = revolve(lipFace(plane002), angle = 90, axis = axis001) lipSingleWidthCorner = revolve(lipFace(plane002), angle = 90, axis = axis001)
// create the corners of the bin // Create the corners of the bin
lipCorners000 = patternCircular3d( lipCorners000 = patternCircular3d(
lipSingleLengthCorner, lipSingleLengthCorner,
arcDegrees = 360, arcDegrees = 360,
@ -294,7 +293,7 @@ lipCorners000 = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// create the corners of the bin // Create the corners of the bin
lipCorners001 = patternCircular3d( lipCorners001 = patternCircular3d(
lipSingleWidthCorner, lipSingleWidthCorner,
arcDegrees = 360, arcDegrees = 360,

View File

@ -4,7 +4,7 @@
// Set units in millimeters (mm) // Set units in millimeters (mm)
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
binLength = 41.5 binLength = 41.5
binHeight = 7.0 binHeight = 7.0
binBaseLength = 2.95 binBaseLength = 2.95
@ -26,7 +26,7 @@ countBinHeight = 2
// The total height of the baseplate is a summation of the vertical heights of the baseplate steps // The total height of the baseplate is a summation of the vertical heights of the baseplate steps
height = firstStep + secondStep + thirdStep height = firstStep + secondStep + thirdStep
// define a function which builds the profile of the baseplate bin // Define a function which builds the profile of the baseplate bin
fn face(plane) { fn face(plane) {
faceSketch = startSketchOn(plane) faceSketch = startSketchOn(plane)
|> startProfileAt([binBaseLength + binTol, 0], %) |> startProfileAt([binBaseLength + binTol, 0], %)
@ -39,10 +39,10 @@ fn face(plane) {
return faceSketch return faceSketch
} }
// extrude a single side of the bin // Extrude a single side of the bin
singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius + binTol)), length = binLength - (cornerRadius * 2)) singleSide = extrude(face(offsetPlane(YZ, offset = cornerRadius + binTol)), length = binLength - (cornerRadius * 2))
// create the other sides of the bin by using a circular pattern // Create the other sides of the bin by using a circular pattern
sides = patternCircular3d( sides = patternCircular3d(
singleSide, singleSide,
arcDegrees = 360, arcDegrees = 360,
@ -56,7 +56,7 @@ sides = patternCircular3d(
rotateDuplicates = true, rotateDuplicates = true,
) )
// define an axis axis000 // Define an axis axis000
axis000 = { axis000 = {
direction = [0.0, 1.0], direction = [0.0, 1.0],
origin = [ origin = [
@ -65,10 +65,10 @@ axis000 = {
] ]
} }
// create a single corner of the bin // Create a single corner of the bin
singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius + binTol)), angle = -90, axis = axis000) singleCorner = revolve(face(offsetPlane(YZ, offset = cornerRadius + binTol)), angle = -90, axis = axis000)
// create the corners of the bin // Create the corners of the bin
corners = patternCircular3d( corners = patternCircular3d(
singleCorner, singleCorner,
arcDegrees = 360, arcDegrees = 360,
@ -121,7 +121,7 @@ magCutout000 = startSketchOn(singleBinFill, "start")
) )
|> extrude(length = -magDepth) |> extrude(length = -magDepth)
// create the baseplate by patterning sides // Create the baseplate by patterning sides
binSides = patternLinear3d( binSides = patternLinear3d(
sides, sides,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -130,7 +130,7 @@ binSides = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
// create the corners of the baseplate by patterning the corners // Create the corners of the baseplate by patterning the corners
binCorners = patternLinear3d( binCorners = patternLinear3d(
corners, corners,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -139,7 +139,7 @@ binCorners = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
// create the fill of the bin by patterning the corners // Create the fill of the bin by patterning the corners
binFill = patternLinear3d( binFill = patternLinear3d(
singleBinFill, singleBinFill,
axis = [1.0, 0.0, 0.0], axis = [1.0, 0.0, 0.0],
@ -148,7 +148,7 @@ binFill = patternLinear3d(
) )
|> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2) |> patternLinear3d(axis = [0.0, 1.0, 0.0], instances = countBinLength, distance = binLength + binTol * 2)
// create the top of the bin // Create the top of the bin
binTop = startSketchOn(offsetPlane(XY, offset = height)) binTop = startSketchOn(offsetPlane(XY, offset = height))
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
|> xLine(length = (binLength + 2 * binTol) * countBinWidth, tag = $line010) |> xLine(length = (binLength + 2 * binTol) * countBinWidth, tag = $line010)

View File

@ -1,10 +1,10 @@
// Hex nut // Hex Nut
// A hex nut is a type of fastener with a threaded hole and a hexagonal outer shape, used in a wide variety of applications to secure parts together. The hexagonal shape allows for a greater torque to be applied with wrenches or tools, making it one of the most common nut types in hardware. // A hex nut is a type of fastener with a threaded hole and a hexagonal outer shape, used in a wide variety of applications to secure parts together. The hexagonal shape allows for a greater torque to be applied with wrenches or tools, making it one of the most common nut types in hardware.
// Set Units // Set Units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants (5/16" - 24 thread size) // Define parameters (5/16" - 24 thread size)
wallToWallLength = 0.5 wallToWallLength = 0.5
thickness = 0.266 thickness = 0.266
diameter = 0.3125 diameter = 0.3125

View File

@ -1,10 +1,10 @@
// I-beam // I-beam
// A structural metal beam with an I shaped cross section. Often used in construction and architecture // A structural metal beam with an I shaped cross section. Often used in construction and architecture
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define Beam Dimensions // Define parameters
beamLength = 6 * ft() beamLength = 6 * ft()
beamHeight = 4 beamHeight = 4
flangeWidth = 2.663 flangeWidth = 2.663
@ -13,7 +13,7 @@ webThickness = 0.193
rootRadius = 0.457 rootRadius = 0.457
// Sketch a quadrant of the beam cross section, then mirror for symmetry across each axis. Extrude to the appropriate length // Sketch a quadrant of the beam cross section, then mirror for symmetry across each axis. Extrude to the appropriate length
sketch001 = startSketchOn(-XZ) iBeam = startSketchOn(-XZ)
|> startProfileAt([0, beamHeight / 2], %) |> startProfileAt([0, beamHeight / 2], %)
|> xLine(length = flangeWidth / 2) |> xLine(length = flangeWidth / 2)
|> yLine(length = -flangeThickness) |> yLine(length = -flangeThickness)

View File

@ -1,10 +1,10 @@
// Zoo Keyboard // Zoo Keyboard
// A custom keyboard with Zoo brand lettering // A custom keyboard with Zoo brand lettering
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
baseColor = "#0f0f0f" baseColor = "#0f0f0f"
highlightColor1 = "#b0b0b0" highlightColor1 = "#b0b0b0"
highlightColor2 = "#23af93" highlightColor2 = "#23af93"

View File

@ -1,7 +1,7 @@
// Kitt // Kitt
// The beloved KittyCAD mascot in a voxelized style. // The beloved KittyCAD mascot in a voxelized style.
// pixel box function // Pixel box function
fn pixelBox(kitExtrude, extrudeTag, positionY, positionZ, width, height, depth) { fn pixelBox(kitExtrude, extrudeTag, positionY, positionZ, width, height, depth) {
pixelBoxBody = startSketchOn(kitExtrude, extrudeTag) pixelBoxBody = startSketchOn(kitExtrude, extrudeTag)
|> startProfileAt([positionY, positionZ], %) |> startProfileAt([positionY, positionZ], %)

View File

@ -4,8 +4,8 @@
// Set Units // Set Units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
lbumps = 4 // number of bumps long lbumps = 3 // number of bumps long
wbumps = 2 // number of bumps wide wbumps = 2 // number of bumps wide
pitch = 8.0 pitch = 8.0
clearance = 0.1 clearance = 0.1

View File

@ -1,19 +1,19 @@
// Makeup Mirror // Makeup Mirror
// A circular vanity mirror mounted on a swiveling arm with pivot joints, used for personal grooming. // A circular vanity mirror mounted on a swiveling arm with pivot joints, used for personal grooming.
// Settings // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// hinge // Hinge parameters
hingeRadius = 8 hingeRadius = 8
hingeHeight = hingeRadius * 3 hingeHeight = hingeRadius * 3
hingeGap = 0.5 hingeGap = 0.5
// arm // Arm parameters
armLength = 170 armLength = 170
armRadius = 5 armRadius = 5
// mirror // Mirror parameters
mirrorRadius = 170 / 2 mirrorRadius = 170 / 2
mirrorThickness = 10 mirrorThickness = 10
archToMirrorGap = 5 archToMirrorGap = 5
@ -21,7 +21,7 @@ archThickness = 1
archRadius = mirrorRadius + archToMirrorGap archRadius = mirrorRadius + archToMirrorGap
// Geometry // Geometry
// hinge // Add a function to create the hinge
fn hingeFn(x, y, z) { fn hingeFn(x, y, z) {
hingeBody = startSketchOn(offsetPlane(XY, offset = z)) hingeBody = startSketchOn(offsetPlane(XY, offset = z))
|> circle(center = [x, y], radius = hingeRadius) |> circle(center = [x, y], radius = hingeRadius)
@ -39,7 +39,7 @@ hingePartB3 = hingeFn(armLength, 0, hingeHeight * 2 + hingeGap * 2)
hingePartC2 = hingeFn(armLength, -armLength, hingeHeight * 2 + hingeGap * 2) hingePartC2 = hingeFn(armLength, -armLength, hingeHeight * 2 + hingeGap * 2)
hingePartC3 = hingeFn(armLength, -armLength, hingeHeight * 3 + hingeGap * 3) hingePartC3 = hingeFn(armLength, -armLength, hingeHeight * 3 + hingeGap * 3)
// arm // Add a function to create the arm
fn armFn(plane, offset, altitude) { fn armFn(plane, offset, altitude) {
armBody = startSketchOn(plane) armBody = startSketchOn(plane)
|> circle(center = [offset, altitude], radius = armRadius) |> circle(center = [offset, altitude], radius = armRadius)
@ -50,7 +50,7 @@ fn armFn(plane, offset, altitude) {
armPartA = armFn(YZ, 0, hingeHeight * 1.5 + hingeGap) armPartA = armFn(YZ, 0, hingeHeight * 1.5 + hingeGap)
armPartB = armFn(XZ, armLength, hingeHeight * 2.5 + hingeGap * 2) armPartB = armFn(XZ, armLength, hingeHeight * 2.5 + hingeGap * 2)
// mirror // Add a function to create the mirror
fn mirrorFn(plane, offsetX, offsetY, altitude, radius, tiefe, gestellR, gestellD) { fn mirrorFn(plane, offsetX, offsetY, altitude, radius, tiefe, gestellR, gestellD) {
armPlane = startSketchOn( offsetPlane(plane, offset = offsetY - (tiefe / 2))) armPlane = startSketchOn( offsetPlane(plane, offset = offsetY - (tiefe / 2)))
armBody = circle(armPlane, center = [offsetX, altitude], radius = radius) armBody = circle(armPlane, center = [offsetX, altitude], radius = radius)

View File

@ -6,13 +6,6 @@
"title": "80/20 Rail", "title": "80/20 Rail",
"description": "An 80/20 extruded aluminum linear rail. T-slot profile adjustable by profile height, rail length, and origin position" "description": "An 80/20 extruded aluminum linear rail. T-slot profile adjustable by profile height, rail length, and origin position"
}, },
{
"file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "a-parametric-bearing-pillow-block/main.kcl",
"multipleFiles": false,
"title": "A Parametric Bearing Pillow Block",
"description": "A bearing pillow block, also known as a plummer block or pillow block bearing, is a pedestal used to provide support for a rotating shaft with the help of compatible bearings and various accessories. Housing a bearing, the pillow block provides a secure and stable foundation that allows the shaft to rotate smoothly within its machinery setup. These components are essential in a wide range of mechanical systems and machinery, playing a key role in reducing friction and supporting radial and axial loads."
},
{ {
"file": "main.kcl", "file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "ball-bearing/main.kcl", "pathFromProjectDirectoryToFirstFile": "ball-bearing/main.kcl",
@ -157,7 +150,7 @@
"file": "main.kcl", "file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "hex-nut/main.kcl", "pathFromProjectDirectoryToFirstFile": "hex-nut/main.kcl",
"multipleFiles": false, "multipleFiles": false,
"title": "Hex nut", "title": "Hex Nut",
"description": "A hex nut is a type of fastener with a threaded hole and a hexagonal outer shape, used in a wide variety of applications to secure parts together. The hexagonal shape allows for a greater torque to be applied with wrenches or tools, making it one of the most common nut types in hardware." "description": "A hex nut is a type of fastener with a threaded hole and a hexagonal outer shape, used in a wide variety of applications to secure parts together. The hexagonal shape allows for a greater torque to be applied with wrenches or tools, making it one of the most common nut types in hardware."
}, },
{ {
@ -209,12 +202,19 @@
"title": "Robot Arm", "title": "Robot Arm",
"description": "A 4 axis robotic arm for industrial use. These machines can be used for assembly, packaging, organization of goods, and quality inspection processes" "description": "A 4 axis robotic arm for industrial use. These machines can be used for assembly, packaging, organization of goods, and quality inspection processes"
}, },
{
"file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "parametric-bearing-pillow-block/main.kcl",
"multipleFiles": false,
"title": "Parametric Bearing Pillow Block",
"description": "A bearing pillow block, also known as a plummer block or pillow block bearing, is a pedestal used to provide support for a rotating shaft with the help of compatible bearings and various accessories. Housing a bearing, the pillow block provides a secure and stable foundation that allows the shaft to rotate smoothly within its machinery setup. These components are essential in a wide range of mechanical systems and machinery, playing a key role in reducing friction and supporting radial and axial loads."
},
{ {
"file": "main.kcl", "file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "pipe/main.kcl", "pathFromProjectDirectoryToFirstFile": "pipe/main.kcl",
"multipleFiles": false, "multipleFiles": false,
"title": "Pipe", "title": "Pipe",
"description": "A tubular section or hollow cylinder, usually but not necessarily of circular cross-section, used mainly to convey substances that can flow." "description": "Piping for the pipe flange assembly"
}, },
{ {
"file": "main.kcl", "file": "main.kcl",
@ -248,7 +248,7 @@
"file": "main.kcl", "file": "main.kcl",
"pathFromProjectDirectoryToFirstFile": "router-template-slate/main.kcl", "pathFromProjectDirectoryToFirstFile": "router-template-slate/main.kcl",
"multipleFiles": false, "multipleFiles": false,
"title": "Router template for a slate", "title": "Router Template for a Slate",
"description": "A guide for routing a slate for a cross bar." "description": "A guide for routing a slate for a cross bar."
}, },
{ {

View File

@ -1,10 +1,10 @@
// Mounting Plate // Mounting Plate
// A flat piece of material, often metal or plastic, that serves as a support or base for attaching, securing, or mounting various types of equipment, devices, or components. // A flat piece of material, often metal or plastic, that serves as a support or base for attaching, securing, or mounting various types of equipment, devices, or components.
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
plateLength = 10 plateLength = 10
plateWidth = 6 plateWidth = 6
filletRadius = 0.5 filletRadius = 0.5

View File

@ -4,6 +4,7 @@
// Set Units // Set Units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Import parts
import "robot-arm-base.kcl" as robotArmBase import "robot-arm-base.kcl" as robotArmBase
import "robot-rotating-base.kcl" as rotatingBase import "robot-rotating-base.kcl" as rotatingBase
import "robot-arm-j2.kcl" as j2RobotArm import "robot-arm-j2.kcl" as j2RobotArm

View File

@ -1,10 +1,10 @@
// A Parametric Bearing Pillow Block // Parametric Bearing Pillow Block
// A bearing pillow block, also known as a plummer block or pillow block bearing, is a pedestal used to provide support for a rotating shaft with the help of compatible bearings and various accessories. Housing a bearing, the pillow block provides a secure and stable foundation that allows the shaft to rotate smoothly within its machinery setup. These components are essential in a wide range of mechanical systems and machinery, playing a key role in reducing friction and supporting radial and axial loads. // A bearing pillow block, also known as a plummer block or pillow block bearing, is a pedestal used to provide support for a rotating shaft with the help of compatible bearings and various accessories. Housing a bearing, the pillow block provides a secure and stable foundation that allows the shaft to rotate smoothly within its machinery setup. These components are essential in a wide range of mechanical systems and machinery, playing a key role in reducing friction and supporting radial and axial loads.
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants such as length, width, height, counter-bore depth and diameter, bearing diameter, hole location padding, and more // Define parameters
length = 6 length = 6
width = 4 width = 4
height = 1 height = 1
@ -14,15 +14,15 @@ holeDia = .375
padding = 1.5 padding = 1.5
bearingDia = 3 bearingDia = 3
// (Needs to be updated). Sketch the block and extrude up to where the counterbore diameter starts. // Sketch the block body
extrude001 = startSketchOn(XY) body = startSketchOn(XY)
|> startProfileAt([-width / 2, -length / 2], %) |> startProfileAt([-width / 2, -length / 2], %)
|> line(endAbsolute = [width / 2, -length / 2]) |> line(endAbsolute = [width / 2, -length / 2])
|> line(endAbsolute = [width / 2, length / 2]) |> line(endAbsolute = [width / 2, length / 2])
|> line(endAbsolute = [-width / 2, length / 2]) |> line(endAbsolute = [-width / 2, length / 2])
|> close() |> close()
|> extrude(length = height) |> extrude(length = height)
extrude002 = startSketchOn(extrude001, 'end') counterBoreHoles = startSketchOn(body, 'end')
|> circle( |> circle(
center = [ center = [
-(width / 2 - (padding / 2)), -(width / 2 - (padding / 2)),
@ -34,7 +34,7 @@ extrude002 = startSketchOn(extrude001, 'end')
|> patternLinear2d(instances = 2, distance = width - padding, axis = [1, 0]) |> patternLinear2d(instances = 2, distance = width - padding, axis = [1, 0])
|> extrude(%, length = -cbDepth) |> extrude(%, length = -cbDepth)
extrude003 = startSketchOn(extrude001, 'start') boltHoles = startSketchOn(body, 'start')
|> circle( |> circle(
center = [ center = [
-(width / 2 - (padding / 2)), -(width / 2 - (padding / 2)),
@ -46,6 +46,6 @@ extrude003 = startSketchOn(extrude001, 'start')
|> patternLinear2d(instances = 2, distance = width - padding, axis = [1, 0]) |> patternLinear2d(instances = 2, distance = width - padding, axis = [1, 0])
|> extrude(length = -height + cbDepth) |> extrude(length = -height + cbDepth)
extrude004 = startSketchOn(extrude001, 'end') centerHole = startSketchOn(body, 'end')
|> circle(center = [0, 0], radius = bearingDia / 2) |> circle(center = [0, 0], radius = bearingDia / 2)
|> extrude(length = -height) |> extrude(length = -height)

View File

@ -1,25 +1,23 @@
// Pipe // Pipe
// piping for the pipe flange assembly // Piping for the pipe flange assembly
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import pipeInnerDiameter, pipeOuterDiameter, pipeLength from "globals.kcl" import pipeInnerDiameter, pipeOuterDiameter, pipeLength from "parameters.kcl"
// create a function to make the pipe // Create a function to make the pipe. Export
export fn pipe() { export fn pipe() {
// create the pipe base // Create the pipe base
pipeBase = startSketchOn(XZ) pipeBase = startSketchOn(XZ)
|> circle(%, center = [0, 0], radius = pipeOuterDiameter / 2) |> circle(%, center = [0, 0], radius = pipeOuterDiameter / 2)
|> extrude(%, length = pipeLength) |> extrude(%, length = pipeLength)
// extrude a hole through the length of the pipe // Extrude a hole through the length of the pipe
pipe = startSketchOn(pipeBase, 'end') pipe = startSketchOn(pipeBase, 'end')
|> circle(center = [0, 0], radius = pipeInnerDiameter / 2) |> circle(center = [0, 0], radius = pipeInnerDiameter / 2)
|> extrude(%, length = -pipeLength) |> extrude(%, length = -pipeLength)
|> appearance(color = "#a24ed0") |> appearance(color = "#a24ed0")
return pipe return pipe
} }
// https://www.mcmaster.com/1120T74/

View File

@ -1,15 +1,15 @@
// 68095k348 flange // Flange
// flange used for mating two pipes together in the pipe flange assembly. // Flange used for mating two pipes together in the pipe flange assembly.
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import pipeDiameter, mountingHoleDiameter, mountingHolePlacementDiameter, flangeDiameter, flangeTotalThickness, flangeBackHeight, flangeFrontHeight, flangeBaseThickness, flangeBackDiameter, flangeFrontDiameter from "globals.kcl" import pipeDiameter, mountingHoleDiameter, mountingHolePlacementDiameter, flangeDiameter, flangeTotalThickness, flangeBackHeight, flangeFrontHeight, flangeBaseThickness, flangeBackDiameter, flangeFrontDiameter from "parameters.kcl"
// create a function to create the flange // Create a function to create the flange. We must create a function since we are using multiple flanges.
export fn flange() { export fn flange() {
// sketch the mounting hole pattern // Sketch the mounting hole pattern
mountingHoles = startSketchOn(XY) mountingHoles = startSketchOn(XY)
|> circle(%, center = [0, mountingHolePlacementDiameter / 2], radius = mountingHoleDiameter / 2) |> circle(%, center = [0, mountingHolePlacementDiameter / 2], radius = mountingHoleDiameter / 2)
|> patternCircular2d( |> patternCircular2d(
@ -20,13 +20,13 @@ export fn flange() {
rotateDuplicates = false, rotateDuplicates = false,
) )
// create the flange base // Create the flange base
flangeBase = startSketchOn(XY) flangeBase = startSketchOn(XY)
|> circle(%, center = [0, 0], radius = flangeDiameter / 2) |> circle(%, center = [0, 0], radius = flangeDiameter / 2)
|> hole(mountingHoles, %) |> hole(mountingHoles, %)
|> extrude(%, length = flangeBaseThickness) |> extrude(%, length = flangeBaseThickness)
// create both the raised portions on the front and back of the flange base // Create both the raised portions on the front and back of the flange base
flangeBack = startSketchOn(flangeBase, 'start') flangeBack = startSketchOn(flangeBase, 'start')
|> circle(%, center = [0, 0], radius = flangeBackDiameter / 2) |> circle(%, center = [0, 0], radius = flangeBackDiameter / 2)
|> extrude(%, length = flangeBackHeight) |> extrude(%, length = flangeBackHeight)
@ -34,7 +34,7 @@ export fn flange() {
|> circle(%, center = [0, 0], radius = flangeFrontDiameter / 2) |> circle(%, center = [0, 0], radius = flangeFrontDiameter / 2)
|> extrude(%, length = flangeFrontHeight) |> extrude(%, length = flangeFrontHeight)
// create the circular cut in the center for the pipe // Create the circular cut in the center for the pipe
pipeCut = startSketchOn(flangeFront, 'end') pipeCut = startSketchOn(flangeFront, 'end')
|> circle(%, center = [0, 0], radius = pipeDiameter / 2) |> circle(%, center = [0, 0], radius = pipeDiameter / 2)
|> extrude(%, length = -flangeTotalThickness) |> extrude(%, length = -flangeTotalThickness)
@ -42,5 +42,3 @@ export fn flange() {
return pipeCut return pipeCut
} }
// https://www.mcmaster.com/68095K348/

View File

@ -1,13 +1,13 @@
// 91251A404 Socket Head Cap Screw // Socket Head Cap Screw
// screw for mating the flanges together in the pipe flange assembly // screw for mating the flanges together in the pipe flange assembly
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import boltDiameter, boltLength, boltHeadLength, boltHeadDiameter, boltHexDrive, boltHexFlatLength, boltThreadLength from "globals.kcl" import boltDiameter, boltLength, boltHeadLength, boltHeadDiameter, boltHexDrive, boltHexFlatLength, boltThreadLength from "parameters.kcl"
// create a function to make a the bolt // Create a function to make a the bolt
export fn bolt() { export fn bolt() {
// Create the head of the cap screw // Create the head of the cap screw
boltHead = startSketchOn(XZ) boltHead = startSketchOn(XZ)
@ -52,5 +52,3 @@ export fn bolt() {
return boltBody return boltBody
} }
// https://www.mcmaster.com/91251a404/

View File

@ -1,26 +1,19 @@
// 9472K188 Gasket // Gasket
// gasket for the pipe flange assembly. A gasket is a mechanical seal that fills the space between two or more mating surfaces, preventing leaks of liquids or gases under compression // Gasket for the pipe flange assembly. A gasket is a mechanical seal that fills the space between two or more mating surfaces, preventing leaks of liquids or gases under compression
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import gasketOutsideDiameter, gasketInnerDiameter, gasketThickness from "globals.kcl" import gasketOutsideDiameter, gasketInnerDiameter, gasketThickness from "parameters.kcl"
// create a function to make the gasket // Create the base of the gasket
export fn gasket() { gasketBase = startSketchOn(XY)
// create the base of the gasket |> circle(%, center = [0, 0], radius = gasketOutsideDiameter / 2)
gasketBase = startSketchOn(XY) |> extrude(%, length = gasketThickness)
|> circle(%, center = [0, 0], radius = gasketOutsideDiameter / 2)
|> extrude(%, length = gasketThickness)
// extrude a circular hole through the gasket base // Extrude a circular hole through the gasket base
gasket = startSketchOn(gasketBase, 'end') startSketchOn(gasketBase, 'end')
|> circle(%, center = [0, 0], radius = gasketInnerDiameter / 2) |> circle(%, center = [0, 0], radius = gasketInnerDiameter / 2)
|> extrude(%, length = -gasketThickness) |> extrude(%, length = -gasketThickness)
|> appearance(%, color = "#d0cb3e") |> appearance(%, color = "#d0cb3e")
return gasket
}
// https://www.mcmaster.com/9472K616/

View File

@ -1,15 +1,15 @@
// 95479A127 Hex Nut // Hex Nut
// hex nut for the screws in the pipe flange assembly. // Hex nut for the screws in the pipe flange assembly.
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import hexNutDiameter, hexNutFlatToFlat, hexNutThickness, hexNutFlatLength from "globals.kcl" import hexNutDiameter, hexNutFlatToFlat, hexNutThickness, hexNutFlatLength from "parameters.kcl"
// create a function to make the hex nut // Create a function to make the hex nut. Must be a function since multiple hex nuts are used
export fn hexNut() { export fn hexNut() {
// create the base of the hex nut // Create the base of the hex nut
hexNutBase = startSketchOn(XY) hexNutBase = startSketchOn(XY)
|> startProfileAt([ |> startProfileAt([
hexNutFlatToFlat / 2, hexNutFlatToFlat / 2,
@ -38,7 +38,7 @@ export fn hexNut() {
|> close() |> close()
|> extrude(length = hexNutThickness) |> extrude(length = hexNutThickness)
// create the hole in the center of the hex nut // Create the hole in the center of the hex nut
hexNut = startSketchOn(hexNutBase, 'end') hexNut = startSketchOn(hexNutBase, 'end')
|> circle(center = [0, 0], radius = hexNutDiameter / 2) |> circle(center = [0, 0], radius = hexNutDiameter / 2)
|> extrude(%, length = -hexNutThickness) |> extrude(%, length = -hexNutThickness)
@ -46,4 +46,3 @@ export fn hexNut() {
return hexNut return hexNut
} }
// https://www.mcmaster.com/95479A127/

View File

@ -1,20 +1,20 @@
// 98017A257 Washer // 98017A257 Washer
// washer for the screws in the pipe flange assembly. // Washer for the screws in the pipe flange assembly.
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import washerInnerDia, washerOuterDia, washerThickness from "globals.kcl" import washerInnerDia, washerOuterDia, washerThickness from "parameters.kcl"
// create a function to make the washer // Create a function to make the washer. Must be a function since multiple washers are used.
export fn washer() { export fn washer() {
// create the base of the washer // Create the base of the washer
washerBase = startSketchOn(XY) washerBase = startSketchOn(XY)
|> circle(center = [0, 0], radius = washerOuterDia / 2) |> circle(center = [0, 0], radius = washerOuterDia / 2)
|> extrude(length = washerThickness) |> extrude(length = washerThickness)
// extrude a hole through the washer // Extrude a hole through the washer
washer = startSketchOn(washerBase, 'end') washer = startSketchOn(washerBase, 'end')
|> circle(center = [0, 0], radius = washerInnerDia / 2) |> circle(center = [0, 0], radius = washerInnerDia / 2)
|> extrude(%, length = -washerThickness) |> extrude(%, length = -washerThickness)
@ -22,5 +22,3 @@ export fn washer() {
return washer return washer
} }
// https://www.mcmaster.com/98017A257/

View File

@ -1,31 +1,31 @@
// Pipe and Flange Assembly // Pipe and Flange Assembly
// A crucial component in various piping systems, designed to facilitate the connection, disconnection, and access to piping for inspection, cleaning, and modifications. This assembly combines pipes (long cylindrical conduits) with flanges (plate-like fittings) to create a secure yet detachable joint. // A crucial component in various piping systems, designed to facilitate the connection, disconnection, and access to piping for inspection, cleaning, and modifications. This assembly combines pipes (long cylindrical conduits) with flanges (plate-like fittings) to create a secure yet detachable joint.
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import * from "globals.kcl" import * from "parameters.kcl"
// import parts // Import parts
import "9472k188-gasket.kcl" as gasket
import flange from "68095k348-flange.kcl" import flange from "68095k348-flange.kcl"
import gasket from "9472k188-gasket.kcl"
import washer from "98017a257-washer.kcl" import washer from "98017a257-washer.kcl"
import bolt from "91251a404-bolt.kcl" import bolt from "91251a404-bolt.kcl"
import hexNut from "95479a127-hex-nut.kcl" import hexNut from "95479a127-hex-nut.kcl"
import pipe from "1120t74-pipe.kcl" import pipe from "1120t74-pipe.kcl"
// place flanges // Place flanges
flange() flange()
flange() flange()
|> rotate(axis = [0, 1, 0], angle = 180) |> rotate(axis = [0, 1, 0], angle = 180)
|> translate(x = 0, y = 0, z = flangeBackHeight * 2 + gasketThickness) |> translate(x = 0, y = 0, z = flangeBackHeight * 2 + gasketThickness)
// place gasket between the flanges // Place gasket between the flanges
gasket() gasket
|> translate(x = 0, y = 0, z = -flangeBackHeight - gasketThickness) |> translate(x = 0, y = 0, z = -flangeBackHeight - gasketThickness)
// place eight washers (four front, four back) // Place eight washers (four front, four back)
washer() washer()
|> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = flangeBaseThickness) |> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = flangeBaseThickness)
|> patternCircular3d( |> patternCircular3d(
@ -43,7 +43,7 @@ washer()
axis = [0, 0, 1], axis = [0, 0, 1],
) )
// place four bolts // Place four bolts
bolt() bolt()
|> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = flangeBaseThickness + washerThickness) |> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = flangeBaseThickness + washerThickness)
|> rotate(roll = 90, pitch = 0, yaw = 0) |> rotate(roll = 90, pitch = 0, yaw = 0)
@ -56,7 +56,7 @@ bolt()
rotateDuplicates = false, rotateDuplicates = false,
) )
// place four hex nuts // Place four hex nuts
hexNut() hexNut()
|> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = -(flangeBackHeight * 2 + gasketThickness + flangeBaseThickness + washerThickness + hexNutThickness)) |> translate(x = mountingHolePlacementDiameter / 2, y = 0, z = -(flangeBackHeight * 2 + gasketThickness + flangeBaseThickness + washerThickness + hexNutThickness))
|> patternCircular3d( |> patternCircular3d(
@ -68,7 +68,7 @@ hexNut()
rotateDuplicates = false, rotateDuplicates = false,
) )
// place both pieces of pipe // Place both pieces of pipe
pipe() pipe()
|> rotate( |> rotate(
%, %,

View File

@ -1,9 +1,9 @@
// Globals // Parameters
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// flange (68095K348) // Flange (68095K348)
export pipeDiameter = 2.440 export pipeDiameter = 2.440
export mountingHoleDiameter = 0.750 export mountingHoleDiameter = 0.750
export mountingHolePlacementDiameter = 4.750 export mountingHolePlacementDiameter = 4.750
@ -17,12 +17,12 @@ export flangeBaseThickness = flangeTotalThickness - flangeBackHeight - flangeFro
export flangeBackDiameter = 3.620 export flangeBackDiameter = 3.620
export flangeFrontDiameter = 3.060 export flangeFrontDiameter = 3.060
// washer (98017A257) // Washer (98017A257)
export washerInnerDia = 0.640 export washerInnerDia = 0.640
export washerOuterDia = 1.188 export washerOuterDia = 1.188
export washerThickness = 0.032 export washerThickness = 0.032
// bolt (91251A404) // Bolt (91251A404)
export boltDiameter = 0.625 export boltDiameter = 0.625
export boltLength = 2.500 export boltLength = 2.500
export boltHeadLength = boltDiameter export boltHeadLength = boltDiameter
@ -31,18 +31,18 @@ export boltHexDrive = 1 / 2
export boltHexFlatLength = boltHexDrive / (2 * cos(toRadians(30))) export boltHexFlatLength = boltHexDrive / (2 * cos(toRadians(30)))
export boltThreadLength = 1.750 export boltThreadLength = 1.750
// hex nut (95479A127) // Hex nut (95479A127)
export hexNutDiameter = 5 / 8 export hexNutDiameter = 5 / 8
export hexNutFlatToFlat = 15 / 16 export hexNutFlatToFlat = 15 / 16
export hexNutThickness = 35 / 64 export hexNutThickness = 35 / 64
export hexNutFlatLength = hexNutFlatToFlat / (2 * cos(toRadians(30))) export hexNutFlatLength = hexNutFlatToFlat / (2 * cos(toRadians(30)))
// gasket (9472K188) // Gasket (9472K188)
export gasketOutsideDiameter = 4.125 export gasketOutsideDiameter = 4.125
export gasketInnerDiameter = 2.375 export gasketInnerDiameter = 2.375
export gasketThickness = 0.031 export gasketThickness = 0.031
// pipe (1120T74) // Pipe (1120T74)
export pipeInnerDiameter = 2.0 export pipeInnerDiameter = 2.0
export pipeOuterDiameter = 2.375 export pipeOuterDiameter = 2.375
export pipeLength = 6 export pipeLength = 6

View File

@ -4,24 +4,24 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
innerDiameter = 10 innerDiameter = 10
outerDiameter = 20 outerDiameter = 20
bendRadius = 30 bendRadius = 30
bendAngle = 90 bendAngle = 90
// create a sketch in the 'XZ' plane // Create a sketch in the 'XZ' plane
sketch000 = startSketchOn(XZ) sketch000 = startSketchOn(XZ)
// create a profile for the outer diameter // Create a profile for the outer diameter
outerProfile = circle(sketch000, center = [bendRadius, 0], radius = outerDiameter / 2) outerProfile = circle(sketch000, center = [bendRadius, 0], radius = outerDiameter / 2)
// create a profile for the inner diameter // Create a profile for the inner diameter
innerProfile = circle(sketch000, center = [bendRadius, 0], radius = innerDiameter / 2) innerProfile = circle(sketch000, center = [bendRadius, 0], radius = innerDiameter / 2)
// create the profile of the pipe // Create the profile of the pipe
pipeProfile = outerProfile pipeProfile = outerProfile
|> hole(innerProfile, %) |> hole(innerProfile, %)
// revolve the pipe profile at the desired angle // Revolve the pipe profile at the desired angle
pipe = revolve(pipeProfile, axis = Y, angle = bendAngle) pipe = revolve(pipeProfile, axis = Y, angle = bendAngle)

View File

@ -1,36 +1,21 @@
// Pipe // Pipe
// A tubular section or hollow cylinder, usually but not necessarily of circular cross-section, used mainly to convey substances that can flow. // Piping for the pipe flange assembly
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants // Define parameters
pipeTotalLength = 20 pipeInnerDiameter = 2.0
pipeLargeDiaLength = 1 pipeOuterDiameter = 2.375
pipeLargeDia = 1 pipeLength = 6
pipeSmallDia = .75
thickness = 0.125
pipeTransitionAngle = 60
pipeTransitionLength = 0.5
pipeSmallDiaLength = pipeTotalLength - pipeTransitionLength - pipeLargeDiaLength
// Create the sketch to be revolved around the y-axis. Use the small diameter, large diameter, length, and thickness to define the sketch. // Create the pipe base
pipeSketch = startSketchOn(XY) pipeBase = startSketchOn(XZ)
|> startProfileAt([pipeSmallDia - (thickness / 2), 38], %) |> circle(%, center = [0, 0], radius = pipeOuterDiameter / 2)
|> line(end = [thickness, 0]) |> extrude(%, length = pipeLength)
|> line(end = [0, -pipeSmallDiaLength])
|> angledLineOfYLength({
angle = -60,
length = pipeTransitionLength
}, %)
|> line(end = [0, -pipeLargeDiaLength])
|> xLine(length = -thickness)
|> line(end = [0, pipeLargeDiaLength])
|> angledLineToX({
angle = -pipeTransitionAngle + 180,
to = pipeSmallDia - (thickness / 2)
}, %)
|> close()
// Revolve the sketch to create the pipe // Extrude a hole through the length of the pipe
pipe = revolve(pipeSketch, axis = Y) pipe = startSketchOn(pipeBase, 'end')
|> circle(center = [0, 0], radius = pipeInnerDiameter / 2)
|> extrude(%, length = -pipeLength)
|> appearance(color = "#a24ed0")

View File

@ -4,6 +4,7 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define parameters
wallThickness = 0.125 wallThickness = 0.125
wallsWidth = 3 wallsWidth = 3
height = 5.125 height = 5.125
@ -12,6 +13,7 @@ backLength = 6
exitHeight = 1 exitHeight = 1
frontLength = 7 frontLength = 7
// Create the curved portion that catches the printer poop
sketch001 = startSketchOn(-YZ) sketch001 = startSketchOn(-YZ)
|> startProfileAt([wallsWidth / 2, 0], %) |> startProfileAt([wallsWidth / 2, 0], %)
|> xLine(length = wallThickness / 2) |> xLine(length = wallThickness / 2)
@ -78,6 +80,7 @@ sketch003 = startSketchOn(customPlane)
|> close() |> close()
|> extrude(length = wallThickness) |> extrude(length = wallThickness)
// Create the right side wall of the tub
sketch004 = startSketchOn(sketch002, 'END') sketch004 = startSketchOn(sketch002, 'END')
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
|> yLine(endAbsolute = height) |> yLine(endAbsolute = height)

View File

@ -1,18 +1,23 @@
// Router template for a cross bar // Router template for a cross bar
// A guide for routing a notch into a cross bar. // A guide for routing a notch into a cross bar.
// Set Units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define parameters
routerDiameter = 12.7 routerDiameter = 12.7
templateDiameter = 11 / 16 * inch() templateDiameter = 11 / 16 * inch()
templateGap = (templateDiameter - routerDiameter) / 2 - 0.5
slateWidthHalf = 41.5 / 2 slateWidthHalf = 41.5 / 2
minClampingDistance = 50 + 30 minClampingDistance = 50 + 30
templateThickness = 10 templateThickness = 10
radius = 10 radius = 10
depth = 30 depth = 30
// Calculated parameters
templateGap = (templateDiameter - routerDiameter) / 2 - 0.5
distanceToInsideEdge = slateWidthHalf + templateThickness + templateGap distanceToInsideEdge = slateWidthHalf + templateThickness + templateGap
// Create the first sketch
sketch001 = startSketchOn(XZ) sketch001 = startSketchOn(XZ)
|> startProfileAt([0, depth + templateGap], %) |> startProfileAt([0, depth + templateGap], %)
|> xLine(length = slateWidthHalf - radius, tag = $seg01) |> xLine(length = slateWidthHalf - radius, tag = $seg01)
@ -44,9 +49,12 @@ sketch001 = startSketchOn(XZ)
}, %) }, %)
|> line(endAbsolute = [profileStartX(%), profileStartY(%)]) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close() |> close()
// Extrude the first sketch
extrude001 = extrude(sketch001, length = 5) extrude001 = extrude(sketch001, length = 5)
sketch003 = startSketchOn(extrude001, 'START') // Create the second sketch
sketch002 = startSketchOn(extrude001, 'START')
|> startProfileAt([distanceToInsideEdge, 0], %) |> startProfileAt([distanceToInsideEdge, 0], %)
|> angledLine([180, templateThickness], %, $rectangleSegmentA002) |> angledLine([180, templateThickness], %, $rectangleSegmentA002)
|> angledLine([ |> angledLine([
@ -59,9 +67,12 @@ sketch003 = startSketchOn(extrude001, 'START')
], %, $rectangleSegmentC002) ], %, $rectangleSegmentC002)
|> line(endAbsolute = [profileStartX(%), profileStartY(%)]) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close() |> close()
extrude003 = extrude(sketch003, length = 13)
sketch002 = startSketchOn(extrude001, 'START') // Extrude the second sketch
extrude002 = extrude(sketch002, length = 13)
// Create the third sketch
sketch003 = startSketchOn(extrude001, 'START')
|> startProfileAt([-distanceToInsideEdge, 0], %) |> startProfileAt([-distanceToInsideEdge, 0], %)
|> angledLine([0, templateThickness], %, $rectangleSegmentA001) |> angledLine([0, templateThickness], %, $rectangleSegmentA001)
|> angledLine([ |> angledLine([
@ -75,8 +86,10 @@ sketch002 = startSketchOn(extrude001, 'START')
|> line(endAbsolute = [profileStartX(%), profileStartY(%)]) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close() |> close()
extrude002 = extrude(sketch002, length = 13) // Extrude the third sketch
extrude003 = extrude(sketch003, length = 13)
// Create the fourth sketch
sketch004 = startSketchOn(extrude002, 'END') sketch004 = startSketchOn(extrude002, 'END')
|> startProfileAt([-distanceToInsideEdge, 0], %) |> startProfileAt([-distanceToInsideEdge, 0], %)
|> angledLine([0, distanceToInsideEdge * 2], %, $rectangleSegmentA003) |> angledLine([0, distanceToInsideEdge * 2], %, $rectangleSegmentA003)
@ -90,4 +103,6 @@ sketch004 = startSketchOn(extrude002, 'END')
], %, $rectangleSegmentC003) ], %, $rectangleSegmentC003)
|> line(endAbsolute = [profileStartX(%), profileStartY(%)]) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close() |> close()
// Extrude the fourth sketch
extrude004 = extrude(sketch004, length = 4) extrude004 = extrude(sketch004, length = 4)

View File

@ -1,18 +1,20 @@
// Router template for a slate // Router Template for a Slate
// A guide for routing a slate for a cross bar. // A guide for routing a slate for a cross bar.
// Set Units // Set units
@settings(defaultLengthUnit = mm) @settings(defaultLengthUnit = mm)
// Define constants // Define parameters
routerDiameter = 12.7 routerDiameter = 12.7
templateDiameter = 11 / 16 * inch() templateDiameter = 11 / 16 * inch()
templateGap = (templateDiameter - routerDiameter) / 2 - 0.5
slateWidthHalf = 41.5 / 2 slateWidthHalf = 41.5 / 2
minClampingDistance = 50 + 30 minClampingDistance = 50 + 30
templateThickness = 10 templateThickness = 10
radius = 10 radius = 10
depth = 30 depth = 30
// Calculated parameters
templateGap = (templateDiameter - routerDiameter) / 2 - 0.5
length001 = slateWidthHalf - radius length001 = slateWidthHalf - radius
length002 = depth + minClampingDistance length002 = depth + minClampingDistance

Binary file not shown.

Before

Width:  |  Height:  |  Size: 86 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 KiB

After

Width:  |  Height:  |  Size: 57 KiB

View File

@ -1,7 +1,7 @@
// Sheet Metal Bracket // Sheet Metal Bracket
// A component typically made from flat sheet metal through various manufacturing processes such as bending, punching, cutting, and forming. These brackets are used to support, attach, or mount other hardware components, often providing a structural or functional base for assembly. // A component typically made from flat sheet metal through various manufacturing processes such as bending, punching, cutting, and forming. These brackets are used to support, attach, or mount other hardware components, often providing a structural or functional base for assembly.
// Set Units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Input bolt pattern dimensions to mount the bracket // Input bolt pattern dimensions to mount the bracket
@ -14,13 +14,13 @@ componentBoltDiameter = 3 / 16
componentBoltPatternX = 2 componentBoltPatternX = 2
componentBoltPatternY = 3 componentBoltPatternY = 3
// Define bracket constants such as sheet metal thickness, bend radius, flange length, etc. // Define bracket parameters such as sheet metal thickness, bend radius, flange length, etc.
hatHeight = 2.5 hatHeight = 2.5
bendAngle = 75 bendAngle = 75
thickness = 0.125 thickness = 0.125
interiorBendRadius = 0.125 interiorBendRadius = 0.125
// Calculate Remaining Parameters // Calculate remaining parameters
exteriorBendRadius = interiorBendRadius + thickness exteriorBendRadius = interiorBendRadius + thickness
overhang = 3 * mountingBoltDiameter overhang = 3 * mountingBoltDiameter
flangeLength = 6 * mountingBoltDiameter flangeLength = 6 * mountingBoltDiameter

View File

@ -1,58 +1,53 @@
// Socket Head Cap Screw // Socket Head Cap Screw
// This is for a #10-24 screw that is 1.00 inches long. A socket head cap screw is a type of fastener that is widely used in a variety of applications requiring a high strength fastening solution. It is characterized by its cylindrical head and internal hexagonal drive, which allows for tightening with an Allen wrench or hex key. // This is for a #10-24 screw that is 1.00 inches long. A socket head cap screw is a type of fastener that is widely used in a variety of applications requiring a high strength fastening solution. It is characterized by its cylindrical head and internal hexagonal drive, which allows for tightening with an Allen wrench or hex key.
// set units // Set units
@settings(defaultLengthUnit = in, defaultAngleUnit = deg) @settings(defaultLengthUnit = in)
export boltDiameter = 0.190 // Define parameters
export boltLength = 1.0 boltDiameter = 0.190
export boltHeadLength = boltDiameter boltLength = 1.0
export boltHeadDiameter = 0.313 boltHeadLength = boltDiameter
export boltHexDrive = 5 / 32 boltHeadDiameter = 0.313
export boltHexFlatLength = boltHexDrive / (2 * cos(toRadians(30))) boltHexDrive = 5 / 32
boltHexFlatLength = boltHexDrive / (2 * cos(toRadians(30)))
export fn bolt() { // Create the head of the cap screw
// Create the head of the cap screw boltHead = startSketchOn(XZ)
boltHead = startSketchOn(XZ) |> circle(center = [0, 0], radius = boltHeadDiameter / 2, tag = $topEdge)
|> circle(center = [0, 0], radius = boltHeadDiameter / 2, tag = $topEdge) |> extrude(length = -boltHeadLength)
|> extrude(length = -boltHeadLength) |> fillet(radius = 0.020, tags = [topEdge, getOppositeEdge(topEdge)])
|> fillet(radius = 0.020, tags = [topEdge, getOppositeEdge(topEdge)])
// Define the sketch of the hex pattern on the screw head // Define the sketch of the hex pattern on the screw head
hexPatternSketch = startSketchOn(boltHead, 'start') hexPatternSketch = startSketchOn(boltHead, 'start')
|> startProfileAt([ |> startProfileAt([
boltHexDrive / 2, boltHexDrive / 2,
boltHexFlatLength / 2 boltHexFlatLength / 2
], %) ], %)
|> angledLine({ |> angledLine({
angle = 270, angle = 270,
length = boltHexFlatLength length = boltHexFlatLength
}, %) }, %)
|> angledLine({ |> angledLine({
angle = 210, angle = 210,
length = boltHexFlatLength length = boltHexFlatLength
}, %) }, %)
|> angledLine({ |> angledLine({
angle = 150, angle = 150,
length = boltHexFlatLength length = boltHexFlatLength
}, %) }, %)
|> angledLine({ |> angledLine({
angle = 90, angle = 90,
length = boltHexFlatLength length = boltHexFlatLength
}, %) }, %)
|> angledLine({ |> angledLine({
angle = 30, angle = 30,
length = boltHexFlatLength length = boltHexFlatLength
}, %) }, %)
|> close() |> close()
|> extrude(length = -boltHeadLength * 0.75) |> extrude(length = -boltHeadLength * 0.75)
boltBody = startSketchOn(boltHead, 'end') boltBody = startSketchOn(boltHead, 'end')
|> circle(center = [0, 0], radius = boltDiameter / 2, tag = $filletEdge) |> circle(center = [0, 0], radius = boltDiameter / 2, tag = $filletEdge)
|> extrude(length = boltLength) |> extrude(length = boltLength)
|> fillet(radius = .020, tags = [getOppositeEdge(filletEdge)]) |> fillet(radius = .020, tags = [getOppositeEdge(filletEdge)])
|> appearance(color = "#4dd043", metalness = 90, roughness = 90) |> appearance(color = "#4dd043", metalness = 90, roughness = 90)
return boltBody
}
bolt()

View File

@ -1,35 +1,32 @@
// Walkie talkie antenna // Walkie Talkie Antenna
// antenna for the walkie talkie assembly // Antenna for the walkie talkie assembly
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import antennaLength, antennaBaseWidth, antennaBaseHeight, antennaTopWidth, antennaTopHeight from "globals.kcl" import antennaLength, antennaBaseWidth, antennaBaseHeight, antennaTopWidth, antennaTopHeight from "parameters.kcl"
export fn antenna() { // Create the antenna base sketch
// Create the antenna base sketch antennaBaseSketch = startSketchOn(XY)
sketch001 = startSketchOn(XY) |> startProfileAt([0, 0], %)
|> startProfileAt([0, 0], %) |> line(end = [antennaBaseWidth, 0])
|> line(end = [antennaBaseWidth, 0]) |> line(end = [0, -antennaBaseHeight])
|> line(end = [0, -antennaBaseHeight]) |> line(end = [-antennaBaseWidth, 0])
|> line(end = [-antennaBaseWidth, 0]) |> close()
|> close()
// Create the antenna top sketch // Create the antenna top sketch
loftPlane = offsetPlane(XY, offset = antennaLength) loftPlane = offsetPlane(XY, offset = antennaLength)
sketch002 = startSketchOn(loftPlane) antennaTopSketch = startSketchOn(loftPlane)
|> startProfileAt([ |> startProfileAt([
(antennaBaseWidth - antennaTopWidth) / 2, (antennaBaseWidth - antennaTopWidth) / 2,
(antennaBaseHeight - antennaTopHeight) / 2 (antennaBaseHeight - antennaTopHeight) / 2
], %) ], %)
|> xLine(length = antennaTopWidth) |> xLine(length = antennaTopWidth)
|> yLine(length = -antennaTopHeight) |> yLine(length = -antennaTopHeight)
|> xLine(length = -antennaTopWidth) |> xLine(length = -antennaTopWidth)
|> close() |> close()
// Create the antenna using a loft // Create the antenna using a loft
antenna = loft([sketch001, sketch002]) loft([antennaBaseSketch, antennaTopSketch])
|> appearance(color = "#000000") |> appearance(color = "#000000")
return antenna
}

View File

@ -1,84 +1,78 @@
// Walkie talkie body // Walkie Talkie Body
// the main body of the walkie talkie assembly // The main body of the walkie talkie assembly
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import height, width, thickness, chamferLength, offset, screenWidth, screenHeight, screenYPosition, screenDepth, speakerBoxWidth, speakerBoxHeight from "globals.kcl" import height, width, thickness, chamferLength, offset, screenWidth, screenHeight, screenYPosition, screenDepth, speakerBoxWidth, speakerBoxHeight from "parameters.kcl"
// create a function to define the body // Sketch and extrude the body of the walkie talkie
export fn body() { body = startSketchOn(XZ)
// sketch and extrude the body of the walkie talkie |> startProfileAt([-width / 2, height / 2], %)
bodySketch = startSketchOn(XZ) |> xLine(length = width, tag = $chamfer1)
|> startProfileAt([-width / 2, height / 2], %) |> yLine(length = -height, tag = $chamfer2)
|> xLine(length = width, tag = $chamfer1) |> xLine(length = -width, tag = $chamfer3)
|> yLine(length = -height, tag = $chamfer2) |> close(tag = $chamfer4)
|> xLine(length = -width, tag = $chamfer3) |> extrude(%, length = thickness)
|> close(tag = $chamfer4) |> chamfer(
bodyExtrude = extrude(bodySketch, length = thickness) length = chamferLength,
|> chamfer( tags = [
length = chamferLength, getNextAdjacentEdge(chamfer1),
tags = [ getNextAdjacentEdge(chamfer2),
getNextAdjacentEdge(chamfer1), getNextAdjacentEdge(chamfer3),
getNextAdjacentEdge(chamfer2), getNextAdjacentEdge(chamfer4)
getNextAdjacentEdge(chamfer3), ],
getNextAdjacentEdge(chamfer4) )
],
)
// cut out the indentation for the case // Cut out the indentation for the case
sketch002 = startSketchOn(bodyExtrude, 'END') caseIndentSketch = startSketchOn(body, 'END')
|> startProfileAt([ |> startProfileAt([
-width / 2 + offset, -width / 2 + offset,
height / 2 - (chamferLength + offset / 2 * cos(toRadians(45))) height / 2 - (chamferLength + offset / 2 * cos(toRadians(45)))
], %) ], %)
|> angledLineToY({ angle = 45, to = height / 2 - offset }, %) |> angledLineToY({ angle = 45, to = height / 2 - offset }, %)
|> line(endAbsolute = [ |> line(endAbsolute = [
width / 2 - (chamferLength + offset / 2 * cos(toRadians(45))), width / 2 - (chamferLength + offset / 2 * cos(toRadians(45))),
height / 2 - offset height / 2 - offset
]) ])
|> angledLineToX({ angle = -45, to = width / 2 - offset }, %) |> angledLineToX({ angle = -45, to = width / 2 - offset }, %)
|> line(endAbsolute = [ |> line(endAbsolute = [
width / 2 - offset, width / 2 - offset,
-(height / 2 - (chamferLength + offset / 2 * cos(toRadians(45)))) -(height / 2 - (chamferLength + offset / 2 * cos(toRadians(45))))
]) ])
|> angledLineToY({ |> angledLineToY({
angle = -135, angle = -135,
to = -height / 2 + offset to = -height / 2 + offset
}, %) }, %)
|> line(endAbsolute = [ |> line(endAbsolute = [
-(width / 2 - (chamferLength + offset / 2 * cos(toRadians(45)))), -(width / 2 - (chamferLength + offset / 2 * cos(toRadians(45)))),
-height / 2 + offset -height / 2 + offset
]) ])
|> angledLineToX({ |> angledLineToX({
angle = -225, angle = -225,
to = -width / 2 + offset to = -width / 2 + offset
}, %) }, %)
|> close() |> close()
extrude002 = extrude(sketch002, length = -0.0625) extrude002 = extrude(caseIndentSketch, length = -0.0625)
// Create the pocket for the screen // Create the pocket for the screen
sketch003 = startSketchOn(extrude002, 'start') screenCutout = startSketchOn(extrude002, 'start')
|> startProfileAt([-screenWidth / 2, screenYPosition], %) |> startProfileAt([-screenWidth / 2, screenYPosition], %)
|> xLine(length = screenWidth, tag = $seg01) |> xLine(length = screenWidth, tag = $seg01)
|> yLine(length = -screenHeight) |> yLine(length = -screenHeight)
|> xLine(length = -segLen(seg01)) |> xLine(length = -segLen(seg01))
|> line(endAbsolute = [profileStartX(%), profileStartY(%)]) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close() |> close()
extrude003 = extrude(sketch003, length = screenDepth) extrude003 = extrude(screenCutout, length = screenDepth)
// Create the speaker box // Create the speaker box
sketch004 = startSketchOn(extrude002, 'start') speakerBox = startSketchOn(extrude002, 'start')
|> startProfileAt([-1.25 / 2, -.125], %) |> startProfileAt([-1.25 / 2, -.125], %)
|> xLine(length = speakerBoxWidth) |> xLine(length = speakerBoxWidth)
|> yLine(length = -speakerBoxHeight) |> yLine(length = -speakerBoxHeight)
|> xLine(length = -speakerBoxWidth) |> xLine(length = -speakerBoxWidth)
|> close() |> close()
body = extrude(sketch004, length = -.5) extrude(speakerBox, length = -.5)
|> appearance(color = "#277bb0") |> appearance(color = "#277bb0")
return body
}
body()

View File

@ -1,21 +1,24 @@
// Walkie Talkie button // Walkie Talkie Button
// Button for the walkie talkie
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import buttonWidth, buttonHeight, buttonThickness from "globals.kcl" import buttonWidth, buttonHeight, buttonThickness from "parameters.kcl"
// Create a function for the button. We need to create a function to use multiple buttons.
// create a function to define the button
export fn button() { export fn button() {
// sketch the button profile and extrude // Sketch the button profile and extrude
buttonSketch = startSketchOn(XZ) buttonSketch = startSketchOn(XZ)
|> startProfileAt([0, 0], %) |> startProfileAt([0, 0], %)
|> angledLine({ angle = 180, length = buttonWidth }, %, $tag1) |> angledLine({ angle = 180, length = buttonWidth }, %, $tag1)
|> angledLine({ angle = 270, length = buttonHeight }, %, $tag2) |> angledLine({ angle = 270, length = buttonHeight }, %, $tag2)
|> angledLine({ angle = 0, length = buttonWidth }, %) |> angledLine({ angle = 0, length = buttonWidth }, %)
|> close() |> close()
buttonExtrude = extrude(buttonSketch, length = buttonThickness) button = extrude(buttonSketch, length = buttonThickness)
|> chamfer( |> chamfer(
length = .050, length = .050,
tags = [ tags = [
@ -25,5 +28,5 @@ export fn button() {
) )
|> appearance(color = "#ff0000") |> appearance(color = "#ff0000")
return buttonExtrude return button
} }

View File

@ -1,88 +1,83 @@
// Walkie talkie case // Walkie Talkie Case
// the plastic case for the front of the walkie talkie // The plastic case for the front of the walkie talkie
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants and Zoo logo // Import parameters and Zoo logo
import width, height, chamferLength, offset, screenWidth, screenHeight, screenYPosition, screenDepth, speakerBoxWidth, speakerBoxHeight, squareHoleSideLength, caseTolerance from "globals.kcl" import width, height, chamferLength, offset, screenWidth, screenHeight, screenYPosition, screenDepth, speakerBoxWidth, speakerBoxHeight, squareHoleSideLength, caseTolerance from "parameters.kcl"
import zLogo, oLogo, oLogo2 from "zoo-logo.kcl" import zLogo, oLogo, oLogo2 from "zoo-logo.kcl"
// create a function to define the case // Sketch the profile of the screen
export fn case() { screenSketch = startSketchOn(XZ)
// sketch the profile of the screen |> startProfileAt([-screenWidth / 2, screenYPosition], %)
sketch006 = startSketchOn(startSketchOn(XZ)) |> xLine(length = screenWidth)
|> startProfileAt([-screenWidth / 2, screenYPosition], %) |> yLine(length = -screenHeight)
|> xLine(length = screenWidth) |> xLine(length = -screenWidth)
|> yLine(length = -screenHeight) |> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> xLine(length = -screenWidth) |> close()
|> line(endAbsolute = [profileStartX(%), profileStartY(%)])
|> close()
// create transform functions for the speaker grid pattern // Create transform functions for the speaker grid pattern
fn transformX(i) { fn transformX(i) {
return { translate = [.125 * i, 0] } return { translate = [.125 * i, 0] }
}
fn transformY(i) {
return { translate = [0, -.125 * i] }
}
// sketch the square hole grid pattern
squareHolePatternSketch = startSketchOn(startSketchOn(XZ))
|> startProfileAt([-screenWidth / 2 + .100, 0], %)
|> line(end = [squareHoleSideLength / 2, 0])
|> line(end = [0, -squareHoleSideLength / 2])
|> line(end = [-squareHoleSideLength / 2, 0])
|> close()
|> patternTransform2d(instances = 13, transform = transformX)
|> patternTransform2d(instances = 11, transform = transformY)
// sketch the outer profile of the case and extrude with holes using the previously made profiles
sketch005 = startSketchOn(startSketchOn(XZ))
|> startProfileAt([
-width / 2 + offset + caseTolerance,
height / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45)))
], %)
|> angledLineToY({
angle = 45,
to = height / 2 - (offset + caseTolerance)
}, %)
|> line(endAbsolute = [
width / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45))),
height / 2 - (offset + caseTolerance)
])
|> angledLineToX({
angle = -45,
to = width / 2 - (offset + caseTolerance)
}, %)
|> line(endAbsolute = [
width / 2 - (offset + caseTolerance),
-(height / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45))))
])
|> angledLineToY({
angle = -135,
to = -height / 2 + offset + caseTolerance
}, %)
|> line(endAbsolute = [
-(width / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45)))),
-height / 2 + offset + caseTolerance
])
|> angledLineToX({
angle = -225,
to = -width / 2 + offset + caseTolerance
}, %)
|> close()
|> hole(sketch006, %)
|> hole(squareHolePatternSketch, %)
// create the Zoo logo
|> hole(zLogo(startSketchOn(XZ), [-.30, -1.825], .20), %)
|> hole(oLogo(startSketchOn(XZ), [-.075, -1.825], .20), %)
|> hole(oLogo2(startSketchOn(XZ), [-.075, -1.825], .20), %)
|> hole(oLogo(startSketchOn(XZ), [.175, -1.825], .20), %)
|> hole(oLogo2(startSketchOn(XZ), [.175, -1.825], .20), %)
case = extrude(sketch005, length = -0.0625)
|> appearance(color = '#D0FF01', metalness = 0, roughness = 50)
return case
} }
fn transformY(i) {
return { translate = [0, -.125 * i] }
}
// Sketch the square hole grid pattern
squareHolePatternSketch = startSketchOn(XZ)
|> startProfileAt([-screenWidth / 2 + .100, 0], %)
|> line(end = [squareHoleSideLength / 2, 0])
|> line(end = [0, -squareHoleSideLength / 2])
|> line(end = [-squareHoleSideLength / 2, 0])
|> close()
|> patternTransform2d(instances = 13, transform = transformX)
|> patternTransform2d(instances = 11, transform = transformY)
// Sketch the outer profile of the case and extrude with holes using the previously made profiles
case = startSketchOn(XZ)
|> startProfileAt([
-width / 2 + offset + caseTolerance,
height / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45)))
], %)
|> angledLineToY({
angle = 45,
to = height / 2 - (offset + caseTolerance)
}, %)
|> line(endAbsolute = [
width / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45))),
height / 2 - (offset + caseTolerance)
])
|> angledLineToX({
angle = -45,
to = width / 2 - (offset + caseTolerance)
}, %)
|> line(endAbsolute = [
width / 2 - (offset + caseTolerance),
-(height / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45))))
])
|> angledLineToY({
angle = -135,
to = -height / 2 + offset + caseTolerance
}, %)
|> line(endAbsolute = [
-(width / 2 - (chamferLength + (offset + caseTolerance) / 2 * cos(toRadians(45)))),
-height / 2 + offset + caseTolerance
])
|> angledLineToX({
angle = -225,
to = -width / 2 + offset + caseTolerance
}, %)
|> close()
|> hole(screenSketch, %)
|> hole(squareHolePatternSketch, %)
// Create the Zoo logo
|> hole(zLogo(startSketchOn(XZ), [-.30, -1.825], .20), %)
|> hole(oLogo(startSketchOn(XZ), [-.075, -1.825], .20), %)
|> hole(oLogo2(startSketchOn(XZ), [-.075, -1.825], .20), %)
|> hole(oLogo(startSketchOn(XZ), [.175, -1.825], .20), %)
|> hole(oLogo2(startSketchOn(XZ), [.175, -1.825], .20), %)
extrude(case, length = -0.0625)
|> appearance(color = '#D0FF01', metalness = 0, roughness = 50)

View File

@ -1,28 +1,23 @@
// Walkie talkie frequency knob // Walkie Talkie Frequency Knob
// the frequency knob for the walkie talkie assembly // The frequency knob for the walkie talkie assembly
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import width, thickness, height, knobDiameter, knobHeight, knobRadius from "globals.kcl" import width, thickness, height, knobDiameter, knobHeight, knobRadius from "parameters.kcl"
// create a function to define the knob // Create the knob sketch and revolve
export fn knob() { startSketchOn(XZ)
// Create the knob sketch and revolve |> startProfileAt([0.0001, 0], %)
knob = startSketchOn(XZ) |> xLine(length = knobDiameter / 2)
|> startProfileAt([0.0001, 0], %) |> yLine(length = knobHeight - 0.05)
|> xLine(length = knobDiameter / 2) |> arc({
|> yLine(length = knobHeight - 0.05) angleStart = 0,
|> arc({ angleEnd = 90,
angleStart = 0, radius = .05
angleEnd = 90, }, %)
radius = .05 |> xLine(endAbsolute = 0.0001)
}, %) |> close()
|> xLine(endAbsolute = 0.0001) |> revolve(axis = Y)
|> close() |> appearance(color = '#D0FF01', metalness = 90, roughness = 50)
|> revolve(axis = Y)
|> appearance(color = '#D0FF01', metalness = 90, roughness = 50)
return knob
}

View File

@ -5,36 +5,36 @@
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // import constants
import * from "globals.kcl" import * from "parameters.kcl"
// import parts and constants // import parts and parameters
import body from "body.kcl" import "body.kcl" as body
import case from "case.kcl" import "case.kcl" as case
import antenna from "antenna.kcl" import "antenna.kcl" as antenna
import talkButton from "talk-button.kcl" import "talk-button.kcl" as talkButton
import knob from "knob.kcl" import "knob.kcl" as knob
import button from "button.kcl" import button from "button.kcl"
// import the body // Import the body
body() body
// import the antenna // Import the antenna
antenna() antenna
|> translate(x = -width / 2 + .45, y = -0.10, z = height / 2) |> translate(x = -width / 2 + .45, y = -0.10, z = height / 2)
// import the case // Import the case
case() case
|> translate(x = 0, y = -1, z = 0) |> translate(x = 0, y = -1, z = 0)
// import the talk button // Import the talk button
talkButton() talkButton
|> translate(x = width / 2, y = -thickness / 2, z = .5) |> translate(x = width / 2, y = -thickness / 2, z = .5)
// import the frequency knob // Import the frequency knob
knob() knob
|> translate(x = width / 2 - 0.70, y = -thickness / 2, z = height / 2) |> translate(x = width / 2 - 0.70, y = -thickness / 2, z = height / 2)
// import the buttons // Import the buttons
button() button()
|> translate(x = -(screenWidth / 2 + tolerance), y = -1, z = screenYPosition) |> translate(x = -(screenWidth / 2 + tolerance), y = -1, z = screenYPosition)
button() button()

View File

@ -1,4 +1,4 @@
// Global constants for the walkie talkie // Global parameters for the walkie talkie
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)

View File

@ -1,35 +1,31 @@
// Walkie talkie talk button // Walkie talkie talk button
// set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// import constants // Import parameters
import width, thickness, talkButtonSideLength, talkButtonHeight from "globals.kcl" import width, thickness, talkButtonSideLength, talkButtonHeight from "parameters.kcl"
export fn talkButton() { // Create the talk button sketch
// create the talk button sketch talkButtonSketch = startSketchOn(YZ)
talkButtonSketch = startSketchOn(YZ) |> startProfileAt([
|> startProfileAt([ -talkButtonSideLength / 2,
-talkButtonSideLength / 2, talkButtonSideLength / 2
talkButtonSideLength / 2 ], %)
], %) |> xLine(length = talkButtonSideLength, tag = $tag1)
|> xLine(length = talkButtonSideLength, tag = $tag1) |> yLine(length = -talkButtonSideLength, tag = $tag2)
|> yLine(length = -talkButtonSideLength, tag = $tag2) |> xLine(length = -talkButtonSideLength, tag = $tag3)
|> xLine(length = -talkButtonSideLength, tag = $tag3) |> close(tag = $tag4)
|> close(tag = $tag4)
// create the talk button and apply fillets // create the talk button and apply fillets
talkButton = extrude(talkButtonSketch, length = talkButtonHeight) extrude(talkButtonSketch, length = talkButtonHeight)
|> fillet( |> fillet(
radius = 0.050, radius = 0.050,
tags = [ tags = [
getNextAdjacentEdge(tag1), getNextAdjacentEdge(tag1),
getNextAdjacentEdge(tag2), getNextAdjacentEdge(tag2),
getNextAdjacentEdge(tag3), getNextAdjacentEdge(tag3),
getNextAdjacentEdge(tag4) getNextAdjacentEdge(tag4)
], ],
) )
|> appearance(color = '#D0FF01', metalness = 90, roughness = 90) |> appearance(color = '#D0FF01', metalness = 90, roughness = 90)
return talkButton
}

View File

@ -4,21 +4,16 @@
// Set units // Set units
@settings(defaultLengthUnit = in) @settings(defaultLengthUnit = in)
// Define constants in inches (in) // Define parameters
innerDiameter = 0.203 innerDiameter = 0.203
outerDiameter = 0.438 outerDiameter = 0.438
thicknessMax = 0.038 thicknessMax = 0.038
thicknessNom = 0.032
thicknessMin = 0.024 thicknessMin = 0.024
// Write a function that defines the washer and extrude it. // Define the sketch of the washer
fn washer(plane, innerDia, outerDia, thk) { washerSketch = startSketchOn(XY)
// Define the sketch of the washer |> circle(center = [0, 0], radius = outerDiameter / 2)
washerSketch = startSketchOn(plane) |> hole(circle(center = [0, 0], radius = innerDiameter / 2), %)
|> circle(center = [0, 0], radius = outerDia / 2)
|> hole(circle(center = [0, 0], radius = innerDia / 2), %)
washer = extrude(washerSketch, length = thk) washer = extrude(washerSketch, length = thicknessNom)
return washer
}
washer(XY, innerDiameter, outerDiameter, thicknessMax)

View File

@ -418,6 +418,9 @@ pub struct Sketch {
pub artifact_id: ArtifactId, pub artifact_id: ArtifactId,
#[ts(skip)] #[ts(skip)]
pub original_id: uuid::Uuid, pub original_id: uuid::Uuid,
/// If the sketch includes a mirror.
#[serde(skip)]
pub mirror: Option<uuid::Uuid>,
pub units: UnitLen, pub units: UnitLen,
/// Metadata. /// Metadata.
#[serde(skip)] #[serde(skip)]

View File

@ -13,7 +13,7 @@ use kcmc::{
websocket::{ModelingCmdReq, OkWebSocketResponseData}, websocket::{ModelingCmdReq, OkWebSocketResponseData},
ModelingCmd, ModelingCmd,
}; };
use kittycad_modeling_cmds as kcmc; use kittycad_modeling_cmds::{self as kcmc};
use uuid::Uuid; use uuid::Uuid;
use crate::{ use crate::{
@ -168,13 +168,18 @@ pub(crate) async fn do_post_extrude<'a>(
) )
.await?; .await?;
// The "get extrusion face info" API call requires *any* edge on the sketch being extruded. let any_edge_id = if let Some(edge_id) = sketch.mirror {
// So, let's just use the first one. edge_id
let Some(any_edge_id) = sketch.paths.first().map(|edge| edge.get_base().geo_meta.id) else { } else {
return Err(KclError::Type(KclErrorDetails { // The "get extrusion face info" API call requires *any* edge on the sketch being extruded.
message: "Expected a non-empty sketch".to_string(), // So, let's just use the first one.
source_ranges: vec![args.source_range], let Some(any_edge_id) = sketch.paths.first().map(|edge| edge.get_base().geo_meta.id) else {
})); return Err(KclError::Type(KclErrorDetails {
message: "Expected a non-empty sketch".to_string(),
source_ranges: vec![args.source_range],
}));
};
any_edge_id
}; };
let mut sketch = sketch.clone(); let mut sketch = sketch.clone();

View File

@ -2,10 +2,13 @@
use anyhow::Result; use anyhow::Result;
use kcmc::{each_cmd as mcmd, ModelingCmd}; use kcmc::{each_cmd as mcmd, ModelingCmd};
use kittycad_modeling_cmds::{self as kcmc, length_unit::LengthUnit, shared::Point3d}; use kittycad_modeling_cmds::{
self as kcmc, length_unit::LengthUnit, ok_response::OkModelingCmdResponse, output::EntityGetAllChildUuids,
shared::Point3d, websocket::OkWebSocketResponseData,
};
use crate::{ use crate::{
errors::KclError, errors::{KclError, KclErrorDetails},
execution::{ execution::{
types::{PrimitiveType, RuntimeType}, types::{PrimitiveType, RuntimeType},
ExecState, KclValue, Sketch, ExecState, KclValue, Sketch,
@ -31,13 +34,21 @@ pub async fn mirror_2d(exec_state: &mut ExecState, args: Args) -> Result<KclValu
Ok(sketches.into()) Ok(sketches.into())
} }
/// Mirror a sketch.
///
/// Only works on unclosed sketches for now.
async fn inner_mirror_2d( async fn inner_mirror_2d(
sketches: Vec<Sketch>, sketches: Vec<Sketch>,
axis: Axis2dOrEdgeReference, axis: Axis2dOrEdgeReference,
exec_state: &mut ExecState, exec_state: &mut ExecState,
args: Args, args: Args,
) -> Result<Vec<Sketch>, KclError> { ) -> Result<Vec<Sketch>, KclError> {
let starting_sketches = sketches; let mut starting_sketches = sketches.clone();
// Update all to have a mirror.
starting_sketches.iter_mut().for_each(|sketch| {
sketch.mirror = Some(exec_state.next_uuid());
});
if args.ctx.no_engine_commands().await { if args.ctx.no_engine_commands().await {
return Ok(starting_sketches); return Ok(starting_sketches);
@ -77,5 +88,40 @@ async fn inner_mirror_2d(
} }
}; };
// After the mirror, get the first child uuid for the path.
// The "get extrusion face info" API call requires *any* edge on the sketch being extruded.
// But if you mirror2d a sketch these IDs might change so we need to get the children versus
// using the IDs we already have.
// We only do this with mirrors because otherwise it is a waste of a websocket call.
for sketch in &mut starting_sketches {
let response = args
.send_modeling_cmd(
exec_state.next_uuid(),
ModelingCmd::from(mcmd::EntityGetAllChildUuids { entity_id: sketch.id }),
)
.await?;
let OkWebSocketResponseData::Modeling {
modeling_response:
OkModelingCmdResponse::EntityGetAllChildUuids(EntityGetAllChildUuids { entity_ids: child_ids }),
} = response
else {
return Err(KclError::Internal(KclErrorDetails {
message: "Expected a successful response from EntityGetAllChildUuids".to_string(),
source_ranges: vec![args.source_range],
}));
};
if child_ids.len() >= 2 {
// The first child is the original sketch, the second is the mirrored sketch.
let child_id = child_ids[1];
sketch.mirror = Some(child_id);
} else {
return Err(KclError::Type(KclErrorDetails {
message: "Expected child uuids to be >= 2".to_string(),
source_ranges: vec![args.source_range],
}));
}
}
Ok(starting_sketches) Ok(starting_sketches)
} }

View File

@ -1343,6 +1343,7 @@ pub(crate) async fn inner_start_profile_at(
on: sketch_surface.clone(), on: sketch_surface.clone(),
paths: vec![], paths: vec![],
units: sketch_surface.units(), units: sketch_surface.units(),
mirror: Default::default(),
meta: vec![args.source_range.into()], meta: vec![args.source_range.into()],
tags: if let Some(tag) = &tag { tags: if let Some(tag) = &tag {
let mut tag_identifier: TagIdentifier = tag.into(); let mut tag_identifier: TagIdentifier = tag.into();

View File

@ -96,6 +96,25 @@ export fn circle(
/// ///
/// example = extrude(sketch001, length = 10) /// example = extrude(sketch001, length = 10)
/// ``` /// ```
///
/// ```
/// // Sketch on the face of a mirrored sketch, that has been extruded.
/// sketch0011 = startSketchOn(XY)
/// |> startProfileAt([6.77, 0], %)
/// |> yLine(length = 1.27)
/// |> tangentialArcTo([5.96, 2.37], %)
/// |> tangentialArcTo([-6.2, 2.44], %)
/// |> tangentialArcTo([-6.6, 1.82], %)
/// |> yLine(length = -1.82)
/// |> mirror2d( axis = X )
/// |> extrude(length = 10)
///
/// sketch002 = startSketchOn(sketch0011, 'END')
/// |> circle( center = [-0.01, 1.58], radius = 1.2 )
/// |> extrude(length = 1.2)
///
/// shell([sketch002], faces = ['end'], thickness = .1 )
/// ```
@(impl = std_rust) @(impl = std_rust)
export fn mirror2d( export fn mirror2d(
/// The sketch or sketches to be reflected. /// The sketch or sketches to be reflected.

View File

@ -1,81 +1,81 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[324, 421, 0]"] 2["Path<br>[349, 446, 0]"]
3["Segment<br>[429, 534, 0]"] 3["Segment<br>[454, 559, 0]"]
4["Segment<br>[542, 651, 0]"] 4["Segment<br>[567, 676, 0]"]
5["Segment<br>[659, 691, 0]"] 5["Segment<br>[684, 716, 0]"]
6["Segment<br>[699, 808, 0]"] 6["Segment<br>[724, 833, 0]"]
7["Segment<br>[816, 863, 0]"] 7["Segment<br>[841, 888, 0]"]
8["Segment<br>[871, 919, 0]"] 8["Segment<br>[896, 944, 0]"]
9["Segment<br>[927, 976, 0]"] 9["Segment<br>[952, 1001, 0]"]
10["Segment<br>[984, 1101, 0]"] 10["Segment<br>[1009, 1126, 0]"]
11["Segment<br>[1109, 1157, 0]"] 11["Segment<br>[1134, 1182, 0]"]
12["Segment<br>[1165, 1273, 0]"] 12["Segment<br>[1190, 1298, 0]"]
13["Segment<br>[1281, 1330, 0]"] 13["Segment<br>[1306, 1355, 0]"]
14["Segment<br>[1338, 1387, 0]"] 14["Segment<br>[1363, 1412, 0]"]
15["Segment<br>[1395, 1428, 0]"] 15["Segment<br>[1420, 1453, 0]"]
16["Segment<br>[1436, 1545, 0]"] 16["Segment<br>[1461, 1570, 0]"]
17["Segment<br>[1553, 1585, 0]"] 17["Segment<br>[1578, 1610, 0]"]
18["Segment<br>[1593, 1702, 0]"] 18["Segment<br>[1618, 1727, 0]"]
19["Segment<br>[1710, 1813, 0]"] 19["Segment<br>[1735, 1838, 0]"]
20["Segment<br>[1854, 1964, 0]"] 20["Segment<br>[1879, 1989, 0]"]
21["Segment<br>[1972, 2004, 0]"] 21["Segment<br>[1997, 2029, 0]"]
22["Segment<br>[2012, 2122, 0]"] 22["Segment<br>[2037, 2147, 0]"]
23["Segment<br>[2130, 2177, 0]"] 23["Segment<br>[2155, 2202, 0]"]
24["Segment<br>[2185, 2235, 0]"] 24["Segment<br>[2210, 2260, 0]"]
25["Segment<br>[2243, 2293, 0]"] 25["Segment<br>[2268, 2318, 0]"]
26["Segment<br>[2311, 2440, 0]"] 26["Segment<br>[2336, 2465, 0]"]
27["Segment<br>[2458, 2507, 0]"] 27["Segment<br>[2483, 2532, 0]"]
28["Segment<br>[2521, 2635, 0]"] 28["Segment<br>[2546, 2660, 0]"]
29["Segment<br>[2649, 2699, 0]"] 29["Segment<br>[2674, 2724, 0]"]
30["Segment<br>[2713, 2762, 0]"] 30["Segment<br>[2738, 2787, 0]"]
31["Segment<br>[2770, 2803, 0]"] 31["Segment<br>[2795, 2828, 0]"]
32["Segment<br>[2811, 2921, 0]"] 32["Segment<br>[2836, 2946, 0]"]
33["Segment<br>[2929, 2961, 0]"] 33["Segment<br>[2954, 2986, 0]"]
34["Segment<br>[2969, 3079, 0]"] 34["Segment<br>[2994, 3104, 0]"]
35["Segment<br>[3120, 3222, 0]"] 35["Segment<br>[3145, 3247, 0]"]
36["Segment<br>[3230, 3340, 0]"] 36["Segment<br>[3255, 3365, 0]"]
37["Segment<br>[3348, 3381, 0]"] 37["Segment<br>[3373, 3406, 0]"]
38["Segment<br>[3389, 3499, 0]"] 38["Segment<br>[3414, 3524, 0]"]
39["Segment<br>[3507, 3556, 0]"] 39["Segment<br>[3532, 3581, 0]"]
40["Segment<br>[3564, 3614, 0]"] 40["Segment<br>[3589, 3639, 0]"]
41["Segment<br>[3622, 3671, 0]"] 41["Segment<br>[3647, 3696, 0]"]
42["Segment<br>[3679, 3807, 0]"] 42["Segment<br>[3704, 3832, 0]"]
43["Segment<br>[3815, 3865, 0]"] 43["Segment<br>[3840, 3890, 0]"]
44["Segment<br>[3873, 3988, 0]"] 44["Segment<br>[3898, 4013, 0]"]
45["Segment<br>[3996, 4045, 0]"] 45["Segment<br>[4021, 4070, 0]"]
46["Segment<br>[4053, 4102, 0]"] 46["Segment<br>[4078, 4127, 0]"]
47["Segment<br>[4110, 4144, 0]"] 47["Segment<br>[4135, 4169, 0]"]
48["Segment<br>[4152, 4262, 0]"] 48["Segment<br>[4177, 4287, 0]"]
49["Segment<br>[4270, 4303, 0]"] 49["Segment<br>[4295, 4328, 0]"]
50["Segment<br>[4311, 4421, 0]"] 50["Segment<br>[4336, 4446, 0]"]
51["Segment<br>[4429, 4533, 0]"] 51["Segment<br>[4454, 4558, 0]"]
52["Segment<br>[4574, 4684, 0]"] 52["Segment<br>[4599, 4709, 0]"]
53["Segment<br>[4692, 4725, 0]"] 53["Segment<br>[4717, 4750, 0]"]
54["Segment<br>[4733, 4843, 0]"] 54["Segment<br>[4758, 4868, 0]"]
55["Segment<br>[4851, 4900, 0]"] 55["Segment<br>[4876, 4925, 0]"]
56["Segment<br>[4908, 4957, 0]"] 56["Segment<br>[4933, 4982, 0]"]
57["Segment<br>[4965, 5014, 0]"] 57["Segment<br>[4990, 5039, 0]"]
58["Segment<br>[5022, 5141, 0]"] 58["Segment<br>[5047, 5166, 0]"]
59["Segment<br>[5149, 5199, 0]"] 59["Segment<br>[5174, 5224, 0]"]
60["Segment<br>[5207, 5315, 0]"] 60["Segment<br>[5232, 5340, 0]"]
61["Segment<br>[5323, 5372, 0]"] 61["Segment<br>[5348, 5397, 0]"]
62["Segment<br>[5380, 5430, 0]"] 62["Segment<br>[5405, 5455, 0]"]
63["Segment<br>[5438, 5472, 0]"] 63["Segment<br>[5463, 5497, 0]"]
64["Segment<br>[5480, 5590, 0]"] 64["Segment<br>[5505, 5615, 0]"]
65["Segment<br>[5598, 5631, 0]"] 65["Segment<br>[5623, 5656, 0]"]
66["Segment<br>[5639, 5749, 0]"] 66["Segment<br>[5664, 5774, 0]"]
67["Segment<br>[5757, 5764, 0]"] 67["Segment<br>[5782, 5789, 0]"]
68[Solid2d] 68[Solid2d]
end end
subgraph path69 [Path] subgraph path69 [Path]
69["Path<br>[5815, 5993, 0]"] 69["Path<br>[5840, 6018, 0]"]
70["Segment<br>[5815, 5993, 0]"] 70["Segment<br>[5840, 6018, 0]"]
71[Solid2d] 71[Solid2d]
end end
1["Plane<br>[298, 316, 0]"] 1["Plane<br>[323, 341, 0]"]
72["Sweep Extrusion<br>[6005, 6033, 0]"] 72["Sweep Extrusion<br>[6030, 6058, 0]"]
73[Wall] 73[Wall]
74[Wall] 74[Wall]
75[Wall] 75[Wall]
@ -270,38 +270,38 @@ flowchart LR
264["SweepEdge Adjacent"] 264["SweepEdge Adjacent"]
265["SweepEdge Opposite"] 265["SweepEdge Opposite"]
266["SweepEdge Adjacent"] 266["SweepEdge Adjacent"]
267["EdgeCut Fillet<br>[6041, 6746, 0]"] 267["EdgeCut Fillet<br>[6066, 6771, 0]"]
268["EdgeCut Fillet<br>[6041, 6746, 0]"] 268["EdgeCut Fillet<br>[6066, 6771, 0]"]
269["EdgeCut Fillet<br>[6041, 6746, 0]"] 269["EdgeCut Fillet<br>[6066, 6771, 0]"]
270["EdgeCut Fillet<br>[6041, 6746, 0]"] 270["EdgeCut Fillet<br>[6066, 6771, 0]"]
271["EdgeCut Fillet<br>[6041, 6746, 0]"] 271["EdgeCut Fillet<br>[6066, 6771, 0]"]
272["EdgeCut Fillet<br>[6041, 6746, 0]"] 272["EdgeCut Fillet<br>[6066, 6771, 0]"]
273["EdgeCut Fillet<br>[6041, 6746, 0]"] 273["EdgeCut Fillet<br>[6066, 6771, 0]"]
274["EdgeCut Fillet<br>[6041, 6746, 0]"] 274["EdgeCut Fillet<br>[6066, 6771, 0]"]
275["EdgeCut Fillet<br>[6041, 6746, 0]"] 275["EdgeCut Fillet<br>[6066, 6771, 0]"]
276["EdgeCut Fillet<br>[6041, 6746, 0]"] 276["EdgeCut Fillet<br>[6066, 6771, 0]"]
277["EdgeCut Fillet<br>[6041, 6746, 0]"] 277["EdgeCut Fillet<br>[6066, 6771, 0]"]
278["EdgeCut Fillet<br>[6041, 6746, 0]"] 278["EdgeCut Fillet<br>[6066, 6771, 0]"]
279["EdgeCut Fillet<br>[6041, 6746, 0]"] 279["EdgeCut Fillet<br>[6066, 6771, 0]"]
280["EdgeCut Fillet<br>[6041, 6746, 0]"] 280["EdgeCut Fillet<br>[6066, 6771, 0]"]
281["EdgeCut Fillet<br>[6041, 6746, 0]"] 281["EdgeCut Fillet<br>[6066, 6771, 0]"]
282["EdgeCut Fillet<br>[6041, 6746, 0]"] 282["EdgeCut Fillet<br>[6066, 6771, 0]"]
283["EdgeCut Fillet<br>[6754, 7458, 0]"] 283["EdgeCut Fillet<br>[6779, 7483, 0]"]
284["EdgeCut Fillet<br>[6754, 7458, 0]"] 284["EdgeCut Fillet<br>[6779, 7483, 0]"]
285["EdgeCut Fillet<br>[6754, 7458, 0]"] 285["EdgeCut Fillet<br>[6779, 7483, 0]"]
286["EdgeCut Fillet<br>[6754, 7458, 0]"] 286["EdgeCut Fillet<br>[6779, 7483, 0]"]
287["EdgeCut Fillet<br>[6754, 7458, 0]"] 287["EdgeCut Fillet<br>[6779, 7483, 0]"]
288["EdgeCut Fillet<br>[6754, 7458, 0]"] 288["EdgeCut Fillet<br>[6779, 7483, 0]"]
289["EdgeCut Fillet<br>[6754, 7458, 0]"] 289["EdgeCut Fillet<br>[6779, 7483, 0]"]
290["EdgeCut Fillet<br>[6754, 7458, 0]"] 290["EdgeCut Fillet<br>[6779, 7483, 0]"]
291["EdgeCut Fillet<br>[6754, 7458, 0]"] 291["EdgeCut Fillet<br>[6779, 7483, 0]"]
292["EdgeCut Fillet<br>[6754, 7458, 0]"] 292["EdgeCut Fillet<br>[6779, 7483, 0]"]
293["EdgeCut Fillet<br>[6754, 7458, 0]"] 293["EdgeCut Fillet<br>[6779, 7483, 0]"]
294["EdgeCut Fillet<br>[6754, 7458, 0]"] 294["EdgeCut Fillet<br>[6779, 7483, 0]"]
295["EdgeCut Fillet<br>[6754, 7458, 0]"] 295["EdgeCut Fillet<br>[6779, 7483, 0]"]
296["EdgeCut Fillet<br>[6754, 7458, 0]"] 296["EdgeCut Fillet<br>[6779, 7483, 0]"]
297["EdgeCut Fillet<br>[6754, 7458, 0]"] 297["EdgeCut Fillet<br>[6779, 7483, 0]"]
298["EdgeCut Fillet<br>[6754, 7458, 0]"] 298["EdgeCut Fillet<br>[6779, 7483, 0]"]
1 --- 2 1 --- 2
1 --- 69 1 --- 69
2 --- 3 2 --- 3

File diff suppressed because it is too large Load Diff

View File

@ -9,8 +9,8 @@ description: Operations executed 80-20-rail.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "rail8020", "name": "rail8020",
"functionSourceRange": [ "functionSourceRange": [
214, 239,
7479, 7504,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,

View File

@ -1,58 +1,58 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[731, 793, 0]"] 2["Path<br>[664, 726, 0]"]
3["Segment<br>[731, 793, 0]"] 3["Segment<br>[664, 726, 0]"]
4[Solid2d] 4[Solid2d]
end end
subgraph path5 [Path] subgraph path5 [Path]
5["Path<br>[804, 850, 0]"] 5["Path<br>[737, 783, 0]"]
6["Segment<br>[804, 850, 0]"] 6["Segment<br>[737, 783, 0]"]
7[Solid2d] 7[Solid2d]
end end
subgraph path15 [Path] subgraph path15 [Path]
15["Path<br>[1037, 1093, 0]"] 15["Path<br>[970, 1026, 0]"]
16["Segment<br>[1099, 1191, 0]"] 16["Segment<br>[1032, 1124, 0]"]
17["Segment<br>[1197, 1204, 0]"] 17["Segment<br>[1130, 1137, 0]"]
18[Solid2d] 18[Solid2d]
end end
subgraph path24 [Path] subgraph path24 [Path]
24["Path<br>[1574, 1707, 0]"] 24["Path<br>[1507, 1640, 0]"]
25["Segment<br>[1713, 1806, 0]"] 25["Segment<br>[1646, 1739, 0]"]
26["Segment<br>[1812, 1843, 0]"] 26["Segment<br>[1745, 1776, 0]"]
27["Segment<br>[1849, 1877, 0]"] 27["Segment<br>[1782, 1810, 0]"]
28["Segment<br>[1883, 1890, 0]"] 28["Segment<br>[1816, 1823, 0]"]
29[Solid2d] 29[Solid2d]
end end
subgraph path40 [Path] subgraph path40 [Path]
40["Path<br>[2224, 2366, 0]"] 40["Path<br>[2157, 2299, 0]"]
41["Segment<br>[2224, 2366, 0]"] 41["Segment<br>[2157, 2299, 0]"]
42[Solid2d] 42[Solid2d]
end end
subgraph path50 [Path] subgraph path50 [Path]
50["Path<br>[2760, 2813, 0]"] 50["Path<br>[2693, 2746, 0]"]
51["Segment<br>[2760, 2813, 0]"] 51["Segment<br>[2693, 2746, 0]"]
52[Solid2d] 52[Solid2d]
end end
subgraph path53 [Path] subgraph path53 [Path]
53["Path<br>[2824, 2898, 0]"] 53["Path<br>[2757, 2831, 0]"]
54["Segment<br>[2824, 2898, 0]"] 54["Segment<br>[2757, 2831, 0]"]
55[Solid2d] 55[Solid2d]
end end
1["Plane<br>[677, 724, 0]"] 1["Plane<br>[610, 657, 0]"]
8["Sweep Extrusion<br>[905, 957, 0]"] 8["Sweep Extrusion<br>[838, 890, 0]"]
9[Wall] 9[Wall]
10["Cap Start"] 10["Cap Start"]
11["Cap End"] 11["Cap End"]
12["SweepEdge Opposite"] 12["SweepEdge Opposite"]
13["SweepEdge Adjacent"] 13["SweepEdge Adjacent"]
14["Plane<br>[1014, 1031, 0]"] 14["Plane<br>[947, 964, 0]"]
19["Sweep Revolve<br>[1286, 1316, 0]"] 19["Sweep Revolve<br>[1219, 1249, 0]"]
20[Wall] 20[Wall]
21[Wall] 21[Wall]
22["SweepEdge Adjacent"] 22["SweepEdge Adjacent"]
23["Plane<br>[1551, 1568, 0]"] 23["Plane<br>[1484, 1501, 0]"]
30["Sweep Revolve<br>[1932, 1962, 0]"] 30["Sweep Revolve<br>[1865, 1895, 0]"]
31[Wall] 31[Wall]
32[Wall] 32[Wall]
33[Wall] 33[Wall]
@ -61,22 +61,22 @@ flowchart LR
36["SweepEdge Adjacent"] 36["SweepEdge Adjacent"]
37["SweepEdge Adjacent"] 37["SweepEdge Adjacent"]
38["SweepEdge Adjacent"] 38["SweepEdge Adjacent"]
39["Plane<br>[2201, 2218, 0]"] 39["Plane<br>[2134, 2151, 0]"]
43["Sweep Revolve<br>[2409, 2460, 0]"] 43["Sweep Revolve<br>[2342, 2393, 0]"]
44[Wall] 44[Wall]
45["Cap Start"] 45["Cap Start"]
46["Cap End"] 46["Cap End"]
47["SweepEdge Opposite"] 47["SweepEdge Opposite"]
48["SweepEdge Adjacent"] 48["SweepEdge Adjacent"]
49["Plane<br>[2706, 2753, 0]"] 49["Plane<br>[2639, 2686, 0]"]
56["Sweep Extrusion<br>[2918, 2971, 0]"] 56["Sweep Extrusion<br>[2851, 2904, 0]"]
57[Wall] 57[Wall]
58["Cap Start"] 58["Cap Start"]
59["Cap End"] 59["Cap End"]
60["SweepEdge Opposite"] 60["SweepEdge Opposite"]
61["SweepEdge Adjacent"] 61["SweepEdge Adjacent"]
62["StartSketchOnPlane<br>[663, 725, 0]"] 62["StartSketchOnPlane<br>[596, 658, 0]"]
63["StartSketchOnPlane<br>[2692, 2754, 0]"] 63["StartSketchOnPlane<br>[2625, 2687, 0]"]
1 --- 2 1 --- 2
1 --- 5 1 --- 5
2 --- 3 2 --- 3

File diff suppressed because it is too large Load Diff

View File

@ -1,264 +1,264 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[567, 618, 6]"] 2["Path<br>[571, 622, 6]"]
3["Segment<br>[567, 618, 6]"] 3["Segment<br>[571, 622, 6]"]
4[Solid2d] 4[Solid2d]
end end
subgraph path11 [Path] subgraph path11 [Path]
11["Path<br>[803, 859, 6]"] 11["Path<br>[807, 863, 6]"]
12["Segment<br>[803, 859, 6]"] 12["Segment<br>[807, 863, 6]"]
13[Solid2d] 13[Solid2d]
end end
subgraph path19 [Path] subgraph path19 [Path]
19["Path<br>[984, 1037, 6]"] 19["Path<br>[988, 1041, 6]"]
20["Segment<br>[984, 1037, 6]"] 20["Segment<br>[988, 1041, 6]"]
21[Solid2d] 21[Solid2d]
end end
subgraph path30 [Path] subgraph path30 [Path]
30["Path<br>[1420, 1460, 6]"] 30["Path<br>[1424, 1464, 6]"]
31["Segment<br>[1420, 1460, 6]"] 31["Segment<br>[1424, 1464, 6]"]
32[Solid2d] 32[Solid2d]
end end
subgraph path38 [Path] subgraph path38 [Path]
38["Path<br>[1564, 1615, 6]"] 38["Path<br>[1568, 1619, 6]"]
39["Segment<br>[1564, 1615, 6]"] 39["Segment<br>[1568, 1619, 6]"]
40[Solid2d] 40[Solid2d]
end end
subgraph path47 [Path] subgraph path47 [Path]
47["Path<br>[1748, 1801, 6]"] 47["Path<br>[1752, 1805, 6]"]
48["Segment<br>[1748, 1801, 6]"] 48["Segment<br>[1752, 1805, 6]"]
49[Solid2d] 49[Solid2d]
end end
subgraph path58 [Path] subgraph path58 [Path]
58["Path<br>[2044, 2116, 6]"] 58["Path<br>[2048, 2120, 6]"]
59["Segment<br>[2044, 2116, 6]"] 59["Segment<br>[2048, 2120, 6]"]
60[Solid2d] 60[Solid2d]
end end
subgraph path81 [Path] subgraph path81 [Path]
81["Path<br>[2373, 2404, 6]"] 81["Path<br>[2377, 2408, 6]"]
82["Segment<br>[2410, 2430, 6]"] 82["Segment<br>[2414, 2434, 6]"]
83["Segment<br>[2436, 2456, 6]"] 83["Segment<br>[2440, 2460, 6]"]
84["Segment<br>[2462, 2483, 6]"] 84["Segment<br>[2466, 2487, 6]"]
85["Segment<br>[2489, 2545, 6]"] 85["Segment<br>[2493, 2549, 6]"]
86["Segment<br>[2551, 2558, 6]"] 86["Segment<br>[2555, 2562, 6]"]
87[Solid2d] 87[Solid2d]
end end
subgraph path106 [Path] subgraph path106 [Path]
106["Path<br>[2860, 2892, 6]"] 106["Path<br>[2864, 2896, 6]"]
107["Segment<br>[2898, 2919, 6]"] 107["Segment<br>[2902, 2923, 6]"]
108["Segment<br>[2925, 2945, 6]"] 108["Segment<br>[2929, 2949, 6]"]
109["Segment<br>[2951, 2971, 6]"] 109["Segment<br>[2955, 2975, 6]"]
110["Segment<br>[2977, 3033, 6]"] 110["Segment<br>[2981, 3037, 6]"]
111["Segment<br>[3039, 3046, 6]"] 111["Segment<br>[3043, 3050, 6]"]
112[Solid2d] 112[Solid2d]
end end
subgraph path132 [Path] subgraph path132 [Path]
132["Path<br>[350, 406, 5]"] 132["Path<br>[354, 410, 5]"]
133["Segment<br>[350, 406, 5]"] 133["Segment<br>[354, 410, 5]"]
134[Solid2d] 134[Solid2d]
end end
subgraph path135 [Path] subgraph path135 [Path]
135["Path<br>[417, 473, 5]"] 135["Path<br>[421, 477, 5]"]
136["Segment<br>[417, 473, 5]"] 136["Segment<br>[421, 477, 5]"]
137[Solid2d] 137[Solid2d]
end end
subgraph path144 [Path] subgraph path144 [Path]
144["Path<br>[638, 694, 5]"] 144["Path<br>[642, 698, 5]"]
145["Segment<br>[638, 694, 5]"] 145["Segment<br>[642, 698, 5]"]
146[Solid2d] 146[Solid2d]
end end
subgraph path147 [Path] subgraph path147 [Path]
147["Path<br>[705, 761, 5]"] 147["Path<br>[709, 765, 5]"]
148["Segment<br>[705, 761, 5]"] 148["Segment<br>[709, 765, 5]"]
149[Solid2d] 149[Solid2d]
end end
subgraph path156 [Path] subgraph path156 [Path]
156["Path<br>[905, 959, 5]"] 156["Path<br>[909, 963, 5]"]
157["Segment<br>[905, 959, 5]"] 157["Segment<br>[909, 963, 5]"]
158[Solid2d] 158[Solid2d]
end end
subgraph path167 [Path] subgraph path167 [Path]
167["Path<br>[1237, 1297, 5]"] 167["Path<br>[1241, 1301, 5]"]
168["Segment<br>[1237, 1297, 5]"] 168["Segment<br>[1241, 1301, 5]"]
169[Solid2d] 169[Solid2d]
end end
subgraph path179 [Path] subgraph path179 [Path]
179["Path<br>[1655, 1701, 5]"] 179["Path<br>[1659, 1705, 5]"]
180["Segment<br>[1707, 1759, 5]"] 180["Segment<br>[1711, 1763, 5]"]
181["Segment<br>[1765, 1870, 5]"] 181["Segment<br>[1769, 1874, 5]"]
182["Segment<br>[1876, 1898, 5]"] 182["Segment<br>[1880, 1902, 5]"]
183["Segment<br>[1904, 1960, 5]"] 183["Segment<br>[1908, 1964, 5]"]
184["Segment<br>[1966, 1973, 5]"] 184["Segment<br>[1970, 1977, 5]"]
185[Solid2d] 185[Solid2d]
end end
subgraph path195 [Path] subgraph path195 [Path]
195["Path<br>[2105, 2151, 5]"] 195["Path<br>[2109, 2155, 5]"]
196["Segment<br>[2157, 2209, 5]"] 196["Segment<br>[2161, 2213, 5]"]
197["Segment<br>[2215, 2322, 5]"] 197["Segment<br>[2219, 2326, 5]"]
198["Segment<br>[2328, 2365, 5]"] 198["Segment<br>[2332, 2369, 5]"]
199["Segment<br>[2371, 2427, 5]"] 199["Segment<br>[2375, 2431, 5]"]
200["Segment<br>[2433, 2440, 5]"] 200["Segment<br>[2437, 2444, 5]"]
201[Solid2d] 201[Solid2d]
end end
subgraph path212 [Path] subgraph path212 [Path]
212["Path<br>[2949, 2996, 5]"] 212["Path<br>[2953, 3000, 5]"]
213["Segment<br>[3004, 3344, 5]"] 213["Segment<br>[3008, 3348, 5]"]
214["Segment<br>[3352, 3384, 5]"] 214["Segment<br>[3356, 3388, 5]"]
215["Segment<br>[3392, 3736, 5]"] 215["Segment<br>[3396, 3740, 5]"]
216["Segment<br>[3744, 3800, 5]"] 216["Segment<br>[3748, 3804, 5]"]
217["Segment<br>[3808, 3815, 5]"] 217["Segment<br>[3812, 3819, 5]"]
218[Solid2d] 218[Solid2d]
end end
subgraph path235 [Path] subgraph path235 [Path]
235["Path<br>[2949, 2996, 5]"] 235["Path<br>[2953, 3000, 5]"]
236["Segment<br>[3004, 3344, 5]"] 236["Segment<br>[3008, 3348, 5]"]
237["Segment<br>[3352, 3384, 5]"] 237["Segment<br>[3356, 3388, 5]"]
238["Segment<br>[3392, 3736, 5]"] 238["Segment<br>[3396, 3740, 5]"]
239["Segment<br>[3744, 3800, 5]"] 239["Segment<br>[3748, 3804, 5]"]
240["Segment<br>[3808, 3815, 5]"] 240["Segment<br>[3812, 3819, 5]"]
241[Solid2d] 241[Solid2d]
end end
subgraph path258 [Path] subgraph path258 [Path]
258["Path<br>[4343, 4438, 5]"] 258["Path<br>[4347, 4442, 5]"]
259["Segment<br>[4444, 4477, 5]"] 259["Segment<br>[4448, 4481, 5]"]
260["Segment<br>[4483, 4534, 5]"] 260["Segment<br>[4487, 4538, 5]"]
261["Segment<br>[4540, 4573, 5]"] 261["Segment<br>[4544, 4577, 5]"]
262["Segment<br>[4579, 4629, 5]"] 262["Segment<br>[4583, 4633, 5]"]
263["Segment<br>[4635, 4676, 5]"] 263["Segment<br>[4639, 4680, 5]"]
264["Segment<br>[4682, 4731, 5]"] 264["Segment<br>[4686, 4735, 5]"]
265["Segment<br>[4737, 4770, 5]"] 265["Segment<br>[4741, 4774, 5]"]
266["Segment<br>[4776, 4810, 5]"] 266["Segment<br>[4780, 4814, 5]"]
267["Segment<br>[4816, 4850, 5]"] 267["Segment<br>[4820, 4854, 5]"]
268["Segment<br>[4856, 4908, 5]"] 268["Segment<br>[4860, 4912, 5]"]
269["Segment<br>[4914, 4948, 5]"] 269["Segment<br>[4918, 4952, 5]"]
270["Segment<br>[4954, 5030, 5]"] 270["Segment<br>[4958, 5034, 5]"]
271["Segment<br>[5036, 5069, 5]"] 271["Segment<br>[5040, 5073, 5]"]
272["Segment<br>[5075, 5151, 5]"] 272["Segment<br>[5079, 5155, 5]"]
273["Segment<br>[5157, 5191, 5]"] 273["Segment<br>[5161, 5195, 5]"]
274["Segment<br>[5197, 5271, 5]"] 274["Segment<br>[5201, 5275, 5]"]
275["Segment<br>[5277, 5311, 5]"] 275["Segment<br>[5281, 5315, 5]"]
276["Segment<br>[5317, 5368, 5]"] 276["Segment<br>[5321, 5372, 5]"]
277["Segment<br>[5374, 5436, 5]"] 277["Segment<br>[5378, 5440, 5]"]
278["Segment<br>[5442, 5493, 5]"] 278["Segment<br>[5446, 5497, 5]"]
279["Segment<br>[5499, 5533, 5]"] 279["Segment<br>[5503, 5537, 5]"]
280["Segment<br>[5539, 5572, 5]"] 280["Segment<br>[5543, 5576, 5]"]
281["Segment<br>[5578, 5611, 5]"] 281["Segment<br>[5582, 5615, 5]"]
282["Segment<br>[5617, 5624, 5]"] 282["Segment<br>[5621, 5628, 5]"]
283[Solid2d] 283[Solid2d]
end end
subgraph path334 [Path] subgraph path334 [Path]
334["Path<br>[740, 780, 8]"] 334["Path<br>[744, 784, 8]"]
335["Segment<br>[788, 850, 8]"] 335["Segment<br>[792, 854, 8]"]
336["Segment<br>[858, 894, 8]"] 336["Segment<br>[862, 898, 8]"]
337["Segment<br>[902, 932, 8]"] 337["Segment<br>[906, 936, 8]"]
338["Segment<br>[940, 992, 8]"] 338["Segment<br>[944, 996, 8]"]
339["Segment<br>[1000, 1040, 8]"] 339["Segment<br>[1004, 1044, 8]"]
340["Segment<br>[1048, 1083, 8]"] 340["Segment<br>[1052, 1087, 8]"]
341["Segment<br>[1091, 1129, 8]"] 341["Segment<br>[1095, 1133, 8]"]
342["Segment<br>[1137, 1159, 8]"] 342["Segment<br>[1141, 1163, 8]"]
343["Segment<br>[1167, 1174, 8]"] 343["Segment<br>[1171, 1178, 8]"]
344[Solid2d] 344[Solid2d]
end end
subgraph path365 [Path] subgraph path365 [Path]
365["Path<br>[507, 588, 7]"] 365["Path<br>[511, 592, 7]"]
366["Segment<br>[594, 695, 7]"] 366["Segment<br>[598, 699, 7]"]
367["Segment<br>[701, 786, 7]"] 367["Segment<br>[705, 790, 7]"]
368["Segment<br>[792, 876, 7]"] 368["Segment<br>[796, 880, 7]"]
369["Segment<br>[882, 968, 7]"] 369["Segment<br>[886, 972, 7]"]
370["Segment<br>[974, 1059, 7]"] 370["Segment<br>[978, 1063, 7]"]
371["Segment<br>[1065, 1151, 7]"] 371["Segment<br>[1069, 1155, 7]"]
372["Segment<br>[1157, 1280, 7]"] 372["Segment<br>[1161, 1284, 7]"]
373["Segment<br>[1286, 1372, 7]"] 373["Segment<br>[1290, 1376, 7]"]
374["Segment<br>[1378, 1513, 7]"] 374["Segment<br>[1382, 1517, 7]"]
375["Segment<br>[1519, 1605, 7]"] 375["Segment<br>[1523, 1609, 7]"]
376["Segment<br>[1611, 1735, 7]"] 376["Segment<br>[1615, 1739, 7]"]
377["Segment<br>[1741, 1827, 7]"] 377["Segment<br>[1745, 1831, 7]"]
378["Segment<br>[1833, 1918, 7]"] 378["Segment<br>[1837, 1922, 7]"]
379["Segment<br>[1924, 2010, 7]"] 379["Segment<br>[1928, 2014, 7]"]
380["Segment<br>[2016, 2101, 7]"] 380["Segment<br>[2020, 2105, 7]"]
381["Segment<br>[2107, 2192, 7]"] 381["Segment<br>[2111, 2196, 7]"]
382["Segment<br>[2198, 2205, 7]"] 382["Segment<br>[2202, 2209, 7]"]
383[Solid2d] 383[Solid2d]
end end
subgraph path439 [Path] subgraph path439 [Path]
439["Path<br>[483, 540, 9]"] 439["Path<br>[487, 544, 9]"]
440["Segment<br>[546, 680, 9]"] 440["Segment<br>[550, 684, 9]"]
441["Segment<br>[686, 741, 9]"] 441["Segment<br>[690, 745, 9]"]
442["Segment<br>[747, 844, 9]"] 442["Segment<br>[751, 848, 9]"]
443["Segment<br>[850, 882, 9]"] 443["Segment<br>[854, 886, 9]"]
444["Segment<br>[888, 920, 9]"] 444["Segment<br>[892, 924, 9]"]
445["Segment<br>[926, 957, 9]"] 445["Segment<br>[930, 961, 9]"]
446["Segment<br>[963, 1078, 9]"] 446["Segment<br>[967, 1082, 9]"]
447["Segment<br>[1084, 1116, 9]"] 447["Segment<br>[1088, 1120, 9]"]
448["Segment<br>[1122, 1154, 9]"] 448["Segment<br>[1126, 1158, 9]"]
449["Segment<br>[1160, 1191, 9]"] 449["Segment<br>[1164, 1195, 9]"]
450["Segment<br>[1197, 1290, 9]"] 450["Segment<br>[1201, 1294, 9]"]
451["Segment<br>[1296, 1351, 9]"] 451["Segment<br>[1300, 1355, 9]"]
452["Segment<br>[1357, 1430, 9]"] 452["Segment<br>[1361, 1434, 9]"]
453["Segment<br>[1436, 1443, 9]"] 453["Segment<br>[1440, 1447, 9]"]
454[Solid2d] 454[Solid2d]
end end
1["Plane<br>[544, 561, 6]"] 1["Plane<br>[548, 565, 6]"]
5["Sweep Extrusion<br>[627, 683, 6]"] 5["Sweep Extrusion<br>[631, 687, 6]"]
6[Wall] 6[Wall]
7["Cap Start"] 7["Cap Start"]
8["Cap End"] 8["Cap End"]
9["SweepEdge Opposite"] 9["SweepEdge Opposite"]
10["SweepEdge Adjacent"] 10["SweepEdge Adjacent"]
14["Sweep Extrusion<br>[872, 934, 6]"] 14["Sweep Extrusion<br>[876, 938, 6]"]
15[Wall] 15[Wall]
16["Cap End"] 16["Cap End"]
17["SweepEdge Opposite"] 17["SweepEdge Opposite"]
18["SweepEdge Adjacent"] 18["SweepEdge Adjacent"]
22["Sweep Extrusion<br>[1184, 1263, 6]"] 22["Sweep Extrusion<br>[1188, 1267, 6]"]
23[Wall] 23[Wall]
24["SweepEdge Opposite"] 24["SweepEdge Opposite"]
25["SweepEdge Adjacent"] 25["SweepEdge Adjacent"]
26["Sweep Extrusion<br>[1184, 1263, 6]"] 26["Sweep Extrusion<br>[1188, 1267, 6]"]
27["Sweep Extrusion<br>[1184, 1263, 6]"] 27["Sweep Extrusion<br>[1188, 1267, 6]"]
28["Sweep Extrusion<br>[1184, 1263, 6]"] 28["Sweep Extrusion<br>[1188, 1267, 6]"]
29["Sweep Extrusion<br>[1184, 1263, 6]"] 29["Sweep Extrusion<br>[1188, 1267, 6]"]
33["Sweep Extrusion<br>[1466, 1499, 6]"] 33["Sweep Extrusion<br>[1470, 1503, 6]"]
34[Wall] 34[Wall]
35["Cap End"] 35["Cap End"]
36["SweepEdge Opposite"] 36["SweepEdge Opposite"]
37["SweepEdge Adjacent"] 37["SweepEdge Adjacent"]
41["Sweep Extrusion<br>[1630, 1695, 6]"] 41["Sweep Extrusion<br>[1634, 1699, 6]"]
42[Wall] 42[Wall]
43["Cap Start"] 43["Cap Start"]
44["Cap End"] 44["Cap End"]
45["SweepEdge Opposite"] 45["SweepEdge Opposite"]
46["SweepEdge Adjacent"] 46["SweepEdge Adjacent"]
50["Sweep Extrusion<br>[1948, 1992, 6]"] 50["Sweep Extrusion<br>[1952, 1996, 6]"]
51[Wall] 51[Wall]
52["SweepEdge Opposite"] 52["SweepEdge Opposite"]
53["SweepEdge Adjacent"] 53["SweepEdge Adjacent"]
54["Sweep Extrusion<br>[1948, 1992, 6]"] 54["Sweep Extrusion<br>[1952, 1996, 6]"]
55["Sweep Extrusion<br>[1948, 1992, 6]"] 55["Sweep Extrusion<br>[1952, 1996, 6]"]
56["Sweep Extrusion<br>[1948, 1992, 6]"] 56["Sweep Extrusion<br>[1952, 1996, 6]"]
57["Sweep Extrusion<br>[1948, 1992, 6]"] 57["Sweep Extrusion<br>[1952, 1996, 6]"]
61["Sweep Extrusion<br>[2271, 2315, 6]"] 61["Sweep Extrusion<br>[2275, 2319, 6]"]
62[Wall] 62[Wall]
63["Cap End"] 63["Cap End"]
64["SweepEdge Opposite"] 64["SweepEdge Opposite"]
65["SweepEdge Adjacent"] 65["SweepEdge Adjacent"]
66["Sweep Extrusion<br>[2271, 2315, 6]"] 66["Sweep Extrusion<br>[2275, 2319, 6]"]
67["Sweep Extrusion<br>[2271, 2315, 6]"] 67["Sweep Extrusion<br>[2275, 2319, 6]"]
68["Sweep Extrusion<br>[2271, 2315, 6]"] 68["Sweep Extrusion<br>[2275, 2319, 6]"]
69["Sweep Extrusion<br>[2271, 2315, 6]"] 69["Sweep Extrusion<br>[2275, 2319, 6]"]
70["Sweep Extrusion<br>[2271, 2315, 6]"] 70["Sweep Extrusion<br>[2275, 2319, 6]"]
71["Sweep Extrusion<br>[2271, 2315, 6]"] 71["Sweep Extrusion<br>[2275, 2319, 6]"]
72["Sweep Extrusion<br>[2271, 2315, 6]"] 72["Sweep Extrusion<br>[2275, 2319, 6]"]
73["Sweep Extrusion<br>[2271, 2315, 6]"] 73["Sweep Extrusion<br>[2275, 2319, 6]"]
74["Sweep Extrusion<br>[2271, 2315, 6]"] 74["Sweep Extrusion<br>[2275, 2319, 6]"]
75["Sweep Extrusion<br>[2271, 2315, 6]"] 75["Sweep Extrusion<br>[2275, 2319, 6]"]
76["Sweep Extrusion<br>[2271, 2315, 6]"] 76["Sweep Extrusion<br>[2275, 2319, 6]"]
77["Sweep Extrusion<br>[2271, 2315, 6]"] 77["Sweep Extrusion<br>[2275, 2319, 6]"]
78["Sweep Extrusion<br>[2271, 2315, 6]"] 78["Sweep Extrusion<br>[2275, 2319, 6]"]
79["Sweep Extrusion<br>[2271, 2315, 6]"] 79["Sweep Extrusion<br>[2275, 2319, 6]"]
80["Sweep Extrusion<br>[2271, 2315, 6]"] 80["Sweep Extrusion<br>[2275, 2319, 6]"]
88["Sweep Extrusion<br>[2724, 2792, 6]"] 88["Sweep Extrusion<br>[2728, 2796, 6]"]
89[Wall] 89[Wall]
90[Wall] 90[Wall]
91[Wall] 91[Wall]
@ -272,11 +272,11 @@ flowchart LR
99["SweepEdge Adjacent"] 99["SweepEdge Adjacent"]
100["SweepEdge Opposite"] 100["SweepEdge Opposite"]
101["SweepEdge Adjacent"] 101["SweepEdge Adjacent"]
102["Sweep Extrusion<br>[2724, 2792, 6]"] 102["Sweep Extrusion<br>[2728, 2796, 6]"]
103["Sweep Extrusion<br>[2724, 2792, 6]"] 103["Sweep Extrusion<br>[2728, 2796, 6]"]
104["Sweep Extrusion<br>[2724, 2792, 6]"] 104["Sweep Extrusion<br>[2728, 2796, 6]"]
105["Sweep Extrusion<br>[2724, 2792, 6]"] 105["Sweep Extrusion<br>[2728, 2796, 6]"]
113["Sweep Extrusion<br>[3198, 3272, 6]"] 113["Sweep Extrusion<br>[3202, 3276, 6]"]
114[Wall] 114[Wall]
115[Wall] 115[Wall]
116[Wall] 116[Wall]
@ -290,41 +290,41 @@ flowchart LR
124["SweepEdge Adjacent"] 124["SweepEdge Adjacent"]
125["SweepEdge Opposite"] 125["SweepEdge Opposite"]
126["SweepEdge Adjacent"] 126["SweepEdge Adjacent"]
127["Sweep Extrusion<br>[3198, 3272, 6]"] 127["Sweep Extrusion<br>[3202, 3276, 6]"]
128["Sweep Extrusion<br>[3198, 3272, 6]"] 128["Sweep Extrusion<br>[3202, 3276, 6]"]
129["Sweep Extrusion<br>[3198, 3272, 6]"] 129["Sweep Extrusion<br>[3202, 3276, 6]"]
130["Sweep Extrusion<br>[3198, 3272, 6]"] 130["Sweep Extrusion<br>[3202, 3276, 6]"]
131["Plane<br>[327, 344, 5]"] 131["Plane<br>[331, 348, 5]"]
138["Sweep Extrusion<br>[483, 516, 5]"] 138["Sweep Extrusion<br>[487, 520, 5]"]
139[Wall] 139[Wall]
140["Cap Start"] 140["Cap Start"]
141["Cap End"] 141["Cap End"]
142["SweepEdge Opposite"] 142["SweepEdge Opposite"]
143["SweepEdge Adjacent"] 143["SweepEdge Adjacent"]
150["Sweep Extrusion<br>[771, 804, 5]"] 150["Sweep Extrusion<br>[775, 808, 5]"]
151[Wall] 151[Wall]
152["Cap Start"] 152["Cap Start"]
153["Cap End"] 153["Cap End"]
154["SweepEdge Opposite"] 154["SweepEdge Opposite"]
155["SweepEdge Adjacent"] 155["SweepEdge Adjacent"]
159["Sweep Extrusion<br>[1106, 1140, 5]"] 159["Sweep Extrusion<br>[1110, 1144, 5]"]
160[Wall] 160[Wall]
161["SweepEdge Opposite"] 161["SweepEdge Opposite"]
162["SweepEdge Adjacent"] 162["SweepEdge Adjacent"]
163["Sweep Extrusion<br>[1106, 1140, 5]"] 163["Sweep Extrusion<br>[1110, 1144, 5]"]
164["Sweep Extrusion<br>[1106, 1140, 5]"] 164["Sweep Extrusion<br>[1110, 1144, 5]"]
165["Sweep Extrusion<br>[1106, 1140, 5]"] 165["Sweep Extrusion<br>[1110, 1144, 5]"]
166["Sweep Extrusion<br>[1106, 1140, 5]"] 166["Sweep Extrusion<br>[1110, 1144, 5]"]
170["Sweep Extrusion<br>[1444, 1478, 5]"] 170["Sweep Extrusion<br>[1448, 1482, 5]"]
171[Wall] 171[Wall]
172["SweepEdge Opposite"] 172["SweepEdge Opposite"]
173["SweepEdge Adjacent"] 173["SweepEdge Adjacent"]
174["Sweep Extrusion<br>[1444, 1478, 5]"] 174["Sweep Extrusion<br>[1448, 1482, 5]"]
175["Sweep Extrusion<br>[1444, 1478, 5]"] 175["Sweep Extrusion<br>[1448, 1482, 5]"]
176["Sweep Extrusion<br>[1444, 1478, 5]"] 176["Sweep Extrusion<br>[1448, 1482, 5]"]
177["Sweep Extrusion<br>[1444, 1478, 5]"] 177["Sweep Extrusion<br>[1448, 1482, 5]"]
178["Plane<br>[1632, 1649, 5]"] 178["Plane<br>[1636, 1653, 5]"]
186["Sweep Revolve<br>[1979, 1996, 5]"] 186["Sweep Revolve<br>[1983, 2000, 5]"]
187[Wall] 187[Wall]
188[Wall] 188[Wall]
189[Wall] 189[Wall]
@ -332,8 +332,8 @@ flowchart LR
191["SweepEdge Adjacent"] 191["SweepEdge Adjacent"]
192["SweepEdge Adjacent"] 192["SweepEdge Adjacent"]
193["SweepEdge Adjacent"] 193["SweepEdge Adjacent"]
194["Plane<br>[2082, 2099, 5]"] 194["Plane<br>[2086, 2103, 5]"]
202["Sweep Revolve<br>[2446, 2463, 5]"] 202["Sweep Revolve<br>[2450, 2467, 5]"]
203[Wall] 203[Wall]
204[Wall] 204[Wall]
205[Wall] 205[Wall]
@ -342,8 +342,8 @@ flowchart LR
208["SweepEdge Adjacent"] 208["SweepEdge Adjacent"]
209["SweepEdge Adjacent"] 209["SweepEdge Adjacent"]
210["SweepEdge Adjacent"] 210["SweepEdge Adjacent"]
211["Plane<br>[2918, 2941, 5]"] 211["Plane<br>[2922, 2945, 5]"]
219["Sweep Extrusion<br>[3863, 3909, 5]"] 219["Sweep Extrusion<br>[3867, 3913, 5]"]
220[Wall] 220[Wall]
221[Wall] 221[Wall]
222[Wall] 222[Wall]
@ -358,8 +358,8 @@ flowchart LR
231["SweepEdge Adjacent"] 231["SweepEdge Adjacent"]
232["SweepEdge Opposite"] 232["SweepEdge Opposite"]
233["SweepEdge Adjacent"] 233["SweepEdge Adjacent"]
234["Plane<br>[2918, 2941, 5]"] 234["Plane<br>[2922, 2945, 5]"]
242["Sweep Extrusion<br>[3863, 3909, 5]"] 242["Sweep Extrusion<br>[3867, 3913, 5]"]
243[Wall] 243[Wall]
244[Wall] 244[Wall]
245[Wall] 245[Wall]
@ -374,8 +374,8 @@ flowchart LR
254["SweepEdge Adjacent"] 254["SweepEdge Adjacent"]
255["SweepEdge Opposite"] 255["SweepEdge Opposite"]
256["SweepEdge Adjacent"] 256["SweepEdge Adjacent"]
257["Plane<br>[4320, 4337, 5]"] 257["Plane<br>[4324, 4341, 5]"]
284["Sweep Revolve<br>[5630, 5647, 5]"] 284["Sweep Revolve<br>[5634, 5651, 5]"]
285[Wall] 285[Wall]
286[Wall] 286[Wall]
287[Wall] 287[Wall]
@ -424,8 +424,8 @@ flowchart LR
330["SweepEdge Adjacent"] 330["SweepEdge Adjacent"]
331["SweepEdge Adjacent"] 331["SweepEdge Adjacent"]
332["SweepEdge Adjacent"] 332["SweepEdge Adjacent"]
333["Plane<br>[706, 732, 8]"] 333["Plane<br>[710, 736, 8]"]
345["Sweep Revolve<br>[1182, 1199, 8]"] 345["Sweep Revolve<br>[1186, 1203, 8]"]
346[Wall] 346[Wall]
347[Wall] 347[Wall]
348[Wall] 348[Wall]
@ -444,8 +444,8 @@ flowchart LR
361["SweepEdge Adjacent"] 361["SweepEdge Adjacent"]
362["SweepEdge Adjacent"] 362["SweepEdge Adjacent"]
363["SweepEdge Adjacent"] 363["SweepEdge Adjacent"]
364["Plane<br>[484, 501, 7]"] 364["Plane<br>[488, 505, 7]"]
384["Sweep Revolve<br>[2243, 2293, 7]"] 384["Sweep Revolve<br>[2247, 2297, 7]"]
385[Wall] 385[Wall]
386[Wall] 386[Wall]
387[Wall] 387[Wall]
@ -499,8 +499,8 @@ flowchart LR
435["SweepEdge Adjacent"] 435["SweepEdge Adjacent"]
436["SweepEdge Opposite"] 436["SweepEdge Opposite"]
437["SweepEdge Adjacent"] 437["SweepEdge Adjacent"]
438["Plane<br>[460, 477, 9]"] 438["Plane<br>[464, 481, 9]"]
455["Sweep Revolve<br>[1486, 1515, 9]"] 455["Sweep Revolve<br>[1490, 1519, 9]"]
456[Wall] 456[Wall]
457[Wall] 457[Wall]
458[Wall] 458[Wall]
@ -529,17 +529,17 @@ flowchart LR
481["SweepEdge Adjacent"] 481["SweepEdge Adjacent"]
482["SweepEdge Adjacent"] 482["SweepEdge Adjacent"]
483["SweepEdge Adjacent"] 483["SweepEdge Adjacent"]
484["StartSketchOnFace<br>[770, 797, 6]"] 484["StartSketchOnFace<br>[774, 801, 6]"]
485["StartSketchOnFace<br>[947, 978, 6]"] 485["StartSketchOnFace<br>[951, 982, 6]"]
486["StartSketchOnFace<br>[1385, 1414, 6]"] 486["StartSketchOnFace<br>[1389, 1418, 6]"]
487["StartSketchOnFace<br>[1524, 1558, 6]"] 487["StartSketchOnFace<br>[1528, 1562, 6]"]
488["StartSketchOnFace<br>[1709, 1742, 6]"] 488["StartSketchOnFace<br>[1713, 1746, 6]"]
489["StartSketchOnFace<br>[2009, 2038, 6]"] 489["StartSketchOnFace<br>[2013, 2042, 6]"]
490["StartSketchOnFace<br>[2338, 2367, 6]"] 490["StartSketchOnFace<br>[2342, 2371, 6]"]
491["StartSketchOnFace<br>[2821, 2854, 6]"] 491["StartSketchOnFace<br>[2825, 2858, 6]"]
492["StartSketchOnFace<br>[603, 632, 5]"] 492["StartSketchOnFace<br>[607, 636, 5]"]
493["StartSketchOnFace<br>[865, 899, 5]"] 493["StartSketchOnFace<br>[869, 903, 5]"]
494["StartSketchOnFace<br>[1202, 1231, 5]"] 494["StartSketchOnFace<br>[1206, 1235, 5]"]
1 --- 2 1 --- 2
2 --- 3 2 --- 3
2 ---- 5 2 ---- 5

View File

@ -12,10 +12,13 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "Kcl", "type": "Kcl",
"filename": "car-wheel.kcl" "filename": "car-wheel.kcl"
}, },
"preComments": [
"// Import parts"
],
"selector": { "selector": {
"type": "None", "type": "None",
"alias": { "alias": {
"commentStart": 155, "commentStart": 171,
"end": 0, "end": 0,
"name": "carWheel", "name": "carWheel",
"start": 0, "start": 0,
@ -27,7 +30,7 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 164, "commentStart": 180,
"end": 0, "end": 0,
"path": { "path": {
"type": "Kcl", "type": "Kcl",
@ -36,7 +39,7 @@ description: Result of parsing car-wheel-assembly.kcl
"selector": { "selector": {
"type": "None", "type": "None",
"alias": { "alias": {
"commentStart": 190, "commentStart": 206,
"end": 0, "end": 0,
"name": "carRotor", "name": "carRotor",
"start": 0, "start": 0,
@ -48,7 +51,7 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 199, "commentStart": 215,
"end": 0, "end": 0,
"path": { "path": {
"type": "Kcl", "type": "Kcl",
@ -57,7 +60,7 @@ description: Result of parsing car-wheel-assembly.kcl
"selector": { "selector": {
"type": "None", "type": "None",
"alias": { "alias": {
"commentStart": 229, "commentStart": 245,
"end": 0, "end": 0,
"name": "brakeCaliper", "name": "brakeCaliper",
"start": 0, "start": 0,
@ -69,7 +72,7 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 242, "commentStart": 258,
"end": 0, "end": 0,
"path": { "path": {
"type": "Kcl", "type": "Kcl",
@ -78,7 +81,7 @@ description: Result of parsing car-wheel-assembly.kcl
"selector": { "selector": {
"type": "None", "type": "None",
"alias": { "alias": {
"commentStart": 266, "commentStart": 282,
"end": 0, "end": 0,
"name": "lugNut", "name": "lugNut",
"start": 0, "start": 0,
@ -90,7 +93,7 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 273, "commentStart": 289,
"end": 0, "end": 0,
"path": { "path": {
"type": "Kcl", "type": "Kcl",
@ -99,7 +102,7 @@ description: Result of parsing car-wheel-assembly.kcl
"selector": { "selector": {
"type": "None", "type": "None",
"alias": { "alias": {
"commentStart": 298, "commentStart": 314,
"end": 0, "end": 0,
"name": "carTire", "name": "carTire",
"start": 0, "start": 0,
@ -111,46 +114,38 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 306, "commentStart": 321,
"end": 0, "end": 0,
"path": { "path": {
"type": "Kcl", "type": "Kcl",
"filename": "globals.kcl" "filename": "parameters.kcl"
}, },
"preComments": [
"",
"",
"// Import parameters"
],
"selector": { "selector": {
"type": "List", "commentStart": 351,
"items": [ "end": 0,
{ "start": 0,
"alias": null, "type": "Glob"
"commentStart": 313,
"end": 0,
"name": {
"commentStart": 313,
"end": 0,
"name": "lugCount",
"start": 0,
"type": "Identifier"
},
"start": 0,
"type": "ImportItem"
}
]
}, },
"start": 0, "start": 0,
"type": "ImportStatement", "type": "ImportStatement",
"type": "ImportStatement" "type": "ImportStatement"
}, },
{ {
"commentStart": 340, "commentStart": 374,
"end": 0, "end": 0,
"expression": { "expression": {
"body": [ "body": [
{ {
"abs_path": false, "abs_path": false,
"commentStart": 342, "commentStart": 399,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 342, "commentStart": 399,
"end": 0, "end": 0,
"name": "carRotor", "name": "carRotor",
"start": 0, "start": 0,
@ -166,14 +161,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 366, "commentStart": 423,
"end": 0, "end": 0,
"name": "x", "name": "x",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 370, "commentStart": 427,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -188,14 +183,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 373, "commentStart": 430,
"end": 0, "end": 0,
"name": "y", "name": "y",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 377, "commentStart": 434,
"end": 0, "end": 0,
"raw": "0.5", "raw": "0.5",
"start": 0, "start": 0,
@ -210,14 +205,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 382, "commentStart": 439,
"end": 0, "end": 0,
"name": "z", "name": "z",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 386, "commentStart": 443,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -232,10 +227,10 @@ description: Result of parsing car-wheel-assembly.kcl
], ],
"callee": { "callee": {
"abs_path": false, "abs_path": false,
"commentStart": 356, "commentStart": 413,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 356, "commentStart": 413,
"end": 0, "end": 0,
"name": "translate", "name": "translate",
"start": 0, "start": 0,
@ -245,7 +240,7 @@ description: Result of parsing car-wheel-assembly.kcl
"start": 0, "start": 0,
"type": "Name" "type": "Name"
}, },
"commentStart": 356, "commentStart": 413,
"end": 0, "end": 0,
"start": 0, "start": 0,
"type": "CallExpressionKw", "type": "CallExpressionKw",
@ -253,25 +248,48 @@ description: Result of parsing car-wheel-assembly.kcl
"unlabeled": null "unlabeled": null
} }
], ],
"commentStart": 342, "commentStart": 399,
"end": 0, "end": 0,
"nonCodeMeta": {
"nonCodeNodes": {
"1": [
{
"commentStart": 445,
"end": 0,
"start": 0,
"type": "NonCodeNode",
"value": {
"type": "newLineBlockComment",
"value": "Place the car wheel",
"style": "line"
}
}
]
},
"startNodes": []
},
"start": 0, "start": 0,
"type": "PipeExpression", "type": "PipeExpression",
"type": "PipeExpression" "type": "PipeExpression"
}, },
"preComments": [
"",
"",
"// Place the car rotor"
],
"start": 0, "start": 0,
"type": "ExpressionStatement", "type": "ExpressionStatement",
"type": "ExpressionStatement" "type": "ExpressionStatement"
}, },
{ {
"commentStart": 389, "commentStart": 470,
"end": 0, "end": 0,
"expression": { "expression": {
"abs_path": false, "abs_path": false,
"commentStart": 389, "commentStart": 470,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 389, "commentStart": 470,
"end": 0, "end": 0,
"name": "carWheel", "name": "carWheel",
"start": 0, "start": 0,
@ -287,16 +305,16 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ExpressionStatement" "type": "ExpressionStatement"
}, },
{ {
"commentStart": 398, "commentStart": 478,
"end": 0, "end": 0,
"expression": { "expression": {
"body": [ "body": [
{ {
"abs_path": false, "abs_path": false,
"commentStart": 398, "commentStart": 502,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 398, "commentStart": 502,
"end": 0, "end": 0,
"name": "lugNut", "name": "lugNut",
"start": 0, "start": 0,
@ -312,14 +330,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 436, "commentStart": 540,
"end": 0, "end": 0,
"name": "arcDegrees", "name": "arcDegrees",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 449, "commentStart": 553,
"end": 0, "end": 0,
"raw": "360", "raw": "360",
"start": 0, "start": 0,
@ -334,17 +352,17 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 461, "commentStart": 565,
"end": 0, "end": 0,
"name": "axis", "name": "axis",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 468, "commentStart": 572,
"elements": [ "elements": [
{ {
"commentStart": 469, "commentStart": 573,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -356,7 +374,7 @@ description: Result of parsing car-wheel-assembly.kcl
} }
}, },
{ {
"commentStart": 472, "commentStart": 576,
"end": 0, "end": 0,
"raw": "1", "raw": "1",
"start": 0, "start": 0,
@ -368,7 +386,7 @@ description: Result of parsing car-wheel-assembly.kcl
} }
}, },
{ {
"commentStart": 475, "commentStart": 579,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -389,17 +407,17 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 486, "commentStart": 590,
"end": 0, "end": 0,
"name": "center", "name": "center",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 495, "commentStart": 599,
"elements": [ "elements": [
{ {
"commentStart": 496, "commentStart": 600,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -411,7 +429,7 @@ description: Result of parsing car-wheel-assembly.kcl
} }
}, },
{ {
"commentStart": 499, "commentStart": 603,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -423,7 +441,7 @@ description: Result of parsing car-wheel-assembly.kcl
} }
}, },
{ {
"commentStart": 502, "commentStart": 606,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -444,7 +462,7 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 513, "commentStart": 617,
"end": 0, "end": 0,
"name": "instances", "name": "instances",
"start": 0, "start": 0,
@ -452,10 +470,10 @@ description: Result of parsing car-wheel-assembly.kcl
}, },
"arg": { "arg": {
"abs_path": false, "abs_path": false,
"commentStart": 525, "commentStart": 629,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 525, "commentStart": 629,
"end": 0, "end": 0,
"name": "lugCount", "name": "lugCount",
"start": 0, "start": 0,
@ -470,14 +488,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 542, "commentStart": 646,
"end": 0, "end": 0,
"name": "rotateDuplicates", "name": "rotateDuplicates",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 561, "commentStart": 665,
"end": 0, "end": 0,
"raw": "false", "raw": "false",
"start": 0, "start": 0,
@ -489,10 +507,10 @@ description: Result of parsing car-wheel-assembly.kcl
], ],
"callee": { "callee": {
"abs_path": false, "abs_path": false,
"commentStart": 410, "commentStart": 514,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 410, "commentStart": 514,
"end": 0, "end": 0,
"name": "patternCircular3d", "name": "patternCircular3d",
"start": 0, "start": 0,
@ -502,7 +520,7 @@ description: Result of parsing car-wheel-assembly.kcl
"start": 0, "start": 0,
"type": "Name" "type": "Name"
}, },
"commentStart": 410, "commentStart": 514,
"end": 0, "end": 0,
"start": 0, "start": 0,
"type": "CallExpressionKw", "type": "CallExpressionKw",
@ -510,27 +528,50 @@ description: Result of parsing car-wheel-assembly.kcl
"unlabeled": null "unlabeled": null
} }
], ],
"commentStart": 398, "commentStart": 502,
"end": 0, "end": 0,
"nonCodeMeta": {
"nonCodeNodes": {
"1": [
{
"commentStart": 678,
"end": 0,
"start": 0,
"type": "NonCodeNode",
"value": {
"type": "newLineBlockComment",
"value": "Place the brake caliper",
"style": "line"
}
}
]
},
"startNodes": []
},
"start": 0, "start": 0,
"type": "PipeExpression", "type": "PipeExpression",
"type": "PipeExpression" "type": "PipeExpression"
}, },
"preComments": [
"",
"",
"// Place the lug nuts"
],
"start": 0, "start": 0,
"type": "ExpressionStatement", "type": "ExpressionStatement",
"type": "ExpressionStatement" "type": "ExpressionStatement"
}, },
{ {
"commentStart": 575, "commentStart": 707,
"end": 0, "end": 0,
"expression": { "expression": {
"body": [ "body": [
{ {
"abs_path": false, "abs_path": false,
"commentStart": 575, "commentStart": 707,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 575, "commentStart": 707,
"end": 0, "end": 0,
"name": "brakeCaliper", "name": "brakeCaliper",
"start": 0, "start": 0,
@ -546,14 +587,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 603, "commentStart": 735,
"end": 0, "end": 0,
"name": "x", "name": "x",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 607, "commentStart": 739,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -568,14 +609,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 610, "commentStart": 742,
"end": 0, "end": 0,
"name": "y", "name": "y",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 614, "commentStart": 746,
"end": 0, "end": 0,
"raw": "0.5", "raw": "0.5",
"start": 0, "start": 0,
@ -590,14 +631,14 @@ description: Result of parsing car-wheel-assembly.kcl
{ {
"type": "LabeledArg", "type": "LabeledArg",
"label": { "label": {
"commentStart": 619, "commentStart": 751,
"end": 0, "end": 0,
"name": "z", "name": "z",
"start": 0, "start": 0,
"type": "Identifier" "type": "Identifier"
}, },
"arg": { "arg": {
"commentStart": 623, "commentStart": 755,
"end": 0, "end": 0,
"raw": "0", "raw": "0",
"start": 0, "start": 0,
@ -612,10 +653,10 @@ description: Result of parsing car-wheel-assembly.kcl
], ],
"callee": { "callee": {
"abs_path": false, "abs_path": false,
"commentStart": 593, "commentStart": 725,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 593, "commentStart": 725,
"end": 0, "end": 0,
"name": "translate", "name": "translate",
"start": 0, "start": 0,
@ -625,7 +666,7 @@ description: Result of parsing car-wheel-assembly.kcl
"start": 0, "start": 0,
"type": "Name" "type": "Name"
}, },
"commentStart": 593, "commentStart": 725,
"end": 0, "end": 0,
"start": 0, "start": 0,
"type": "CallExpressionKw", "type": "CallExpressionKw",
@ -633,8 +674,26 @@ description: Result of parsing car-wheel-assembly.kcl
"unlabeled": null "unlabeled": null
} }
], ],
"commentStart": 575, "commentStart": 707,
"end": 0, "end": 0,
"nonCodeMeta": {
"nonCodeNodes": {
"1": [
{
"commentStart": 757,
"end": 0,
"start": 0,
"type": "NonCodeNode",
"value": {
"type": "newLineBlockComment",
"value": "Place the car tire",
"style": "line"
}
}
]
},
"startNodes": []
},
"start": 0, "start": 0,
"type": "PipeExpression", "type": "PipeExpression",
"type": "PipeExpression" "type": "PipeExpression"
@ -644,14 +703,14 @@ description: Result of parsing car-wheel-assembly.kcl
"type": "ExpressionStatement" "type": "ExpressionStatement"
}, },
{ {
"commentStart": 626, "commentStart": 781,
"end": 0, "end": 0,
"expression": { "expression": {
"abs_path": false, "abs_path": false,
"commentStart": 626, "commentStart": 781,
"end": 0, "end": 0,
"name": { "name": {
"commentStart": 626, "commentStart": 781,
"end": 0, "end": 0,
"name": "carTire", "name": "carTire",
"start": 0, "start": 0,
@ -723,19 +782,7 @@ description: Result of parsing car-wheel-assembly.kcl
} }
], ],
"nonCodeMeta": { "nonCodeMeta": {
"nonCodeNodes": { "nonCodeNodes": {},
"5": [
{
"commentStart": 340,
"end": 0,
"start": 0,
"type": "NonCodeNode",
"value": {
"type": "newLine"
}
}
]
},
"startNodes": [ "startNodes": [
{ {
"commentStart": 127, "commentStart": 127,

View File

@ -1215,8 +1215,8 @@ description: Operations executed car-wheel-assembly.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "spoke", "name": "spoke",
"functionSourceRange": [ "functionSourceRange": [
2616, 2620,
4189, 4193,
5 5
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -1605,8 +1605,8 @@ description: Operations executed car-wheel-assembly.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "spoke", "name": "spoke",
"functionSourceRange": [ "functionSourceRange": [
2616, 2620,
4189, 4193,
5 5
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -2108,8 +2108,8 @@ description: Operations executed car-wheel-assembly.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "lug", "name": "lug",
"functionSourceRange": [ "functionSourceRange": [
664, 668,
1289, 1293,
8 8
], ],
"unlabeledArg": null, "unlabeledArg": null,

View File

@ -3,6 +3,32 @@ source: kcl-lib/src/simulation_tests.rs
description: Variables in memory after executing car-wheel-assembly.kcl description: Variables in memory after executing car-wheel-assembly.kcl
--- ---
{ {
"backSpacing": {
"type": "Number",
"value": 6.38,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"bendRadius": {
"type": "Number",
"value": 1.6,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"brakeCaliper": { "brakeCaliper": {
"type": "Module", "type": "Module",
"value": 7 "value": 7
@ -12,6 +38,71 @@ description: Variables in memory after executing car-wheel-assembly.kcl
"type": "TagIdentifier", "type": "TagIdentifier",
"value": "c1" "value": "c1"
}, },
"caliperInnerEdgeRadius": {
"type": "Number",
"value": 0.12,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"caliperOuterEdgeRadius": {
"type": "Number",
"value": 0.39,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"caliperPadLength": {
"type": "Number",
"value": 1.6,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"caliperThickness": {
"type": "Number",
"value": 0.39,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"caliperTolerance": {
"type": "Number",
"value": 0.05,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"carRotor": { "carRotor": {
"type": "Module", "type": "Module",
"value": 6 "value": 6
@ -24,6 +115,19 @@ description: Variables in memory after executing car-wheel-assembly.kcl
"type": "Module", "type": "Module",
"value": 5 "value": 5
}, },
"drillAndSlotCount": {
"type": "Number",
"value": 5.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"lugCount": { "lugCount": {
"type": "Number", "type": "Number",
"value": 5.0, "value": 5.0,
@ -37,8 +141,350 @@ description: Variables in memory after executing car-wheel-assembly.kcl
} }
} }
}, },
"lugDiameter": {
"type": "Number",
"value": 0.9449,
"ty": {
"type": "Unknown"
}
},
"lugHeadLength": {
"type": "Number",
"value": 0.4724,
"ty": {
"type": "Unknown"
}
},
"lugHolePatternDia": {
"type": "Number",
"value": 3.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"lugLength": {
"type": "Number",
"value": 1.1811,
"ty": {
"type": "Unknown"
}
},
"lugNut": { "lugNut": {
"type": "Module", "type": "Module",
"value": 8 "value": 8
},
"lugSpacing": {
"type": "Number",
"value": 4.5,
"ty": {
"type": "Unknown"
}
},
"lugThreadDepth": {
"type": "Number",
"value": 0.6811,
"ty": {
"type": "Unknown"
}
},
"lugThreadDiameter": {
"type": "Number",
"value": 0.4016,
"ty": {
"type": "Unknown"
}
},
"offset": {
"type": "Number",
"value": -1.378,
"ty": {
"type": "Unknown"
}
},
"rotorDiameter": {
"type": "Number",
"value": 12.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"rotorInnerDiameter": {
"type": "Number",
"value": 6.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"rotorInnerDiameterThickness": {
"type": "Number",
"value": 0.5,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"rotorSinglePlateThickness": {
"type": "Number",
"value": 0.25,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"rotorTotalThickness": {
"type": "Number",
"value": 1.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spacerCount": {
"type": "Number",
"value": 16.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spacerDiameter": {
"type": "Number",
"value": 0.25,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spacerLength": {
"type": "Number",
"value": 0.5,
"ty": {
"type": "Unknown"
}
},
"spacerPatternDiameter": {
"type": "Number",
"value": 11.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spokeAngle": {
"type": "Number",
"value": 0.02,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spokeCount": {
"type": "Number",
"value": 6.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spokeGap": {
"type": "Number",
"value": 0.2,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"spokeThickness": {
"type": "Number",
"value": 0.95,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireDepth": {
"type": "Number",
"value": 11.02,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireInnerDiameter": {
"type": "Number",
"value": 19.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireOuterDiameter": {
"type": "Number",
"value": 24.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireTreadDepth": {
"type": "Number",
"value": 0.39,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireTreadOffset": {
"type": "Number",
"value": 3.15,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"tireTreadWidth": {
"type": "Number",
"value": 0.39,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"wheelDiameter": {
"type": "Number",
"value": 19.0,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"wheelWidth": {
"type": "Number",
"value": 9.5,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
},
"yAxisOffset": {
"type": "Number",
"value": 0.5,
"ty": {
"type": "Default",
"len": {
"type": "Inches"
},
"angle": {
"type": "Degrees"
}
}
} }
} }

View File

@ -1,66 +1,66 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path7 [Path] subgraph path7 [Path]
7["Path<br>[769, 809, 0]"] 7["Path<br>[773, 813, 0]"]
8["Segment<br>[817, 864, 0]"] 8["Segment<br>[821, 868, 0]"]
9["Segment<br>[872, 978, 0]"] 9["Segment<br>[876, 982, 0]"]
10["Segment<br>[986, 1112, 0]"] 10["Segment<br>[990, 1116, 0]"]
11["Segment<br>[1120, 1176, 0]"] 11["Segment<br>[1124, 1180, 0]"]
12["Segment<br>[1184, 1191, 0]"] 12["Segment<br>[1188, 1195, 0]"]
13[Solid2d] 13[Solid2d]
end end
subgraph path29 [Path] subgraph path29 [Path]
29["Path<br>[769, 809, 0]"] 29["Path<br>[773, 813, 0]"]
30["Segment<br>[817, 864, 0]"] 30["Segment<br>[821, 868, 0]"]
31["Segment<br>[872, 978, 0]"] 31["Segment<br>[876, 982, 0]"]
32["Segment<br>[986, 1112, 0]"] 32["Segment<br>[990, 1116, 0]"]
33["Segment<br>[1120, 1176, 0]"] 33["Segment<br>[1124, 1180, 0]"]
34["Segment<br>[1184, 1191, 0]"] 34["Segment<br>[1188, 1195, 0]"]
35[Solid2d] 35[Solid2d]
end end
subgraph path51 [Path] subgraph path51 [Path]
51["Path<br>[769, 809, 0]"] 51["Path<br>[773, 813, 0]"]
52["Segment<br>[817, 864, 0]"] 52["Segment<br>[821, 868, 0]"]
53["Segment<br>[872, 978, 0]"] 53["Segment<br>[876, 982, 0]"]
54["Segment<br>[986, 1112, 0]"] 54["Segment<br>[990, 1116, 0]"]
55["Segment<br>[1120, 1176, 0]"] 55["Segment<br>[1124, 1180, 0]"]
56["Segment<br>[1184, 1191, 0]"] 56["Segment<br>[1188, 1195, 0]"]
57[Solid2d] 57[Solid2d]
end end
subgraph path73 [Path] subgraph path73 [Path]
73["Path<br>[769, 809, 0]"] 73["Path<br>[773, 813, 0]"]
74["Segment<br>[817, 864, 0]"] 74["Segment<br>[821, 868, 0]"]
75["Segment<br>[872, 978, 0]"] 75["Segment<br>[876, 982, 0]"]
76["Segment<br>[986, 1112, 0]"] 76["Segment<br>[990, 1116, 0]"]
77["Segment<br>[1120, 1176, 0]"] 77["Segment<br>[1124, 1180, 0]"]
78["Segment<br>[1184, 1191, 0]"] 78["Segment<br>[1188, 1195, 0]"]
79[Solid2d] 79[Solid2d]
end end
subgraph path95 [Path] subgraph path95 [Path]
95["Path<br>[769, 809, 0]"] 95["Path<br>[773, 813, 0]"]
96["Segment<br>[817, 864, 0]"] 96["Segment<br>[821, 868, 0]"]
97["Segment<br>[872, 978, 0]"] 97["Segment<br>[876, 982, 0]"]
98["Segment<br>[986, 1112, 0]"] 98["Segment<br>[990, 1116, 0]"]
99["Segment<br>[1120, 1176, 0]"] 99["Segment<br>[1124, 1180, 0]"]
100["Segment<br>[1184, 1191, 0]"] 100["Segment<br>[1188, 1195, 0]"]
101[Solid2d] 101[Solid2d]
end end
subgraph path117 [Path] subgraph path117 [Path]
117["Path<br>[769, 809, 0]"] 117["Path<br>[773, 813, 0]"]
118["Segment<br>[817, 864, 0]"] 118["Segment<br>[821, 868, 0]"]
119["Segment<br>[872, 978, 0]"] 119["Segment<br>[876, 982, 0]"]
120["Segment<br>[986, 1112, 0]"] 120["Segment<br>[990, 1116, 0]"]
121["Segment<br>[1120, 1176, 0]"] 121["Segment<br>[1124, 1180, 0]"]
122["Segment<br>[1184, 1191, 0]"] 122["Segment<br>[1188, 1195, 0]"]
123[Solid2d] 123[Solid2d]
end end
1["Plane<br>[352, 386, 0]"] 1["Plane<br>[356, 390, 0]"]
2["Plane<br>[401, 436, 0]"] 2["Plane<br>[405, 440, 0]"]
3["Plane<br>[450, 485, 0]"] 3["Plane<br>[454, 489, 0]"]
4["Plane<br>[500, 536, 0]"] 4["Plane<br>[504, 540, 0]"]
5["Plane<br>[548, 598, 0]"] 5["Plane<br>[552, 602, 0]"]
6["Plane<br>[611, 646, 0]"] 6["Plane<br>[615, 650, 0]"]
14["Sweep Extrusion<br>[1199, 1233, 0]"] 14["Sweep Extrusion<br>[1203, 1237, 0]"]
15[Wall] 15[Wall]
16[Wall] 16[Wall]
17[Wall] 17[Wall]
@ -75,7 +75,7 @@ flowchart LR
26["SweepEdge Adjacent"] 26["SweepEdge Adjacent"]
27["SweepEdge Opposite"] 27["SweepEdge Opposite"]
28["SweepEdge Adjacent"] 28["SweepEdge Adjacent"]
36["Sweep Extrusion<br>[1199, 1233, 0]"] 36["Sweep Extrusion<br>[1203, 1237, 0]"]
37[Wall] 37[Wall]
38[Wall] 38[Wall]
39[Wall] 39[Wall]
@ -90,7 +90,7 @@ flowchart LR
48["SweepEdge Adjacent"] 48["SweepEdge Adjacent"]
49["SweepEdge Opposite"] 49["SweepEdge Opposite"]
50["SweepEdge Adjacent"] 50["SweepEdge Adjacent"]
58["Sweep Extrusion<br>[1199, 1233, 0]"] 58["Sweep Extrusion<br>[1203, 1237, 0]"]
59[Wall] 59[Wall]
60[Wall] 60[Wall]
61[Wall] 61[Wall]
@ -105,7 +105,7 @@ flowchart LR
70["SweepEdge Adjacent"] 70["SweepEdge Adjacent"]
71["SweepEdge Opposite"] 71["SweepEdge Opposite"]
72["SweepEdge Adjacent"] 72["SweepEdge Adjacent"]
80["Sweep Extrusion<br>[1199, 1233, 0]"] 80["Sweep Extrusion<br>[1203, 1237, 0]"]
81[Wall] 81[Wall]
82[Wall] 82[Wall]
83[Wall] 83[Wall]
@ -120,7 +120,7 @@ flowchart LR
92["SweepEdge Adjacent"] 92["SweepEdge Adjacent"]
93["SweepEdge Opposite"] 93["SweepEdge Opposite"]
94["SweepEdge Adjacent"] 94["SweepEdge Adjacent"]
102["Sweep Extrusion<br>[1199, 1233, 0]"] 102["Sweep Extrusion<br>[1203, 1237, 0]"]
103[Wall] 103[Wall]
104[Wall] 104[Wall]
105[Wall] 105[Wall]
@ -135,7 +135,7 @@ flowchart LR
114["SweepEdge Adjacent"] 114["SweepEdge Adjacent"]
115["SweepEdge Opposite"] 115["SweepEdge Opposite"]
116["SweepEdge Adjacent"] 116["SweepEdge Adjacent"]
124["Sweep Extrusion<br>[1199, 1233, 0]"] 124["Sweep Extrusion<br>[1203, 1237, 0]"]
125[Wall] 125[Wall]
126[Wall] 126[Wall]
127[Wall] 127[Wall]

File diff suppressed because it is too large Load Diff

View File

@ -153,8 +153,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -203,8 +203,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -253,8 +253,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -303,8 +303,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -353,8 +353,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -403,8 +403,8 @@ description: Operations executed color-cube.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "sketchRectangle", "name": "sketchRectangle",
"functionSourceRange": [ "functionSourceRange": [
726, 730,
1326, 1330,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,

View File

@ -1,57 +1,57 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[587, 821, 0]"] 2["Path<br>[631, 865, 0]"]
3["Segment<br>[831, 964, 0]"] 3["Segment<br>[875, 1008, 0]"]
4["Segment<br>[974, 1065, 0]"] 4["Segment<br>[1018, 1109, 0]"]
5["Segment<br>[1075, 1130, 0]"] 5["Segment<br>[1119, 1174, 0]"]
6["Segment<br>[1140, 1231, 0]"] 6["Segment<br>[1184, 1275, 0]"]
7["Segment<br>[1241, 1296, 0]"] 7["Segment<br>[1285, 1340, 0]"]
8["Segment<br>[1306, 1362, 0]"] 8["Segment<br>[1350, 1406, 0]"]
9["Segment<br>[1372, 1380, 0]"] 9["Segment<br>[1416, 1424, 0]"]
10[Solid2d] 10[Solid2d]
end end
subgraph path11 [Path] subgraph path11 [Path]
11["Path<br>[1395, 1445, 0]"] 11["Path<br>[1439, 1489, 0]"]
12["Segment<br>[1395, 1445, 0]"] 12["Segment<br>[1439, 1489, 0]"]
13[Solid2d] 13[Solid2d]
end end
subgraph path15 [Path] subgraph path15 [Path]
15["Path<br>[587, 821, 0]"] 15["Path<br>[631, 865, 0]"]
16["Segment<br>[831, 964, 0]"] 16["Segment<br>[875, 1008, 0]"]
17["Segment<br>[974, 1065, 0]"] 17["Segment<br>[1018, 1109, 0]"]
18["Segment<br>[1075, 1130, 0]"] 18["Segment<br>[1119, 1174, 0]"]
19["Segment<br>[1140, 1231, 0]"] 19["Segment<br>[1184, 1275, 0]"]
20["Segment<br>[1241, 1296, 0]"] 20["Segment<br>[1285, 1340, 0]"]
21["Segment<br>[1306, 1362, 0]"] 21["Segment<br>[1350, 1406, 0]"]
22["Segment<br>[1372, 1380, 0]"] 22["Segment<br>[1416, 1424, 0]"]
23[Solid2d] 23[Solid2d]
end end
subgraph path24 [Path] subgraph path24 [Path]
24["Path<br>[1395, 1445, 0]"] 24["Path<br>[1439, 1489, 0]"]
25["Segment<br>[1395, 1445, 0]"] 25["Segment<br>[1439, 1489, 0]"]
26[Solid2d] 26[Solid2d]
end end
subgraph path28 [Path] subgraph path28 [Path]
28["Path<br>[587, 821, 0]"] 28["Path<br>[631, 865, 0]"]
35["Segment<br>[1372, 1380, 0]"] 35["Segment<br>[1416, 1424, 0]"]
36[Solid2d] 36[Solid2d]
end end
subgraph path37 [Path] subgraph path37 [Path]
37["Path<br>[1395, 1445, 0]"] 37["Path<br>[1439, 1489, 0]"]
38["Segment<br>[1395, 1445, 0]"] 38["Segment<br>[1439, 1489, 0]"]
39[Solid2d] 39[Solid2d]
end end
1["Plane<br>[543, 576, 0]"] 1["Plane<br>[587, 620, 0]"]
14["Plane<br>[543, 576, 0]"] 14["Plane<br>[587, 620, 0]"]
27["Plane<br>[543, 576, 0]"] 27["Plane<br>[587, 620, 0]"]
29["SweepEdge Opposite"] 29["SweepEdge Opposite"]
30["SweepEdge Opposite"] 30["SweepEdge Opposite"]
31["SweepEdge Opposite"] 31["SweepEdge Opposite"]
32["SweepEdge Opposite"] 32["SweepEdge Opposite"]
33["SweepEdge Opposite"] 33["SweepEdge Opposite"]
34["SweepEdge Opposite"] 34["SweepEdge Opposite"]
40["Sweep Loft<br>[1575, 1664, 0]"] 40["Sweep Loft<br>[1619, 1708, 0]"]
41[Wall] 41[Wall]
42[Wall] 42[Wall]
43[Wall] 43[Wall]
@ -66,9 +66,9 @@ flowchart LR
52["SweepEdge Adjacent"] 52["SweepEdge Adjacent"]
53["SweepEdge Adjacent"] 53["SweepEdge Adjacent"]
54["SweepEdge Adjacent"] 54["SweepEdge Adjacent"]
55["StartSketchOnPlane<br>[529, 577, 0]"] 55["StartSketchOnPlane<br>[573, 621, 0]"]
56["StartSketchOnPlane<br>[529, 577, 0]"] 56["StartSketchOnPlane<br>[573, 621, 0]"]
57["StartSketchOnPlane<br>[529, 577, 0]"] 57["StartSketchOnPlane<br>[573, 621, 0]"]
1 --- 2 1 --- 2
1 --- 11 1 --- 11
2 --- 3 2 --- 3

File diff suppressed because it is too large Load Diff

View File

@ -9,8 +9,8 @@ description: Operations executed cycloidal-gear.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "cycloidalGear", "name": "cycloidalGear",
"functionSourceRange": [ "functionSourceRange": [
221, 265,
1685, 1729,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -24,8 +24,8 @@ description: Operations executed cycloidal-gear.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "gearSketch", "name": "gearSketch",
"functionSourceRange": [ "functionSourceRange": [
447, 491,
1476, 1520,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -185,8 +185,8 @@ description: Operations executed cycloidal-gear.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "gearSketch", "name": "gearSketch",
"functionSourceRange": [ "functionSourceRange": [
447, 491,
1476, 1520,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -340,8 +340,8 @@ description: Operations executed cycloidal-gear.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "gearSketch", "name": "gearSketch",
"functionSourceRange": [ "functionSourceRange": [
447, 491,
1476, 1520,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,

View File

@ -99,7 +99,7 @@ description: Result of parsing dodecahedron.kcl
"", "",
"", "",
"// Calculated parameters", "// Calculated parameters",
"// thickness of the dodecahedron" "// Thickness of the dodecahedron"
], ],
"start": 0, "start": 0,
"type": "VariableDeclaration", "type": "VariableDeclaration",
@ -213,7 +213,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// angle between faces in radians" "// Angle between faces in radians"
], ],
"start": 0, "start": 0,
"type": "VariableDeclaration", "type": "VariableDeclaration",
@ -383,7 +383,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// inscribed radius" "// Inscribed radius"
], ],
"start": 0, "start": 0,
"type": "VariableDeclaration", "type": "VariableDeclaration",
@ -553,7 +553,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// pentagon edge length" "// Pentagon edge length"
], ],
"start": 0, "start": 0,
"type": "VariableDeclaration", "type": "VariableDeclaration",
@ -683,7 +683,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// pentagon radius" "// Pentagon radius"
], ],
"start": 0, "start": 0,
"type": "VariableDeclaration", "type": "VariableDeclaration",
@ -2493,7 +2493,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// pattern the bottom to create the top face" "// Pattern the bottom to create the top face"
], ],
"start": 0, "start": 0,
"type": "ExpressionStatement", "type": "ExpressionStatement",
@ -2722,7 +2722,7 @@ description: Result of parsing dodecahedron.kcl
"preComments": [ "preComments": [
"", "",
"", "",
"// pattern the bottom angled faces to create the top" "// Pattern the bottom angled faces to create the top"
], ],
"start": 0, "start": 0,
"type": "ExpressionStatement", "type": "ExpressionStatement",

View File

@ -1,119 +1,119 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[662, 696, 0]"] 2["Path<br>[672, 706, 0]"]
3["Segment<br>[702, 734, 0]"] 3["Segment<br>[712, 744, 0]"]
4["Segment<br>[740, 772, 0]"] 4["Segment<br>[750, 782, 0]"]
5["Segment<br>[778, 811, 0]"] 5["Segment<br>[788, 821, 0]"]
6["Segment<br>[817, 873, 0]"] 6["Segment<br>[827, 883, 0]"]
7["Segment<br>[879, 886, 0]"] 7["Segment<br>[889, 896, 0]"]
8[Solid2d] 8[Solid2d]
end end
subgraph path32 [Path] subgraph path32 [Path]
32["Path<br>[1279, 1332, 0]"] 32["Path<br>[1289, 1342, 0]"]
33["Segment<br>[1338, 1370, 0]"] 33["Segment<br>[1348, 1380, 0]"]
34["Segment<br>[1376, 1408, 0]"] 34["Segment<br>[1386, 1418, 0]"]
35["Segment<br>[1414, 1447, 0]"] 35["Segment<br>[1424, 1457, 0]"]
36["Segment<br>[1453, 1509, 0]"] 36["Segment<br>[1463, 1519, 0]"]
37["Segment<br>[1515, 1522, 0]"] 37["Segment<br>[1525, 1532, 0]"]
38[Solid2d] 38[Solid2d]
end end
subgraph path59 [Path] subgraph path59 [Path]
59["Path<br>[1787, 1840, 0]"] 59["Path<br>[1797, 1850, 0]"]
60["Segment<br>[1846, 1878, 0]"] 60["Segment<br>[1856, 1888, 0]"]
61["Segment<br>[1884, 1916, 0]"] 61["Segment<br>[1894, 1926, 0]"]
62["Segment<br>[1922, 1955, 0]"] 62["Segment<br>[1932, 1965, 0]"]
63["Segment<br>[1961, 2017, 0]"] 63["Segment<br>[1971, 2027, 0]"]
64["Segment<br>[2023, 2030, 0]"] 64["Segment<br>[2033, 2040, 0]"]
65[Solid2d] 65[Solid2d]
end end
subgraph path83 [Path] subgraph path83 [Path]
83["Path<br>[2426, 2481, 0]"] 83["Path<br>[2436, 2491, 0]"]
84["Segment<br>[2487, 2519, 0]"] 84["Segment<br>[2497, 2529, 0]"]
85["Segment<br>[2525, 2557, 0]"] 85["Segment<br>[2535, 2567, 0]"]
86["Segment<br>[2563, 2596, 0]"] 86["Segment<br>[2573, 2606, 0]"]
87["Segment<br>[2602, 2658, 0]"] 87["Segment<br>[2612, 2668, 0]"]
88["Segment<br>[2664, 2671, 0]"] 88["Segment<br>[2674, 2681, 0]"]
89[Solid2d] 89[Solid2d]
end end
subgraph path111 [Path] subgraph path111 [Path]
111["Path<br>[2973, 3011, 0]"] 111["Path<br>[2983, 3021, 0]"]
112["Segment<br>[3017, 3049, 0]"] 112["Segment<br>[3027, 3059, 0]"]
113["Segment<br>[3055, 3081, 0]"] 113["Segment<br>[3065, 3091, 0]"]
114["Segment<br>[3087, 3120, 0]"] 114["Segment<br>[3097, 3130, 0]"]
115["Segment<br>[3126, 3182, 0]"] 115["Segment<br>[3136, 3192, 0]"]
116["Segment<br>[3188, 3195, 0]"] 116["Segment<br>[3198, 3205, 0]"]
117[Solid2d] 117[Solid2d]
end end
subgraph path134 [Path] subgraph path134 [Path]
134["Path<br>[3378, 3431, 0]"] 134["Path<br>[3388, 3441, 0]"]
135["Segment<br>[3437, 3469, 0]"] 135["Segment<br>[3447, 3479, 0]"]
136["Segment<br>[3475, 3507, 0]"] 136["Segment<br>[3485, 3517, 0]"]
137["Segment<br>[3513, 3546, 0]"] 137["Segment<br>[3523, 3556, 0]"]
138["Segment<br>[3552, 3608, 0]"] 138["Segment<br>[3562, 3618, 0]"]
139["Segment<br>[3614, 3621, 0]"] 139["Segment<br>[3624, 3631, 0]"]
140[Solid2d] 140[Solid2d]
end end
subgraph path158 [Path] subgraph path158 [Path]
158["Path<br>[3849, 3886, 0]"] 158["Path<br>[3859, 3896, 0]"]
159["Segment<br>[3892, 3918, 0]"] 159["Segment<br>[3902, 3928, 0]"]
160["Segment<br>[3924, 3950, 0]"] 160["Segment<br>[3934, 3960, 0]"]
161["Segment<br>[3956, 3983, 0]"] 161["Segment<br>[3966, 3993, 0]"]
162["Segment<br>[3989, 4045, 0]"] 162["Segment<br>[3999, 4055, 0]"]
163["Segment<br>[4051, 4058, 0]"] 163["Segment<br>[4061, 4068, 0]"]
164[Solid2d] 164[Solid2d]
end end
subgraph path180 [Path] subgraph path180 [Path]
180["Path<br>[4340, 4408, 0]"] 180["Path<br>[4350, 4418, 0]"]
181["Segment<br>[4414, 4440, 0]"] 181["Segment<br>[4424, 4450, 0]"]
182["Segment<br>[4446, 4472, 0]"] 182["Segment<br>[4456, 4482, 0]"]
183["Segment<br>[4478, 4505, 0]"] 183["Segment<br>[4488, 4515, 0]"]
184["Segment<br>[4511, 4567, 0]"] 184["Segment<br>[4521, 4577, 0]"]
185["Segment<br>[4573, 4580, 0]"] 185["Segment<br>[4583, 4590, 0]"]
186[Solid2d] 186[Solid2d]
end end
subgraph path202 [Path] subgraph path202 [Path]
202["Path<br>[4769, 4890, 0]"] 202["Path<br>[4779, 4900, 0]"]
203["Segment<br>[4896, 4945, 0]"] 203["Segment<br>[4906, 4955, 0]"]
204["Segment<br>[4951, 4999, 0]"] 204["Segment<br>[4961, 5009, 0]"]
205["Segment<br>[5005, 5053, 0]"] 205["Segment<br>[5015, 5063, 0]"]
206["Segment<br>[5059, 5115, 0]"] 206["Segment<br>[5069, 5125, 0]"]
207["Segment<br>[5121, 5128, 0]"] 207["Segment<br>[5131, 5138, 0]"]
208[Solid2d] 208[Solid2d]
end end
subgraph path225 [Path] subgraph path225 [Path]
225["Path<br>[5660, 5701, 0]"] 225["Path<br>[5670, 5711, 0]"]
226["Segment<br>[5707, 5739, 0]"] 226["Segment<br>[5717, 5749, 0]"]
227["Segment<br>[5745, 5770, 0]"] 227["Segment<br>[5755, 5780, 0]"]
228["Segment<br>[5776, 5809, 0]"] 228["Segment<br>[5786, 5819, 0]"]
229["Segment<br>[5815, 5871, 0]"] 229["Segment<br>[5825, 5881, 0]"]
230["Segment<br>[5877, 5884, 0]"] 230["Segment<br>[5887, 5894, 0]"]
231[Solid2d] 231[Solid2d]
end end
subgraph path252 [Path] subgraph path252 [Path]
252["Path<br>[6171, 6212, 0]"] 252["Path<br>[6181, 6222, 0]"]
253["Segment<br>[6218, 6244, 0]"] 253["Segment<br>[6228, 6254, 0]"]
254["Segment<br>[6250, 6282, 0]"] 254["Segment<br>[6260, 6292, 0]"]
255["Segment<br>[6288, 6315, 0]"] 255["Segment<br>[6298, 6325, 0]"]
256["Segment<br>[6321, 6377, 0]"] 256["Segment<br>[6331, 6387, 0]"]
257["Segment<br>[6383, 6390, 0]"] 257["Segment<br>[6393, 6400, 0]"]
258[Solid2d] 258[Solid2d]
end end
subgraph path276 [Path] subgraph path276 [Path]
276["Path<br>[6867, 6917, 0]"] 276["Path<br>[6877, 6927, 0]"]
277["Segment<br>[6923, 6960, 0]"] 277["Segment<br>[6933, 6970, 0]"]
278["Segment<br>[6966, 7050, 0]"] 278["Segment<br>[6976, 7060, 0]"]
279["Segment<br>[7056, 7092, 0]"] 279["Segment<br>[7066, 7102, 0]"]
280["Segment<br>[7098, 7190, 0]"] 280["Segment<br>[7108, 7200, 0]"]
281["Segment<br>[7196, 7232, 0]"] 281["Segment<br>[7206, 7242, 0]"]
end end
subgraph path283 [Path] subgraph path283 [Path]
283["Path<br>[7295, 7406, 0]"] 283["Path<br>[7305, 7416, 0]"]
284["Segment<br>[7295, 7406, 0]"] 284["Segment<br>[7305, 7416, 0]"]
285[Solid2d] 285[Solid2d]
end end
1["Plane<br>[555, 572, 0]"] 1["Plane<br>[565, 582, 0]"]
9["Sweep Extrusion<br>[1047, 1074, 0]"] 9["Sweep Extrusion<br>[1057, 1084, 0]"]
10[Wall] 10[Wall]
11[Wall] 11[Wall]
12[Wall] 12[Wall]
@ -128,15 +128,15 @@ flowchart LR
21["SweepEdge Adjacent"] 21["SweepEdge Adjacent"]
22["SweepEdge Opposite"] 22["SweepEdge Opposite"]
23["SweepEdge Adjacent"] 23["SweepEdge Adjacent"]
24["Sweep Extrusion<br>[1047, 1074, 0]"] 24["Sweep Extrusion<br>[1057, 1084, 0]"]
25["Sweep Extrusion<br>[1047, 1074, 0]"] 25["Sweep Extrusion<br>[1057, 1084, 0]"]
26["Sweep Extrusion<br>[1047, 1074, 0]"] 26["Sweep Extrusion<br>[1057, 1084, 0]"]
27["Sweep Extrusion<br>[1047, 1074, 0]"] 27["Sweep Extrusion<br>[1057, 1084, 0]"]
28["Sweep Extrusion<br>[1047, 1074, 0]"] 28["Sweep Extrusion<br>[1057, 1084, 0]"]
29["Sweep Extrusion<br>[1047, 1074, 0]"] 29["Sweep Extrusion<br>[1057, 1084, 0]"]
30["Sweep Extrusion<br>[1047, 1074, 0]"] 30["Sweep Extrusion<br>[1057, 1084, 0]"]
31["Plane<br>[1206, 1260, 0]"] 31["Plane<br>[1216, 1270, 0]"]
39["Sweep Extrusion<br>[1685, 1719, 0]"] 39["Sweep Extrusion<br>[1695, 1729, 0]"]
40[Wall] 40[Wall]
41[Wall] 41[Wall]
42[Wall] 42[Wall]
@ -151,12 +151,12 @@ flowchart LR
51["SweepEdge Adjacent"] 51["SweepEdge Adjacent"]
52["SweepEdge Opposite"] 52["SweepEdge Opposite"]
53["SweepEdge Adjacent"] 53["SweepEdge Adjacent"]
54["Sweep Extrusion<br>[1685, 1719, 0]"] 54["Sweep Extrusion<br>[1695, 1729, 0]"]
55["Sweep Extrusion<br>[1685, 1719, 0]"] 55["Sweep Extrusion<br>[1695, 1729, 0]"]
56["Sweep Extrusion<br>[1685, 1719, 0]"] 56["Sweep Extrusion<br>[1695, 1729, 0]"]
57["Sweep Extrusion<br>[1685, 1719, 0]"] 57["Sweep Extrusion<br>[1695, 1729, 0]"]
58["Sweep Extrusion<br>[1685, 1719, 0]"] 58["Sweep Extrusion<br>[1695, 1729, 0]"]
66["Sweep Extrusion<br>[2129, 2163, 0]"] 66["Sweep Extrusion<br>[2139, 2173, 0]"]
67[Wall] 67[Wall]
68[Wall] 68[Wall]
69[Wall] 69[Wall]
@ -171,9 +171,9 @@ flowchart LR
78["SweepEdge Adjacent"] 78["SweepEdge Adjacent"]
79["SweepEdge Opposite"] 79["SweepEdge Opposite"]
80["SweepEdge Adjacent"] 80["SweepEdge Adjacent"]
81["Sweep Extrusion<br>[2129, 2163, 0]"] 81["Sweep Extrusion<br>[2139, 2173, 0]"]
82["Plane<br>[2280, 2331, 0]"] 82["Plane<br>[2290, 2341, 0]"]
90["Sweep Extrusion<br>[2834, 2869, 0]"] 90["Sweep Extrusion<br>[2844, 2879, 0]"]
91[Wall] 91[Wall]
92[Wall] 92[Wall]
93[Wall] 93[Wall]
@ -188,13 +188,13 @@ flowchart LR
102["SweepEdge Adjacent"] 102["SweepEdge Adjacent"]
103["SweepEdge Opposite"] 103["SweepEdge Opposite"]
104["SweepEdge Adjacent"] 104["SweepEdge Adjacent"]
105["Sweep Extrusion<br>[2834, 2869, 0]"] 105["Sweep Extrusion<br>[2844, 2879, 0]"]
106["Sweep Extrusion<br>[2834, 2869, 0]"] 106["Sweep Extrusion<br>[2844, 2879, 0]"]
107["Sweep Extrusion<br>[2834, 2869, 0]"] 107["Sweep Extrusion<br>[2844, 2879, 0]"]
108["Sweep Extrusion<br>[2834, 2869, 0]"] 108["Sweep Extrusion<br>[2844, 2879, 0]"]
109["Sweep Extrusion<br>[2834, 2869, 0]"] 109["Sweep Extrusion<br>[2844, 2879, 0]"]
110["Plane<br>[2916, 2953, 0]"] 110["Plane<br>[2926, 2963, 0]"]
118["Sweep Extrusion<br>[3275, 3310, 0]"] 118["Sweep Extrusion<br>[3285, 3320, 0]"]
119[Wall] 119[Wall]
120[Wall] 120[Wall]
121[Wall] 121[Wall]
@ -209,8 +209,8 @@ flowchart LR
130["SweepEdge Adjacent"] 130["SweepEdge Adjacent"]
131["SweepEdge Opposite"] 131["SweepEdge Opposite"]
132["SweepEdge Adjacent"] 132["SweepEdge Adjacent"]
133["Sweep Extrusion<br>[3275, 3310, 0]"] 133["Sweep Extrusion<br>[3285, 3320, 0]"]
141["Sweep Extrusion<br>[3720, 3755, 0]"] 141["Sweep Extrusion<br>[3730, 3765, 0]"]
142[Wall] 142[Wall]
143[Wall] 143[Wall]
144[Wall] 144[Wall]
@ -225,9 +225,9 @@ flowchart LR
153["SweepEdge Adjacent"] 153["SweepEdge Adjacent"]
154["SweepEdge Opposite"] 154["SweepEdge Opposite"]
155["SweepEdge Adjacent"] 155["SweepEdge Adjacent"]
156["Sweep Extrusion<br>[3720, 3755, 0]"] 156["Sweep Extrusion<br>[3730, 3765, 0]"]
157["Plane<br>[3795, 3832, 0]"] 157["Plane<br>[3805, 3842, 0]"]
165["Sweep Extrusion<br>[4064, 4097, 0]"] 165["Sweep Extrusion<br>[4074, 4107, 0]"]
166[Wall] 166[Wall]
167[Wall] 167[Wall]
168[Wall] 168[Wall]
@ -242,7 +242,7 @@ flowchart LR
177["SweepEdge Adjacent"] 177["SweepEdge Adjacent"]
178["SweepEdge Opposite"] 178["SweepEdge Opposite"]
179["SweepEdge Adjacent"] 179["SweepEdge Adjacent"]
187["Sweep Extrusion<br>[4670, 4697, 0]"] 187["Sweep Extrusion<br>[4680, 4707, 0]"]
188[Wall] 188[Wall]
189[Wall] 189[Wall]
190[Wall] 190[Wall]
@ -256,8 +256,8 @@ flowchart LR
198["SweepEdge Adjacent"] 198["SweepEdge Adjacent"]
199["SweepEdge Opposite"] 199["SweepEdge Opposite"]
200["SweepEdge Adjacent"] 200["SweepEdge Adjacent"]
201["Sweep Extrusion<br>[4670, 4697, 0]"] 201["Sweep Extrusion<br>[4680, 4707, 0]"]
209["Sweep Extrusion<br>[5217, 5245, 0]"] 209["Sweep Extrusion<br>[5227, 5255, 0]"]
210[Wall] 210[Wall]
211[Wall] 211[Wall]
212[Wall] 212[Wall]
@ -271,9 +271,9 @@ flowchart LR
220["SweepEdge Adjacent"] 220["SweepEdge Adjacent"]
221["SweepEdge Opposite"] 221["SweepEdge Opposite"]
222["SweepEdge Adjacent"] 222["SweepEdge Adjacent"]
223["Sweep Extrusion<br>[5217, 5245, 0]"] 223["Sweep Extrusion<br>[5227, 5255, 0]"]
224["Plane<br>[5598, 5647, 0]"] 224["Plane<br>[5608, 5657, 0]"]
232["Sweep Extrusion<br>[5983, 6011, 0]"] 232["Sweep Extrusion<br>[5993, 6021, 0]"]
233[Wall] 233[Wall]
234[Wall] 234[Wall]
235[Wall] 235[Wall]
@ -288,12 +288,12 @@ flowchart LR
244["SweepEdge Adjacent"] 244["SweepEdge Adjacent"]
245["SweepEdge Opposite"] 245["SweepEdge Opposite"]
246["SweepEdge Adjacent"] 246["SweepEdge Adjacent"]
247["Sweep Extrusion<br>[5983, 6011, 0]"] 247["Sweep Extrusion<br>[5993, 6021, 0]"]
248["Sweep Extrusion<br>[5983, 6011, 0]"] 248["Sweep Extrusion<br>[5993, 6021, 0]"]
249["Sweep Extrusion<br>[5983, 6011, 0]"] 249["Sweep Extrusion<br>[5993, 6021, 0]"]
250["Sweep Extrusion<br>[5983, 6011, 0]"] 250["Sweep Extrusion<br>[5993, 6021, 0]"]
251["Sweep Extrusion<br>[5983, 6011, 0]"] 251["Sweep Extrusion<br>[5993, 6021, 0]"]
259["Sweep Extrusion<br>[6472, 6500, 0]"] 259["Sweep Extrusion<br>[6482, 6510, 0]"]
260[Wall] 260[Wall]
261[Wall] 261[Wall]
262[Wall] 262[Wall]
@ -308,23 +308,23 @@ flowchart LR
271["SweepEdge Adjacent"] 271["SweepEdge Adjacent"]
272["SweepEdge Opposite"] 272["SweepEdge Opposite"]
273["SweepEdge Adjacent"] 273["SweepEdge Adjacent"]
274["Sweep Extrusion<br>[6472, 6500, 0]"] 274["Sweep Extrusion<br>[6482, 6510, 0]"]
275["Plane<br>[6793, 6844, 0]"] 275["Plane<br>[6803, 6854, 0]"]
282["Plane<br>[7254, 7271, 0]"] 282["Plane<br>[7264, 7281, 0]"]
286["Sweep Sweep<br>[7420, 7473, 0]"] 286["Sweep Sweep<br>[7430, 7483, 0]"]
287[Wall] 287[Wall]
288["Cap Start"] 288["Cap Start"]
289["Cap Start"] 289["Cap Start"]
290["SweepEdge Opposite"] 290["SweepEdge Opposite"]
291["SweepEdge Adjacent"] 291["SweepEdge Adjacent"]
292["StartSketchOnPlane<br>[1192, 1261, 0]"] 292["StartSketchOnPlane<br>[1202, 1271, 0]"]
293["StartSketchOnPlane<br>[2266, 2332, 0]"] 293["StartSketchOnPlane<br>[2276, 2342, 0]"]
294["StartSketchOnPlane<br>[2902, 2954, 0]"] 294["StartSketchOnPlane<br>[2912, 2964, 0]"]
295["StartSketchOnPlane<br>[3781, 3833, 0]"] 295["StartSketchOnPlane<br>[3791, 3843, 0]"]
296["StartSketchOnFace<br>[4285, 4321, 0]"] 296["StartSketchOnFace<br>[4295, 4331, 0]"]
297["StartSketchOnFace<br>[4717, 4751, 0]"] 297["StartSketchOnFace<br>[4727, 4761, 0]"]
298["StartSketchOnPlane<br>[5584, 5648, 0]"] 298["StartSketchOnPlane<br>[5594, 5658, 0]"]
299["StartSketchOnPlane<br>[6779, 6845, 0]"] 299["StartSketchOnPlane<br>[6789, 6855, 0]"]
1 --- 2 1 --- 2
2 --- 3 2 --- 3
2 --- 4 2 --- 4

File diff suppressed because it is too large Load Diff

View File

@ -1,114 +1,114 @@
```mermaid ```mermaid
flowchart LR flowchart LR
subgraph path2 [Path] subgraph path2 [Path]
2["Path<br>[266, 291, 0]"] 2["Path<br>[287, 312, 0]"]
3["Segment<br>[297, 345, 0]"] 3["Segment<br>[318, 366, 0]"]
4["Segment<br>[351, 453, 0]"] 4["Segment<br>[372, 474, 0]"]
5["Segment<br>[459, 579, 0]"] 5["Segment<br>[480, 600, 0]"]
6["Segment<br>[585, 670, 0]"] 6["Segment<br>[606, 691, 0]"]
7["Segment<br>[676, 683, 0]"] 7["Segment<br>[697, 704, 0]"]
8[Solid2d] 8[Solid2d]
end end
subgraph path29 [Path] subgraph path29 [Path]
29["Path<br>[1594, 1677, 0]"] 29["Path<br>[1615, 1698, 0]"]
30["Segment<br>[1594, 1677, 0]"] 30["Segment<br>[1615, 1698, 0]"]
31[Solid2d] 31[Solid2d]
end end
subgraph path32 [Path] subgraph path32 [Path]
32["Path<br>[1690, 1757, 0]"] 32["Path<br>[1711, 1778, 0]"]
33["Segment<br>[1690, 1757, 0]"] 33["Segment<br>[1711, 1778, 0]"]
34[Solid2d] 34[Solid2d]
end end
subgraph path42 [Path] subgraph path42 [Path]
42["Path<br>[1594, 1677, 0]"] 42["Path<br>[1615, 1698, 0]"]
43["Segment<br>[1594, 1677, 0]"] 43["Segment<br>[1615, 1698, 0]"]
44[Solid2d] 44[Solid2d]
end end
subgraph path45 [Path] subgraph path45 [Path]
45["Path<br>[1690, 1757, 0]"] 45["Path<br>[1711, 1778, 0]"]
46["Segment<br>[1690, 1757, 0]"] 46["Segment<br>[1711, 1778, 0]"]
47[Solid2d] 47[Solid2d]
end end
subgraph path55 [Path] subgraph path55 [Path]
55["Path<br>[1594, 1677, 0]"] 55["Path<br>[1615, 1698, 0]"]
56["Segment<br>[1594, 1677, 0]"] 56["Segment<br>[1615, 1698, 0]"]
57[Solid2d] 57[Solid2d]
end end
subgraph path58 [Path] subgraph path58 [Path]
58["Path<br>[1690, 1757, 0]"] 58["Path<br>[1711, 1778, 0]"]
59["Segment<br>[1690, 1757, 0]"] 59["Segment<br>[1711, 1778, 0]"]
60[Solid2d] 60[Solid2d]
end end
subgraph path68 [Path] subgraph path68 [Path]
68["Path<br>[1594, 1677, 0]"] 68["Path<br>[1615, 1698, 0]"]
69["Segment<br>[1594, 1677, 0]"] 69["Segment<br>[1615, 1698, 0]"]
70[Solid2d] 70[Solid2d]
end end
subgraph path71 [Path] subgraph path71 [Path]
71["Path<br>[1690, 1757, 0]"] 71["Path<br>[1711, 1778, 0]"]
72["Segment<br>[1690, 1757, 0]"] 72["Segment<br>[1711, 1778, 0]"]
73[Solid2d] 73[Solid2d]
end end
subgraph path81 [Path] subgraph path81 [Path]
81["Path<br>[2328, 2363, 0]"] 81["Path<br>[2349, 2384, 0]"]
82["Segment<br>[2369, 2417, 0]"] 82["Segment<br>[2390, 2438, 0]"]
83["Segment<br>[2423, 2525, 0]"] 83["Segment<br>[2444, 2546, 0]"]
84["Segment<br>[2531, 2651, 0]"] 84["Segment<br>[2552, 2672, 0]"]
85["Segment<br>[2657, 2742, 0]"] 85["Segment<br>[2678, 2763, 0]"]
86["Segment<br>[2748, 2755, 0]"] 86["Segment<br>[2769, 2776, 0]"]
87[Solid2d] 87[Solid2d]
end end
subgraph path88 [Path] subgraph path88 [Path]
88["Path<br>[2766, 2922, 0]"] 88["Path<br>[2787, 2943, 0]"]
89["Segment<br>[2766, 2922, 0]"] 89["Segment<br>[2787, 2943, 0]"]
90[Solid2d] 90[Solid2d]
end end
subgraph path91 [Path] subgraph path91 [Path]
91["Path<br>[2937, 3104, 0]"] 91["Path<br>[2958, 3125, 0]"]
92["Segment<br>[2937, 3104, 0]"] 92["Segment<br>[2958, 3125, 0]"]
93[Solid2d] 93[Solid2d]
end end
subgraph path94 [Path] subgraph path94 [Path]
94["Path<br>[3119, 3277, 0]"] 94["Path<br>[3140, 3298, 0]"]
95["Segment<br>[3119, 3277, 0]"] 95["Segment<br>[3140, 3298, 0]"]
96[Solid2d] 96[Solid2d]
end end
subgraph path97 [Path] subgraph path97 [Path]
97["Path<br>[3292, 3461, 0]"] 97["Path<br>[3313, 3482, 0]"]
98["Segment<br>[3292, 3461, 0]"] 98["Segment<br>[3313, 3482, 0]"]
99[Solid2d] 99[Solid2d]
end end
subgraph path119 [Path] subgraph path119 [Path]
119["Path<br>[3902, 3986, 0]"] 119["Path<br>[3923, 4007, 0]"]
120["Segment<br>[3992, 4062, 0]"] 120["Segment<br>[4013, 4083, 0]"]
121["Segment<br>[4068, 4192, 0]"] 121["Segment<br>[4089, 4213, 0]"]
122["Segment<br>[4198, 4318, 0]"] 122["Segment<br>[4219, 4339, 0]"]
123["Segment<br>[4324, 4409, 0]"] 123["Segment<br>[4345, 4430, 0]"]
124["Segment<br>[4415, 4422, 0]"] 124["Segment<br>[4436, 4443, 0]"]
125[Solid2d] 125[Solid2d]
end end
subgraph path126 [Path] subgraph path126 [Path]
126["Path<br>[4433, 4605, 0]"] 126["Path<br>[4454, 4626, 0]"]
127["Segment<br>[4433, 4605, 0]"] 127["Segment<br>[4454, 4626, 0]"]
128[Solid2d] 128[Solid2d]
end end
subgraph path129 [Path] subgraph path129 [Path]
129["Path<br>[4620, 4803, 0]"] 129["Path<br>[4641, 4824, 0]"]
130["Segment<br>[4620, 4803, 0]"] 130["Segment<br>[4641, 4824, 0]"]
131[Solid2d] 131[Solid2d]
end end
subgraph path132 [Path] subgraph path132 [Path]
132["Path<br>[4818, 4992, 0]"] 132["Path<br>[4839, 5013, 0]"]
133["Segment<br>[4818, 4992, 0]"] 133["Segment<br>[4839, 5013, 0]"]
134[Solid2d] 134[Solid2d]
end end
subgraph path135 [Path] subgraph path135 [Path]
135["Path<br>[5007, 5192, 0]"] 135["Path<br>[5028, 5213, 0]"]
136["Segment<br>[5007, 5192, 0]"] 136["Segment<br>[5028, 5213, 0]"]
137[Solid2d] 137[Solid2d]
end end
1["Plane<br>[243, 260, 0]"] 1["Plane<br>[264, 281, 0]"]
9["Sweep Extrusion<br>[697, 732, 0]"] 9["Sweep Extrusion<br>[718, 753, 0]"]
10[Wall] 10[Wall]
11[Wall] 11[Wall]
12[Wall] 12[Wall]
@ -123,40 +123,40 @@ flowchart LR
21["SweepEdge Adjacent"] 21["SweepEdge Adjacent"]
22["SweepEdge Opposite"] 22["SweepEdge Opposite"]
23["SweepEdge Adjacent"] 23["SweepEdge Adjacent"]
24["EdgeCut Fillet<br>[738, 1020, 0]"] 24["EdgeCut Fillet<br>[759, 1041, 0]"]
25["EdgeCut Fillet<br>[738, 1020, 0]"] 25["EdgeCut Fillet<br>[759, 1041, 0]"]
26["EdgeCut Fillet<br>[738, 1020, 0]"] 26["EdgeCut Fillet<br>[759, 1041, 0]"]
27["EdgeCut Fillet<br>[738, 1020, 0]"] 27["EdgeCut Fillet<br>[759, 1041, 0]"]
28["Plane<br>[1563, 1586, 0]"] 28["Plane<br>[1584, 1607, 0]"]
35["Sweep Extrusion<br>[1777, 1828, 0]"] 35["Sweep Extrusion<br>[1798, 1849, 0]"]
36[Wall] 36[Wall]
37["Cap Start"] 37["Cap Start"]
38["Cap End"] 38["Cap End"]
39["SweepEdge Opposite"] 39["SweepEdge Opposite"]
40["SweepEdge Adjacent"] 40["SweepEdge Adjacent"]
41["Plane<br>[1563, 1586, 0]"] 41["Plane<br>[1584, 1607, 0]"]
48["Sweep Extrusion<br>[1777, 1828, 0]"] 48["Sweep Extrusion<br>[1798, 1849, 0]"]
49[Wall] 49[Wall]
50["Cap Start"] 50["Cap Start"]
51["Cap End"] 51["Cap End"]
52["SweepEdge Opposite"] 52["SweepEdge Opposite"]
53["SweepEdge Adjacent"] 53["SweepEdge Adjacent"]
54["Plane<br>[1563, 1586, 0]"] 54["Plane<br>[1584, 1607, 0]"]
61["Sweep Extrusion<br>[1777, 1828, 0]"] 61["Sweep Extrusion<br>[1798, 1849, 0]"]
62[Wall] 62[Wall]
63["Cap Start"] 63["Cap Start"]
64["Cap End"] 64["Cap End"]
65["SweepEdge Opposite"] 65["SweepEdge Opposite"]
66["SweepEdge Adjacent"] 66["SweepEdge Adjacent"]
67["Plane<br>[1563, 1586, 0]"] 67["Plane<br>[1584, 1607, 0]"]
74["Sweep Extrusion<br>[1777, 1828, 0]"] 74["Sweep Extrusion<br>[1798, 1849, 0]"]
75[Wall] 75[Wall]
76["Cap Start"] 76["Cap Start"]
77["Cap End"] 77["Cap End"]
78["SweepEdge Opposite"] 78["SweepEdge Opposite"]
79["SweepEdge Adjacent"] 79["SweepEdge Adjacent"]
80["Plane<br>[2305, 2322, 0]"] 80["Plane<br>[2326, 2343, 0]"]
100["Sweep Extrusion<br>[3479, 3521, 0]"] 100["Sweep Extrusion<br>[3500, 3542, 0]"]
101[Wall] 101[Wall]
102[Wall] 102[Wall]
103[Wall] 103[Wall]
@ -171,11 +171,11 @@ flowchart LR
112["SweepEdge Adjacent"] 112["SweepEdge Adjacent"]
113["SweepEdge Opposite"] 113["SweepEdge Opposite"]
114["SweepEdge Adjacent"] 114["SweepEdge Adjacent"]
115["EdgeCut Fillet<br>[3527, 3809, 0]"] 115["EdgeCut Fillet<br>[3548, 3830, 0]"]
116["EdgeCut Fillet<br>[3527, 3809, 0]"] 116["EdgeCut Fillet<br>[3548, 3830, 0]"]
117["EdgeCut Fillet<br>[3527, 3809, 0]"] 117["EdgeCut Fillet<br>[3548, 3830, 0]"]
118["EdgeCut Fillet<br>[3527, 3809, 0]"] 118["EdgeCut Fillet<br>[3548, 3830, 0]"]
138["Sweep Extrusion<br>[5210, 5252, 0]"] 138["Sweep Extrusion<br>[5231, 5273, 0]"]
139[Wall] 139[Wall]
140[Wall] 140[Wall]
141[Wall] 141[Wall]
@ -190,11 +190,11 @@ flowchart LR
150["SweepEdge Adjacent"] 150["SweepEdge Adjacent"]
151["SweepEdge Opposite"] 151["SweepEdge Opposite"]
152["SweepEdge Adjacent"] 152["SweepEdge Adjacent"]
153["EdgeCut Fillet<br>[5258, 5540, 0]"] 153["EdgeCut Fillet<br>[5279, 5561, 0]"]
154["EdgeCut Fillet<br>[5258, 5540, 0]"] 154["EdgeCut Fillet<br>[5279, 5561, 0]"]
155["EdgeCut Fillet<br>[5258, 5540, 0]"] 155["EdgeCut Fillet<br>[5279, 5561, 0]"]
156["EdgeCut Fillet<br>[5258, 5540, 0]"] 156["EdgeCut Fillet<br>[5279, 5561, 0]"]
157["StartSketchOnFace<br>[3864, 3896, 0]"] 157["StartSketchOnFace<br>[3885, 3917, 0]"]
1 --- 2 1 --- 2
2 --- 3 2 --- 3
2 --- 4 2 --- 4

File diff suppressed because it is too large Load Diff

View File

@ -150,8 +150,8 @@ description: Operations executed enclosure.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "function001", "name": "function001",
"functionSourceRange": [ "functionSourceRange": [
1254, 1275,
1851, 1872,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -423,8 +423,8 @@ description: Operations executed enclosure.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "function001", "name": "function001",
"functionSourceRange": [ "functionSourceRange": [
1254, 1275,
1851, 1872,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -696,8 +696,8 @@ description: Operations executed enclosure.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "function001", "name": "function001",
"functionSourceRange": [ "functionSourceRange": [
1254, 1275,
1851, 1872,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,
@ -969,8 +969,8 @@ description: Operations executed enclosure.kcl
"type": "FunctionCall", "type": "FunctionCall",
"name": "function001", "name": "function001",
"functionSourceRange": [ "functionSourceRange": [
1254, 1275,
1851, 1872,
0 0
], ],
"unlabeledArg": null, "unlabeledArg": null,

Some files were not shown because too many files have changed in this diff Show More