Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
90 commits
Select commit Hold shift + click to select a range
476de7d
infra: Setup C++ component
ishan-karmakar Feb 5, 2026
8914d3f
feat: Convert LoggedNetworkInput to C++
ishan-karmakar Feb 5, 2026
e98521f
feat: Convert LogValue and SharedTimestamp
ishan-karmakar Feb 6, 2026
057116f
feat: Add LoggableInputs and more LogTable functions
ishan-karmakar Feb 6, 2026
9f20ea1
feat: LoggedNetworkBoolean stub
ishan-karmakar Feb 6, 2026
dfc2c0d
feat: Add stub for LoggedNetworkNumber
ishan-karmakar Feb 6, 2026
57e2875
Merge pull request #1 from ishan-karmakar/networktables-conversion
ishan-karmakar Feb 6, 2026
4fec20c
feat: Integrate magic_enum
ishan-karmakar Feb 6, 2026
54d5890
Merge pull request #2 from ishan-karmakar/integrate-magic-enum
ishan-karmakar Feb 6, 2026
2d40b77
feat: Port LoggedNetworkString to C++
ishan-karmakar Feb 6, 2026
93d76e6
feat: Port LoggedDashboardChooser to C++
ishan-karmakar Feb 6, 2026
d80b4ae
Merge pull request #3 from ishan-karmakar/port-logged-network-string
ishan-karmakar Feb 6, 2026
64862ef
feat: Make stub for NT4Publisher
ishan-karmakar Feb 8, 2026
d146486
Merge pull request #4 from ishan-karmakar/nt4-publisher
ishan-karmakar Feb 8, 2026
ada9cef
feat: Stub for LoggedRobot
ishan-karmakar Feb 8, 2026
b459f5e
Merge pull request #5 from ishan-karmakar/logged-robot
ishan-karmakar Feb 8, 2026
5bca30f
feat: Create ConduitApi
ishan-karmakar Feb 8, 2026
1628395
feat: Implement LoggedSystemStats
ishan-karmakar Feb 8, 2026
2b1314e
Merge pull request #6 from ishan-karmakar/logged-system-stats
ishan-karmakar Feb 8, 2026
31c885b
feat: Implement LoggedPowerDistribution
ishan-karmakar Feb 9, 2026
8dc9eac
Merge pull request #7 from ishan-karmakar/logged-power-distribution
ishan-karmakar Feb 9, 2026
558b3a3
feat: Implement LoggedDriverStation
ishan-karmakar Feb 9, 2026
33e4d13
Merge pull request #8 from ishan-karmakar/logged-driver-station
ishan-karmakar Feb 9, 2026
ed36f43
feat: Implement LogReplaySource
ishan-karmakar Feb 9, 2026
5a83a4b
Merge pull request #9 from ishan-karmakar/log-replay-source
ishan-karmakar Feb 9, 2026
49bd8a2
feat: LoggedNetworkBoolean cleaned up
ishan-karmakar Feb 9, 2026
7b5227a
feat: Clean up LoggedNetworkNumber
ishan-karmakar Feb 9, 2026
7d0b16f
feat: Clean up LoggedNetworkString
ishan-karmakar Feb 9, 2026
6cc2ee5
Merge pull request #10 from ishan-karmakar/logged-network
ishan-karmakar Feb 9, 2026
a4961b0
feat: Clean up LoggedSystemStats
ishan-karmakar Feb 9, 2026
db0c7e4
feat: Fix ConduitApi
ishan-karmakar Feb 9, 2026
7898d09
feat: Cleaning up LogTable
ishan-karmakar Feb 9, 2026
7b6b742
feat: Added all LogTable put overloads
ishan-karmakar Feb 9, 2026
66f7400
fix: Bug fixes with LogTable
ishan-karmakar Feb 9, 2026
092f518
feat: More bug fixes
ishan-karmakar Feb 9, 2026
5f68ddd
feat: Code now builds
ishan-karmakar Feb 9, 2026
d290807
Merge pull request #11 from ishan-karmakar/logged-cleanup
ishan-karmakar Feb 9, 2026
f6881d3
feat: Add get() functions to LogTable
ishan-karmakar Feb 9, 2026
65b087d
feat: Port NT4Receiver
ishan-karmakar Feb 10, 2026
72605bb
feat: Working on WPILOG classes
ishan-karmakar Feb 10, 2026
fb978f5
feat: Working on WPILOG classes
ishan-karmakar Feb 10, 2026
a54aac6
feat: WPILOG classes now compiles
ishan-karmakar Feb 10, 2026
a965997
Merge pull request #12 from ishan-karmakar/wpilog-classes
ishan-karmakar Feb 10, 2026
4897cc4
feat: Created header files
ishan-karmakar Feb 11, 2026
92f101c
feat: Get LoggedMechanismObject2d source written
ishan-karmakar Feb 11, 2026
5d9caaa
feat: Get LoggedMechanismObjectRoot2d written in C++
ishan-karmakar Feb 11, 2026
c66c4fd
feat: Get LoggedMechanismLigament2d in C++
ishan-karmakar Feb 11, 2026
83aaed9
feat: Get LoggedMechanism2d in C++
ishan-karmakar Feb 11, 2026
6b7e46b
Merge pull request #13 from ishan-karmakar/mechanism-classes
ishan-karmakar Feb 11, 2026
cb55263
feat: LogFileUtil class
ishan-karmakar Feb 11, 2026
1dd42f7
feat: Working on RadioLogger
ishan-karmakar Feb 11, 2026
80520d8
feat: RadioLogger to C++
ishan-karmakar Feb 11, 2026
b73063d
feat: LoggedPowerDistribution and LoggedDriverStation cleanup
ishan-karmakar Feb 11, 2026
4d7f1b3
feat: LoggedRobot works in C++
ishan-karmakar Feb 11, 2026
5309f80
feat: ReceiverThread C++
ishan-karmakar Feb 11, 2026
fb91d27
feat: Working on ConsoleSource
ishan-karmakar Feb 12, 2026
57e365f
feat: Working on ConsoleSource
ishan-karmakar Feb 12, 2026
94d335c
feat: Add ConsoleSource C++
ishan-karmakar Feb 12, 2026
e19b078
Merge pull request #14 from ishan-karmakar/radio-logger
ishan-karmakar Feb 12, 2026
89ca400
feat: Lock for RadioLogger
ishan-karmakar Feb 12, 2026
0cd22a4
feat: Locking in LoggedMechanism2d
ishan-karmakar Feb 12, 2026
931f4f1
feat: Locking LoggedMechanism2d
ishan-karmakar Feb 12, 2026
07c271c
feat: Lots of changes
ishan-karmakar Feb 13, 2026
9ca1689
feat: Remove redundant LogValue constructors
ishan-karmakar Feb 13, 2026
4ea2528
feat: Use templates to remove code duplication
ishan-karmakar Feb 13, 2026
a2c53bb
feat: Switching to BlockingConcurrentQueue
ishan-karmakar Feb 13, 2026
55adbb4
Renamed functions
ishan-karmakar Feb 13, 2026
a8999ec
fix: Working on ConsoleSource buffer
ishan-karmakar Feb 15, 2026
afe465f
feat: Make function uppercase
ishan-karmakar Feb 15, 2026
d50f5eb
fix: Fix ConsoleSource
ishan-karmakar Feb 15, 2026
1c00bc7
feat: Add check robot base capability
ishan-karmakar Feb 15, 2026
a9a95c6
infra: Add C++ publishing
ishan-karmakar Feb 15, 2026
2616729
fix: Make Start/EndCompetition public
ishan-karmakar Feb 15, 2026
8de7bec
feat: Get shared library linking working
ishan-karmakar Feb 16, 2026
ff442f5
feat: Move wpilibio include out of ConduitApi.h
ishan-karmakar Feb 16, 2026
bc0d913
feat: Publish third party includes
ishan-karmakar Feb 16, 2026
eb50b2a
feat: Wrap WPI SymbolExports
ishan-karmakar Feb 16, 2026
ddb8ca9
feat: Bug fixes
ishan-karmakar Feb 16, 2026
fdfd4c6
WIP: Fix LogTable
ishan-karmakar Feb 17, 2026
9da4505
feat: Fix bugs
ishan-karmakar Feb 17, 2026
ba3476c
Merge pull request #15 from ishan-karmakar/fix-log-table
ishan-karmakar Feb 17, 2026
f408bc5
Merge branch 'Mechanical-Advantage:main' into main
ishan-karmakar Feb 26, 2026
80d0ffe
feat: Working on working ConsoleSource
ishan-karmakar Mar 3, 2026
caab3d8
feat: Add POSIX implementation for ConsoleSource
ishan-karmakar Mar 4, 2026
f72c47f
feat: Full SimulatorConsoleSource working
ishan-karmakar Mar 4, 2026
8fb76e6
Merge pull request #16 from ishan-karmakar/working-console-source
ishan-karmakar Mar 4, 2026
59002be
feat: Get WPILOGWriter implementation
ishan-karmakar Mar 5, 2026
8beadb5
fix: Fix compile errors with WPILOGWriter implementation
ishan-karmakar Mar 6, 2026
1648c35
fix: Minor WPILOG* fixes
ishan-karmakar Mar 6, 2026
4e4addb
Merge pull request #17 from ishan-karmakar/wpilog-writer
ishan-karmakar Mar 6, 2026
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
12 changes: 12 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[submodule "akit/magic_enum"]
path = akit/magic_enum
url = https://github.com/Neargye/magic_enum.git
[submodule "akit/httplib"]
path = akit/httplib
url = https://github.com/yhirose/cpp-httplib
[submodule "akit/concurrentqueue"]
path = akit/concurrentqueue
url = https://github.com/cameron314/concurrentqueue
[submodule "akit/readerwriterqueue"]
path = akit/readerwriterqueue
url = https://github.com/cameron314/readerwriterqueue
104 changes: 103 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,105 @@
{
"java.configuration.updateBuildConfiguration": "interactive"
"java.configuration.updateBuildConfiguration": "interactive",
"files.associations": {
"cstddef": "cpp",
"algorithm": "cpp",
"array": "cpp",
"atomic": "cpp",
"bit": "cpp",
"cctype": "cpp",
"compare": "cpp",
"concepts": "cpp",
"cstdint": "cpp",
"cstdio": "cpp",
"cstdlib": "cpp",
"cstring": "cpp",
"ctime": "cpp",
"cwchar": "cpp",
"exception": "cpp",
"initializer_list": "cpp",
"iosfwd": "cpp",
"iterator": "cpp",
"limits": "cpp",
"memory": "cpp",
"new": "cpp",
"optional": "cpp",
"set": "cpp",
"span": "cpp",
"string": "cpp",
"tuple": "cpp",
"type_traits": "cpp",
"typeinfo": "cpp",
"utility": "cpp",
"vector": "cpp",
"xmemory": "cpp",
"xstring": "cpp",
"xtr1common": "cpp",
"xtree": "cpp",
"xutility": "cpp",
"any": "cpp",
"chrono": "cpp",
"clocale": "cpp",
"cmath": "cpp",
"codecvt": "cpp",
"complex": "cpp",
"condition_variable": "cpp",
"cstdarg": "cpp",
"cwctype": "cpp",
"deque": "cpp",
"forward_list": "cpp",
"list": "cpp",
"map": "cpp",
"unordered_map": "cpp",
"unordered_set": "cpp",
"functional": "cpp",
"memory_resource": "cpp",
"numeric": "cpp",
"random": "cpp",
"ratio": "cpp",
"string_view": "cpp",
"system_error": "cpp",
"fstream": "cpp",
"iomanip": "cpp",
"iostream": "cpp",
"istream": "cpp",
"mutex": "cpp",
"numbers": "cpp",
"ostream": "cpp",
"ranges": "cpp",
"semaphore": "cpp",
"sstream": "cpp",
"stdexcept": "cpp",
"stop_token": "cpp",
"streambuf": "cpp",
"thread": "cpp",
"valarray": "cpp",
"variant": "cpp",
"charconv": "cpp",
"format": "cpp",
"ios": "cpp",
"locale": "cpp",
"xfacet": "cpp",
"xhash": "cpp",
"xiosbase": "cpp",
"xlocale": "cpp",
"xlocbuf": "cpp",
"xlocinfo": "cpp",
"xlocmes": "cpp",
"xlocmon": "cpp",
"xlocnum": "cpp",
"xloctime": "cpp",
"bitset": "cpp",
"expected": "cpp",
"regex": "cpp",
"source_location": "cpp",
"future": "cpp",
"cinttypes": "cpp",
"*.mac": "cpp",
"filesystem": "cpp",
"csignal": "cpp",
"matrixfunctions": "cpp",
"queue": "cpp",
"strstream": "cpp",
"cfenv": "cpp"
}
}
20 changes: 19 additions & 1 deletion akit/AdvantageKit.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,23 @@
]
}
],
"cppDependencies": []
"cppDependencies": [
{
"groupId": "${groupId}",
"artifactId": "${akitCppArtifactId}",
"version": "${version}",
"headerClassifier": "headers",
"sourcesClassifier": "sources",
"libName": "akit",
"sharedLibrary": true,
"skipInvalidPlatforms": false,
"binaryPlatforms": [
"linuxathena",
"linuxx86-64",
"linuxarm64",
"osxuniversal",
"windowsx86-64"
]
}
]
}
2 changes: 1 addition & 1 deletion akit/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ spotless {
licenseHeader("// Copyright (c) 2021-2026 Littleton Robotics\n// http://github.com/Mechanical-Advantage\n//\n// Use of this source code is governed by a BSD\n// license that can be found in the LICENSE file\n// at the root directory of this project.\n\n")
}
cpp {
target("src/main/native/**/*.cc", "src/main/native/**/*.h", "src/test/native/**/*.cc", "src/test/native/**/*.h")
target("src/main/native/**/*.cc", "src/main/native/**/*.cpp", "src/main/native/**/*.h", "src/test/native/**/*.cc", "src/test/native/**/*.cpp", "src/test/native/**/*.h")
toggleOffOn()
eclipseCdt()
trimTrailingWhitespace()
Expand Down
1 change: 1 addition & 0 deletions akit/concurrentqueue
Submodule concurrentqueue added at 00dd7b
1 change: 1 addition & 0 deletions akit/httplib
Submodule httplib added at a18891
1 change: 1 addition & 0 deletions akit/magic_enum
Submodule magic_enum added at 905ba7
45 changes: 45 additions & 0 deletions akit/native.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,10 @@ nativeUtils {
exportsFile = project.file("src/main/native/symbols.txt")
}
}

