Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stable V1 release #5

Open
wants to merge 93 commits into
base: stable
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
93 commits
Select commit Hold shift + click to select a range
c28c894
removed println
AtomicGamer9523 Nov 2, 2023
f0fed9e
Major improvement + no_std
AtomicGamer9523 Nov 3, 2023
173dabf
LLM improvement
AtomicGamer9523 Nov 5, 2023
679c4d2
Kaboom! It trigs
AtomicGamer9523 Nov 5, 2023
a23007e
Fixed Tests
AtomicGamer9523 Nov 5, 2023
94e59d9
Finally, Odometry works!
AtomicGamer9523 Nov 5, 2023
a96b76c
Minor Fix
AtomicGamer9523 Nov 5, 2023
46a6617
moving Odometry to new library
AtomicGamer9523 Nov 9, 2023
4df3c97
Partial clippy fixes
AtomicGamer9523 Nov 9, 2023
cbce943
A & C
AtomicGamer9523 Nov 9, 2023
d13fd6b
E
AtomicGamer9523 Nov 9, 2023
db0eec2
F
AtomicGamer9523 Nov 9, 2023
4603fed
H
AtomicGamer9523 Nov 9, 2023
b7d51dd
Also This
AtomicGamer9523 Nov 9, 2023
390cbd7
Fixed 2 bugs
AtomicGamer9523 Nov 9, 2023
6937557
Refactor
AtomicGamer9523 Nov 9, 2023
385213f
More LLM Fixes
AtomicGamer9523 Nov 10, 2023
0a1158e
Fmod minor fix
AtomicGamer9523 Nov 10, 2023
8f841d2
Kernel impls update
AtomicGamer9523 Nov 10, 2023
cb1ceae
Logarithms
AtomicGamer9523 Nov 10, 2023
53cb16b
Finished LLM changes
AtomicGamer9523 Nov 10, 2023
edfade4
Complete LLM Clippy fix
AtomicGamer9523 Nov 10, 2023
5b37e10
Doc Improvements + Minor Restructure
AtomicGamer9523 Nov 10, 2023
e25d1ba
Links Fix
AtomicGamer9523 Nov 10, 2023
984e425
Tooling + Workflows
AtomicGamer9523 Nov 10, 2023
3f14230
Minor CI fix
AtomicGamer9523 Nov 11, 2023
8aaed6d
Permission fix
AtomicGamer9523 Nov 11, 2023
e93e13e
Bash ?
AtomicGamer9523 Nov 11, 2023
5192a7c
Shell <- Bash ?
AtomicGamer9523 Nov 11, 2023
0db4f59
Just chmod ?
AtomicGamer9523 Nov 11, 2023
3229ccf
Rename
AtomicGamer9523 Nov 11, 2023
55c6271
Rename + CRLF -> LF
AtomicGamer9523 Nov 11, 2023
a5e4720
Added target installation
AtomicGamer9523 Nov 11, 2023
27a15eb
fmt + cli fix
AtomicGamer9523 Nov 11, 2023
e195ab4
added rustfmt
AtomicGamer9523 Nov 11, 2023
c0bd037
+ rustfmt
AtomicGamer9523 Nov 11, 2023
3328826
+ cargo binstall
AtomicGamer9523 Nov 11, 2023
2e232f4
fixeing binstall
AtomicGamer9523 Nov 11, 2023
1fac1b3
Fixed Linux (Android no work)
AtomicGamer9523 Nov 11, 2023
1ab707e
Tests now seperate
AtomicGamer9523 Nov 11, 2023
00c45fd
Restructure
AtomicGamer9523 Nov 11, 2023
4bc9eee
Lint in release mode
AtomicGamer9523 Nov 11, 2023
db9b444
Started adding Java
AtomicGamer9523 Nov 14, 2023
22936eb
Removed Java + Preparing llm & libtrig
AtomicGamer9523 Nov 16, 2023
0b3afdb
Major upgrade... But Broken
AtomicGamer9523 Nov 16, 2023
d48768e
Improved infrastructure
AtomicGamer9523 Nov 17, 2023
42de6f3
FMT
AtomicGamer9523 Nov 17, 2023
6dba6c6
More fixes... Broken
AtomicGamer9523 Nov 17, 2023
232a32e
More Changes
AtomicGamer9523 Nov 20, 2023
97947a1
Rebarnding: l2math <- llm
AtomicGamer9523 Nov 23, 2023
b3b3f21
2 fixes
AtomicGamer9523 Nov 23, 2023
4ffd51c
fmt bypass ;)
AtomicGamer9523 Nov 23, 2023
04139ec
l2math bindings fixed
AtomicGamer9523 Nov 23, 2023
2f861ea
fixed CI
AtomicGamer9523 Nov 23, 2023
4cee85b
Removed debug print statements
AtomicGamer9523 Nov 23, 2023
5fd8d35
FMT fix
AtomicGamer9523 Nov 23, 2023
7966a6c
Now Bindings work completely!
AtomicGamer9523 Nov 24, 2023
04b4979
Testing everything now
AtomicGamer9523 Nov 24, 2023
02e89b9
Now installing NDK
AtomicGamer9523 Nov 24, 2023
83f620c
Auto-build bindings for tests
AtomicGamer9523 Nov 24, 2023
a20737e
oops, typo
AtomicGamer9523 Nov 24, 2023
3aa2e9d
see what happens
AtomicGamer9523 Nov 24, 2023
a18935f
Fixes
AtomicGamer9523 Nov 24, 2023
ee39247
Debugging
AtomicGamer9523 Nov 24, 2023
973c24b
Upgraded build.rs ?
AtomicGamer9523 Nov 24, 2023
5279fd7
Turns out it wasn't the NDK failing
AtomicGamer9523 Nov 24, 2023
5ea09f2
Now ?
AtomicGamer9523 Nov 24, 2023
b7090cb
Push to prod, and pray to god ;)
AtomicGamer9523 Nov 24, 2023
6cee13c
Better numbers
AtomicGamer9523 Nov 25, 2023
339fb06
Started work on DualNum
AtomicGamer9523 Nov 25, 2023
4ed8f21
99% done with DualNum, starting work on others
AtomicGamer9523 Nov 25, 2023
f56fb45
More Numbers + l2math fixes
AtomicGamer9523 Dec 1, 2023
9f9f563
Major changes are on the way...
AtomicGamer9523 Dec 13, 2023
c2171c2
Moved examples directory
AtomicGamer9523 Dec 13, 2023
e6a3c65
Improved tooling, and getting started on the binaries
AtomicGamer9523 Dec 14, 2023
5d0e4d0
Another run improvement
AtomicGamer9523 Dec 14, 2023
bbc66fe
HAHAHAHA, boom, it works :)
AtomicGamer9523 Dec 16, 2023
97f76ea
fmt
AtomicGamer9523 Dec 16, 2023
007ec53
Fixed CI and build.py
AtomicGamer9523 Dec 16, 2023
5069cfd
minor fix
AtomicGamer9523 Dec 16, 2023
04465fe
CI fails, fix maybe ?
AtomicGamer9523 Dec 16, 2023
0d51868
Trying https://github.com/PyO3/pyo3/issues/3086
AtomicGamer9523 Dec 16, 2023
2d9d702
this maybe fix ?
AtomicGamer9523 Dec 16, 2023
29fd5b7
Added Pos2D
AtomicGamer9523 Dec 18, 2023
5ac566f
fmt
AtomicGamer9523 Dec 18, 2023
eafa630
Uploaded more code
AtomicGamer9523 Dec 22, 2023
b73b883
renamed log1p to a more obvious ln1p
AtomicGamer9523 Dec 24, 2023
02e927f
more
AtomicGamer9523 Dec 24, 2023
7ea1452
updated examples
AtomicGamer9523 Dec 25, 2023
7b11b51
Restructured the codebase
AtomicGamer9523 Dec 28, 2023
dbca55b
License update
AtomicGamer9523 Dec 30, 2023
7b4a98b
More changes, bindings are WIP
AtomicGamer9523 Dec 30, 2023
1774431
Added docs to pymod function
AtomicGamer9523 Dec 30, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/funding.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github: Atomicgamer9523
119 changes: 119 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
name: CI

