From 0258247b4b8ad69b8d51568b8af991ab24573486 Mon Sep 17 00:00:00 2001 From: ZodiusInfuser Date: Fri, 17 Jun 2022 11:25:41 +0100 Subject: [PATCH] PCF85063A: Change location of some constants. --- micropython/modules/pcf85063a/pcf85063a.c | 29 +++++++++++------------ 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/micropython/modules/pcf85063a/pcf85063a.c b/micropython/modules/pcf85063a/pcf85063a.c index 971240c1..ebd5e9fa 100644 --- a/micropython/modules/pcf85063a/pcf85063a.c +++ b/micropython/modules/pcf85063a/pcf85063a.c @@ -42,6 +42,20 @@ STATIC const mp_rom_map_elem_t PCF85063A_locals_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_unset_timer), MP_ROM_PTR(&PCF85063A_unset_timer_obj) }, { MP_ROM_QSTR(MP_QSTR_set_clock_output), MP_ROM_PTR(&PCF85063A_set_clock_output_obj) }, + + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_32768HZ), MP_ROM_INT(0) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_16384HZ), MP_ROM_INT(1) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_8192HZ), MP_ROM_INT(2) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_4096HZ), MP_ROM_INT(3) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_2048HZ), MP_ROM_INT(4) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_1024HZ), MP_ROM_INT(5) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_1HZ), MP_ROM_INT(6) }, + { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_OFF), MP_ROM_INT(7) }, + + { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_4096HZ), MP_ROM_INT(0b00) }, + { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_64HZ), MP_ROM_INT(0b01) }, + { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_1HZ), MP_ROM_INT(0b10) }, + { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_1_OVER_60HZ), MP_ROM_INT(0b11) }, }; STATIC MP_DEFINE_CONST_DICT(PCF85063A_locals_dict, PCF85063A_locals_dict_table); @@ -61,21 +75,6 @@ const mp_obj_type_t pcf85063a_PCF85063A_type = { STATIC const mp_map_elem_t pcf85063a_globals_table[] = { { MP_OBJ_NEW_QSTR(MP_QSTR___name__), MP_OBJ_NEW_QSTR(MP_QSTR_pcf85063a) }, { MP_OBJ_NEW_QSTR(MP_QSTR_PCF85063A), (mp_obj_t)&pcf85063a_PCF85063A_type }, - - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_32768HZ), MP_ROM_INT(0) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_16384HZ), MP_ROM_INT(1) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_8192HZ), MP_ROM_INT(2) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_4096HZ), MP_ROM_INT(3) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_2048HZ), MP_ROM_INT(4) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_1024HZ), MP_ROM_INT(5) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_1HZ), MP_ROM_INT(6) }, - { MP_ROM_QSTR(MP_QSTR_CLOCK_OUT_OFF), MP_ROM_INT(7) }, - - { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_4096HZ), MP_ROM_INT(0b00) }, - { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_64HZ), MP_ROM_INT(0b01) }, - { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_1HZ), MP_ROM_INT(0b10) }, - { MP_ROM_QSTR(MP_QSTR_TIMER_TICK_1_OVER_60HZ), MP_ROM_INT(0b11) }, - { MP_ROM_QSTR(MP_QSTR_MONDAY), MP_ROM_INT(0) }, { MP_ROM_QSTR(MP_QSTR_TUESDAY), MP_ROM_INT(1) }, { MP_ROM_QSTR(MP_QSTR_WEDNESDAY), MP_ROM_INT(2) },