ATTINY40 Support Information

XC8-CC #pragma config Usage

#pragma config <setting>=<named value>
For example:
// Disable external reset : CLEAR
// Watch dog timer always on : CLEAR
// Output external clock : CLEAR
// Brown-out Detector trigger level : Brown-out detection disabled; [BODLEVEL=111]
#pragma config RSTDISBL = CLEAR, WDTON = CLEAR, CKOUT = CLEAR, BODLEVEL = BODLEVEL_DISABLED
#pragma config <setting>=<literal constant>
For example:
// Disable external reset : CLEAR
// Watch dog timer always on : CLEAR
// Output external clock : CLEAR
// Brown-out Detector trigger level : Brown-out detection disabled; [BODLEVEL=111]
#pragma config RSTDISBL = 0x1, WDTON = 0x1, CKOUT = 0x1, BODLEVEL = 0x7

Configuration Registers & Settings

Register: BYTE0
RSTDISBL Disable external reset
SET
CLEAR
WDTON Watch dog timer always on
SET
CLEAR
CKOUT Output external clock
SET
CLEAR
BODLEVEL Brown-out Detector trigger level
BODLEVEL_DISABLED Brown-out detection disabled; [BODLEVEL=111]
BODLEVEL_1V8 Brown-out detection at VCC=1.8 V
BODLEVEL_2V7 Brown-out detection at VCC=2.7 V
BODLEVEL_4V3 Brown-out detection at VCC=4.3 V
Register: LOCKBIT
LB Memory Lock
LB_PROG_VER_DISABLED Further programming and verification disabled
LB_PROG_DISABLED Further programming disabled
LB_NO_LOCK No memory lock features enabled