Skip to content

Commit b82ac53

Browse files
authored
add manjaro installation instructions (#102)
1 parent 2595804 commit b82ac53

File tree

4 files changed

+101
-24
lines changed

4 files changed

+101
-24
lines changed

.github/workflows/build_and_deploy.yml

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,33 +11,36 @@ jobs:
1111
strategy:
1212
matrix:
1313
include:
14-
- os: ubuntu-22.04
14+
- runs-on: ubuntu-22.04
15+
container: "ubuntu:22.04"
1516
target: all
16-
- os: windows-2022
17+
18+
- runs-on: windows-2022
19+
container: "" # Containers on Windows runners are not supported
1720
target: dronecan_v2
18-
runs-on: ${{ matrix.os }}
21+
22+
- runs-on: ubuntu-22.04
23+
container: "manjaro:latest"
24+
target: "all"
25+
26+
runs-on: ${{ matrix.runs-on }}
1927
timeout-minutes: 10
2028
steps:
2129
- uses: actions/checkout@v4
2230
with:
2331
submodules: recursive
2432
fetch-depth: 0
2533

26-
- name: Install dependencies
34+
- name: Install dependencies (Ubuntu & Manjaro & Windows)
2735
run: |
28-
python -m pip install -r requirements.txt
36+
pip install -r requirements.txt
2937
python -m pip install yakut
30-
if [ "${{ runner.os }}" == "Linux" ]; then
31-
sudo apt-get install -y gcc-arm-none-eabi
32-
elif [ "${{ runner.os }}" == "Windows" ]; then
33-
choco install -y gcc-arm-embedded make
34-
choco install -y cmake
35-
fi
38+
python scripts/install.py
3639
shell: bash
3740

3841
- name: Build
3942
run: make ${{ matrix.target }}
4043

4144
- name: Deploy binaries to Telegram
42-
if: matrix.os == 'ubuntu-22.04' && matrix.target == 'all' && github.ref == 'refs/heads/main' && github.repository == 'RaccoonlabDev/mini_v2_node'
45+
if: matrix.runs-on == 'ubuntu-22.04' && matrix.target == 'all' && github.ref == 'refs/heads/main' && github.repository == 'RaccoonlabDev/mini_v2_node'
4346
run: ./scripts/deploy_release_to_telegram.py --bot-token ${{ secrets.TELEGRAM_BOT_TOKEN }} --chat-id ${{ secrets.TELEGRAM_CHAT_ID }}

README.md

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Not suported or tested yet / In Roadmap:
2222
- [ ] Dynamics Node Allocation (DNA),
2323
- [ ] Vibration Analysis: estimate dominant frequency and magnitude of vibrations for diagnosing mechanical issues or ensuring smooth operation in drones or robotic platforms in real time,
2424

25-
### 2. SUPPORTED HARDWARE
25+
### 2. TARGET HARDWARE
2626

2727
The software supports RL v2 nodes (stm32f103, 128 KBytes flash) and v3 nodes (stm32g0b1, 512 KBytes flash).
2828

@@ -31,15 +31,6 @@ The software supports RL v2 nodes (stm32f103, 128 KBytes flash) and v3 nodes (st
3131
| Mini v2 </br> stm32f103 </br> 128 KBytes flash | <img src="https://docs.raccoonlab.co/assets/img/view_top.6b0ef99e.png" alt="drawing" width="120"> | <img src="https://docs.raccoonlab.co/assets/img/pinout.c14a3021.png" alt="drawing" width="120"> | <img src="https://raw.githubusercontent.com/RaccoonLabHardware/mini_v2_stm32cubemx_project/main/Assets/stm32cubemx.png" alt="drawing" width="160"> |
3232
| Mini v3 </br> stm32fg0b1 </br> 512 KBytes flash | <img src="https://docs.raccoonlab.co/assets/img/t-view-bottom.7eadba26.png" alt="drawing" width="120"> | <img src="https://docs.raccoonlab.co/assets/img/pinout.e7b1d6b7.png" alt="drawing" width="120"> | <img src="https://github.com/RaccoonLabHardware/v3-software-template/blob/main/Assets/stm32cubemx.png" alt="drawing" width="160"> |
3333

34-
The following table outlines the compatibility of the project with different operating systems, modes, and support timelines.
35-
36-
| **Operating System** | **DroneCAN Support** | **Cyphal Support** | **Notes** |
37-
|-----------------------|-----------------------|---------------------|----------------------------------------|
38-
| Ubuntu 24.04 | ✅ Supported | ✅ Supported | Latest Ubuntu LTS version. |
39-
| Ubuntu 22.04 | ✅ Supported | ✅ Supported | Fully supported for both modes. |
40-
| Ubuntu 20.04 | ✅ Supported | ❌ Not Supported | Will be deprecated in April, 2026. |
41-
| Windows (2022) | ✅ Supported | ✅ Supported | Current "latest" Windows version. |
42-
4334
### 3. USE CASES
4435

4536
This node is a versatile device integrating PWM control, IMU sensing, and dual CAN bus communication, suitable for various applications in robotics, drones, and other embedded systems. Below are the detailed use cases for different scenarios.
@@ -90,12 +81,33 @@ This node is a versatile device integrating PWM control, IMU sensing, and dual C
9081

9182
> Software doesn't support it yet...
9283
84+
### 4. INSTALLATION
85+
86+
The following table outlines the compatibility of the project with different operating systems, modes, and support timelines.
87+
88+
| **Operating System** | **DroneCAN Support** | **Cyphal Support** | **Notes** |
89+
|----------------------|----------------------|--------------------|----------------------------------------|
90+
| Manjaro (latest) | ✅ Supported | ✅ Supported | Latest Manjaro LTS version. |
91+
| Ubuntu 24.04 | ✅ Supported | ✅ Supported | Latest Ubuntu LTS version. |
92+
| Ubuntu 22.04 | ✅ Supported | ✅ Supported | Fully supported for both modes. |
93+
| Ubuntu 20.04 | ✅ Supported | ❌ Not Supported | Will be deprecated in April, 2026. |
94+
| Windows (2022) | ✅ Supported | ✅ Supported | Current "latest" Windows version. |
95+
96+
The installation process is the same Ubuntu, Manjaro and Windows and it consists of 2 steps:
97+
98+
```bash
99+
# 1. Install python requirements
100+
pip install -r requirements.txt
101+
102+
# 2. Install other requirements
103+
./scripts/install.py
104+
```
93105

94-
### 4. Q&A
106+
### 5. Q&A
95107

96108
If you are strugguling with the software building, please refer to the build workflow [build.yml](.github/workflows/build.yml) for a hint. If it doesn't help, you can open [an issue]( https://github.com/RaccoonlabDev/mini_v2_node/issues?q=is%3Aissue+).
97109

98-
### 5. More examples
110+
### 6. More examples
99111

100112
Consider the following projects as examples:
101113

requirements.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
1+
setuptools
2+
pyyaml
3+
cpplint
14
raccoonlab-tools==0.2.0

scripts/install.py

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
#!/usr/bin/env python3
2+
"""
3+
Install.py
4+
"""
5+
6+
import sys
7+
import platform
8+
import subprocess
9+
10+
11+
def run_command(command):
12+
try:
13+
print(f"$ {command}")
14+
subprocess.run(command, shell=True, check=True)
15+
except subprocess.CalledProcessError:
16+
print("Error: Command execution failed")
17+
sys.exit(1)
18+
except KeyboardInterrupt:
19+
print("KeyboardInterrupt")
20+
21+
def main():
22+
system_name = platform.system().lower()
23+
24+
if system_name == "windows":
25+
print("Detected Windows. Installing packages...")
26+
run_command("choco install -y gcc-arm-embedded make cmake")
27+
28+
elif system_name == "linux":
29+
try:
30+
# Detect Linux distribution
31+
with open("/etc/os-release", "r") as f:
32+
os_info = f.read().lower()
33+
34+
if "ubuntu" in os_info or "debian" in os_info:
35+
print("Detected Ubuntu/Debian. Installing packages...")
36+
run_command("sudo apt-get install -y gcc-arm-none-eabi")
37+
38+
elif "manjaro" in os_info:
39+
print("Detected Manjaro. Installing packages...")
40+
run_command("sudo pacman -S cmake arm-none-eabi-gcc arm-none-eabi-binutils arm-none-eabi-newlib")
41+
42+
else:
43+
print("Unknown Linux distribution.")
44+
sys.exit(1)
45+
46+
except FileNotFoundError:
47+
print("Could not determine Linux distribution.")
48+
sys.exit(1)
49+
50+
elif system_name == "darwin":
51+
print("macOS is not supported at the moment.")
52+
sys.exit(1)
53+
54+
else:
55+
print("Unknown platform.")
56+
sys.exit(1)
57+
58+
if __name__ == "__main__":
59+
main()

0 commit comments

Comments
 (0)