Port of TI's CC3100 Websock camera demo. Using FreeRTOS, mbedTLS, also parts of Arducam for cams ov5642 and 0v2640. Can also use MT9D111. Work in progress. Be warned some parts maybe a bit flacky. This is for Seeed Arch max only, for an M3, see the demo for CM3 using the 0v5642 aducam mini.
String routines helper module
This module implements some string and buffer-related helper routines. More...
Functions | |
int | HttpString_strcmp (struct HttpBlob first, struct HttpBlob second) |
Perform string comparison between two strings. | |
UINT8 * | HttpString_nextToken (char *pToken, UINT16 uTokenLength, struct HttpBlob blob) |
return pointer to the next token | |
UINT32 | HttpString_atou (struct HttpBlob string) |
Parse a string representation of an unsigned decimal number Stops at any non-digit character. | |
void | HttpString_utoa (UINT32 uNum, struct HttpBlob *pString) |
Format an unsigned decimal number as a string. | |
void | HttpString_htoa (UINT32 uNum, struct HttpBlob *pString, UINT8 bPadZero) |
Format an unsigned decimal number as an hexdecimal string. |
Detailed Description
This module implements some string and buffer-related helper routines.
Function Documentation
UINT32 HttpString_atou | ( | struct HttpBlob | string ) |
Parse a string representation of an unsigned decimal number Stops at any non-digit character.
- Parameters:
-
string The string to parse
- Returns:
- The parsed value
Definition at line 128 of file HttpString.cpp.
void HttpString_htoa | ( | UINT32 | uNum, |
struct HttpBlob * | pString, | ||
UINT8 | bPadZero | ||
) |
Format an unsigned decimal number as an hexdecimal string.
- Parameters:
-
uNum The number to format bPadZero nonzero to pad with zeros up to the string length, or zero to use minimal length required to represent the number [in,out] pString A string buffer which returns the formatted string. On entry, uLength is the maximum length of the buffer, upon return uLength is the actual length of the formatted string
Definition at line 165 of file HttpString.cpp.
UINT8 * HttpString_nextToken | ( | char * | pToken, |
UINT16 | uTokenLength, | ||
struct HttpBlob | blob | ||
) |
return pointer to the next token
- Parameters:
-
token Pointer to data of the first token blob Pointer to data of the search string/blob
- Returns:
- pointer if found, otherwize NULL
Definition at line 60 of file HttpString.cpp.
int HttpString_strcmp | ( | struct HttpBlob | first, |
struct HttpBlob | second | ||
) |
Perform string comparison between two strings.
- Parameters:
-
first Pointer to data about the first blob or string second Pointer to data about the second blob or string
- Returns:
- zero if equal, positive if first is later in order, negative if second is later in order
Definition at line 28 of file HttpString.cpp.
void HttpString_utoa | ( | UINT32 | uNum, |
struct HttpBlob * | pString | ||
) |
Format an unsigned decimal number as a string.
- Parameters:
-
uNum The number to format [in,out] pString A string buffer which returns the formatted string. On entry, uLength is the maximum length of the buffer, upon return uLength is the actual length of the formatted string
Definition at line 133 of file HttpString.cpp.
Generated on Tue Jul 12 2022 22:22:39 by 1.7.2