VitroIO SDK
Software development kit for Vitro Shard.
|
This class implements CAN bus transport layer for IoT Blockss. More...
#include <can_layer.h>
Public Member Functions | |
Can_layer (Canbus *bus, uint32_t nodeId) | |
Construct a new Can_layer object. More... | |
int | send (uint32_t parameterId, const IoVec *iov, int iovcnt) |
Function sends given data. More... | |
uint32_t | getTimestamp () |
Function sends timestamp request and returns timestamp value. More... | |
int | computeCRC (const IoVec *iov, int iovcnt, uint32_t *crc_value) |
Function computes CRC of data send via CAN bus to Crystal. More... | |
Public Member Functions inherited from vitroio::sdk::Transport_layer | |
virtual int | send (uint32_t parameterId, const IoVec *iov, int iovcnt) |
Function sends given data. More... | |
virtual uint32_t | getTimestamp () |
Function sends timestamp request and returns timestamp value. More... | |
void | updateNodeId (uint32_t nodeId) |
Update node ID. More... | |
uint32_t | nodeId () |
Returns node ID. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from vitroio::sdk::Transport_layer | |
Transport_layer (uint32_t nodeId) | |
Protected Attributes inherited from vitroio::sdk::Transport_layer | |
uint32_t | nodeId_ |
This class implements CAN bus transport layer for IoT Blockss.
vitroio::sdk::Can_layer::Can_layer | ( | Canbus * | bus, |
uint32_t | nodeId | ||
) |
int vitroio::sdk::Can_layer::computeCRC | ( | const IoVec * | iov, |
int | iovcnt, | ||
uint32_t * | crc_value | ||
) |
Function computes CRC of data send via CAN bus to Crystal.
iov | Chunks of data |
iovcnt | Count of chunks |
crc_value | Pointer to save CRC |
|
virtual |
Function sends timestamp request and returns timestamp value.
Reimplemented from vitroio::sdk::Transport_layer.
|
virtual |
Function sends given data.
parameterId | Id of parameter sent |
iov | Pointer to first IoVec with data to be sent IoVec |
iovcnt | Count of IoVects to read |
Reimplemented from vitroio::sdk::Transport_layer.