Choco OS  V.0.16.9.0
Join to the chocolate world
oc_cfg.h
Go to the documentation of this file.
1 
44 #ifndef SYSTEM_CORE_OC_CFG_H_
45 #define SYSTEM_CORE_OC_CFG_H_
46 
47 #include <stdbool.h>
48 #include <oc_frequency.h>
49 #include <oc_time.h>
50 
54 #define ON 2
55 
58 #define OFF 1
59 
63 #define LEVEL(Lvl) (Lvl)
64 
68 #define PERCENT(Percent) ((float)Percent/(float)100)
69 
73 #define B(Bytes) (Bytes)
74 
78 #define kB(kBytes) (kBytes * 1024)
79 
83 #define MB(MBytes) (MBytes * kB(1024))
84 
88 #define GB(GBytes) (GBytes * MB(1024ULL))
89 
93 #define TB(TBytes) (TBytes * GB(1024))
94 
98 #define Hz(Freq) (oC_Hz(Freq))
99 
103 #define kHz(Freq) (oC_kHz(Freq))
104 
108 #define MHz(Freq) (oC_MHz(Freq))
109 
113 #define GHz(Freq) (oC_GHz(Freq))
114 
118 #define ns(time) (oC_ns(time))
119 
123 #define us(time) (oC_us(time))
124 
128 #define ms(time) (oC_ms(time))
129 
133 #define s(time) (oC_s(time))
134 
138 #define min(time) (oC_min(time))
139 
143 #define hour(time) (oC_hour(time))
144 
148 #define day(time) (oC_day(time))
149 
150 
155 #define UNIVERSAL_DONT_ADD(...)
156 
157 #endif /* SYSTEM_CORE_OC_CFG_H_ */
The file with frequency definitions.
The library with time definitions.