Absolutely! Let’s design a thoughtful, practical, and visually appealing phone stand using Rhino Python. I’ll explain the design logic, then provide a script you can run in Rhino 5’s Python editor.
Design Concept
- Stable Base: Wide enough to prevent tipping.
- Angled Backrest: Holds the phone at a comfortable viewing angle (e.g., 70° from horizontal).
- Cradle Slot: Fits the phone’s thickness, with a little extra clearance.
- Open Bottom: Allows charging cable access.
- Universal Fit: Adjustable for most modern phones (customize for your device).
Parameters (You Can Adjust)
# Phone dimensions (mm)
phone_width = 77 # e.g. Oppo Reno 10 Pro+
phone_thickness = 9 # with case
# Stand dimensions
base_width = phone_width + 30 # extra for stability
base_depth = 80
base_thickness = 6
backrest_height = 110
backrest_angle_deg = 70 # from horizontal
slot_width = phone_width + 6 # 3mm clearance each side
slot_depth = 16 # how much phone sits in
slot_thickness = phone_thickness + 4 # 2mm clearance each side
slot_bottom_gap = 18 # opening for charging cable
Script: Angled Phone Stand with Charging Slot
import rhinoscriptsyntax as rs
import math
# --- PARAMETERS ---
phone_width = 77
phone_thickness = 9
base_width = phone_width + 30
base_depth = 80
base_thickness = 6
backrest_height = 110
backrest_angle_deg = 70
slot_width = phone_width + 6
slot_depth = 16
slot_thickness = phone_thickness + 4
slot_bottom_gap = 18
# --- CALCULATIONS ---
angle_rad = math.radians(backrest_angle_deg)
backrest_offset = (backrest_height - base_thickness) * math.cos(angle_rad)
backrest_top_x = base_depth - backrest_offset
backrest_top_z = base_thickness + (backrest_height - base_thickness) * math.sin(angle_rad)
# --- CREATE BASE ---
base = rs.AddBox([
(0, 0, 0),
(base_depth, 0, 0),
(base_depth, base_width, 0),
(0, base_width, 0),
(0, 0, base_thickness),
(base_depth, 0, base_thickness),
(base_depth, base_width, base_thickness),
(0, base_width, base_thickness)
])
# --- CREATE BACKREST (TILTED) ---
# Backrest is a rectangular plate, tilted at the desired angle
br_x0 = base_depth - slot_depth
br_x1 = base_depth
br_z0 = base_thickness
br_z1 = base_thickness + backrest_height
# Calculate tilt using rotation
br_pts = [
(br_x0, (base_width-slot_width)/2, br_z0),
(br_x1, (base_width-slot_width)/2, br_z0),
(br_x1, (base_width+slot_width)/2, br_z0),
(br_x0, (base_width+slot_width)/2, br_z0),
(br_x0, (base_width-slot_width)/2, br_z1),
(br_x1, (base_width-slot_width)/2, br_z1),
(br_x1, (base_width+slot_width)/2, br_z1),
(br_x0, (base_width+slot_width)/2, br_z1)
]
backrest = rs.AddBox(br_pts)
# Rotate backrest around Y axis at base of backrest
pivot = (br_x0, base_width/2, base_thickness)
rs.RotateObject(backrest, pivot, -backrest_angle_deg, (0,1,0))
# --- CREATE PHONE SLOT (CUTOUT) ---
# Slot is a box, subtracted from the backrest
slot_x0 = base_depth - slot_depth - 1
slot_x1 = base_depth + 2
slot_y0 = (base_width-slot_width)/2
slot_y1 = slot_y0 + slot_width
slot_z0 = base_thickness + slot_bottom_gap
slot_z1 = slot_z0 + slot_thickness
slot_pts = [
(slot_x0, slot_y0, slot_z0),
(slot_x1, slot_y0, slot_z0),
(slot_x1, slot_y1, slot_z0),
(slot_x0, slot_y1, slot_z0),
(slot_x0, slot_y0, slot_z1),
(slot_x1, slot_y0, slot_z1),
(slot_x1, slot_y1, slot_z1),
(slot_x0, slot_y1, slot_z1)
]
slot_box = rs.AddBox(slot_pts)
# Rotate slot to match backrest
rs.RotateObject(slot_box, pivot, -backrest_angle_deg, (0,1,0))
# --- BOOLEAN DIFFERENCE: Cut slot from backrest ---
backrest_cut = rs.BooleanDifference(backrest, slot_box)
# --- UNION: Combine base and backrest ---
if backrest_cut:
stand = rs.BooleanUnion([base, backrest_cut[0]])
if stand:
rs.SelectObject(stand)
print("Phone stand created! Export as STL for 3D printing.")
else:
print("Boolean union failed.")
else:
print("Boolean difference failed.")
How to Use
- Copy the script into Rhino’s Python editor (
EditPythonScript).
- Adjust parameters at the top for your phone and preferences.
- Run the script. The stand will appear in Rhino.
- Export as STL for 3D printing.
Features & Improvements
- Stable, wide base for tipping resistance.
- Angled backrest for ergonomic viewing.
- Slot with cable gap for charging while docked.
- Universal fit (adjust slot size for your phone).
- Easy to print: No supports needed if printed upright.
You can further enhance by adding fillets, logo cutouts, or rubber feet pads in Rhino.
Let me know if you want a more complex design (e.g., folding, adjustable, or with sound amplification)!