exportsConfigs {
akit {}
}
}

model {
Expand All @@ -207,6 +211,32 @@ model {

nativeUtils.useRequiredLibrary(it, "driver_shared")
}

akit(JniNativeLibrarySpec) {
jniCrossCompileOptions << JniCrossCompileOptions(nativeUtils.wpi.platforms.roborio)
// Leave these for future proofing
jniCrossCompileOptions << JniCrossCompileOptions(nativeUtils.wpi.platforms.linuxarm32)
jniCrossCompileOptions << JniCrossCompileOptions(nativeUtils.wpi.platforms.linuxarm64)
sources {
cpp {
source {
srcDirs 'src/main/native/cpp'
include '**/*.cpp'
}

exportedHeaders {
srcDirs 'src/main/native/include', 'src/main/generated/include', 'src/main/thirdparty/include', 'magic_enum/include', 'httplib', 'concurrentqueue', 'readerwriterqueue'
}
}
}

nativeUtils.useRequiredLibrary(it, "wpilib_shared")

binaries.all {
lib project: ':', library: 'wpilibio', linkage: 'static'
cppCompiler.args << '-DWPILIB_EXPORTS'
}
}
}
testSuites {
wpilibioTest {
Expand All @@ -219,5 +249,20 @@ model {

nativeUtils.useRequiredLibrary(it, "wpilib_executable_shared", "googletest_static")
}
akitTest {
sources.cpp {
source {
srcDir 'src/test/native/cpp'
include '**/*.cpp'
}
}

nativeUtils.useRequiredLibrary(it, "wpilib_executable_shared", "googletest_static")

binaries.all {
lib project: ':', library: 'wpilibio', linkage: 'static'
cppCompiler.args << '-DWPILIB_EXPORTS'
}
}
}
}
61 changes: 61 additions & 0 deletions akit/publish.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,53 @@ def artifactGroupId = 'org.littletonrobotics.akit'
def javaArtifactId = 'akit-java'
def wpilibioArtifactId = 'akit-wpilibio'
def wpilibioZipBaseName = "_GROUP_${artifactGroupId.replace('.', '_')}_ID_${wpilibioArtifactId}_CLS"
def akitCppArtifactId = 'akit-cpp'
def akitCppZipBaseName = "_GROUP_${artifactGroupId.replace('.', '_')}_ID_${akitCppArtifactId}_CLS"

