refactor(app): replace Zephyr integer types with C99 integer types

u8_t → uint8_t
u16_t → uint16_t
u32_t → uint32_t
u64_t → uint64_t
s8_t → int8_t
s16_t → int16_t
s32_t → int32_t
s64_t → int64_t

Prerequisite for #223
See: https://github.com/zephyrproject-rtos/zephyr/releases/tag/zephyr-v2.4.0
PR: #467
This commit is contained in:
innovaker
2020-12-02 16:41:57 +00:00
committed by Pete Johanson
parent a4652fa25d
commit bac1f17cf6
45 changed files with 208 additions and 205 deletions

View File

@@ -29,8 +29,8 @@ static int ec11_get_ab_state(struct device *dev) {
static int ec11_sample_fetch(struct device *dev, enum sensor_channel chan) {
struct ec11_data *drv_data = dev->driver_data;
const struct ec11_config *drv_cfg = dev->config_info;
u8_t val;
s8_t delta;
uint8_t val;
int8_t delta;
__ASSERT_NO_MSG(chan == SENSOR_CHAN_ALL || chan == SENSOR_CHAN_ROTATION);

View File

@@ -12,23 +12,23 @@
struct ec11_config {
const char *a_label;
const u8_t a_pin;
const u8_t a_flags;
const uint8_t a_pin;
const uint8_t a_flags;
const char *b_label;
const u8_t b_pin;
const u8_t b_flags;
const uint8_t b_pin;
const uint8_t b_flags;
const u8_t resolution;
const uint8_t resolution;
};
struct ec11_data {
struct device *a;
struct device *b;
u8_t ab_state;
s8_t pulses;
s8_t ticks;
s8_t delta;
uint8_t ab_state;
int8_t pulses;
int8_t ticks;
int8_t delta;
#ifdef CONFIG_EC11_TRIGGER
struct gpio_callback a_gpio_cb;

View File

@@ -36,7 +36,7 @@ static inline void setup_int(struct device *dev, bool enable) {
}
}
static void ec11_a_gpio_callback(struct device *dev, struct gpio_callback *cb, u32_t pins) {
static void ec11_a_gpio_callback(struct device *dev, struct gpio_callback *cb, uint32_t pins) {
struct ec11_data *drv_data = CONTAINER_OF(cb, struct ec11_data, a_gpio_cb);
LOG_DBG("");
@@ -50,7 +50,7 @@ static void ec11_a_gpio_callback(struct device *dev, struct gpio_callback *cb, u
#endif
}
static void ec11_b_gpio_callback(struct device *dev, struct gpio_callback *cb, u32_t pins) {
static void ec11_b_gpio_callback(struct device *dev, struct gpio_callback *cb, uint32_t pins) {
struct ec11_data *drv_data = CONTAINER_OF(cb, struct ec11_data, b_gpio_cb);
LOG_DBG("");