ota_send_file.pb-c.c 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657
  1. /* Generated by the protocol buffer compiler. DO NOT EDIT! */
  2. /* Generated from: ota_send_file.proto */
  3. /* Do not generate deprecated warnings for self */
  4. #ifndef PROTOBUF_C__NO_DEPRECATED
  5. #define PROTOBUF_C__NO_DEPRECATED
  6. #endif
  7. #include "ota_send_file.pb-c.h"
  8. void cmd_send_file__init
  9. (CmdSendFile *message)
  10. {
  11. static const CmdSendFile init_value = CMD_SEND_FILE__INIT;
  12. *message = init_value;
  13. }
  14. size_t cmd_send_file__get_packed_size
  15. (const CmdSendFile *message)
  16. {
  17. assert(message->base.descriptor == &cmd_send_file__descriptor);
  18. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  19. }
  20. size_t cmd_send_file__pack
  21. (const CmdSendFile *message,
  22. uint8_t *out)
  23. {
  24. assert(message->base.descriptor == &cmd_send_file__descriptor);
  25. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  26. }
  27. size_t cmd_send_file__pack_to_buffer
  28. (const CmdSendFile *message,
  29. ProtobufCBuffer *buffer)
  30. {
  31. assert(message->base.descriptor == &cmd_send_file__descriptor);
  32. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  33. }
  34. CmdSendFile *
  35. cmd_send_file__unpack
  36. (ProtobufCAllocator *allocator,
  37. size_t len,
  38. const uint8_t *data)
  39. {
  40. return (CmdSendFile *)
  41. protobuf_c_message_unpack (&cmd_send_file__descriptor,
  42. allocator, len, data);
  43. }
  44. void cmd_send_file__free_unpacked
  45. (CmdSendFile *message,
  46. ProtobufCAllocator *allocator)
  47. {
  48. if (!message) {
  49. return;
  50. }
  51. assert(message->base.descriptor == &cmd_send_file__descriptor);
  52. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  53. }
  54. void resp_send_file__init
  55. (RespSendFile *message)
  56. {
  57. static const RespSendFile init_value = RESP_SEND_FILE__INIT;
  58. *message = init_value;
  59. }
  60. size_t resp_send_file__get_packed_size
  61. (const RespSendFile *message)
  62. {
  63. assert(message->base.descriptor == &resp_send_file__descriptor);
  64. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  65. }
  66. size_t resp_send_file__pack
  67. (const RespSendFile *message,
  68. uint8_t *out)
  69. {
  70. assert(message->base.descriptor == &resp_send_file__descriptor);
  71. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  72. }
  73. size_t resp_send_file__pack_to_buffer
  74. (const RespSendFile *message,
  75. ProtobufCBuffer *buffer)
  76. {
  77. assert(message->base.descriptor == &resp_send_file__descriptor);
  78. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  79. }
  80. RespSendFile *
  81. resp_send_file__unpack
  82. (ProtobufCAllocator *allocator,
  83. size_t len,
  84. const uint8_t *data)
  85. {
  86. return (RespSendFile *)
  87. protobuf_c_message_unpack (&resp_send_file__descriptor,
  88. allocator, len, data);
  89. }
  90. void resp_send_file__free_unpacked
  91. (RespSendFile *message,
  92. ProtobufCAllocator *allocator)
  93. {
  94. if (!message) {
  95. return;
  96. }
  97. assert(message->base.descriptor == &resp_send_file__descriptor);
  98. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  99. }
  100. void cmd_start_ota__init
  101. (CmdStartOTA *message)
  102. {
  103. static const CmdStartOTA init_value = CMD_START_OTA__INIT;
  104. *message = init_value;
  105. }
  106. size_t cmd_start_ota__get_packed_size
  107. (const CmdStartOTA *message)
  108. {
  109. assert(message->base.descriptor == &cmd_start_ota__descriptor);
  110. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  111. }
  112. size_t cmd_start_ota__pack
  113. (const CmdStartOTA *message,
  114. uint8_t *out)
  115. {
  116. assert(message->base.descriptor == &cmd_start_ota__descriptor);
  117. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  118. }
  119. size_t cmd_start_ota__pack_to_buffer
  120. (const CmdStartOTA *message,
  121. ProtobufCBuffer *buffer)
  122. {
  123. assert(message->base.descriptor == &cmd_start_ota__descriptor);
  124. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  125. }
  126. CmdStartOTA *
  127. cmd_start_ota__unpack
  128. (ProtobufCAllocator *allocator,
  129. size_t len,
  130. const uint8_t *data)
  131. {
  132. return (CmdStartOTA *)
  133. protobuf_c_message_unpack (&cmd_start_ota__descriptor,
  134. allocator, len, data);
  135. }
  136. void cmd_start_ota__free_unpacked
  137. (CmdStartOTA *message,
  138. ProtobufCAllocator *allocator)
  139. {
  140. if (!message) {
  141. return;
  142. }
  143. assert(message->base.descriptor == &cmd_start_ota__descriptor);
  144. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  145. }
  146. void resp_start_ota__init
  147. (RespStartOTA *message)
  148. {
  149. static const RespStartOTA init_value = RESP_START_OTA__INIT;
  150. *message = init_value;
  151. }
  152. size_t resp_start_ota__get_packed_size
  153. (const RespStartOTA *message)
  154. {
  155. assert(message->base.descriptor == &resp_start_ota__descriptor);
  156. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  157. }
  158. size_t resp_start_ota__pack
  159. (const RespStartOTA *message,
  160. uint8_t *out)
  161. {
  162. assert(message->base.descriptor == &resp_start_ota__descriptor);
  163. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  164. }
  165. size_t resp_start_ota__pack_to_buffer
  166. (const RespStartOTA *message,
  167. ProtobufCBuffer *buffer)
  168. {
  169. assert(message->base.descriptor == &resp_start_ota__descriptor);
  170. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  171. }
  172. RespStartOTA *
  173. resp_start_ota__unpack
  174. (ProtobufCAllocator *allocator,
  175. size_t len,
  176. const uint8_t *data)
  177. {
  178. return (RespStartOTA *)
  179. protobuf_c_message_unpack (&resp_start_ota__descriptor,
  180. allocator, len, data);
  181. }
  182. void resp_start_ota__free_unpacked
  183. (RespStartOTA *message,
  184. ProtobufCAllocator *allocator)
  185. {
  186. if (!message) {
  187. return;
  188. }
  189. assert(message->base.descriptor == &resp_start_ota__descriptor);
  190. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  191. }
  192. void cmd_finish_ota__init
  193. (CmdFinishOTA *message)
  194. {
  195. static const CmdFinishOTA init_value = CMD_FINISH_OTA__INIT;
  196. *message = init_value;
  197. }
  198. size_t cmd_finish_ota__get_packed_size
  199. (const CmdFinishOTA *message)
  200. {
  201. assert(message->base.descriptor == &cmd_finish_ota__descriptor);
  202. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  203. }
  204. size_t cmd_finish_ota__pack
  205. (const CmdFinishOTA *message,
  206. uint8_t *out)
  207. {
  208. assert(message->base.descriptor == &cmd_finish_ota__descriptor);
  209. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  210. }
  211. size_t cmd_finish_ota__pack_to_buffer
  212. (const CmdFinishOTA *message,
  213. ProtobufCBuffer *buffer)
  214. {
  215. assert(message->base.descriptor == &cmd_finish_ota__descriptor);
  216. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  217. }
  218. CmdFinishOTA *
  219. cmd_finish_ota__unpack
  220. (ProtobufCAllocator *allocator,
  221. size_t len,
  222. const uint8_t *data)
  223. {
  224. return (CmdFinishOTA *)
  225. protobuf_c_message_unpack (&cmd_finish_ota__descriptor,
  226. allocator, len, data);
  227. }
  228. void cmd_finish_ota__free_unpacked
  229. (CmdFinishOTA *message,
  230. ProtobufCAllocator *allocator)
  231. {
  232. if (!message) {
  233. return;
  234. }
  235. assert(message->base.descriptor == &cmd_finish_ota__descriptor);
  236. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  237. }
  238. void resp_finish_ota__init
  239. (RespFinishOTA *message)
  240. {
  241. static const RespFinishOTA init_value = RESP_FINISH_OTA__INIT;
  242. *message = init_value;
  243. }
  244. size_t resp_finish_ota__get_packed_size
  245. (const RespFinishOTA *message)
  246. {
  247. assert(message->base.descriptor == &resp_finish_ota__descriptor);
  248. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  249. }
  250. size_t resp_finish_ota__pack
  251. (const RespFinishOTA *message,
  252. uint8_t *out)
  253. {
  254. assert(message->base.descriptor == &resp_finish_ota__descriptor);
  255. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  256. }
  257. size_t resp_finish_ota__pack_to_buffer
  258. (const RespFinishOTA *message,
  259. ProtobufCBuffer *buffer)
  260. {
  261. assert(message->base.descriptor == &resp_finish_ota__descriptor);
  262. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  263. }
  264. RespFinishOTA *
  265. resp_finish_ota__unpack
  266. (ProtobufCAllocator *allocator,
  267. size_t len,
  268. const uint8_t *data)
  269. {
  270. return (RespFinishOTA *)
  271. protobuf_c_message_unpack (&resp_finish_ota__descriptor,
  272. allocator, len, data);
  273. }
  274. void resp_finish_ota__free_unpacked
  275. (RespFinishOTA *message,
  276. ProtobufCAllocator *allocator)
  277. {
  278. if (!message) {
  279. return;
  280. }
  281. assert(message->base.descriptor == &resp_finish_ota__descriptor);
  282. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  283. }
  284. void send_file_payload__init
  285. (SendFilePayload *message)
  286. {
  287. static const SendFilePayload init_value = SEND_FILE_PAYLOAD__INIT;
  288. *message = init_value;
  289. }
  290. size_t send_file_payload__get_packed_size
  291. (const SendFilePayload *message)
  292. {
  293. assert(message->base.descriptor == &send_file_payload__descriptor);
  294. return protobuf_c_message_get_packed_size ((const ProtobufCMessage *)(message));
  295. }
  296. size_t send_file_payload__pack
  297. (const SendFilePayload *message,
  298. uint8_t *out)
  299. {
  300. assert(message->base.descriptor == &send_file_payload__descriptor);
  301. return protobuf_c_message_pack ((const ProtobufCMessage *)message, out);
  302. }
  303. size_t send_file_payload__pack_to_buffer
  304. (const SendFilePayload *message,
  305. ProtobufCBuffer *buffer)
  306. {
  307. assert(message->base.descriptor == &send_file_payload__descriptor);
  308. return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage *)message, buffer);
  309. }
  310. SendFilePayload *
  311. send_file_payload__unpack
  312. (ProtobufCAllocator *allocator,
  313. size_t len,
  314. const uint8_t *data)
  315. {
  316. return (SendFilePayload *)
  317. protobuf_c_message_unpack (&send_file_payload__descriptor,
  318. allocator, len, data);
  319. }
  320. void send_file_payload__free_unpacked
  321. (SendFilePayload *message,
  322. ProtobufCAllocator *allocator)
  323. {
  324. if (!message) {
  325. return;
  326. }
  327. assert(message->base.descriptor == &send_file_payload__descriptor);
  328. protobuf_c_message_free_unpacked ((ProtobufCMessage *)message, allocator);
  329. }
  330. static const ProtobufCFieldDescriptor cmd_send_file__field_descriptors[1] = {
  331. {
  332. "data",
  333. 1,
  334. PROTOBUF_C_LABEL_NONE,
  335. PROTOBUF_C_TYPE_BYTES,
  336. 0, /* quantifier_offset */
  337. offsetof(CmdSendFile, data),
  338. NULL,
  339. NULL,
  340. 0, /* flags */
  341. 0, NULL, NULL /* reserved1,reserved2, etc */
  342. },
  343. };
  344. static const unsigned cmd_send_file__field_indices_by_name[] = {
  345. 0, /* field[0] = data */
  346. };
  347. static const ProtobufCIntRange cmd_send_file__number_ranges[1 + 1] = {
  348. { 1, 0 },
  349. { 0, 1 }
  350. };
  351. const ProtobufCMessageDescriptor cmd_send_file__descriptor = {
  352. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  353. "CmdSendFile",
  354. "CmdSendFile",
  355. "CmdSendFile",
  356. "",
  357. sizeof(CmdSendFile),
  358. 1,
  359. cmd_send_file__field_descriptors,
  360. cmd_send_file__field_indices_by_name,
  361. 1, cmd_send_file__number_ranges,
  362. (ProtobufCMessageInit) cmd_send_file__init,
  363. NULL, NULL, NULL /* reserved[123] */
  364. };
  365. #define resp_send_file__field_descriptors NULL
  366. #define resp_send_file__field_indices_by_name NULL
  367. #define resp_send_file__number_ranges NULL
  368. const ProtobufCMessageDescriptor resp_send_file__descriptor = {
  369. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  370. "RespSendFile",
  371. "RespSendFile",
  372. "RespSendFile",
  373. "",
  374. sizeof(RespSendFile),
  375. 0,
  376. resp_send_file__field_descriptors,
  377. resp_send_file__field_indices_by_name,
  378. 0, resp_send_file__number_ranges,
  379. (ProtobufCMessageInit) resp_send_file__init,
  380. NULL, NULL, NULL /* reserved[123] */
  381. };
  382. static const ProtobufCFieldDescriptor cmd_start_ota__field_descriptors[3] = {
  383. {
  384. "file_size",
  385. 1,
  386. PROTOBUF_C_LABEL_NONE,
  387. PROTOBUF_C_TYPE_UINT64,
  388. 0, /* quantifier_offset */
  389. offsetof(CmdStartOTA, file_size),
  390. NULL,
  391. NULL,
  392. 0, /* flags */
  393. 0, NULL, NULL /* reserved1,reserved2, etc */
  394. },
  395. {
  396. "block_size",
  397. 2,
  398. PROTOBUF_C_LABEL_NONE,
  399. PROTOBUF_C_TYPE_UINT64,
  400. 0, /* quantifier_offset */
  401. offsetof(CmdStartOTA, block_size),
  402. NULL,
  403. NULL,
  404. 0, /* flags */
  405. 0, NULL, NULL /* reserved1,reserved2, etc */
  406. },
  407. {
  408. "partition_name",
  409. 3,
  410. PROTOBUF_C_LABEL_NONE,
  411. PROTOBUF_C_TYPE_STRING,
  412. 0, /* quantifier_offset */
  413. offsetof(CmdStartOTA, partition_name),
  414. NULL,
  415. &protobuf_c_empty_string,
  416. 0, /* flags */
  417. 0, NULL, NULL /* reserved1,reserved2, etc */
  418. },
  419. };
  420. static const unsigned cmd_start_ota__field_indices_by_name[] = {
  421. 1, /* field[1] = block_size */
  422. 0, /* field[0] = file_size */
  423. 2, /* field[2] = partition_name */
  424. };
  425. static const ProtobufCIntRange cmd_start_ota__number_ranges[1 + 1] = {
  426. { 1, 0 },
  427. { 0, 3 }
  428. };
  429. const ProtobufCMessageDescriptor cmd_start_ota__descriptor = {
  430. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  431. "CmdStartOTA",
  432. "CmdStartOTA",
  433. "CmdStartOTA",
  434. "",
  435. sizeof(CmdStartOTA),
  436. 3,
  437. cmd_start_ota__field_descriptors,
  438. cmd_start_ota__field_indices_by_name,
  439. 1, cmd_start_ota__number_ranges,
  440. (ProtobufCMessageInit) cmd_start_ota__init,
  441. NULL, NULL, NULL /* reserved[123] */
  442. };
  443. #define resp_start_ota__field_descriptors NULL
  444. #define resp_start_ota__field_indices_by_name NULL
  445. #define resp_start_ota__number_ranges NULL
  446. const ProtobufCMessageDescriptor resp_start_ota__descriptor = {
  447. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  448. "RespStartOTA",
  449. "RespStartOTA",
  450. "RespStartOTA",
  451. "",
  452. sizeof(RespStartOTA),
  453. 0,
  454. resp_start_ota__field_descriptors,
  455. resp_start_ota__field_indices_by_name,
  456. 0, resp_start_ota__number_ranges,
  457. (ProtobufCMessageInit) resp_start_ota__init,
  458. NULL, NULL, NULL /* reserved[123] */
  459. };
  460. #define cmd_finish_ota__field_descriptors NULL
  461. #define cmd_finish_ota__field_indices_by_name NULL
  462. #define cmd_finish_ota__number_ranges NULL
  463. const ProtobufCMessageDescriptor cmd_finish_ota__descriptor = {
  464. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  465. "CmdFinishOTA",
  466. "CmdFinishOTA",
  467. "CmdFinishOTA",
  468. "",
  469. sizeof(CmdFinishOTA),
  470. 0,
  471. cmd_finish_ota__field_descriptors,
  472. cmd_finish_ota__field_indices_by_name,
  473. 0, cmd_finish_ota__number_ranges,
  474. (ProtobufCMessageInit) cmd_finish_ota__init,
  475. NULL, NULL, NULL /* reserved[123] */
  476. };
  477. #define resp_finish_ota__field_descriptors NULL
  478. #define resp_finish_ota__field_indices_by_name NULL
  479. #define resp_finish_ota__number_ranges NULL
  480. const ProtobufCMessageDescriptor resp_finish_ota__descriptor = {
  481. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  482. "RespFinishOTA",
  483. "RespFinishOTA",
  484. "RespFinishOTA",
  485. "",
  486. sizeof(RespFinishOTA),
  487. 0,
  488. resp_finish_ota__field_descriptors,
  489. resp_finish_ota__field_indices_by_name,
  490. 0, resp_finish_ota__number_ranges,
  491. (ProtobufCMessageInit) resp_finish_ota__init,
  492. NULL, NULL, NULL /* reserved[123] */
  493. };
  494. static const ProtobufCFieldDescriptor send_file_payload__field_descriptors[8] = {
  495. {
  496. "msg",
  497. 1,
  498. PROTOBUF_C_LABEL_NONE,
  499. PROTOBUF_C_TYPE_ENUM,
  500. 0, /* quantifier_offset */
  501. offsetof(SendFilePayload, msg),
  502. &send_file_msg_type__descriptor,
  503. NULL,
  504. 0, /* flags */
  505. 0, NULL, NULL /* reserved1,reserved2, etc */
  506. },
  507. {
  508. "status",
  509. 2,
  510. PROTOBUF_C_LABEL_NONE,
  511. PROTOBUF_C_TYPE_ENUM,
  512. 0, /* quantifier_offset */
  513. offsetof(SendFilePayload, status),
  514. &status__descriptor,
  515. NULL,
  516. 0, /* flags */
  517. 0, NULL, NULL /* reserved1,reserved2, etc */
  518. },
  519. {
  520. "cmd_send_file",
  521. 10,
  522. PROTOBUF_C_LABEL_NONE,
  523. PROTOBUF_C_TYPE_MESSAGE,
  524. offsetof(SendFilePayload, payload_case),
  525. offsetof(SendFilePayload, cmd_send_file),
  526. &cmd_send_file__descriptor,
  527. NULL,
  528. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  529. 0, NULL, NULL /* reserved1,reserved2, etc */
  530. },
  531. {
  532. "resp_send_file",
  533. 11,
  534. PROTOBUF_C_LABEL_NONE,
  535. PROTOBUF_C_TYPE_MESSAGE,
  536. offsetof(SendFilePayload, payload_case),
  537. offsetof(SendFilePayload, resp_send_file),
  538. &resp_send_file__descriptor,
  539. NULL,
  540. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  541. 0, NULL, NULL /* reserved1,reserved2, etc */
  542. },
  543. {
  544. "cmd_start_ota",
  545. 12,
  546. PROTOBUF_C_LABEL_NONE,
  547. PROTOBUF_C_TYPE_MESSAGE,
  548. offsetof(SendFilePayload, payload_case),
  549. offsetof(SendFilePayload, cmd_start_ota),
  550. &cmd_start_ota__descriptor,
  551. NULL,
  552. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  553. 0, NULL, NULL /* reserved1,reserved2, etc */
  554. },
  555. {
  556. "resp_start_ota",
  557. 13,
  558. PROTOBUF_C_LABEL_NONE,
  559. PROTOBUF_C_TYPE_MESSAGE,
  560. offsetof(SendFilePayload, payload_case),
  561. offsetof(SendFilePayload, resp_start_ota),
  562. &resp_start_ota__descriptor,
  563. NULL,
  564. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  565. 0, NULL, NULL /* reserved1,reserved2, etc */
  566. },
  567. {
  568. "cmd_finish_ota",
  569. 14,
  570. PROTOBUF_C_LABEL_NONE,
  571. PROTOBUF_C_TYPE_MESSAGE,
  572. offsetof(SendFilePayload, payload_case),
  573. offsetof(SendFilePayload, cmd_finish_ota),
  574. &cmd_finish_ota__descriptor,
  575. NULL,
  576. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  577. 0, NULL, NULL /* reserved1,reserved2, etc */
  578. },
  579. {
  580. "resp_finish_ota",
  581. 15,
  582. PROTOBUF_C_LABEL_NONE,
  583. PROTOBUF_C_TYPE_MESSAGE,
  584. offsetof(SendFilePayload, payload_case),
  585. offsetof(SendFilePayload, resp_finish_ota),
  586. &resp_finish_ota__descriptor,
  587. NULL,
  588. 0 | PROTOBUF_C_FIELD_FLAG_ONEOF, /* flags */
  589. 0, NULL, NULL /* reserved1,reserved2, etc */
  590. },
  591. };
  592. static const unsigned send_file_payload__field_indices_by_name[] = {
  593. 6, /* field[6] = cmd_finish_ota */
  594. 2, /* field[2] = cmd_send_file */
  595. 4, /* field[4] = cmd_start_ota */
  596. 0, /* field[0] = msg */
  597. 7, /* field[7] = resp_finish_ota */
  598. 3, /* field[3] = resp_send_file */
  599. 5, /* field[5] = resp_start_ota */
  600. 1, /* field[1] = status */
  601. };
  602. static const ProtobufCIntRange send_file_payload__number_ranges[2 + 1] = {
  603. { 1, 0 },
  604. { 10, 2 },
  605. { 0, 8 }
  606. };
  607. const ProtobufCMessageDescriptor send_file_payload__descriptor = {
  608. PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  609. "SendFilePayload",
  610. "SendFilePayload",
  611. "SendFilePayload",
  612. "",
  613. sizeof(SendFilePayload),
  614. 8,
  615. send_file_payload__field_descriptors,
  616. send_file_payload__field_indices_by_name,
  617. 2, send_file_payload__number_ranges,
  618. (ProtobufCMessageInit) send_file_payload__init,
  619. NULL, NULL, NULL /* reserved[123] */
  620. };
  621. static const ProtobufCEnumValue send_file_msg_type__enum_values_by_number[7] = {
  622. { "TypeReserved", "SEND_FILE_MSG_TYPE__TypeReserved", 0 },
  623. { "TypeCmdSendFile", "SEND_FILE_MSG_TYPE__TypeCmdSendFile", 1 },
  624. { "TypeRespSendFile", "SEND_FILE_MSG_TYPE__TypeRespSendFile", 2 },
  625. { "TypeCmdStartOTA", "SEND_FILE_MSG_TYPE__TypeCmdStartOTA", 3 },
  626. { "TypeRespStartOTA", "SEND_FILE_MSG_TYPE__TypeRespStartOTA", 4 },
  627. { "TypeCmdFinishOTA", "SEND_FILE_MSG_TYPE__TypeCmdFinishOTA", 5 },
  628. { "TypeRespFinishOTA", "SEND_FILE_MSG_TYPE__TypeRespFinishOTA", 6 },
  629. };
  630. static const ProtobufCIntRange send_file_msg_type__value_ranges[] = {
  631. {0, 0}, {0, 7}
  632. };
  633. static const ProtobufCEnumValueIndex send_file_msg_type__enum_values_by_name[7] = {
  634. { "TypeCmdFinishOTA", 5 },
  635. { "TypeCmdSendFile", 1 },
  636. { "TypeCmdStartOTA", 3 },
  637. { "TypeReserved", 0 },
  638. { "TypeRespFinishOTA", 6 },
  639. { "TypeRespSendFile", 2 },
  640. { "TypeRespStartOTA", 4 },
  641. };
  642. const ProtobufCEnumDescriptor send_file_msg_type__descriptor = {
  643. PROTOBUF_C__ENUM_DESCRIPTOR_MAGIC,
  644. "SendFileMsgType",
  645. "SendFileMsgType",
  646. "SendFileMsgType",
  647. "",
  648. 7,
  649. send_file_msg_type__enum_values_by_number,
  650. 7,
  651. send_file_msg_type__enum_values_by_name,
  652. 1,
  653. send_file_msg_type__value_ranges,
  654. NULL, NULL, NULL, NULL /* reserved[1234] */
  655. };