67 lines
1.5 KiB
Markdown
67 lines
1.5 KiB
Markdown
# Laser turret Debug
|
|
|
|
Code de la tourelle de pointage laser du projet bouchons EDF.
|
|
|
|
> [!WARNING]
|
|
> Code de debuggage uniquement.
|
|
|
|
> [!IMPORTANT]
|
|
> Nouvelle méca, les axes H/x et V/y sont découplés.
|
|
|
|
## Usage
|
|
|
|
Compile through Arduino IDE or equivalent.
|
|
|
|
> [!IMPORTANT]
|
|
> Add [kissStepper](https://github.com/risitt/kissStepper) to your project
|
|
> librairies.
|
|
|
|
## Conventions
|
|
|
|
- **x** is the horizontal axis centered at 0 and going from left (min value) to
|
|
right (max value).
|
|
- **y** is the vertical axis centered at 0 and going from bottom (min value) to
|
|
top (max value).
|
|
- **z** is the distance between the turrent and the target.
|
|
|
|
```mermaid
|
|
xychart-beta
|
|
title "Turret coordinate system"
|
|
x-axis "X axis [m]" -3 --> 3
|
|
y-axis "Y axis [m]" -3 --> 3
|
|
bar [-4]
|
|
```
|
|
|
|
## Development
|
|
|
|
Required dependeinces if not using
|
|
[Arduino IDE](https://www.arduino.cc/en/software/):
|
|
|
|
- [Arduino CLI](https://docs.arduino.cc/arduino-cli/):
|
|
- Install:
|
|
```sh
|
|
# linux
|
|
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh
|
|
|
|
# macos
|
|
brew update
|
|
brew install arduino-cli
|
|
|
|
# windows
|
|
winget install --id=ArduinoSA.CLI -e
|
|
```
|
|
- Configure:
|
|
```sh
|
|
arduino-cli config init
|
|
arduino-cli core update-index
|
|
arduino-cli core install arduino:avr
|
|
```
|
|
|
|
If you use `clangd` as lsp run `python ./generate_clangd.py` to load arduino
|
|
config and libraries.
|
|
|
|
## Contributing
|
|
|
|
Before `git commit`, run `git clang-format --staged` to format stagged files and
|
|
then `git add` to commit formatting.
|