libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.
Collaboration diagram for Clock Control Register:

Macros

#define CCSCTL   MMIO32(SCC_BASE)
 
#define CCS_CTL_FRCLKMUXSEL_MASK   (0x03)
 
#define CCS_CTL_FRCLKMUXSEL(sel)   ((sel) & CCS_CTL_FRCLKMUXSEL_MASK)
 
#define CCS_CTL_FRCLKMUXSEL_ROSC   (0)
 
#define CCS_CTL_FRCLKMUXSEL_CLKREF   (1)
 
#define CCS_CTL_FRCLKMUXSEL_EXTCLK   (3)
 
#define CCS_CTL_ROSCEN   BIT2
 
#define CCS_CTL_SCLKMUXSEL   BIT4
 
#define CCS_CTL_SCLKMUXSEL_FRCLK   (0)
 
#define CCS_CTL_SCLKMUXSEL_PLLCLK   (1)
 
#define CCS_CTL_CLKFAILEN   BIT5
 
#define CCS_CTL_CLKFAILMUXSEL   BIT6
 
#define CCS_CTL_CLKFAILIF   BIT7
 
#define CCS_CTL_LDOEN   BIT8
 
#define CCS_CTL_SWRESET   BIT11
 
#define CCS_CTL_PCLKEN   BIT12
 
#define CCS_CTL_ACLKEN   BIT13
 
#define CCS_CTL_ADCCLKEN   BIT14
 
#define CCS_CTL_STCLKSLPEN   BIT15
 
#define CCS_CTL_PCLKDIV_MASK   (0x07)
 
#define CCS_CTL_PCLKDIV_SHIFT   (16)
 
#define CCS_CTL_PCLKDIV(div)   (((div-1) & CCS_CTL_PCLKDIV_MASK) << CCS_CTL_PCLKDIV_SHIFT)
 
#define CCS_CTL_ACLKDIV_MASK   (0x07)
 
#define CCS_CTL_ACLKDIV_SHIFT   (20)
 
#define CCS_CTL_ACLKDIV(div)   (((div-1) & CCS_CTL_ACLKDIV_MASK) << CCS_CTL_ACLKDIV_SHIFT)
 
#define CCS_CTL_HCLKDIV_MASK   (0x07)
 
#define CCS_CTL_HCLKDIV_SHIFT   (24)
 
#define CCS_CTL_HCLKDIV(div)   (((div-1) & CCS_CTL_HCLKDIV_MASK) << CCS_CTL_HCLKDIV_SHIFT)
 
#define CCS_CTL_USAMODE   BIT28
 
#define CCS_CTL_USBMODE   BIT29
 
#define CCS_CTL_USCMODE   BIT30
 
#define CCS_CTL_USDMODE   BIT31
 

Detailed Description

Macro Definition Documentation

◆ CCS_CTL_ACLKDIV

#define CCS_CTL_ACLKDIV (   div)    (((div-1) & CCS_CTL_ACLKDIV_MASK) << CCS_CTL_ACLKDIV_SHIFT)

Definition at line 78 of file ccs.h.

◆ CCS_CTL_ACLKDIV_MASK

#define CCS_CTL_ACLKDIV_MASK   (0x07)

Definition at line 75 of file ccs.h.

◆ CCS_CTL_ACLKDIV_SHIFT

#define CCS_CTL_ACLKDIV_SHIFT   (20)

Definition at line 76 of file ccs.h.

◆ CCS_CTL_ACLKEN

#define CCS_CTL_ACLKEN   BIT13

Definition at line 68 of file ccs.h.

◆ CCS_CTL_ADCCLKEN

#define CCS_CTL_ADCCLKEN   BIT14

Definition at line 69 of file ccs.h.

◆ CCS_CTL_CLKFAILEN

#define CCS_CTL_CLKFAILEN   BIT5

Definition at line 62 of file ccs.h.

◆ CCS_CTL_CLKFAILIF

#define CCS_CTL_CLKFAILIF   BIT7

Definition at line 64 of file ccs.h.

◆ CCS_CTL_CLKFAILMUXSEL

#define CCS_CTL_CLKFAILMUXSEL   BIT6

Definition at line 63 of file ccs.h.

