MCPcopy Create free account
hub / github.com/EIPStackGroup/OpENer / EncodeItemCount

Function EncodeItemCount

source/src/enet_encap/cpf.c:364–371  ·  view source on GitHub ↗

* @brief Adds the item count to the message frame * * @param common_packet_format_data_item The Common Packet Format data structure from which the message is constructed * @param outgoing_message The outgoing message object * * @return The new size of the message frame after encoding */

Source from the content-addressed store, hash-verified

362 * @return The new size of the message frame after encoding
363 */
364int EncodeItemCount(
365 const CipCommonPacketFormatData *const common_packet_format_data_item,
366 ENIPMessage *const outgoing_message) {
367 outgoing_message->used_message_length += AddIntToMessage(
368 common_packet_format_data_item->item_count,
369 &outgoing_message->current_message_position); /* item count */
370 return outgoing_message->used_message_length;
371}
372
373/**
374 * Adds the data item type to the message frame

Callers 1

AssembleLinearMessageFunction · 0.85

Calls 1

AddIntToMessageFunction · 0.85

Tested by

no test coverage detected