1
1
#pragma once
2
2
3
-
4
3
/*
5
4
def d(var_raw)
6
5
var = var_raw.split("_")[0]
7
- out = "#define #{var}_P(...) #{var}(__VA_ARGS__)\n"
6
+ out = "#define #{var}_P(...) :: #{var}(__VA_ARGS__)\n"
8
7
IO.popen('pbcopy', 'w') { |f| f << out }
9
8
out
10
9
end
@@ -16,7 +15,7 @@ out.each { |l| puts d(l) }
16
15
*/
17
16
18
17
#include <avr/io.h>
19
- #include < string>
18
+ #include <string.h >
20
19
21
20
#define PROGMEM
22
21
@@ -50,46 +49,46 @@ out.each { |l| puts d(l) }
50
49
#define pgm_read_ptr (x ) (x)
51
50
#define pgm_get_far_address (x ) (x)
52
51
53
- #define memchr_P (...) memchr(__VA_ARGS__)
54
- #define memcmp_P (...) memcmp(__VA_ARGS__)
55
- #define memccpy_P (...) memccpy(__VA_ARGS__)
56
- #define memcpy_P (...) memcpy(__VA_ARGS__)
57
- #define memmem_P (...) memmem(__VA_ARGS__)
58
- #define memrchr_P (...) memrchr(__VA_ARGS__)
59
- #define strcat_P (...) strcat(__VA_ARGS__)
60
- #define strchr_P (...) strchr(__VA_ARGS__)
61
- #define strchrnul_P (...) strchrnul(__VA_ARGS__)
62
- #define strcmp_P (...) strcmp(__VA_ARGS__)
63
- #define strcpy_P (...) strcpy(__VA_ARGS__)
64
- #define strcasecmp_P (...) strcasecmp(__VA_ARGS__)
65
- #define strcasestr_P (...) strcasestr(__VA_ARGS__)
66
- #define strcspn_P (...) strcspn(__VA_ARGS__)
67
- #define strlcat_P (...) strlcat(__VA_ARGS__)
68
- #define strlcpy_P (...) strlcpy(__VA_ARGS__)
69
- #define strnlen_P (...) strnlen(__VA_ARGS__)
70
- #define strncmp_P (...) strncmp(__VA_ARGS__)
71
- #define strncasecmp_P (...) strncasecmp(__VA_ARGS__)
72
- #define strncat_P (...) strncat(__VA_ARGS__)
73
- #define strncpy_P (...) strncpy(__VA_ARGS__)
74
- #define strpbrk_P (...) strpbrk(__VA_ARGS__)
75
- #define strrchr_P (...) strrchr(__VA_ARGS__)
76
- #define strsep_P (...) strsep(__VA_ARGS__)
77
- #define strspn_P (...) strspn(__VA_ARGS__)
78
- #define strstr_P (...) strstr(__VA_ARGS__)
79
- #define strtok_P (...) strtok(__VA_ARGS__)
80
- #define strtok_P (...) strtok(__VA_ARGS__)
81
- #define strlen_P (...) strlen(__VA_ARGS__)
82
- #define strnlen_P (...) strnlen(__VA_ARGS__)
83
- #define memcpy_P (...) memcpy(__VA_ARGS__)
84
- #define strcpy_P (...) strcpy(__VA_ARGS__)
85
- #define strncpy_P (...) strncpy(__VA_ARGS__)
86
- #define strcat_P (...) strcat(__VA_ARGS__)
87
- #define strlcat_P (...) strlcat(__VA_ARGS__)
88
- #define strncat_P (...) strncat(__VA_ARGS__)
89
- #define strcmp_P (...) strcmp(__VA_ARGS__)
90
- #define strncmp_P (...) strncmp(__VA_ARGS__)
91
- #define strcasecmp_P (...) strcasecmp(__VA_ARGS__)
92
- #define strncasecmp_P (...) strncasecmp(__VA_ARGS__)
93
- #define strstr_P (...) strstr(__VA_ARGS__)
94
- #define strlcpy_P (...) strlcpy(__VA_ARGS__)
95
- #define memcmp_P (...) memcmp(__VA_ARGS__)
52
+ #define memchr_P (...) :: memchr(__VA_ARGS__)
53
+ #define memcmp_P (...) :: memcmp(__VA_ARGS__)
54
+ #define memccpy_P (...) :: memccpy(__VA_ARGS__)
55
+ #define memcpy_P (...) :: memcpy(__VA_ARGS__)
56
+ #define memmem_P (...) :: memmem(__VA_ARGS__)
57
+ #define memrchr_P (...) :: memrchr(__VA_ARGS__)
58
+ #define strcat_P (...) :: strcat(__VA_ARGS__)
59
+ #define strchr_P (...) :: strchr(__VA_ARGS__)
60
+ #define strchrnul_P (...) :: strchrnul(__VA_ARGS__)
61
+ #define strcmp_P (...) :: strcmp(__VA_ARGS__)
62
+ #define strcpy_P (...) :: strcpy(__VA_ARGS__)
63
+ #define strcasecmp_P (...) :: strcasecmp(__VA_ARGS__)
64
+ #define strcasestr_P (...) :: strcasestr(__VA_ARGS__)
65
+ #define strcspn_P (...) :: strcspn(__VA_ARGS__)
66
+ #define strlcat_P (...) :: strlcat(__VA_ARGS__)
67
+ #define strlcpy_P (...) :: strlcpy(__VA_ARGS__)
68
+ #define strnlen_P (...) :: strnlen(__VA_ARGS__)
69
+ #define strncmp_P (...) :: strncmp(__VA_ARGS__)
70
+ #define strncasecmp_P (...) :: strncasecmp(__VA_ARGS__)
71
+ #define strncat_P (...) :: strncat(__VA_ARGS__)
72
+ #define strncpy_P (...) :: strncpy(__VA_ARGS__)
73
+ #define strpbrk_P (...) :: strpbrk(__VA_ARGS__)
74
+ #define strrchr_P (...) :: strrchr(__VA_ARGS__)
75
+ #define strsep_P (...) :: strsep(__VA_ARGS__)
76
+ #define strspn_P (...) :: strspn(__VA_ARGS__)
77
+ #define strstr_P (...) :: strstr(__VA_ARGS__)
78
+ #define strtok_P (...) :: strtok(__VA_ARGS__)
79
+ #define strtok_P (...) :: strtok(__VA_ARGS__)
80
+ #define strlen_P (...) :: strlen(__VA_ARGS__)
81
+ #define strnlen_P (...) :: strnlen(__VA_ARGS__)
82
+ #define memcpy_P (...) :: memcpy(__VA_ARGS__)
83
+ #define strcpy_P (...) :: strcpy(__VA_ARGS__)
84
+ #define strncpy_P (...) :: strncpy(__VA_ARGS__)
85
+ #define strcat_P (...) :: strcat(__VA_ARGS__)
86
+ #define strlcat_P (...) :: strlcat(__VA_ARGS__)
87
+ #define strncat_P (...) :: strncat(__VA_ARGS__)
88
+ #define strcmp_P (...) :: strcmp(__VA_ARGS__)
89
+ #define strncmp_P (...) :: strncmp(__VA_ARGS__)
90
+ #define strcasecmp_P (...) :: strcasecmp(__VA_ARGS__)
91
+ #define strncasecmp_P (...) :: strncasecmp(__VA_ARGS__)
92
+ #define strstr_P (...) :: strstr(__VA_ARGS__)
93
+ #define strlcpy_P (...) :: strlcpy(__VA_ARGS__)
94
+ #define memcmp_P (...) :: memcmp(__VA_ARGS__)
0 commit comments