Searched refs:pet (Results 1 – 12 of 12) sorted by relevance
/zcbor-3.6.0/tests/encode/test2_simple/ |
D | CMakeLists.txt | 16 -c ${CMAKE_CURRENT_LIST_DIR}/../../cases/pet.cddl 17 --output-cmake ${PROJECT_BINARY_DIR}/pet.cmake 29 include(${PROJECT_BINARY_DIR}/pet.cmake) 31 target_link_libraries(pet PRIVATE zephyr_interface) 32 target_link_libraries(app PRIVATE pet)
|
/zcbor-3.6.0/tests/unit/test2_cpp/ |
D | CMakeLists.txt | 24 -c ${CMAKE_CURRENT_LIST_DIR}/../../cases/pet.cddl 25 --output-cmake ${PROJECT_BINARY_DIR}/pet.cmake 37 include(${PROJECT_BINARY_DIR}/pet.cmake) 38 target_link_libraries(pet PRIVATE zephyr_interface) 39 target_link_libraries(app PRIVATE pet)
|
/zcbor-3.6.0/samples/pet/src/ |
D | main.c | 13 static void print_pet(const struct Pet *pet) in print_pet() argument 16 for (int i = 0; i < pet->names_count; i++) { in print_pet() 17 printf(" %.*s", (int)pet->names[i].len, pet->names[i].value); in print_pet() 20 for (int i = 0; i < pet->birthday.len; i++) { in print_pet() 21 printf("%02x", pet->birthday.value[i]); in print_pet() 23 switch (pet->species_choice) { in print_pet()
|
/zcbor-3.6.0/tests/decode/test3_simple/src/ |
D | main.c | 433 struct Pet pet; in ZTEST() local 439 zassert_equal(ZCBOR_SUCCESS, cbor_decode_Pet(input, sizeof(input), &pet, &decode_len), ""); in ZTEST() 444 zassert_equal(2, pet.names_count, "Expect 2 names"); in ZTEST() 445 zassert_mem_equal("foo", pet.names[0].value, 3, "Expect first name 'foo'"); in ZTEST() 446 zassert_mem_equal("bar", pet.names[1].value, 3, "Expect first name 'bar'"); in ZTEST() 447 zassert_equal(8, pet.birthday.len, "Expect len 8 birthday"); in ZTEST() 448 zassert_mem_equal(exp_birthday, pet.birthday.value, 8, "Expect birthday"); in ZTEST() 449 zassert_equal(Pet_species_dog_c, pet.species_choice, "Expect dog"); in ZTEST()
|
/zcbor-3.6.0/tests/fuzz/ |
D | CMakeLists.txt | 17 set(TEST_CASE "pet" CACHE STRING "Test case (pet or manifest12)") 19 if (${TEST_CASE} STREQUAL pet) 23 -c ${CMAKE_CURRENT_LIST_DIR}/../cases/pet.cddl 24 --output-cmake ${PROJECT_BINARY_DIR}/pet.cmake 32 --cddl ${CMAKE_CURRENT_LIST_DIR}/../cases/pet.cddl 41 include(${PROJECT_BINARY_DIR}/pet.cmake) 42 target_link_libraries(fuzz_target PRIVATE pet)
|
/zcbor-3.6.0/samples/pet/ |
D | CMakeLists.txt | 17 …-c ${CMAKE_CURRENT_LIST_DIR}/../../tests/cases/pet.cddl # Generate code for the data structures in… 18 -t Pet # Create a public API for decoding/encoding the "Pet" type from pet.cddl 19 … --output-cmake ${CMAKE_CURRENT_LIST_DIR}/pet.cmake # The generated cmake file will be placed here 30 zcbor convert -c ${CMAKE_CURRENT_LIST_DIR}/../../tests/cases/pet.cddl -t Pet 42 include(${CMAKE_CURRENT_LIST_DIR}/pet.cmake) 46 # Link the library from pet.cmake 47 target_link_libraries(app PRIVATE pet)
|
D | pet.cmake | 11 add_library(pet) target 12 target_sources(pet PRIVATE 19 target_include_directories(pet PUBLIC
|
D | README.md | 14 …ee representations. Changing [pet1.yml](pet1.yml) will change the printed output for the first pet.
|
/zcbor-3.6.0/tests/decode/test3_simple/ |
D | CMakeLists.txt | 19 -c ${CMAKE_CURRENT_LIST_DIR}/../../cases/pet.cddl 20 --output-cmake ${PROJECT_BINARY_DIR}/pet.cmake 51 include(${PROJECT_BINARY_DIR}/pet.cmake) 59 target_link_libraries(pet PRIVATE zephyr_interface) 60 target_link_libraries(app PRIVATE pet)
|
/zcbor-3.6.0/tests/encode/test2_simple/src/ |
D | main.c | 39 struct Pet pet = { in ZTEST() local 60 zassert_equal(ZCBOR_SUCCESS, cbor_encode_Pet(output, sizeof(output), &pet, &out_len), NULL); in ZTEST()
|
/zcbor-3.6.0/tests/unit/test2_cpp/src/ |
D | main.cpp | 109 struct Pet pet; in main() local 114 int int_ret = cbor_decode_Pet(input, sizeof(input), &pet, NULL); in main()
|
/zcbor-3.6.0/ |
D | README.md | 41 2. The [pet sample](samples/pet/README.md) shows a how to use the C library together with generated… 209 …e the [hello_world](samples/hello_world/src/main.c) sample, or the [pet](samples/pet/src/main.c) s… 211 To see how to use code generation, see the [pet](samples/pet/src/main.c) sample. 213 Look at the [CMakeLists.txt](samples/pet/CMakeLists.txt) file to see how zcbor is invoked for code … 215 To see how to do conversion, see the [pet](samples/pet/CMakeLists.txt) sample. 223 python3 <zcbor base>/zcbor/zcbor.py code -c pet.cddl -d -t Pet --oc pet_decode.c --oh pet_decode.h 225 zcbor code -c pet.cddl -d -t Pet --oc pet_decode.c --oh pet_decode.h 234 python3 <zcbor base>/zcbor/zcbor.py convert -c pet.cddl -t Pet -i mypet.yaml -o mypet.cbor 236 zcbor convert -c pet.cddl -t Pet -i mypet.yaml -o mypet.cbor 239 …m mypet.yaml, validates it against the Pet type in the CDDL description in pet.cddl, and writes bi… [all …]
|