Skip to content

Commit 0a3a03f

Browse files
authored
Merge pull request #1 from aeriqkim/main
Update reference to libethard to libudpard
2 parents 78e3aca + fd0280a commit 0a3a03f

19 files changed

+12174
-6240
lines changed

README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1+
# NOTICE
2+
3+
This package is a staging package to make changes before committing a pull request for the github repo: https://github.com/OpenCyphal-Garage/libudpard based on @schoberm's prototype work
4+
15
# Compact Cyphal/UDP v0 in C
26

3-
Libethard is a compact implementation of the Cyphal/UDP protocol stack in C99/C11 for high-integrity real-time
7+
Libudpard is a compact implementation of the Cyphal/UDP protocol stack in C99/C11 for high-integrity real-time
48
embedded systems.
59

610
[Cyphal](https://opencyphal.org) is an open lightweight data bus standard designed for reliable intravehicular
7-
communication in aerospace and robotic applications via CAN bus, Ethernet, and other robust transports.
11+
communication in aerospace and robotic applications via CAN bus, UDP, and other robust transports.
812

913
## WORK IN PROGRESS, NOT READY FOR FORMAL USE
1014

11-
**Read the docs in [`libethard/ethard.h`](/libethard/ethard.h).**
15+
**Read the docs in [`libudpard/udpard.h`](/libudpard/udpard.h).**
1216

1317
Building
1418
```
@@ -17,6 +21,7 @@ cmake -B ./build -DCMAKE_BUILD_TYPE=Debug -DNO_STATIC_ANALYSIS=1 -DCMAKE_C_COMPI
1721
Testing
1822
```
1923
cd build
24+
make
2025
make test
2126
```
2227

libethard/cavl.h renamed to libudpard/cavl.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@
2323

2424
#pragma once
2525

26-
#include "ethard.h"
26+
#include "udpard.h"
2727

28-
/// Modified for use with Libethard: use the same assertion check macro if provided.
29-
#ifdef ETHARD_ASSERT
30-
# define CAVL_ASSERT ETHARD_ASSERT
28+
/// Modified for use with Libudpard: use the same assertion check macro if provided.
29+
#ifdef UDPARD_ASSERT
30+
# define CAVL_ASSERT UDPARD_ASSERT
3131
#else
3232
// Intentional violation of MISRA: inclusion not at the top of the file to eliminate unnecessary dependency on assert.h.
3333
# include <assert.h> // NOSONAR
@@ -42,8 +42,8 @@ extern "C" {
4242

4343
// ---------------------------------------- PUBLIC API SECTION ----------------------------------------
4444

45-
/// Modified for use with Libethard: expose the Cavl structure via public API as EthardTreeNode.
46-
typedef EthardTreeNode Cavl;
45+
/// Modified for use with Libudpard: expose the Cavl structure via public API as UdpardTreeNode.
46+
typedef UdpardTreeNode Cavl;
4747

4848
/// Returns POSITIVE if the search target is GREATER than the provided node, negative if smaller, zero on match (found).
4949
/// Values other than {-1, 0, +1} are not recommended to avoid overflow during the narrowing conversion of the result.
Lines changed: 293 additions & 293 deletions
Large diffs are not rendered by default.
Lines changed: 144 additions & 144 deletions
Large diffs are not rendered by default.

tests/CMakeLists.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# This software is distributed under the terms of the MIT License.
22
# Copyright (c) 2016 OpenCyphal.
33
# Author: Pavel Kirienko <[email protected]>
4-
# Contributors: https://github.com/OpenCyphal/libethard/contributors.
4+
# Contributors: https://github.com/OpenCyphal/libudpard/contributors.
55

66
cmake_minimum_required(VERSION 3.12)
7-
project(ethard_tests C CXX)
7+
project(udpard_tests C CXX)
88
enable_testing()
99

1010
set(CTEST_OUTPUT_ON_FAILURE ON)
11-
set(library_dir "${CMAKE_SOURCE_DIR}/../libethard")
11+
set(library_dir "${CMAKE_SOURCE_DIR}/../libudpard")
1212

1313
# Use -DNO_STATIC_ANALYSIS=1 to suppress static analysis.
1414
# If not suppressed, the tools used here shall be available, otherwise the build will fail.
@@ -45,7 +45,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Woverloaded-virtual -Wnon-virtual-dtor
4545
include_directories(catch ${library_dir})
4646
add_definitions(-DCATCH_CONFIG_FAST_COMPILE=1 -DCATCH_CONFIG_ENABLE_ALL_STRINGMAKERS=1)
4747

48-
set(common_sources catch/main.cpp ${library_dir}/ethard.c)
48+
set(common_sources catch/main.cpp ${library_dir}/udpard.c)
4949

5050
function(gen_test name files compile_definitions compile_flags link_flags c_standard)
5151
add_executable(${name} ${common_sources} ${files})
@@ -80,7 +80,7 @@ endfunction()
8080
# Disable missing declaration warning to allow exposure of private definitions.
8181
gen_test_matrix(test_private
8282
"test_private_crc.cpp;test_private_rx.cpp;test_private_tx.cpp;test_private_cavl.cpp;"
83-
"-DETHARD_CONFIG_HEADER=\"${CMAKE_CURRENT_SOURCE_DIR}/ethard_config_private.h\""
83+
"-DUDPARD_CONFIG_HEADER=\"${CMAKE_CURRENT_SOURCE_DIR}/udpard_config_private.h\""
8484
"-Wno-missing-declarations")
8585

8686
gen_test_matrix(test_public

0 commit comments

Comments
 (0)