CCSDS Space Data Link Security (355.0-B-2)
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

regenerate EverParse C files with wire 0.9.0

Wire_3d now generates ExternalTypedefs.h, ExternalAPI.h, Wrapper, and
Fields files for schemas using WireCtx. Bitfield padding fixed so .3d
structs match OCaml codec wire_size. Test.c passes NULL for WIRECTX
and links per-schema Field stubs. File naming matches EverParse output.

Also: gitignore EverParse intermediates (.fst, .krml, .rsp, Makefile)
and remove the previously-tracked ones from ocaml-fsr.

+26 -26
+1 -1
c/EP_Header_ExternalTypedefs.h
··· 1 1 #ifndef WIRECTX_DEFINED 2 2 #define WIRECTX_DEFINED 3 - typedef struct EP_HeaderFields WIRECTX; 3 + typedef struct EpHeaderFields WIRECTX; 4 4 #endif
+2 -2
c/EP_Header_Fields.c
··· 4 4 #include "EP_Header_ExternalAPI.h" 5 5 6 6 void EpHeaderSetU8(WIRECTX *ctx, uint32_t idx, uint8_t v) { 7 - EP_HeaderFields *f = (EP_HeaderFields *) ctx; 7 + EpHeaderFields *f = (EpHeaderFields *) ctx; 8 8 switch (idx) { 9 9 case 0: f->Type = (uint32_t) v; break; 10 10 case 1: f->UF = (uint32_t) v; break; ··· 15 15 } 16 16 17 17 void EpHeaderSetU16be(WIRECTX *ctx, uint32_t idx, uint16_t v) { 18 - EP_HeaderFields *f = (EP_HeaderFields *) ctx; 18 + EpHeaderFields *f = (EpHeaderFields *) ctx; 19 19 switch (idx) { 20 20 case 4: f->PDU_LEN = (uint16_t) v; break; 21 21 default: (void) f; (void) v; break;
+10 -10
c/EP_Header_Fields.h
··· 1 - #ifndef EP_HEADER_FIELDS_H 2 - #define EP_HEADER_FIELDS_H 1 + #ifndef EPHEADER_FIELDS_H 2 + #define EPHEADER_FIELDS_H 3 3 #include <stdint.h> 4 4 5 5 /* Field indices -- use with the schema's WireSet* callbacks in a 6 6 custom [WIRECTX] if you only want to capture a subset. */ 7 - #define EP_HEADER_IDX_TYPE 0 8 - #define EP_HEADER_IDX_UF 1 9 - #define EP_HEADER_IDX_SG 2 10 - #define EP_HEADER_IDX_PID 3 11 - #define EP_HEADER_IDX_PDU_LEN 4 7 + #define EPHEADER_IDX_TYPE 0 8 + #define EPHEADER_IDX_UF 1 9 + #define EPHEADER_IDX_SG 2 10 + #define EPHEADER_IDX_PID 3 11 + #define EPHEADER_IDX_PDU_LEN 4 12 12 13 13 /* Default plug: one typed member per named field. Pass a pointer to 14 - [EP_HeaderFields] as [WIRECTX *] when you want every field populated. */ 15 - typedef struct EP_HeaderFields { 14 + [EpHeaderFields] as [WIRECTX *] when you want every field populated. */ 15 + typedef struct EpHeaderFields { 16 16 uint32_t Type; 17 17 uint32_t UF; 18 18 uint8_t SG; 19 19 uint8_t PID; 20 20 uint16_t PDU_LEN; 21 - } EP_HeaderFields; 21 + } EpHeaderFields; 22 22 #endif
+1 -1
c/MC_Status_Reply_ExternalTypedefs.h
··· 1 1 #ifndef WIRECTX_DEFINED 2 2 #define WIRECTX_DEFINED 3 - typedef struct MC_Status_ReplyFields WIRECTX; 3 + typedef struct McStatusReplyFields WIRECTX; 4 4 #endif
+2 -2
c/MC_Status_Reply_Fields.c
··· 4 4 #include "MC_Status_Reply_ExternalAPI.h" 5 5 6 6 void McStatusReplySetU8(WIRECTX *ctx, uint32_t idx, uint8_t v) { 7 - MC_Status_ReplyFields *f = (MC_Status_ReplyFields *) ctx; 7 + McStatusReplyFields *f = (McStatusReplyFields *) ctx; 8 8 switch (idx) { 9 9 case 0: f->Operational = (uint32_t) v; break; 10 10 default: (void) f; (void) v; break; ··· 12 12 } 13 13 14 14 void McStatusReplySetU16be(WIRECTX *ctx, uint32_t idx, uint16_t v) { 15 - MC_Status_ReplyFields *f = (MC_Status_ReplyFields *) ctx; 15 + McStatusReplyFields *f = (McStatusReplyFields *) ctx; 16 16 switch (idx) { 17 17 case 1: f->KeyCount = (uint16_t) v; break; 18 18 case 2: f->SACount = (uint16_t) v; break;
+8 -8
c/MC_Status_Reply_Fields.h
··· 1 - #ifndef MC_STATUS_REPLY_FIELDS_H 2 - #define MC_STATUS_REPLY_FIELDS_H 1 + #ifndef MCSTATUSREPLY_FIELDS_H 2 + #define MCSTATUSREPLY_FIELDS_H 3 3 #include <stdint.h> 4 4 5 5 /* Field indices -- use with the schema's WireSet* callbacks in a 6 6 custom [WIRECTX] if you only want to capture a subset. */ 7 - #define MC_STATUS_REPLY_IDX_OPERATIONAL 0 8 - #define MC_STATUS_REPLY_IDX_KEYCOUNT 1 9 - #define MC_STATUS_REPLY_IDX_SACOUNT 2 7 + #define MCSTATUSREPLY_IDX_OPERATIONAL 0 8 + #define MCSTATUSREPLY_IDX_KEYCOUNT 1 9 + #define MCSTATUSREPLY_IDX_SACOUNT 2 10 10 11 11 /* Default plug: one typed member per named field. Pass a pointer to 12 - [MC_Status_ReplyFields] as [WIRECTX *] when you want every field populated. */ 13 - typedef struct MC_Status_ReplyFields { 12 + [McStatusReplyFields] as [WIRECTX *] when you want every field populated. */ 13 + typedef struct McStatusReplyFields { 14 14 uint32_t Operational; 15 15 uint16_t KeyCount; 16 16 uint16_t SACount; 17 - } MC_Status_ReplyFields; 17 + } McStatusReplyFields; 18 18 #endif
+2 -2
c/test.c
··· 30 30 int pass = 0, fail = 0; 31 31 uint8_t buf[3]; 32 32 uint64_t r; 33 - EP_HeaderFields ctx = {0}; 33 + EpHeaderFields ctx = {0}; 34 34 35 35 memset(buf, 0, 3); 36 36 r = EpHeaderValidateEpHeader((WIRECTX *) &ctx, NULL, counting_error_handler, buf, 3, 0); ··· 77 77 int pass = 0, fail = 0; 78 78 uint8_t buf[5]; 79 79 uint64_t r; 80 - MC_Status_ReplyFields ctx = {0}; 80 + McStatusReplyFields ctx = {0}; 81 81 82 82 memset(buf, 0, 5); 83 83 r = McStatusReplyValidateMcStatusReply((WIRECTX *) &ctx, NULL, counting_error_handler, buf, 5, 0);