28
28
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29
29
POSSIBILITY OF SUCH DAMAGE. */
31
/* $Id: iotn261.h,v 1.3.2.2 2008/01/06 20:10:47 arcanum Exp $ */
31
/* $Id: iotn261.h,v 1.3.2.6 2009/02/11 18:05:32 arcanum Exp $ */
33
33
/* avr/iotn261.h - definitions for ATtiny261 */
38
38
#include <avr/iotnx61.h>
43
#define FLASHEND 0x7FF
44
#define SPM_PAGESIZE 32
40
#define SPM_PAGESIZE 32
42
#define XRAMEND RAMEND
45
#define FLASHEND 0x7FF
48
49
#define FUSE_MEMORY_SIZE 3
50
51
/* Low Fuse Byte */
51
#define FUSE_CKSEL0 ~_BV(0)
52
#define FUSE_CKSEL1 ~_BV(1)
53
#define FUSE_CKSEL2 ~_BV(2)
54
#define FUSE_CKSEL3 ~_BV(3)
55
#define FUSE_SUT0 ~_BV(4)
56
#define FUSE_SUT1 ~_BV(5)
57
#define FUSE_CKOUT ~_BV(6)
58
#define FUSE_CKDIV8 ~_BV(7)
52
#define FUSE_CKSEL0 (unsigned char)~_BV(0)
53
#define FUSE_CKSEL1 (unsigned char)~_BV(1)
54
#define FUSE_CKSEL2 (unsigned char)~_BV(2)
55
#define FUSE_CKSEL3 (unsigned char)~_BV(3)
56
#define FUSE_SUT0 (unsigned char)~_BV(4)
57
#define FUSE_SUT1 (unsigned char)~_BV(5)
58
#define FUSE_CKOUT (unsigned char)~_BV(6)
59
#define FUSE_CKDIV8 (unsigned char)~_BV(7)
59
60
#define LFUSE_DEFAULT (FUSE_CKSEL0 & FUSE_CKSEL2 & FUSE_CKSEL3 & FUSE_SUT0 & FUSE_CKDIV8)
61
62
/* High Fuse Byte */
62
#define FUSE_BODLEVEL0 ~_BV(0)
63
#define FUSE_BODLEVEL1 ~_BV(1)
64
#define FUSE_BODLEVEL2 ~_BV(2)
65
#define FUSE_EESAVE ~_BV(3)
66
#define FUSE_WDTON ~_BV(4)
67
#define FUSE_SPIEN ~_BV(5)
68
#define FUSE_DWEN ~_BV(6)
69
#define FUSE_RSTDISBL ~_BV(7)
63
#define FUSE_BODLEVEL0 (unsigned char)~_BV(0)
64
#define FUSE_BODLEVEL1 (unsigned char)~_BV(1)
65
#define FUSE_BODLEVEL2 (unsigned char)~_BV(2)
66
#define FUSE_EESAVE (unsigned char)~_BV(3)
67
#define FUSE_WDTON (unsigned char)~_BV(4)
68
#define FUSE_SPIEN (unsigned char)~_BV(5)
69
#define FUSE_DWEN (unsigned char)~_BV(6)
70
#define FUSE_RSTDISBL (unsigned char)~_BV(7)
70
71
#define HFUSE_DEFAULT (FUSE_SPIEN)
72
73
/* Extended Fuse Byte */
73
#define FUSE_SELFPRGEN ~_BV(0)
74
#define FUSE_SELFPRGEN (unsigned char)~_BV(0)
74
75
#define EFUSE_DEFAULT (0xFF)