X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;f=tos%2Fplatforms%2Firis%2Fchips%2Frf230%2FHplRF230.h;h=4418ffea859a57e4039e05996ab8e213e711f31c;hb=e3cfa7776f6d8e739d5fb613668b470111d75d55;hp=c144173b95278561af987bb77e1782cff3687537;hpb=fcb117d8c101ca455d5728fd9772ca69a6bfe0ae;p=tinyos-2.x.git diff --git a/tos/platforms/iris/chips/rf230/HplRF230.h b/tos/platforms/iris/chips/rf230/HplRF230.h index c144173b..4418ffea 100644 --- a/tos/platforms/iris/chips/rf230/HplRF230.h +++ b/tos/platforms/iris/chips/rf230/HplRF230.h @@ -52,10 +52,16 @@ enum */ typedef TOne TRF230; + +/** + * The number of alarm ticks per one second (921600) + */ +#define RF230_ALARM_SEC ((7372800UL / MHZ / 32) * (1 << MICA_DIVIDE_ONE_FOR_32KHZ_LOG2)) + /** * The number of alarm ticks per one microsecond (0.9216) */ -#define RF230_ALARM_MICROSEC ((7.3728 / MHZ / 32.0) * (1 << MICA_DIVIDE_ONE_FOR_32KHZ_LOG2)) +#define RF230_ALARM_MICROSEC (RF230_ALARM_SEC / 1000000.0) /* This is the default value of the TX_PWR field of the PHY_TX_PWR register. */ #ifndef RF230_DEF_RFPOWER