Difference between revisions of "Component: Base 64 (Comms: Networking)"
(XML import) |
(XML import BR) |
(One intermediate revision by the same user not shown) | |
(No difference)
|
Latest revision as of 15:45, 16 February 2017
Author | Matrix TSL |
Version | 1.0 (Release) |
Category | Comms: Networking |
Contents
Base 64 component
Component to allow base 64 encoding and decoding. Sometimes when communicating raw binary data it is useful to perform base 64 encoding to ensure that none of your data bytes trigger any escape codes or other special case conditions. Base64 converts your binary data into readable data using standard ASCII characters so you can be fairly certain that the data you send is the same as the data that is received.
Examples
Here is a basic example that shows how to convert data into base64 encoded data and visa versa.
Base64 Tests
Downloadable macro reference
Encode
Encodes an array of bytes into a base64 encoded string
Parameters
- BYTE BinaryData
- Raw binary data array you wish to encode
- UINT ByteCount
- Number of bytes of data to encode
Return value
Decode
Decodes a base64 encoded string into an array of bytes.
Populates the BinaryData parameter array with the decoded data.
Returns the number of decoded data bytes.
Parameters
- BYTE BinaryData
- Variable to hold the decoded binary data
- <- STRING Base64Data
- Data string you wish to decode
- This parameter may be returned back to the caller
Return value
Simulation macro reference
This component does not contain any simulation macros
Property reference
This component does not contain any properties