2022-07-15 12:44:08 +02:00
|
|
|
/*
|
|
|
|
* helper.h
|
|
|
|
*
|
|
|
|
* Created on: Jul 14, 2022
|
|
|
|
* Author: tom
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef INC_HELPER_H_
|
|
|
|
#define INC_HELPER_H_
|
|
|
|
|
2022-07-16 00:30:23 +02:00
|
|
|
struct _tm_ { /* compare to ctime(3) */
|
|
|
|
uint16_t year;
|
|
|
|
uint16_t mon;
|
|
|
|
uint16_t day;
|
|
|
|
uint16_t hour;
|
|
|
|
uint16_t min;
|
|
|
|
uint16_t sec;
|
|
|
|
};
|
|
|
|
|
2022-07-15 12:44:08 +02:00
|
|
|
char *ltrim(char *s);
|
|
|
|
char *rtrim(char *s);
|
|
|
|
char *trim(char *s);
|
|
|
|
|
2022-07-16 00:30:23 +02:00
|
|
|
int strtotime (char *s, struct _tm_ *tp);
|
|
|
|
// uint8_t dayofweek(uint8_t century, uint8_t y, uint8_t m, uint8_t d);
|
|
|
|
|
|
|
|
|
2022-07-15 12:44:08 +02:00
|
|
|
#endif /* INC_HELPER_H_ */
|