◆ CCS_CTL_FRCLKMUXSEL

#define CCS_CTL_FRCLKMUXSEL (   sel)    ((sel) & CCS_CTL_FRCLKMUXSEL_MASK)

Definition at line 54 of file ccs.h.

◆ CCS_CTL_FRCLKMUXSEL_CLKREF

#define CCS_CTL_FRCLKMUXSEL_CLKREF   (1)

Definition at line 56 of file ccs.h.

◆ CCS_CTL_FRCLKMUXSEL_EXTCLK

#define CCS_CTL_FRCLKMUXSEL_EXTCLK   (3)

Definition at line 57 of file ccs.h.

◆ CCS_CTL_FRCLKMUXSEL_MASK

#define CCS_CTL_FRCLKMUXSEL_MASK   (0x03)

Definition at line 53 of file ccs.h.

◆ CCS_CTL_FRCLKMUXSEL_ROSC

#define CCS_CTL_FRCLKMUXSEL_ROSC   (0)

Definition at line 55 of file ccs.h.

◆ CCS_CTL_HCLKDIV

#define CCS_CTL_HCLKDIV (   div)    (((div-1) & CCS_CTL_HCLKDIV_MASK) << CCS_CTL_HCLKDIV_SHIFT)

Definition at line 82 of file ccs.h.

◆ CCS_CTL_HCLKDIV_MASK

#define CCS_CTL_HCLKDIV_MASK   (0x07)

Definition at line 79 of file ccs.h.

◆ CCS_CTL_HCLKDIV_SHIFT

#define CCS_CTL_HCLKDIV_SHIFT   (24)

Definition at line 80 of file ccs.h.

◆ CCS_CTL_LDOEN

#define CCS_CTL_LDOEN   BIT8

Definition at line 65 of file ccs.h.

◆ CCS_CTL_PCLKDIV

#define CCS_CTL_PCLKDIV (   div)    (((div-1) & CCS_CTL_PCLKDIV_MASK) << CCS_CTL_PCLKDIV_SHIFT)

Definition at line 74 of file ccs.h.

◆ CCS_CTL_PCLKDIV_MASK

#define CCS_CTL_PCLKDIV_MASK   (0x07)

Definition at line 71 of file ccs.h.

◆ CCS_CTL_PCLKDIV_SHIFT

#define CCS_CTL_PCLKDIV_SHIFT   (16)

Definition at line 72 of file ccs.h.

◆ CCS_CTL_PCLKEN

#define CCS_CTL_PCLKEN   BIT12

Definition at line 67 of file ccs.h.

◆ CCS_CTL_ROSCEN

#define CCS_CTL_ROSCEN   BIT2

Definition at line 58 of file ccs.h.

◆ CCS_CTL_SCLKMUXSEL

#define CCS_CTL_SCLKMUXSEL   BIT4

Definition at line 59 of file ccs.h.

◆ CCS_CTL_SCLKMUXSEL_FRCLK

#define CCS_CTL_SCLKMUXSEL_FRCLK   (0)

Definition at line 60 of file ccs.h.

◆ CCS_CTL_SCLKMUXSEL_PLLCLK

#define CCS_CTL_SCLKMUXSEL_PLLCLK   (1)

Definition at line 61 of file ccs.h.

◆ CCS_CTL_STCLKSLPEN

#define CCS_CTL_STCLKSLPEN   BIT15

Definition at line 70 of file ccs.h.

◆ CCS_CTL_SWRESET

#define CCS_CTL_SWRESET   BIT11

Definition at line 66 of file ccs.h.

◆ CCS_CTL_USAMODE

#define CCS_CTL_USAMODE   BIT28

Definition at line 83 of file ccs.h.

◆ CCS_CTL_USBMODE

#define CCS_CTL_USBMODE   BIT29

Definition at line 84 of file ccs.h.

◆ CCS_CTL_USCMODE

#define CCS_CTL_USCMODE   BIT30

Definition at line 85 of file ccs.h.

◆ CCS_CTL_USDMODE

#define CCS_CTL_USDMODE   BIT31

Definition at line 86 of file ccs.h.

◆ CCSCTL

#define CCSCTL   MMIO32(SCC_BASE)

Definition at line 52 of file ccs.h.