Make sure AO_TICK_TYPE is used "everywhere", instead of uint16_t or other.
Signed-off-by: Keith Packard <keithp@keithp.com>
ao_wakeup((void *) &ao_tick_count);
}
ao_wakeup((void *) &ao_tick_count);
}
ao_time(void)
{
uint16_t r;
ao_time(void)
{
uint16_t r;
/* Set all LEDs in 'mask' to the specified state */
void
/* Set all LEDs in 'mask' to the specified state */
void
-ao_led_set_mask(uint8_t colors, uint8_t mask);
+ao_led_set_mask(AO_LED_TYPE colors, AO_LED_TYPE mask);
/* Toggle the specified LEDs */
void
/* Toggle the specified LEDs */
void
/* Turn on the specified LEDs for the indicated interval */
void
/* Turn on the specified LEDs for the indicated interval */
void
-ao_led_for(AO_LED_TYPE colors, uint16_t ticks);
+ao_led_for(AO_LED_TYPE colors, AO_TICK_TYPE ticks);
/* Initialize the LEDs */
void
/* Initialize the LEDs */
void
#define AO_LED_TYPE AO_PORT_TYPE
#define AO_LED_TYPE AO_PORT_TYPE
-#ifndef AO_TICK_TYPE
-#define AO_TICK_TYPE uint16_t
-#define AO_TICK_SIGNED int16_t
-#endif
-
/* Various definitions to make GCC look more like SDCC */
#define ao_arch_naked_declare __attribute__((naked))
/* Various definitions to make GCC look more like SDCC */
#define ao_arch_naked_declare __attribute__((naked))
-ao_led_for(AO_PORT_TYPE colors, uint16_t ticks)
+ao_led_for(AO_PORT_TYPE colors, AO_TICK_TYPE ticks)
{
ao_led_on(colors);
ao_delay(ticks);
{
ao_led_on(colors);
ao_delay(ticks);
volatile AO_TICK_TYPE ao_tick_count;
volatile AO_TICK_TYPE ao_tick_count;
ao_time(void)
{
return ao_tick_count;
ao_time(void)
{
return ao_tick_count;
#define AO_STACK_SIZE 512
#endif
#define AO_STACK_SIZE 512
#endif
-#ifndef AO_TICK_TYPE
-#define AO_TICK_TYPE uint16_t
-#define AO_TICK_SIGNED int16_t
-#endif
-
#define AO_PORT_TYPE uint16_t
/* Various definitions to make GCC look more like SDCC */
#define AO_PORT_TYPE uint16_t
/* Various definitions to make GCC look more like SDCC */
-ao_led_for(AO_LED_TYPE colors, AO_LED_TYPE ticks)
+ao_led_for(AO_LED_TYPE colors, AO_TICK_TYPE ticks)
{
ao_led_on(colors);
ao_delay(ticks);
{
ao_led_on(colors);
ao_delay(ticks);
#define AO_LED_TYPE uint16_t
#define AO_LED_TYPE uint16_t
-#ifndef AO_TICK_TYPE
-#define AO_TICK_TYPE uint16_t
-#define AO_TICK_SIGNED int16_t
-#endif
-
#define AO_PORT_TYPE uint16_t
/* Various definitions to make GCC look more like SDCC */
#define AO_PORT_TYPE uint16_t
/* Various definitions to make GCC look more like SDCC */