cfg_spi_divtable.h File Reference

Collection of pre-computed bus pre-scalers for SPI configuration. More...

Detailed Description

Collection of pre-computed bus pre-scalers for SPI configuration.

Author
Hauke Petersen hauke.nosp@m..pet.nosp@m.ersen.nosp@m.@fu-.nosp@m.berli.nosp@m.n.de

Definition in file cfg_spi_divtable.h.

+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

SPI bus divider values for pre-defined peripheral bus clock speeds

Note
These spi_divtables are generated using cpu/stm32_common/dist/spi_divtable/spi_divtable.c
#define CFG_SPIDIV_20
 
#define CFG_SPIDIV_30
 
#define CFG_SPIDIV_32
 
#define CFG_SPIDIV_36
 
#define CFG_SPIDIV_40
 
#define CFG_SPIDIV_42
 
#define CFG_SPIDIV_45
 
#define CFG_SPIDIV_48
 
#define CFG_SPIDIV_50
 
#define CFG_SPIDIV_54
 
#define CFG_SPIDIV_60
 
#define CFG_SPIDIV_64
 
#define CFG_SPIDIV_72
 
#define CFG_SPIDIV_84
 
#define CFG_SPIDIV_90
 
#define CFG_SPIDIV_96
 
#define CFG_SPIDIV_100
 
#define CFG_SPIDIV_108
 

SPI clock divisors

Note
The spi_divtable is auto-generated from cpu/stm32_common/dist/spi_divtable/spi_divtable.c
static const uint8_t spi_divtable [2][5]
 

Macro Definition Documentation

◆ CFG_SPIDIV_100

#define CFG_SPIDIV_100
Value:
{ /* for 100000000Hz */ \
7, /* -> 390625Hz */ \
7, /* -> 390625Hz */ \
6, /* -> 781250Hz */ \
3, /* -> 6250000Hz */ \
2 /* -> 12500000Hz */ \
},

Definition at line 177 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_108

#define CFG_SPIDIV_108
Value:
{ /* for 108000000Hz */ \
7, /* -> 421875Hz */ \
7, /* -> 421875Hz */ \
6, /* -> 843750Hz */ \
4, /* -> 3375000Hz */ \
3 /* -> 6750000Hz */ \
},

Definition at line 186 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_20

#define CFG_SPIDIV_20
Value:
{ /* for 20000000Hz */ \
7, /* -> 78125Hz */ \
5, /* -> 312500Hz */ \
3, /* -> 1250000Hz */ \
1, /* -> 5000000Hz */ \
0 /* -> 10000000Hz */ \
},

Definition at line 33 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_30

#define CFG_SPIDIV_30
Value:
{ /* for 30000000Hz */ \
7, /* -> 117187Hz */ \
5, /* -> 468750Hz */ \
4, /* -> 937500Hz */ \
2, /* -> 3750000Hz */ \
1 /* -> 7500000Hz */ \
},

Definition at line 42 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_32

#define CFG_SPIDIV_32
Value:
{ /* for 32000000Hz */ \
7, /* -> 125000Hz */ \
5, /* -> 500000Hz */ \
4, /* -> 1000000Hz */ \
2, /* -> 4000000Hz */ \
1 /* -> 8000000Hz */ \
},

Definition at line 51 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_36

#define CFG_SPIDIV_36
Value:
{ /* for 36000000Hz */ \
7, /* -> 140625Hz */ \
6, /* -> 281250Hz */ \
4, /* -> 1125000Hz */ \
2, /* -> 4500000Hz */ \
1 /* -> 9000000Hz */ \
},

Definition at line 60 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_40

#define CFG_SPIDIV_40
Value:
{ /* for 40000000Hz */ \
7, /* -> 156250Hz */ \
6, /* -> 312500Hz */ \
4, /* -> 1250000Hz */ \
2, /* -> 5000000Hz */ \
1 /* -> 10000000Hz */ \
},

Definition at line 69 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_42

#define CFG_SPIDIV_42
Value:
{ /* for 42000000Hz */ \
7, /* -> 164062Hz */ \
6, /* -> 328125Hz */ \
4, /* -> 1312500Hz */ \
2, /* -> 5250000Hz */ \
1 /* -> 10500000Hz */ \
},

Definition at line 78 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_45

#define CFG_SPIDIV_45
Value:
{ /* for 45000000Hz */ \
7, /* -> 175781Hz */ \
6, /* -> 351562Hz */ \
5, /* -> 703125Hz */ \
2, /* -> 5625000Hz */ \
1 /* -> 11250000Hz */ \
},

Definition at line 87 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_48

#define CFG_SPIDIV_48
Value:
{ /* for 48000000Hz */ \
7, /* -> 187500Hz */ \
6, /* -> 375000Hz */ \
5, /* -> 750000Hz */ \
2, /* -> 6000000Hz */ \
1 /* -> 12000000Hz */ \
},

Definition at line 96 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_50

#define CFG_SPIDIV_50
Value:
{ /* for 50000000Hz */ \
7, /* -> 195312Hz */ \
6, /* -> 390625Hz */ \
5, /* -> 781250Hz */ \
2, /* -> 6250000Hz */ \
1 /* -> 12500000Hz */ \
},

Definition at line 105 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_54

#define CFG_SPIDIV_54
Value:
{ /* for 54000000Hz */ \
7, /* -> 210937Hz */ \
6, /* -> 421875Hz */ \
5, /* -> 843750Hz */ \
3, /* -> 3375000Hz */ \
2 /* -> 6750000Hz */ \
},

Definition at line 114 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_60

#define CFG_SPIDIV_60
Value:
{ /* for 60000000Hz */ \
7, /* -> 234375Hz */ \
6, /* -> 468750Hz */ \
5, /* -> 937500Hz */ \
3, /* -> 3750000Hz */ \
2 /* -> 7500000Hz */ \
},

Definition at line 123 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_64

#define CFG_SPIDIV_64
Value:
{ /* for 64000000Hz */ \
7, /* -> 250000Hz */ \
6, /* -> 500000Hz */ \
5, /* -> 1000000Hz */ \
3, /* -> 4000000Hz */ \
2 /* -> 8000000Hz */ \
},

Definition at line 132 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_72

#define CFG_SPIDIV_72
Value:
{ /* for 72000000Hz */ \
7, /* -> 281250Hz */ \
7, /* -> 281250Hz */ \
5, /* -> 1125000Hz */ \
3, /* -> 4500000Hz */ \
2 /* -> 9000000Hz */ \
},

Definition at line 141 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_84

#define CFG_SPIDIV_84
Value:
{ /* for 84000000Hz */ \
7, /* -> 328125Hz */ \
7, /* -> 328125Hz */ \
5, /* -> 1312500Hz */ \
3, /* -> 5250000Hz */ \
2 /* -> 10500000Hz */ \
},

Definition at line 150 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_90

#define CFG_SPIDIV_90
Value:
{ /* for 90000000Hz */ \
7, /* -> 351562Hz */ \
7, /* -> 351562Hz */ \
6, /* -> 703125Hz */ \
3, /* -> 5625000Hz */ \
2 /* -> 11250000Hz */ \
},

Definition at line 159 of file cfg_spi_divtable.h.

◆ CFG_SPIDIV_96

#define CFG_SPIDIV_96
Value:
{ /* for 96000000Hz */ \
7, /* -> 375000Hz */ \
7, /* -> 375000Hz */ \
6, /* -> 750000Hz */ \
3, /* -> 6000000Hz */ \
2 /* -> 12000000Hz */ \
},

Definition at line 168 of file cfg_spi_divtable.h.