Permalink
Browse files

redefine bytes for mac and update makefile for attiny85

  • Loading branch information...
1 parent 284297f commit 12638c76e64dab2fe33259cf117469c85fc224b5 Alex committed May 7, 2011
Showing with 12 additions and 12 deletions.
  1. +2 −2 Makefile
  2. +3 −3 badge.c
  3. +7 −7 trippyrgb.h
View
@@ -1,6 +1,6 @@
-MCU = attiny25
#MCU = attiny25
-#MCU = attiny85
+#MCU = attiny25
+MCU = attiny85
F_CPU = 8000000 # 8 MHz
View
@@ -33,7 +33,7 @@
#define B8(d) ((unsigned char)B8__(HEX__(d)))
#include "badge.h"
-//#include "trippyrgb.h"
+#include "trippyrgb.h"
uint8_t last_eeprom_read = 1;
uint8_t enable_rgb_led = 1;
@@ -103,11 +103,11 @@ void space(int time) {
void enableIROut(void) {
#ifdef TRIPPY_RGB_WAVE
- TCCR0A = 0b01000010; // COM0A1:0=01 to toggle OC0A on Compare Match
+ TCCR0A = B8(01000010); // COM0A1:0=01 to toggle OC0A on Compare Match
// COM0B1:0=00 to disconnect OC0B
// bits 3:2 are unused
// WGM01:00=10 for CTC Mode (WGM02=0 in TCCR0B)
- TCCR0B = 0b00000001; // FOC0A=0 (no force compare)
+ TCCR0B = B8(00000001); // FOC0A=0 (no force compare)
// F0C0B=0 (no force compare)
// bits 5:4 are unused
// WGM2=0 for CTC Mode (WGM01:00=10 in TCCR0A)
View
@@ -2,13 +2,13 @@
#define TRIPPY_RGB_WAVE 1
// overrides for Cornfield Trippy RGB Wave board
-#define bogusMask 0b00100000
-#define redMask 0b00000010
-#define grnMask 0b00010000
-#define bluMask 0b00000100
-#define rgbMask 0b00010110
-#define irInMask 0b00001000
-#define irOutMask 0b00000001
+#define bogusMask B8(00100000)
+#define redMask B8(00000010)
+#define grnMask B8(00010000)
+#define bluMask B8(00000100)
+#define rgbMask B8(00010110)
+#define irInMask B8(00001000)
+#define irOutMask B8(00000001)
// 4 = PB3
#define irInPortBPin 4

0 comments on commit 12638c7

Please sign in to comment.