From 24a4477a7334e67fcf8dc934800e97a19c3dc822 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Tue, 22 May 2012 16:12:37 +0000 Subject: improved CPU_PRESCALE Macro git-svn-id: https://svn.spreadspace.org/mur.sat@476 7de4ea59-55d0-425e-a1af-a3118ea81d4c --- software/hhd70dongle/hhd70dongle.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'software/hhd70dongle') diff --git a/software/hhd70dongle/hhd70dongle.c b/software/hhd70dongle/hhd70dongle.c index 0f216d2..fd92527 100644 --- a/software/hhd70dongle/hhd70dongle.c +++ b/software/hhd70dongle/hhd70dongle.c @@ -39,8 +39,7 @@ #include "c1101lib.h" #include "usb_rawhid.h" - -#define CPU_PRESCALE(n) (CLKPR = 0x80, CLKPR = (n)) +#define CPU_PRESCALE(n) do { CLKPR = 0x80; CLKPR = (n); } while(0) uint8_t read_buffer[64]; // buffer for reading usb signals uint8_t write_buffer[64]; // buffer for writing usb signals -- cgit v1.2.3