Skip to content

Commit 7c236c4

Browse files
committed
doc: document new dev env
1 parent 10e4858 commit 7c236c4

File tree

4 files changed

+94
-10
lines changed

4 files changed

+94
-10
lines changed

CONTRIBUTING.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,12 @@ Please contribute and raise issues via the [github repository](https://github.co
1010
- Once your contribution is ready & tested, please create a [Pull Request](https://github.com/Infineon/XMC-for-Arduino/compare) to the master branch
1111
- Once we merged your changes to the master branch, they are automatically included in the next release
1212

13-
## Install the BSP under development (on Windows)
14-
Clone the repository in Arduino folder:
15-
- Open Arduino and install any version of this project as described [here](https://xmc-arduino.readthedocs.io/en/latest/installation-instructions.html).
16-
- Open the installation location in your Arduino program folder, e.g.
17-
`C:\Users\<username>\AppData\Local\Arduino15\packages\Infineon\hardware\xmc`
18-
- Open git bash, type command:
19-
`git clone <your-xmc-for-arduino-fork> <version>`
20-
13+
## Development (Linux/ WSL)
14+
1. Create an `<SKETCHBOOK>/hardware/arduino-git` folder. Where `<SKETCHBOOK>` is the location of your Arduino sketchbook. You can run:`mkdir -p $sketchbook/hardware/arduino-git`
15+
1. Change directories: `cd <SKETCHBOOK>/hardware/arduino-git`
16+
1. Clone this repo: `git clone https://github.com/Infineon/XMC-for-Arduino.git xmc`
2117
This allows quick testing of local changes during development.
18+
1. From the root directory of the core, run the setup script : `bash tools/dev-setup.sh`
2219

2320
[!TIP]
2421
If you encounter strange behavior with Arduino IDE during development, try cleaning up the cache:

docs/conf.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@
4646

4747
extensions = [
4848
# 'sphinx.ext.autodoc',
49-
# 'sphinxemoji.sphinxemoji',
50-
# 'sphinx_tabs.tabs',
49+
'sphinxemoji.sphinxemoji',
50+
'sphinx_tabs.tabs',
5151
# 'sphinx.ext.intersphinx',
5252
# 'sphinx.ext.autosectionlabel',
5353
# 'sphinx.ext.todo',

docs/development-instructions.rst

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
Development Instructions
2+
=========================
3+
4+
.. warning::
5+
6+
This is a work in progress version of XMC4Arduino documentation.
7+
While this warning notice is present, the documentation is NOT ready for public usage.
8+
9+
..
10+
TODOS:
11+
- Contribution guidelines (move here from Contributing.md)
12+
- Code conventions
13+
- ....
14+
- Tools installation:
15+
- uncrustify
16+
- python ?
17+
- pip ?
18+
- pre-commit hook?
19+
- spellchecker
20+
- ...
21+
- Installation of the xmc Arduino core
22+
- Setting up the development environment
23+
24+
.. _env_dev_setup:
25+
26+
Environment setup
27+
------------------
28+
29+
.. note::
30+
| The development environment setup is (currently) only supported on **Linux/WSL** |:penguin:|.
31+
| As many tools and scripts are not cross-platform, some of them will not directly work on Windows |:abcd:| or macOS |:apple:|.
32+
33+
34+
0. Obviously |:neutral_face:|, install `Arduino IDE (2.0 or higher) <https://docs.arduino.cc/software/ide-v2/tutorials/getting-started/ide-v2-downloading-and-installing/>`_ or `Arduino CLI (1.0.0 or higher) <https://arduino.github.io/arduino-cli/0.24/installation/>`_.
35+
36+
1. Create an ``<SKETCHBOOK>/hardware/arduino-git`` folder. Where ``<SKETCHBOOK>`` is the location of your Arduino sketchbook.
37+
You can run:
38+
::
39+
40+
mkdir -p $sketchbook/hardware/arduino-git
41+
42+
2. Change directories:
43+
::
44+
45+
cd <SKETCHBOOK>/hardware/arduino-git
46+
47+
3. Clone this repo:
48+
::
49+
50+
git clone https://github.com/Infineon/XMC-for-Arduino.git xmc
51+
52+
4. You can check if the correct version is installed by running
53+
54+
.. tabs::
55+
56+
.. group-tab:: Linux
57+
58+
::
59+
60+
arduino-cli core list
61+
62+
.. group-tab:: Windows/ WSL
63+
64+
::
65+
66+
arduino-cli.exe core list
67+
68+
This allows quick testing of local changes during development, and keep released version.
69+
4. From the root directory of the core, run the setup script :
70+
::
71+
72+
bash tools/dev-setup.sh
73+
74+
5. Start developing |:tools:|!
75+
76+
|:bell:|
77+
If you encounter strange behavior with Arduino IDE during development, try cleaning up the IDE cache:
78+
* Windows:
79+
::
80+
C:\User\"username"\AppData\Roaming\arduino-ide
81+
* Linux:
82+
::
83+
~/.config/arduino-ide
84+
* macOS:
85+
::
86+
~/Library/Application Support/arduino-ide/

docs/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ advantage of the advanced features and performance offered by XMC microcontrolle
3737

3838
Introduction<self>
3939
installation-instructions
40+
development-instructions
4041
hw-platforms
4142
builtin-libraries
4243
arduino-deviations

0 commit comments

Comments
 (0)