From 76b3b6575a38b445cdaf4eaa883376124353d1d9 Mon Sep 17 00:00:00 2001 From: h3n3 Date: Tue, 26 Nov 2024 23:59:05 +0100 Subject: [PATCH] Standalone ocp_vscode viewer --- installatie_ocp_vscode-viewer.md | 21 +++++++++++++++++++++ oefening01.py | 7 +++++++ 2 files changed, 28 insertions(+) create mode 100644 installatie_ocp_vscode-viewer.md create mode 100644 oefening01.py diff --git a/installatie_ocp_vscode-viewer.md b/installatie_ocp_vscode-viewer.md new file mode 100644 index 0000000..a6e4bc1 --- /dev/null +++ b/installatie_ocp_vscode-viewer.md @@ -0,0 +1,21 @@ +## Installatie build123d en ocp_vscode viewer + +### Start de virtuele omgeving +`source /home/h3n3/CAD/.ocp_venv/bin/activate` + +### Download de viewer + +`wget https://github.com/bernhard-42/vscode-ocp-cad-viewer/releases/download/v2.6.1/ocp_vscode-2.6.1-py3-none-any.whl` + +### Installeer de programma's + +`pip install build123d` +`pip install ocp_vscode-2.6.1-py3-none-any.whl` + +### Start de viewer +`python -m ocp_vscode` + +Open in een browser http://localhost:3939/viewer + +Start de tekening: +`python de_tekening.py` diff --git a/oefening01.py b/oefening01.py new file mode 100644 index 0000000..7a12376 --- /dev/null +++ b/oefening01.py @@ -0,0 +1,7 @@ +from ocp_vscode import * +from build123d import * +set_port(3939) + +b = Box(1,2,3) + +show(b)