2025-03-06 18:01:24 -05:00
// Walkie Talkie
// A portable, handheld two-way radio device that allows users to communicate wirelessly over short to medium distances. It operates on specific radio frequencies and features a push-to-talk button for transmitting messages, making it ideal for quick and reliable communication in outdoor, work, or emergency settings.
2025-03-20 09:22:17 -07:00
// set units
2025-03-06 18:01:24 -05:00
@settings(defaultLengthUnit = in)
2025-03-20 09:22:17 -07:00
// import constants
2025-04-04 11:03:13 -07:00
import * from "parameters.kcl"
2025-03-06 18:01:24 -05:00
2025-04-04 11:03:13 -07:00
// import parts and parameters
import "body.kcl" as body
import "case.kcl" as case
import "antenna.kcl" as antenna
import "talk-button.kcl" as talkButton
import "knob.kcl" as knob
2025-03-20 09:22:17 -07:00
import button from "button.kcl"
2025-03-06 18:01:24 -05:00
2025-04-04 11:03:13 -07:00
// Import the body
body
2025-03-20 09:22:17 -07:00
2025-04-04 11:03:13 -07:00
// Import the antenna
antenna
2025-03-28 14:14:29 -07:00
|> translate(x = -width / 2 + .45, y = -0.10, z = height / 2)
2025-03-20 09:22:17 -07:00
2025-04-04 11:03:13 -07:00
// Import the case
case
2025-03-28 14:14:29 -07:00
|> translate(x = 0, y = -1, z = 0)
2025-03-20 09:22:17 -07:00
2025-04-04 11:03:13 -07:00
// Import the talk button
talkButton
2025-03-28 14:14:29 -07:00
|> translate(x = width / 2, y = -thickness / 2, z = .5)
2025-03-20 09:22:17 -07:00
2025-04-04 11:03:13 -07:00
// Import the frequency knob
knob
2025-03-30 10:06:36 -07:00
|> translate(x = width / 2 - 0.70, y = -thickness / 2, z = height / 2)
2025-03-20 09:22:17 -07:00
2025-04-04 11:03:13 -07:00
// Import the buttons
2025-03-20 09:22:17 -07:00
button()
2025-03-30 10:06:36 -07:00
|> translate(x = -(screenWidth / 2 + tolerance), y = -1, z = screenYPosition)
2025-03-20 09:22:17 -07:00
button()
2025-03-30 10:06:36 -07:00
|> translate(x = -(screenWidth / 2 + tolerance), y = -1, z = screenYPosition - buttonHeight - (tolerance * 2))
2025-03-20 09:22:17 -07:00
button()
2025-03-26 08:53:34 -07:00
|> rotate(
%,
roll = 0,
pitch = 180,
yaw = 0,
)
|> translate(
2025-03-30 10:06:36 -07:00
x = screenWidth / 2 + tolerance,
y = -1,
z = screenYPosition - buttonHeight,
global = true,
2025-03-26 08:53:34 -07:00
)
2025-03-20 09:22:17 -07:00
button()
2025-03-26 08:53:34 -07:00
|> rotate(
%,
roll = 0,
pitch = 180,
yaw = 0,
)
|> translate(
2025-03-30 10:06:36 -07:00
x = screenWidth / 2 + tolerance,
y = -1,
z = screenYPosition - (buttonHeight * 2) - (tolerance * 2),
2025-03-26 08:53:34 -07:00
global = true,
)