env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0

on:
push:
branches: [ main ]
pull_request:
workflow_dispatch:

jobs:
# If anything fails, the whole workflow fails.
ci-pass:
name: CI Pass
needs: [style, android, linux, tests]
runs-on: ubuntu-latest
steps:
- run: exit 0

# Check style.
style:
name: Style
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Install toolchain
run: rustup component add rustfmt
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Give permission to run epearl
run: chmod +x ./epearl
- name: Check style
run: ./epearl fmt --check

# Check if the Android build works.
android:
name: Android
needs: [style]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
with:
target: aarch64-linux-android
- name: Install rustup target
run: rustup target add aarch64-linux-android
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.11
# We don't need to install the NDK, but this is nice to keep for reference.
# - name: Install Android NDK
# id: setup-ndk
# uses: nttld/setup-ndk@v1
# with:
# ndk-version: r26b
# local-cache: true
# add-to-path: true
- name: Give permission to run epearl
run: chmod +x ./epearl
- name: Build Android
run: ./epearl build --android
# env:
# ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}

# Check if the Linux build works.
linux:
name: Linux
needs: [style]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install Python C headers
run: sudo apt-get install -y python3-dev
- name: Give permission to run epearl
run: chmod +x ./epearl
- name: Build
run: ./epearl build

# Check if the tests pass.
tests:
name: Tests
needs: [style, linux]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
- name: Set up Binstall
uses: cargo-bins/cargo-binstall@main
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install Python C headers
run: sudo apt-get install -y python3-dev
- name: Give permission to run epearl
run: chmod +x ./epearl
- name: Run tests
run: ./epearl test all
30 changes: 28 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,28 @@
/*.lock
target
# IDE Files
*.code-workspace
.vscode
.idea

# Bazel files
bazel-*

# Lock files
*.lock

# Python files
__pycache__

# Java / Kotlin files
.gradle
local.properties

# Compiled source
target
build
out

# Compiled Item
*.dylib
*.dll
*.lib
*.so
32 changes: 23 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,25 @@
[package]
name = "libtrig"
version = "0.1.0"
edition = "2021"
[workspace]
resolver = "2" # Resolver version (keep it 2)
members = [
# Python interface implementation
"arc",
# ARC client (used to control the robot)
"client",
# The robot code (hardware abstractions, python runtime, http server)
"robot",
]

[lib]
path = "./libtrig/main.rs"
[workspace.package]
# Contributors of team Draniki may add their name bellow
authors = [
"Матвей Т <https://matveit.dev> AtomicGamer9523@github"
]
# Github Repository
repository = "https://github.com/DranikiRobotics/arc"
# Rust edition (keep it 2021)
edition = "2021"
# License of the entire workspace
license = "BSD-2-Clause"

[dependencies.macros]
package = "libtrig-macros"
path = "./macros"
# Version of the entire workspace
version = "0.0.1-dev"
37 changes: 20 additions & 17 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,21 +1,24 @@
MIT License
BSD 2-Clause License

Copyright (c) 2023 AtomicGamer9523 <https://matveit.dev>
Copyright (c) 2023 AtomicGamer9523 <https://matveit.dev> and members of the Draniki Team

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 changes: 25 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# ARC: A complete framework for controlling robots

ARC is a feature complete framework for writing robot code. It is designed to be easy to use, and easy to understand. It is also designed to be modular, so that you can use only the parts you need. ARC is also designed to be easy to extend, so that you can add your own functionality to it. ARC is an acronym, and it stands for: <ins>**A**</ins>dvanced <ins>**R**</ins>obot <ins>**C**</ins>ontroller.

## Features

- **[`l2math`](./libs/l2math/)** - <ins>L</ins>ow <ins>L</ins>evel <ins>Math</ins> - Fundamental math functions and types.
- **[`libtrig`](./libs/libtrig/)** - Trigonometry functionality (angles, vectors, etc.).

## Documentation

For Developers who are planning on using this [read here](./docs/GUIDE.md).

For Developers who are going to be contributing to this [read here](./docs/CONTRIBUTING.md).

<!--
Colors:
Complete Black: #000000
Black: #06070E
Gray: #2d2d2d
Blue: #00A7E1
Green: #84DD63
Red: #DF2935
Yellow: #FFA400
-->
36 changes: 36 additions & 0 deletions arc/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[package]
name = "arc-pylib"
description = "ARC python interface"
repository.workspace = true
version.workspace = true
edition.workspace = true
authors.workspace = true
license.workspace = true

[lib]
path = "lib.rs"
crate-type = ["cdylib", "rlib"]

[dependencies.dranikcore]
package = "dranik-core"
path = "../robot/core"
features = [
"reveal_modules", # More items
"internals", # Internal modules
]

[dependencies.libtrig]
git = "https://github.com/DranikiRobotics/librobomath"
package = "libtrig"
optional = true

[dependencies.pyo3]
version = "0.20"
features = [
"extension-module", # for standalone extension module
"abi3-py311" # for python 3.11
]

[features]
dranik-only-builtins = ["dranikcore/only_builtins"]
math = ["dep:libtrig"]
File renamed without changes.
Loading