You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: software/chords/chords-python/index.rst
+96-36Lines changed: 96 additions & 36 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -62,60 +62,55 @@ Go to tools, select your board, and the correct COM port. Now, hit the upload bu
62
62
Opening Chords-Python
63
63
*********************
64
64
65
-
Follow these steps to set up and install Chords-Python:
65
+
There are two ways to use Chords-Python:
66
66
67
-
1. Ensure you have latest version of Python installed.
68
-
2. **Download the GitHub repository**:
67
+
**A. Using the `chordspy` Python Package (Recommended)**
69
68
70
-
- You can download the Chords-Python repository from GitHub by visiting the following link: `Chords-Python <https://github.com/upsidedownlabs/Chords-Python/>`_.
71
-
- Or, You can clone the repository using Git by running the following command:
69
+
**B. Running Scripts Manually from the Repository**
A virtual environment allows you to manage dependencies for your project in isolation.
74
+
This is the smoothest way to get started. Follow the steps below:
80
75
81
-
- Open a terminal or command prompt.
82
-
- Navigate to the directory where you have cloned the repository.
83
-
- Run the following command to create a virtual environment:
76
+
1. **Install Python**
77
+
Make sure latest version of Python is installed.
84
78
85
-
.. code-block:: console
86
-
87
-
python -m venv venv
79
+
2. **Create and Activate a Virtual Environment**:
80
+
81
+
- **On Windows**:
88
82
89
-
- To activate the virtual environment:
90
-
- **On Windows**:
91
83
.. code-block:: console
92
84
93
-
.\venv\Scripts\activate
85
+
python -m venv .venv
94
86
95
-
- **On macOS/Linux**:
96
-
.. code-block:: python
97
-
98
-
source venv/bin/activate
87
+
.. code-block:: console
99
88
100
-
4. **Install the Required Python Libraries**:
89
+
.venv\Scripts\activate
101
90
102
-
Once the virtual environment is activated, you need to install the required libraries for the project.
91
+
- **On macOS/Linux**:
103
92
104
-
- In the terminal or command prompt, run the following command to install the dependencies needed to run the python script listed in the `requirements.txt` file:
93
+
.. code-block:: console
94
+
95
+
python3 -m venv .venv
96
+
97
+
.. code-block:: console
98
+
99
+
source .venv/bin/activate
100
+
101
+
3. **Install the Package**:
105
102
106
103
.. code-block:: console
107
-
108
-
pip install -r requirements.txt
109
104
110
-
- This will install all the necessary Python libraries and dependencies for Chords-Python.
105
+
pip install chordspy
111
106
112
-
5. To launch the Flask server, run the following command :
107
+
4. **Launch the Web Interface**:
113
108
114
-
.. code-block:: python
115
-
116
-
python app.py
109
+
.. code-block:: console
117
110
118
-
Click on the generated link to open the web interface.
111
+
chordspy
112
+
113
+
A web interface will open where you can connect your device and access applications.
119
114
120
115
.. figure:: ./media/light-interface.*
121
116
:align:center
@@ -129,6 +124,67 @@ Click on the generated link to open the web interface.
129
124
130
125
Interface in Dark Mode
131
126
127
+
B. Running Scripts Manually (Alternative)
128
+
=========================================
129
+
130
+
If you prefer running scripts directly (for development, debugging, or customization):
131
+
132
+
1. **Download the Repository**:
133
+
134
+
- You can download the Chords-Python repository from GitHub by visiting the following link: `Chords-Python <https://github.com/upsidedownlabs/Chords-Python/>`_.
135
+
136
+
- Or, you can clone the repository using Git by running the following command:
0 commit comments