task akitCppHeadersZip(type: Zip) {
archiveBaseName = akitCppZipBaseName
archiveClassifier = "headers"

from(licenseFile) {
into '/'
}

from('src/main/native/include') {
into '/'
}

from('readerwriterqueue') {
into '/'
include '*.h'
}

from('concurrentqueue') {
into '/'
include '*.h'
}

from('magic_enum/include') {
into '/'
}

from('httplib') {
into '/'
include '*.h'
}
}

task akitCppSourceZip(type: Zip) {
archiveBaseName = akitCppZipBaseName
archiveClassifier = "sources"

from(licenseFile) {
into '/'
}

from('src/main/native/cpp') {
into '/'
}
}

artifacts {
archives sourcesJar
Expand Down Expand Up @@ -66,6 +113,7 @@ task vendordep(type: Copy) {
"groupId": artifactGroupId,
"javaArtifactId": javaArtifactId,
"jniArtifactId": wpilibioArtifactId,
"akitCppArtifactId": akitCppArtifactId,
"frcYear": frcYear)
}

Expand All @@ -76,6 +124,7 @@ publish.dependsOn build
model {
publishing {
def wpilibioTaskList = createComponentZipTasks($.components, ['wpilibio'], wpilibioZipBaseName, Zip, project, includeStandardZipFormat)
def akitCppTaskList = createComponentZipTasks($.components, ['akit'], akitCppZipBaseName, Zip, project, includeStandardZipFormat)
def skipJava = project.hasProperty("skipJava")
publications {
wpilibio(MavenPublication) {
Expand All @@ -88,6 +137,18 @@ model {
version pubVersion
}

akitCpp(MavenPublication) {
akitCppTaskList.each {
artifact it
}
artifact akitCppHeadersZip
artifact akitCppSourceZip

artifactId = akitCppArtifactId
groupId artifactGroupId
version pubVersion
}

if (!skipJava) {
java(MavenPublication) {
artifact jar
Expand Down
1 change: 1 addition & 0 deletions akit/readerwriterqueue
Submodule readerwriterqueue added at 211616
17 changes: 17 additions & 0 deletions akit/src/main/native/cpp/AlertLogger.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
// Copyright (c) 2021-2026 Littleton Robotics
// http://github.com/Mechanical-Advantage
//
// Use of this source code is governed by a BSD
// license that can be found in the LICENSE file
// at the root directory of this project.

#include "akit/AlertLogger.h"

using namespace akit;

std::unordered_map<std::string, nt::StringArraySubscriber> AlertLogger::errorSubscribers;
std::unordered_map<std::string, nt::StringArraySubscriber> AlertLogger::warningSubscribers;
std::unordered_map<std::string, nt::StringArraySubscriber> AlertLogger::infoSubscribers;

void AlertLogger::periodic() {
}
Loading