├── requirements.txt
├── source
├── nxp
│ ├── spifi
│ │ ├── spifi_drv_PI.lib
│ │ ├── FlashDev.c
│ │ └── FlashDev.h
│ ├── lpc54018
│ │ ├── fsl_device_registers.h
│ │ └── FlashDev.c
│ ├── lpc54608
│ │ ├── FlashDev.c
│ │ └── fsl_device_registers.h
│ ├── iap_32kb
│ │ └── FlashDev.c
│ ├── lpc54114
│ │ ├── FlashDev.c
│ │ └── fsl_device_registers.h
│ ├── lpc4088_512kb_spifi
│ │ ├── FlashDev.c
│ │ └── rom_drivers.h
│ └── lpc8xx_32kb
│ │ └── FlashDev.c
├── ti
│ └── CC3220SF
│ │ ├── inc
│ │ └── hw_hib3p3.h
│ │ └── FlashDev.c
├── st
│ ├── STM32WB55RC
│ │ ├── inc
│ │ │ ├── stm32wbxx.h
│ │ │ ├── stm32wb55xx.h
│ │ │ ├── cmsis_version.h
│ │ │ └── system_stm32wbxx.h
│ │ └── FlashDev.c
│ ├── STM32WB55RG
│ │ ├── inc
│ │ │ ├── stm32wbxx.h
│ │ │ ├── stm32wb55xx.h
│ │ │ └── cmsis_version.h
│ │ └── FlashDev.c
│ ├── FlashDev.c
│ └── STM32L475
│ │ └── FlashDev.c
├── FlashAlgo.lin
├── FlashAlgo.icf
├── FlashAlgo.ld
├── freescale
│ ├── FlashDev.c
│ └── devices
│ │ ├── MKW01Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKW22D5
│ │ └── fsl_device_registers.h
│ │ ├── MKW24D5
│ │ └── fsl_device_registers.h
│ │ ├── MKW30Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKW40Z4
│ │ └── fsl_device_registers.h
│ │ ├── MK24F25612
│ │ └── fsl_device_registers.h
│ │ ├── MK70F12
│ │ └── fsl_device_registers.h
│ │ ├── MKL28Z7
│ │ └── fsl_device_registers.h
│ │ ├── MKM14ZA5
│ │ └── fsl_device_registers.h
│ │ ├── MKM34ZA5
│ │ └── fsl_device_registers.h
│ │ ├── MKW21D5
│ │ └── fsl_device_registers.h
│ │ ├── MKW41Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKV31F12810
│ │ └── fsl_device_registers.h
│ │ ├── MKV31F25612
│ │ └── fsl_device_registers.h
│ │ ├── MKV31F51212
│ │ └── fsl_device_registers.h
│ │ ├── MKM33ZA5
│ │ └── fsl_device_registers.h
│ │ ├── MKE15Z7
│ │ └── fsl_device_registers.h
│ │ ├── MKL43Z4
│ │ └── fsl_device_registers.h
│ │ ├── MK65F18
│ │ └── fsl_device_registers.h
│ │ ├── MK66F18
│ │ └── fsl_device_registers.h
│ │ ├── MKE18F16
│ │ └── fsl_device_registers.h
│ │ ├── MK80F25615
│ │ └── fsl_device_registers.h
│ │ ├── MK22F51212
│ │ └── fsl_device_registers.h
│ │ ├── MKV10Z7
│ │ └── fsl_device_registers.h
│ │ ├── MKL46Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKL02Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKV11Z7
│ │ └── fsl_device_registers.h
│ │ ├── MKL27Z4
│ │ └── fsl_device_registers.h
│ │ ├── MK64F12
│ │ └── fsl_device_registers.h
│ │ ├── MKL27Z644
│ │ └── fsl_device_registers.h
│ │ ├── MKL05Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKL25Z4
│ │ └── fsl_device_registers.h
│ │ ├── MKV58F22
│ │ └── fsl_device_registers.h
│ │ └── MKL26Z4
│ │ └── fsl_device_registers.h
├── arm
│ ├── gfc100
│ │ ├── FlashDev.c
│ │ └── Native_Driver
│ │ │ └── gfc100_process_spec_api.h
│ └── mt25ql512
│ │ └── FlashDev.c
├── template
│ ├── FlashDev.c
│ └── FlashPrg.c
├── toshiba
│ └── TZ10XX
│ │ ├── FlashDev.c
│ │ └── system_ARMCM4.h
├── wiznet
│ └── W7500
│ │ ├── FlashDev.c
│ │ └── FlashPrg.c
├── onsemi
│ ├── FlashDev.c
│ └── inc1
│ │ ├── types.h
│ │ ├── system_ARMCM3.h
│ │ └── flash_map.h
├── nordic
│ ├── nrf52833
│ │ └── FlashDev.c
│ └── nrf51xxx
│ │ └── FlashDev.c
├── FlashOS.h
├── FlashPrg.h
└── siliconlabs
│ └── EFM32GG
│ └── system_ARMCM3.h
├── records
├── tools
│ ├── uvision.yaml
│ ├── iar_arm.yaml
│ └── make_gcc_arm.yaml
└── projects
│ ├── arm
│ ├── common
│ │ └── arm_flash_driver.yaml
│ └── targets
│ │ ├── musca_a.yaml
│ │ ├── musca_b.yaml
│ │ └── musca_b_eflash.yaml
│ ├── nxp
│ ├── common
│ │ └── nxp_flash_driver.yaml
│ └── targets
│ │ ├── lpc1114fn28.yaml
│ │ ├── lpc824.yaml
│ │ ├── lpc4088.yaml
│ │ ├── lpc54114.yaml
│ │ ├── lpc54608.yaml
│ │ └── lpc54018.yaml
│ ├── freescale
│ ├── targets
│ │ ├── mk20d5.yaml
│ │ ├── mkl02z4.yaml
│ │ ├── mkl05z4.yaml
│ │ ├── mkv10z7.yaml
│ │ ├── mk64f12.yaml
│ │ ├── mk65f18.yaml
│ │ ├── mk66f18.yaml
│ │ ├── mke18f16.yaml
│ │ ├── mkl25z4.yaml
│ │ ├── mkl26z4.yaml
│ │ ├── mkl27z4.yaml
│ │ ├── mkl27z644.yaml
│ │ ├── mkl28z7.yaml
│ │ ├── mkl43z4.yaml
│ │ ├── mkl46z4.yaml
│ │ ├── mkv11z7.yaml
│ │ ├── mkv31f25612.yaml
│ │ ├── mkv58f22.yaml
│ │ ├── mkw01z4.yaml
│ │ ├── mkw30z4.yaml
│ │ ├── mkw40z4.yaml
│ │ ├── mkw41z4.yaml
│ │ ├── mk80f25615.yaml
│ │ ├── mkv31f12810.yaml
│ │ ├── mkv31f51212.yaml
│ │ └── mke15z7.yaml
│ └── common
│ │ └── fsl_flash_driver.yaml
│ ├── st
│ ├── stm32l151.yaml
│ ├── STM32L475.yaml
│ ├── STM32F4xx_2048.yaml
│ ├── STM32L0xx_192.yaml
│ ├── STM32WB55RC.yaml
│ └── STM32WB55RG.yaml
│ ├── template.yaml
│ ├── ti
│ └── cc3220sf.yaml
│ ├── nordic
│ ├── nrf51xxx.yaml
│ └── nrf52833.yaml
│ ├── siliconlabs
│ ├── efm32ggxxxf1024.yaml
│ └── efm32gg.yaml
│ ├── wiznet
│ └── W7500.yaml
│ ├── toshiba
│ └── tz10xx.yaml
│ └── onsemi
│ └── ncs36510.yaml
├── .github
└── workflows
│ └── linux_build.yml
├── scripts
├── __init__.py
├── post_build.bat
├── templates
│ ├── py_blob.tmpl
│ ├── c_blob_mbed.tmpl
│ ├── py_blob_orig.tmpl
│ └── c_blob.tmpl
└── generate_blobs.py
├── .gitignore
├── tools
└── launch_uvision.bat
├── CONTRIBUTING.md
└── README.md
/requirements.txt:
--------------------------------------------------------------------------------
1 | project_generator==0.11.*
2 | Jinja2
3 | pyelftools
4 |
--------------------------------------------------------------------------------
/source/nxp/spifi/spifi_drv_PI.lib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/nxp/spifi/spifi_drv_PI.lib
--------------------------------------------------------------------------------
/source/ti/CC3220SF/inc/hw_hib3p3.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/ti/CC3220SF/inc/hw_hib3p3.h
--------------------------------------------------------------------------------
/records/tools/uvision.yaml:
--------------------------------------------------------------------------------
1 | tool_specific:
2 | uvision:
3 | linker_file:
4 | - source/FlashAlgo.lin
5 |
--------------------------------------------------------------------------------
/source/st/STM32WB55RC/inc/stm32wbxx.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/st/STM32WB55RC/inc/stm32wbxx.h
--------------------------------------------------------------------------------
/source/st/STM32WB55RG/inc/stm32wbxx.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/st/STM32WB55RG/inc/stm32wbxx.h
--------------------------------------------------------------------------------
/source/st/STM32WB55RC/inc/stm32wb55xx.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/st/STM32WB55RC/inc/stm32wb55xx.h
--------------------------------------------------------------------------------
/source/st/STM32WB55RG/inc/stm32wb55xx.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/pyocd/FlashAlgo/HEAD/source/st/STM32WB55RG/inc/stm32wb55xx.h
--------------------------------------------------------------------------------
/records/projects/arm/common/arm_flash_driver.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | includes:
5 | - source
6 | - source/arm
7 |
--------------------------------------------------------------------------------
/records/projects/nxp/common/nxp_flash_driver.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | includes:
5 | - source
6 | - source/nxp
7 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mk20d5.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MK20D5
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MK20DX128VLF5
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl02z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL02Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL02Z32VFM4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl05z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL05Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL05Z32VLF4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv10z7.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKV10Z7
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV10Z32VLF7
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mk64f12.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MK64F12
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MK64FN1M0VLL12
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mk65f18.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MK65F18
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MK65FN2M0VMI18
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mk66f18.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MK66F18
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MK66FN2M0VMD18
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mke18f16.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MKE18F16
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKE18F512VLL16
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl25z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL25Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL25Z128VLK4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl26z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL26Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL26Z128VLH4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl27z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL27Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL27Z256VLH4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl27z644.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL27Z644
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL27Z64VLH4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl28z7.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL28Z7
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL28Z512VLL7
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl43z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL43Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL43Z256VLH4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkl46z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKL46Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKL46Z256VLH4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv11z7.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKV11Z7
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV11Z128VLH7
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv31f25612.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MKV11Z7
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV11Z128VLH7
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv58f22.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MKV58F22
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV58F1M0VLQ22
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkw01z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKW01Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKW01Z128CHN4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkw30z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKW30Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKW30Z160VHM4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkw40z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKW40Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKW40Z160VHT4
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkw41z4.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKW41Z4
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKW41Z512VHT4
9 |
--------------------------------------------------------------------------------
/records/projects/st/stm32l151.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | target:
5 | - cortex-m3
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/st
11 |
--------------------------------------------------------------------------------
/records/projects/template.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | target:
5 | - cortex-m0
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/template
11 |
--------------------------------------------------------------------------------
/records/projects/ti/cc3220sf.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | group_name:
5 | - flash_driver
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/ti/CC3220SF
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mk80f25615.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MK80F25615
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MK80FN256VDC15
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv31f12810.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MKV31F12810
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV31Z128VLH7
9 |
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mkv31f51212.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/freescale/devices/MKV31F51212
6 | macros:
7 | - __NO_EMBEDDED_ASM
8 | - CPU_MKV31F512VLL12
9 |
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc1114fn28.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | sources:
5 | - source/nxp/iap_32kb/FlashDev.c
6 | - source/nxp/iap_32kb/FlashPrg.c
7 | macros:
8 | - __NO_EMBEDDED_ASM
9 |
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc824.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0plus
4 | sources:
5 | - source/nxp/lpc8xx_32kb/FlashDev.c
6 | - source/nxp/lpc8xx_32kb/FlashPrg.c
7 | macros:
8 | - __NO_EMBEDDED_ASM
9 |
--------------------------------------------------------------------------------
/records/projects/nordic/nrf51xxx.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | group_name:
5 | - flash_driver
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/nordic/nrf51xxx
11 |
--------------------------------------------------------------------------------
/records/projects/nordic/nrf52833.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | group_name:
5 | - flash_driver
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/nordic/nrf52833
11 |
--------------------------------------------------------------------------------
/records/projects/st/STM32L475.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | macros:
5 | - STM32L475VG
6 | - FLASH_DRV_VERS=0
7 | includes:
8 | - source/FlashOS.h
9 | sources:
10 | - source/st/STM32L475
11 |
--------------------------------------------------------------------------------
/records/projects/siliconlabs/efm32ggxxxf1024.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | group_name:
5 | - flash_driver
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/siliconlabs/devices/EFM32GG
11 |
--------------------------------------------------------------------------------
/records/projects/wiznet/W7500.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | target:
5 | - cortex-m0
6 | includes:
7 | - source/
8 | sources:
9 | - source/wiznet/W7500/FlashDev.c
10 | - source/wiznet/W7500/FlashPrg.c
11 |
--------------------------------------------------------------------------------
/records/projects/toshiba/tz10xx.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | target:
5 | - cortex-m4
6 | includes:
7 | - source/
8 | sources:
9 | - source/toshiba/TZ10XX/FlashDev.c
10 | - source/toshiba/TZ10XX/FlashPrg.c
11 |
--------------------------------------------------------------------------------
/records/projects/st/STM32F4xx_2048.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/FlashOS.h
6 | sources:
7 | - source/st/STM32F4xx
8 | macros:
9 | - FLASH_MEM
10 | - STM32F4xx_2048
11 | - FLASH_DRV_VERS=0
12 |
--------------------------------------------------------------------------------
/records/projects/st/STM32L0xx_192.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/FlashOS.h
6 | sources:
7 | - source/st/STM32L0xx
8 | macros:
9 | - FLASH_MEMORY
10 | - STM32L0xx_192
11 | - FLASH_DRV_VERS=0
12 |
--------------------------------------------------------------------------------
/records/projects/siliconlabs/efm32gg.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | group_name:
5 | - flash_driver
6 | includes:
7 | - source
8 | sources:
9 | - source
10 | - source/siliconlabs/EFM32GG
11 | macros:
12 | - EFM32GG_1024
13 |
--------------------------------------------------------------------------------
/records/projects/onsemi/ncs36510.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | includes:
5 | - source
6 | - source/onsemi
7 | - source/onsemi/inc1
8 | sources:
9 | - source
10 | - source/onsemi
11 | - source/onsemi/src1
12 | macros:
13 | -
14 |
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc4088.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | sources:
5 | - source/nxp/lpc4088_512kb_spifi/FlashDev.c
6 | - source/nxp/lpc4088_512kb_spifi/FlashPrg.c
7 | includes:
8 | - source/nxp/lpc4088_512kb_spifi
9 | macros:
10 | - __NO_EMBEDDED_ASM
11 |
--------------------------------------------------------------------------------
/records/projects/st/STM32WB55RC.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | macros:
5 | - FLASH_DRV_VERS=0
6 | - STM32WB55xx
7 | includes:
8 | - source/FlashOS.h
9 | - source/st/STM32WB55RC
10 | - source/st/STM32WB55RC/inc
11 | sources:
12 | - source/st/STM32WB55RC
--------------------------------------------------------------------------------
/records/projects/st/STM32WB55RG.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | macros:
5 | - FLASH_DRV_VERS=0
6 | - STM32WB55xx
7 | includes:
8 | - source/FlashOS.h
9 | - source/st/STM32WB55RG
10 | - source/st/STM32WB55RG/inc
11 | sources:
12 | - source/st/STM32WB55RG
--------------------------------------------------------------------------------
/records/projects/freescale/targets/mke15z7.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | includes:
5 | - source/freescale/devices/MKE15Z7
6 | # sources:
7 | # - source/freescale/devices/MKLE15Z7
8 | # - source/freescale/driver/flash_densities_kl_series.c
9 | macros:
10 | - __NO_EMBEDDED_ASM
11 | - CPU_MKE15Z256VLL7
12 |
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc54114.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/nxp/lpc54114
6 | - source/nxp/common_headers
7 | sources:
8 | - source/nxp/lpc54114/FlashDev.c
9 | - source/nxp/lpc54114/FlashPrg.c
10 | - source/nxp/lpc54114/fsl_flashiap.c
11 | macros:
12 | - __NO_EMBEDDED_ASM
13 | - CPU_LPC54114J256BD64_cm4
14 |
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc54608.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/nxp/lpc54608
6 | - source/nxp/common_headers
7 | sources:
8 | - source/nxp/lpc54608/FlashDev.c
9 | - source/nxp/lpc54608/FlashPrg.c
10 | - source/nxp/lpc54608/fsl_flashiap.c
11 | macros:
12 | - __NO_EMBEDDED_ASM
13 | - CPU_LPC54608J512ET180
--------------------------------------------------------------------------------
/records/projects/nxp/targets/lpc54018.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m4
4 | includes:
5 | - source/nxp/lpc54018
6 | - source/nxp/common_headers
7 | sources:
8 | - source/nxp/lpc54018/FlashDev.c
9 | - source/nxp/lpc54018/FlashPrg.c
10 | - source/nxp/lpc54018/fsl_spifi.c
11 | - source/nxp/lpc54018/fsl_reset.c
12 | macros:
13 | - __NO_EMBEDDED_ASM
14 | - CPU_LPC54018JET180
15 |
--------------------------------------------------------------------------------
/records/projects/freescale/common/fsl_flash_driver.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | group_name:
3 | - flash_driver
4 | includes:
5 | - source
6 | - source/freescale
7 | - source/freescale/devices
8 | sources:
9 | - source/freescale/FlashDev.c
10 | - source/freescale/FlashPrg.c
11 | - source/freescale/fsl_flash.c
12 | macros:
13 | - FLASH_SSD_CONFIG_ENABLE_FLEXNVM_SUPPORT=0
14 | - FLASH_DRIVER_IS_FLASH_RESIDENT=0
15 |
--------------------------------------------------------------------------------
/records/projects/arm/targets/musca_a.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | includes:
5 | - source/arm/mt25ql512/qspi_ip6514e/lib
6 | - source/arm/mt25ql512/qspi_ip6514e/native_driver
7 | sources:
8 | - source/arm/mt25ql512/FlashDev.c
9 | - source/arm/mt25ql512/FlashPrg.c
10 | - source/arm/mt25ql512/qspi_ip6514e/lib/mt25ql_flash_lib.c
11 | - source/arm/mt25ql512/qspi_ip6514e/native_driver/qspi_ip6514e_drv.c
12 | macros:
13 | - MUSCA_QSPI_REG_BASE=0x5010A000UL
14 | - MUSCA_QSPI_FLASH_BASE=0x00200000UL
15 |
--------------------------------------------------------------------------------
/records/projects/arm/targets/musca_b.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | includes:
5 | - source/arm/mt25ql512/qspi_ip6514e/lib
6 | - source/arm/mt25ql512/qspi_ip6514e/native_driver
7 | sources:
8 | - source/arm/mt25ql512/FlashDev.c
9 | - source/arm/mt25ql512/FlashPrg.c
10 | - source/arm/mt25ql512/qspi_ip6514e/lib/mt25ql_flash_lib.c
11 | - source/arm/mt25ql512/qspi_ip6514e/native_driver/qspi_ip6514e_drv.c
12 | macros:
13 | - MUSCA_QSPI_REG_BASE=0x52800000UL
14 | - MUSCA_QSPI_FLASH_BASE=0x00000000UL
15 |
--------------------------------------------------------------------------------
/.github/workflows/linux_build.yml:
--------------------------------------------------------------------------------
1 | name: linux develop build "GCC with Make"
2 |
3 | on:
4 | push:
5 | branches: [ "main" ]
6 | pull_request:
7 | branches: [ "main" ]
8 |
9 | jobs:
10 | build:
11 |
12 | runs-on: ubuntu-latest
13 |
14 | steps:
15 | - uses: actions/checkout@v3
16 | - uses: syphar/restore-virtualenv@v1
17 |
18 | - name: install requirements
19 | run: sudo apt-get install -y gcc-arm-none-eabi
20 |
21 | - name: install requirements
22 | run: pip install -r requirements.txt
23 |
24 | - name: build
25 | run: progen build -t make_gcc_arm
26 |
--------------------------------------------------------------------------------
/records/projects/arm/targets/musca_b_eflash.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m3
4 | includes:
5 | - source/arm/gfc100/Native_Driver
6 | - source/arm/gfc100/Native_Driver/sfn40ulp128kx128m64p16i16_c_dw25_svt_110a
7 | sources:
8 | - source/arm/gfc100/FlashDev.c
9 | - source/arm/gfc100/FlashPrg.c
10 | - source/arm/gfc100/Native_Driver/gfc100_eflash_drv.c
11 | - source/arm/gfc100/Native_Driver/sfn40ulp128kx128m64p16i16_c_dw25_svt_110a/sfn40ulp_eflash_drv.c
12 | macros:
13 | - MUSCA_B_EFLASH_BASE=0x0A000000UL
14 | - MUSCA_B_EFLASH_REG_BASE=0x52400000UL
15 |
--------------------------------------------------------------------------------
/records/tools/iar_arm.yaml:
--------------------------------------------------------------------------------
1 | #common:
2 | # target:
3 | # - cortex-m0
4 |
5 | tool_specific:
6 | iar_arm:
7 | macros:
8 | - TOOLCHAIN_IAR
9 | linker_file:
10 | - source/FlashAlgo.lin
11 | misc:
12 | CCDebugInfo:
13 | - enable
14 | CCOptLevel:
15 | - 1
16 | IccLang:
17 | - 1
18 | IccCppDialect:
19 | - 2
20 | GRuntimeLibSelect:
21 | - 2
22 | ACaseSensitivity:
23 | - enable
24 | ADebug:
25 | - enable
26 |
--------------------------------------------------------------------------------
/scripts/__init__.py:
--------------------------------------------------------------------------------
1 | """
2 | DAPLink FlashAlgo
3 | Copyright (c) 2011-2015 ARM Limited
4 |
5 | Licensed under the Apache License, Version 2.0 (the "License");
6 | you may not use this file except in compliance with the License.
7 | You may obtain a copy of the License at
8 |
9 | http://www.apache.org/licenses/LICENSE-2.0
10 |
11 | Unless required by applicable law or agreed to in writing, software
12 | distributed under the License is distributed on an "AS IS" BASIS,
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | See the License for the specific language governing permissions and
15 | limitations under the License.
16 | """
17 |
--------------------------------------------------------------------------------
/records/tools/make_gcc_arm.yaml:
--------------------------------------------------------------------------------
1 | common:
2 | target:
3 | - cortex-m0
4 | core:
5 | - Cortex-M0
6 |
7 | tool_specific:
8 | make_gcc_arm:
9 | linker_file:
10 | - source/FlashAlgo.ld
11 | misc:
12 | libraries:
13 | - m
14 | - gcc
15 | - c
16 | - nosys
17 | common_flags:
18 | - -Os
19 | - -Wall
20 | - -ffunction-sections
21 | - -fdata-sections
22 | - -fpic
23 | - -msingle-pic-base
24 | - -mpic-register=9
25 | - -fno-jump-tables
26 | - -ffreestanding
27 | ld_flags:
28 | - -nostartfiles
29 | - -Wl,--print-memory-usage
30 |
31 |
32 |
--------------------------------------------------------------------------------
/scripts/post_build.bat:
--------------------------------------------------------------------------------
1 | :: FlashAlgo
2 | :: Copyright (c) 2011-2015 ARM Limited
3 | ::
4 | :: Licensed under the Apache License, Version 2.0 (the "License");
5 | :: you may not use this file except in compliance with the License.
6 | :: You may obtain a copy of the License at
7 | ::
8 | :: http://www.apache.org/licenses/LICENSE-2.0
9 | ::
10 | :: Unless required by applicable law or agreed to in writing, software
11 | :: distributed under the License is distributed on an "AS IS" BASIS,
12 | :: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | :: See the License for the specific language governing permissions and
14 | :: limitations under the License.
15 | ::
16 | ::
17 | :: 2 user commands are not enough so this allows passing the control string
18 | ::
19 |
20 | ::echo %1
21 | ::echo %2
22 | ::echo %3
23 | cmd /c %1
24 | cmd /c %2
25 | cmd /c %3
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Mac files
2 | .DS_Store
3 |
4 | # Compiled Object files
5 | *.slo
6 | *.lo
7 | *.o
8 | tmp/
9 |
10 | # Compiled Dynamic libraries
11 | *.so
12 | *.dylib
13 |
14 | # Compiled Static libraries
15 | *.lai
16 | *.la
17 | *.a
18 |
19 | # Python
20 | *.py[cod]
21 |
22 | # Eclipse Project Files
23 | .cproject
24 | .project
25 | .pydevproject
26 |
27 | # uvision Project Files
28 | *.uvproj
29 | *.uvopt
30 |
31 | # generated project files
32 | projectfiles
33 |
34 | *.plg
35 | *.map
36 | *.lst
37 | *.lnp
38 | *.htm
39 | *.dep
40 | *.d
41 | *.crf
42 | *.bak
43 |
44 | *.axf
45 | *.S19
46 | *.bin
47 | *.hex
48 | *.dep
49 | *.FLM
50 | *.log
51 |
52 | # JLink files
53 | JLink*.*
54 |
55 | # Output directories
56 | Output
57 | Lst
58 | Obj
59 |
60 | # cscope
61 | cscope.*
62 |
63 | # ctags
64 | tags
65 |
66 | # Doxygen tags and html output
67 | *.tag
68 | *.html
69 | debug.txt
70 | docs
71 |
72 | # PyCharm project files
73 | .idea
74 |
75 | # virtual environment
76 | venv/
77 |
--------------------------------------------------------------------------------
/source/nxp/lpc54018/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright 2014-2016 Freescale Semiconductor, Inc.
3 | * Copyright 2016-2018 NXP
4 | *
5 | * SPDX-License-Identifier: BSD-3-Clause
6 | *
7 | */
8 |
9 | #ifndef __FSL_DEVICE_REGISTERS_H__
10 | #define __FSL_DEVICE_REGISTERS_H__
11 |
12 | /*
13 | * Include the cpu specific register header files.
14 | *
15 | * The CPU macro should be declared in the project or makefile.
16 | */
17 | #if (defined(CPU_LPC54018JBD208) || defined(CPU_LPC54018JET180))
18 |
19 | #define LPC54018_SERIES
20 |
21 | /* CMSIS-style register definitions */
22 | #include "LPC54018.h"
23 | /* CPU specific feature definitions */
24 | #include "LPC54018_features.h"
25 |
26 | #else
27 | #error "No valid CPU defined!"
28 | #endif
29 |
30 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
31 |
32 | /*******************************************************************************
33 | * EOF
34 | ******************************************************************************/
35 |
--------------------------------------------------------------------------------
/source/FlashAlgo.lin:
--------------------------------------------------------------------------------
1 | ; Flash OS Routines
2 | ; Copyright (c) 2009-2015 ARM Limited
3 | ;
4 | ; Licensed under the Apache License, Version 2.0 (the "License");
5 | ; you may not use this file except in compliance with the License.
6 | ; You may obtain a copy of the License at
7 | ;
8 | ; http://www.apache.org/licenses/LICENSE-2.0
9 | ;
10 | ; Unless required by applicable law or agreed to in writing, software
11 | ; distributed under the License is distributed on an "AS IS" BASIS,
12 | ; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | ; See the License for the specific language governing permissions and
14 | ; limitations under the License.
15 |
16 | PRG 0 PI ; Programming Functions
17 | {
18 | PrgCode +0 ; Code
19 | {
20 | * (+RO)
21 | }
22 | PrgData +0 ; Data
23 | {
24 | * (+RW,+ZI)
25 | }
26 | }
27 |
28 | DSCR +0 ; Device Description
29 | {
30 | DevDscr +0
31 | {
32 | FlashDev.o
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/source/FlashAlgo.icf:
--------------------------------------------------------------------------------
1 | ; Flash OS Routines
2 | ; Copyright (c) 2009-2015 ARM Limited
3 | ;
4 | ; Licensed under the Apache License, Version 2.0 (the "License");
5 | ; you may not use this file except in compliance with the License.
6 | ; You may obtain a copy of the License at
7 | ;
8 | ; http://www.apache.org/licenses/LICENSE-2.0
9 | ;
10 | ; Unless required by applicable law or agreed to in writing, software
11 | ; distributed under the License is distributed on an "AS IS" BASIS,
12 | ; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | ; See the License for the specific language governing permissions and
14 | ; limitations under the License.
15 |
16 |
17 | define memory mem with size = 4G;
18 | define region TEXT_region = mem:[from 0 to 1000];
19 | define region DATA_region = mem:[from 0 to 1000];
20 | define region DevDscr;
21 |
22 | define block RW { readwrite };
23 | define block ZI { zi };
24 |
25 |
26 | place in TEXT_region { readonly };
27 | place in DATA_region { block RW };
28 | place in DATA_region { block ZI };
--------------------------------------------------------------------------------
/source/FlashAlgo.ld:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 |
18 | /*
19 | * The PrgCode and PrgData output section names come from the CMSIS-Pack flash algo
20 | * templates and armlink. It is used here because several tools that work
21 | * with these flash algos expect this section name.
22 | */
23 | SECTIONS
24 | {
25 | PrgCode 0 : ALIGN_WITH_INPUT
26 | {
27 | *(.text*)
28 | EXCLUDE_FILE (*FlashDev.o) *(.rodata*)
29 | . = ALIGN(16);
30 | }
31 |
32 | PrgData : ALIGN_WITH_INPUT
33 | {
34 | *(.data*)
35 | *(.bss*)
36 | *(.got*)
37 | *(COMMON)
38 | . = ALIGN(16);
39 | }
40 |
41 | DevDscr :
42 | {
43 | *FlashDev.o(*)
44 | }
45 |
46 | /DISCARD/ : {
47 | /* Unused exception related info that only wastes space */
48 | *(.ARM.exidx);
49 | *(.ARM.exidx.*);
50 | *(.ARM.extab.*);
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/source/nxp/spifi/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2013 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 | #include "FlashDev.h"
19 |
20 | struct FlashDevice const FlashDevice = {
21 | FLASH_DRV_VERS, // Driver Version, do not modify!
22 | FLASH_DEV_NAME, // Device Name
23 | EXTSPI, // Device Type
24 | FLASH_START, // Device Start Address
25 | FLASH_DEV_SIZE, // Device Size
26 | 256, // Programming Page Size
27 | 0, // Reserved, must be 0
28 | 0xFF, // Initial Content of Erased Memory
29 | 500, // Program Page Timeout 500 mSec
30 | 5000, // Erase Sector Timeout 5000 mSec
31 |
32 | // Specify size and address of sectors for each region
33 | FLASH_SECTOR_SIZE, 0x000000, // sector size, address
34 | SECTOR_END
35 | };
36 |
--------------------------------------------------------------------------------
/source/nxp/lpc54018/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2017 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 |
21 | struct FlashDevice const FlashDevice = {
22 | FLASH_DRV_VERS, // Driver Version, do not modify!
23 | "LPC54018 16MB Serial Flash", // Device Name
24 | EXTSPI, // Device Type
25 | 0x10000000, // Device Start Address
26 | 0x01000000, // Device Size
27 | 256, // Programming Page Size
28 | 0, // Reserved, must be 0
29 | 0xFF, // Initial Content of Erased Memory
30 | 2, // Program Page Timeout 1.5ms + 30 %
31 | 140, // Erase Sector Timeout 120ms + 15%
32 | 4 * 1024, 0x000000, // Sector Size 4KB
33 | SECTOR_END
34 | };
35 |
--------------------------------------------------------------------------------
/source/freescale/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2013 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 | #define DEVICE_NAME "MKXX"
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | DEVICE_NAME, // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Device Start Address
27 | 0x00000000, // Device Size
28 | 1024, // Programming Page Size
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 100, // Program Page Timeout 100 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 | {{0x000400, 0x000000}, // Sector Size 1kB
34 | {SECTOR_END}}
35 | };
36 |
--------------------------------------------------------------------------------
/source/arm/gfc100/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2019 Arm Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 |
21 | struct FlashDevice const FlashDevice = {
22 | FLASH_DRV_VERS, // Driver Version, do not modify!
23 | "MuscaB_eflash", // Device Name
24 | EXTSPI, // Device Type
25 | MUSCA_B_EFLASH_BASE, // Device Start Address
26 | 0x00400000, // Device Size (4MB)
27 | 0x04000, // Programming Page Size
28 | 0, // Reserved, must be 0
29 | 0xFF, // Initial Content of Erased Memory
30 | 100, // Program Page Timeout 100 mSec
31 | 3000, // Erase Sector Timeout 3000 mSec
32 |
33 | // Specify Size and Address of Sectors
34 | 0x04000, 0x000000, // Sector Size 16kB
35 | SECTOR_END
36 | };
37 |
38 |
39 |
--------------------------------------------------------------------------------
/source/arm/mt25ql512/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2013 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 |
21 | struct FlashDevice const FlashDevice = {
22 | FLASH_DRV_VERS, // Driver Version, do not modify!
23 | "MT25QL512", // Device Name
24 | EXTSPI, // Device Type
25 | MUSCA_QSPI_FLASH_BASE, // Device Start Address
26 | 0x00800000, // Device Size (8MB)
27 | 256, // Programming Page Size
28 | 0, // Reserved, must be 0
29 | 0xFF, // Initial Content of Erased Memory
30 | 100, // Program Page Timeout 100 mSec
31 | 3000, // Erase Sector Timeout 3000 mSec
32 |
33 | // Specify Size and Address of Sectors
34 | 0x010000, 0x000000, // Sector Size 64kB
35 | SECTOR_END
36 | };
37 |
38 |
39 |
--------------------------------------------------------------------------------
/source/template/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashDev.c */
18 |
19 | #include "FlashOS.h"
20 |
21 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
22 | #define DEVICE_NAME "XXXX"
23 |
24 | struct FlashDevice const FlashDevice = {
25 | FLASH_DRV_VERS, // Driver Version, do not modify!
26 | DEVICE_NAME, // Device Name (128 chars max)
27 | ONCHIP, // Device Type
28 | 0x00000000, // Device Start Address
29 | 0x00000000, // Device Size
30 | 0x00000200, // Programming Page Size
31 | 0x00000000, // Reserved, must be 0
32 | 0xFF, // Initial Content of Erased Memory
33 | 0x00000064, // Program Page Timeout 100 mSec
34 | 0x00000BB8, // Erase Sector Timeout 3000 mSec
35 | {{0x00000400, 0x00000000}, // Sector Size {1kB, starting at address 0}
36 | {SECTOR_END}}
37 | };
38 |
--------------------------------------------------------------------------------
/source/nxp/lpc54608/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2017 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 | #include "fsl_device_registers.h"
19 |
20 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | "LPC54608 IAP 512kB Flash", // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Device Start Address
27 | FSL_FEATURE_SYSCON_FLASH_SIZE_BYTES, // Device Size
28 | FSL_FEATURE_SYSCON_FLASH_PAGE_SIZE_BYTES, // Programming Page Size
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 300, // Program Page Timeout 300 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 | {{0x008000, 0x000000}, // Sector Size 32kB
34 | {SECTOR_END}}
35 | };
36 |
--------------------------------------------------------------------------------
/source/ti/CC3220SF/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2018 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 | /** @file FlashDev.c */
17 | #include "FlashOS.h"
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 | #define DEVICE_NAME "CC3220SF"
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | DEVICE_NAME, // Device Name (128 chars max)
25 | ONCHIP, // Device Type
26 | 0x01000000, // Device Start Address
27 | 0x00100000, // Device Size(1MB)
28 | 0x00000400, // Programming Page Size
29 | 0x00000000, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 0x00000064, // Program Page Timeout 100 mSec
32 | 0x00000BB8, // Erase Sector Timeout 3000 mSec
33 | {{0x00000800, 0x00000000}, // Sector Size {2kB, starting at address 0x0100 0000}
34 | {SECTOR_END}}
35 | };
36 |
37 |
--------------------------------------------------------------------------------
/source/nxp/iap_32kb/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash Algorithm for NXP IAP 32kB devices
2 | * Copyright (c) 2009-2016 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 |
21 | struct FlashDevice const FlashDevice = {
22 | FLASH_DRV_VERS, // Driver Version, do not modify!
23 | "LPC11xx/122x/13xx IAP 32kB Flash", // Device Name
24 | ONCHIP, // Device Type
25 | 0x00000000, // Device Start Address
26 | 0x00008000, // Device Size (32kB)
27 | 1024, // Programming Page Size
28 | 0, // Reserved, must be 0
29 | 0xFF, // Initial Content of Erased Memory
30 | 300, // Program Page Timeout 300 mSec
31 | 3000, // Erase Sector Timeout 3000 mSec
32 |
33 | // Specify Size and Address of Sectors
34 | 0x001000, 0x000000, // Sector Size 4kB (8 Sectors)
35 | SECTOR_END
36 | };
37 |
--------------------------------------------------------------------------------
/source/nxp/lpc54114/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2013 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 | #include "fsl_device_registers.h"
19 |
20 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | "LPC54114 IAP 256kB Flash", // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Device Start Address
27 | FSL_FEATURE_SYSCON_FLASH_SIZE_BYTES, // Device Size
28 | FSL_FEATURE_SYSCON_FLASH_PAGE_SIZE_BYTES, // Programming Page Size
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 300, // Program Page Timeout 300 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 | {{0x008000, 0x000000}, // Sector Size 32kB
34 | {SECTOR_END}}
35 | };
36 |
--------------------------------------------------------------------------------
/source/toshiba/TZ10XX/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashDev.c */
18 |
19 | #include "FlashOS.h"
20 |
21 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
22 | #define DEVICE_NAME "TZ10XX on package NOR flash(1MB)"
23 |
24 | struct FlashDevice const FlashDevice = {
25 | FLASH_DRV_VERS, // Driver Version, do not modify!
26 | DEVICE_NAME, // Device Name (128 chars max)
27 | ONCHIP, // Device Type
28 | 0x00000000, // Device Start Address
29 | 0x00100000, // Device Size
30 | 0x00000100, // Programming Page Size
31 | 0x00000000, // Reserved, must be 0
32 | 0xFF, // Initial Content of Erased Memory
33 | 0x00000064, // Program Page Timeout 100 mSec
34 | 0x00000320, // Erase Sector Timeout 800 mSec
35 | {{0x00001000, 0x00000000}, // Sector Size {4kB, starting at address 0}
36 | {SECTOR_END}}
37 | };
38 |
--------------------------------------------------------------------------------
/source/wiznet/W7500/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h"
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 | #define DEVICE_NAME "W7500 128KB Flash"
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | DEVICE_NAME, // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Flash start address
27 | 0x00020000, // Flash total size (128 KB // + 1 kB)
28 | 0x00000100, // Programming Page Size
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 100, // Program Page Timeout 100 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 |
34 | 0x00000100, 0x000000, // Sector Size 256bytes (512Sectors,128KB)
35 | SECTOR_END // Marks end of sector table
36 | };
37 |
38 |
--------------------------------------------------------------------------------
/source/onsemi/FlashDev.c:
--------------------------------------------------------------------------------
1 | /** Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashDev.c */
18 |
19 | #include "FlashOS.h"
20 |
21 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
22 | #define DEVICE_NAME "NCS36510 640 KB Flash"
23 |
24 | struct FlashDevice const FlashDevice = {
25 | FLASH_DRV_VERS, // Driver Version, do not modify!
26 | DEVICE_NAME, // Device Name (128 chars max)
27 | ONCHIP, // Device Type
28 | 0x00002000, // Device Start Address
29 | 0x00152000, // Device Size (Flash A 316K + Flash B 320K)
30 | 0x00000800, // Programming Page Size
31 | 0x00000000, // Reserved, must be 0
32 | 0xFF, // Initial Content of Erased Memory
33 | 0x00000064, // Program Page Timeout 100 mSec
34 | 0x00000BB8, // Erase Sector Timeout 3000 mSec
35 | {{0x00000400, 0x00000000}, // Sector Size {1kB, starting at address 0}
36 | {SECTOR_END}}
37 | };
38 |
--------------------------------------------------------------------------------
/source/nordic/nrf52833/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h"
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 | #define DEVICE_NAME "nRF52833"
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | DEVICE_NAME, // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Flash start address
27 | 0x00080000, // Flash total size (512 KB)
28 | 4, // Programming Page Size (4 bytes minimum write)
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 100, // Program Page Timeout 100 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 | {
34 | {0x080000, 0x00000000}, // 512 KBs of flash
35 | {0x000308, 0x10001000}, // UICR
36 | {SECTOR_END} // Marks end of sector table
37 | }
38 | };
39 |
--------------------------------------------------------------------------------
/source/nordic/nrf51xxx/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h"
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 | #define DEVICE_NAME "nRF51822AA 256 KB Flash"
21 |
22 | struct FlashDevice const FlashDevice = {
23 | FLASH_DRV_VERS, // Driver Version, do not modify!
24 | DEVICE_NAME, // Device Name
25 | ONCHIP, // Device Type
26 | 0x00000000, // Flash start address
27 | 0x00040000, // Flash total size (256 KB // + 1 kB)
28 | 4, // Programming Page Size
29 | 0, // Reserved, must be 0
30 | 0xFF, // Initial Content of Erased Memory
31 | 100, // Program Page Timeout 100 mSec
32 | 3000, // Erase Sector Timeout 3000 mSec
33 | {{0x000400, 0x000000}, // Sector Size 1 KB (256 Sectors)
34 | // {0x000400, 0x10001000}, // Sector Size 1 KB (1 Sector)
35 | {SECTOR_END}} // Marks end of sector table
36 | };
37 |
--------------------------------------------------------------------------------
/source/nxp/lpc4088_512kb_spifi/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* Flash Algorithm for Embedded Artists LPC4088 boards with 512kB + QSPI
2 | * Copyright (c) 2009-2016 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h" // FlashOS Structures
18 |
19 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
20 |
21 | struct FlashDevice const FlashDevice = {
22 | FLASH_DRV_VERS, // Driver Version, do not modify!
23 | "LPC4088 IAP 512kB Flash", // Device Name
24 | ONCHIP, // Device Type
25 | 0x00000000, // Device Start Address
26 | 0x00080000, // Device Size (512kB)
27 | 1024, // Programming Page Size
28 | 0, // Reserved, must be 0
29 | 0xFF, // Initial Content of Erased Memory
30 | 300, // Program Page Timeout 300 mSec
31 | 3000, // Erase Sector Timeout 3000 mSec
32 |
33 | // Specify Size and Address of Sectors
34 | 0x001000, 0x000000, // Sector Size 4kB (16 Sectors)
35 | 0x008000, 0x010000, // Sector Size 32kB (14 Sectors)
36 | SECTOR_END
37 | };
38 |
--------------------------------------------------------------------------------
/source/onsemi/inc1/types.h:
--------------------------------------------------------------------------------
1 | /**
2 | ******************************************************************************
3 | * @file types.h
4 | * @author ON Semiconductor
5 | * $Rev: $
6 | * $Date: 2015-11-15 $
7 | * @brief (API) Public header of Flash driver
8 | ******************************************************************************
9 | * @copyright (c) 2012 ON Semiconductor. All rights reserved.
10 | * @internal
11 | * ON Semiconductor is supplying this software for use with ON Semiconductor
12 | * processor based microcontrollers only.
13 | *
14 | * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
15 | * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
16 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
17 | * ON SEMICONDUCTOR SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL,
18 | * INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
19 | * @endinternal
20 | *
21 | * @ingroup FLASH
22 | *
23 | * @details
24 | *
25 | *
General description
26 | *
27 | *
28 | */
29 | #ifndef _types_h
30 | #define _types_h
31 |
32 | #ifdef __cplusplus
33 | extern "C" {
34 | #endif
35 |
36 | #include
37 |
38 | typedef unsigned char u8_t;
39 | typedef signed char i8_t;
40 | typedef unsigned short u16_t;
41 | typedef signed short i16_t;
42 | typedef unsigned long u32_t;
43 | typedef signed long i32_t;
44 | typedef unsigned long long u64_t;
45 | typedef signed long long i64_t;
46 | typedef unsigned char boolean;
47 |
48 | #define ASSERT(test) ((void)(test))
49 |
50 | #define True (1)
51 | #define False (0)
52 | #define Null (0)
53 |
54 | #ifdef __cplusplus
55 | }
56 | #endif
57 |
58 | #endif
59 |
--------------------------------------------------------------------------------
/source/st/STM32WB55RC/inc/cmsis_version.h:
--------------------------------------------------------------------------------
1 | /**************************************************************************//**
2 | * @file cmsis_version.h
3 | * @brief CMSIS Core(M) Version definitions
4 | * @version V5.0.3
5 | * @date 24. June 2019
6 | ******************************************************************************/
7 | /*
8 | * Copyright (c) 2009-2019 ARM Limited. All rights reserved.
9 | *
10 | * SPDX-License-Identifier: Apache-2.0
11 | *
12 | * Licensed under the Apache License, Version 2.0 (the License); you may
13 | * not use this file except in compliance with the License.
14 | * You may obtain a copy of the License at
15 | *
16 | * www.apache.org/licenses/LICENSE-2.0
17 | *
18 | * Unless required by applicable law or agreed to in writing, software
19 | * distributed under the License is distributed on an AS IS BASIS, WITHOUT
20 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21 | * See the License for the specific language governing permissions and
22 | * limitations under the License.
23 | */
24 |
25 | #if defined ( __ICCARM__ )
26 | #pragma system_include /* treat file as system include file for MISRA check */
27 | #elif defined (__clang__)
28 | #pragma clang system_header /* treat file as system include file */
29 | #endif
30 |
31 | #ifndef __CMSIS_VERSION_H
32 | #define __CMSIS_VERSION_H
33 |
34 | /* CMSIS Version definitions */
35 | #define __CM_CMSIS_VERSION_MAIN ( 5U) /*!< [31:16] CMSIS Core(M) main version */
36 | #define __CM_CMSIS_VERSION_SUB ( 3U) /*!< [15:0] CMSIS Core(M) sub version */
37 | #define __CM_CMSIS_VERSION ((__CM_CMSIS_VERSION_MAIN << 16U) | \
38 | __CM_CMSIS_VERSION_SUB ) /*!< CMSIS Core(M) version number */
39 | #endif
40 |
--------------------------------------------------------------------------------
/source/st/STM32WB55RG/inc/cmsis_version.h:
--------------------------------------------------------------------------------
1 | /**************************************************************************//**
2 | * @file cmsis_version.h
3 | * @brief CMSIS Core(M) Version definitions
4 | * @version V5.0.3
5 | * @date 24. June 2019
6 | ******************************************************************************/
7 | /*
8 | * Copyright (c) 2009-2019 ARM Limited. All rights reserved.
9 | *
10 | * SPDX-License-Identifier: Apache-2.0
11 | *
12 | * Licensed under the Apache License, Version 2.0 (the License); you may
13 | * not use this file except in compliance with the License.
14 | * You may obtain a copy of the License at
15 | *
16 | * www.apache.org/licenses/LICENSE-2.0
17 | *
18 | * Unless required by applicable law or agreed to in writing, software
19 | * distributed under the License is distributed on an AS IS BASIS, WITHOUT
20 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21 | * See the License for the specific language governing permissions and
22 | * limitations under the License.
23 | */
24 |
25 | #if defined ( __ICCARM__ )
26 | #pragma system_include /* treat file as system include file for MISRA check */
27 | #elif defined (__clang__)
28 | #pragma clang system_header /* treat file as system include file */
29 | #endif
30 |
31 | #ifndef __CMSIS_VERSION_H
32 | #define __CMSIS_VERSION_H
33 |
34 | /* CMSIS Version definitions */
35 | #define __CM_CMSIS_VERSION_MAIN ( 5U) /*!< [31:16] CMSIS Core(M) main version */
36 | #define __CM_CMSIS_VERSION_SUB ( 3U) /*!< [15:0] CMSIS Core(M) sub version */
37 | #define __CM_CMSIS_VERSION ((__CM_CMSIS_VERSION_MAIN << 16U) | \
38 | __CM_CMSIS_VERSION_SUB ) /*!< CMSIS Core(M) version number */
39 | #endif
40 |
--------------------------------------------------------------------------------
/scripts/templates/py_blob.tmpl:
--------------------------------------------------------------------------------
1 | """
2 | Flash OS Routines (Automagically Generated)
3 | Copyright (c) 2017-2017 ARM Limited
4 |
5 | Licensed under the Apache License, Version 2.0 (the "License");
6 | you may not use this file except in compliance with the License.
7 | You may obtain a copy of the License at
8 |
9 | http://www.apache.org/licenses/LICENSE-2.0
10 |
11 | Unless required by applicable law or agreed to in writing, software
12 | distributed under the License is distributed on an "AS IS" BASIS,
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | See the License for the specific language governing permissions and
15 | limitations under the License.
16 | """
17 |
18 | flash_algo = {
19 |
20 | # Flash algorithm as a hex string
21 | 'instructions':
22 | {{algo.format_algo_data(8, 64, "hex")}},
23 |
24 | # Relative function addresses
25 | 'pc_init': {{'0x%x' % algo.symbols['Init']}},
26 | 'pc_unInit': {{'0x%x' % algo.symbols['UnInit']}},
27 | 'pc_program_page': {{'0x%x' % algo.symbols['ProgramPage']}},
28 | 'pc_erase_sector': {{'0x%x' % algo.symbols['EraseSector']}},
29 | 'pc_eraseAll': {{'0x%x' % algo.symbols['EraseChip']}},
30 |
31 | # Relative region addresses and sizes
32 | 'ro_start': {{'0x%x' % algo.ro_start}},
33 | 'ro_size': {{'0x%x' % algo.ro_size}},
34 | 'rw_start': {{'0x%x' % algo.rw_start}},
35 | 'rw_size': {{'0x%x' % algo.rw_size}},
36 | 'zi_start': {{'0x%x' % algo.zi_start}},
37 | 'zi_size': {{'0x%x' % algo.zi_size}},
38 |
39 | # Flash information
40 | 'flash_start': {{'0x%x' % algo.flash_start}},
41 | 'flash_size': {{'0x%x' % algo.flash_size}},
42 | 'page_size': {{'0x%x' % algo.page_size}},
43 | 'sector_sizes': (
44 | {%- for start, size in algo.sector_sizes %}
45 | {{ "(0x%x, 0x%x)" % (start, size) }},
46 | {%- endfor %}
47 | )
48 | }
49 |
50 |
--------------------------------------------------------------------------------
/tools/launch_uvision.bat:
--------------------------------------------------------------------------------
1 | ::
2 | :: DAPLink Interface Firmware
3 | :: Copyright (c) 2009-2016, ARM Limited, All Rights Reserved
4 | :: SPDX-License-Identifier: Apache-2.0
5 | ::
6 | :: Licensed under the Apache License, Version 2.0 (the "License"); you may
7 | :: not use this file except in compliance with the License.
8 | :: You may obtain a copy of the License at
9 | ::
10 | :: http://www.apache.org/licenses/LICENSE-2.0
11 | ::
12 | :: Unless required by applicable law or agreed to in writing, software
13 | :: distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14 | :: WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 | :: See the License for the specific language governing permissions and
16 | :: limitations under the License.
17 | ::
18 | :: Launches uVision with the python environment needed to build DAPLink
19 | ::
20 | :: git and python are expected to be in PATH. Project will fail to build otherwise
21 | ::
22 |
23 | setlocal
24 |
25 | @rem Script assumes working directory is workspace root. Force it.
26 | cd %~dp0..\
27 |
28 | @rem See if we can find uVision. This logic is consistent with progen
29 | @set uv4exe=c:\Keil_v5\UV4\UV4.exe
30 | @if exist %uv4exe% goto label1
31 | @if [%UV4%]==[] goto error_nomdk
32 | set uv4exe=%UV4%
33 | :label1
34 |
35 | @set env_exists=0
36 | @if exist env set env_exists=1
37 | @if [%env_exists%]==[0] echo Creating python virtual environment && virtualenv env
38 | call env\Scripts\activate
39 |
40 | @echo Doing pip install
41 | @REM use project requirements if not specified
42 | if [%1]==[] pip install -r requirements.txt
43 | @REM use custom requirements if specified
44 | if not [%1]==[] pip install -r %1
45 |
46 | start %uv4exe%
47 | exit /B 0
48 |
49 | :error_nomdk
50 | @echo Error: Keil MDK not installed or not found. If you installed it to a
51 | @echo non-default location, you need to set environment variable UV4 to
52 | @echo the path of the executable
53 | @exit /B 1
54 |
--------------------------------------------------------------------------------
/source/onsemi/inc1/system_ARMCM3.h:
--------------------------------------------------------------------------------
1 | /**
2 | * @file system_ARMCM3.h
3 | * @brief CMSIS Cortex-M3 Device System Header File
4 | * for CM3 Device Series
5 | * @version V1.05
6 | * @date 19. July 2011
7 | *
8 | * @note
9 | * Copyright (C) 2010-2011 ARM Limited. All rights reserved.
10 | *
11 | * @par
12 | * ARM Limited (ARM) is supplying this software for use with Cortex-M
13 | * processor based microcontrollers. This file can be freely distributed
14 | * within development tools that are supporting such ARM based processors.
15 | *
16 | * @par
17 | * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
18 | * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
19 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
20 | * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR
21 | * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
22 | *
23 | * @ingroup bsp
24 | *
25 | ******************************************************************************/
26 |
27 |
28 | #ifndef SYSTEM_ARMCM3_H
29 | #define SYSTEM_ARMCM3_H
30 |
31 | #ifdef __cplusplus
32 | extern "C" {
33 | #endif
34 |
35 | #include "types.h"
36 |
37 | extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
38 |
39 |
40 | /**
41 | * Initialize the system
42 | *
43 | * @param none
44 | * @return none
45 | *
46 | * @brief Setup the microcontroller system.
47 | * Initialize the System and update the SystemCoreClock variable.
48 | */
49 | extern void SystemInit (void);
50 |
51 | /**
52 | * Update SystemCoreClock variable
53 | *
54 | * @param none
55 | * @return none
56 | *
57 | * @brief Updates the SystemCoreClock with current core Clock
58 | * retrieved from cpu registers.
59 | */
60 | extern void SystemCoreClockUpdate (void);
61 |
62 | #ifdef __cplusplus
63 | }
64 | #endif
65 |
66 | #endif /* SYSTEM_ARMCM3_H */
67 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | Contributing
2 | ============
3 |
4 | We appreciate your contributions! Because this is an open source project, we want to keep it as easy
5 | as possible to contribute changes. However, we need contributors to follow a few guidelines.
6 |
7 | By contributing to this project you agree to the [Code of Conduct](CODE_OF_CONDUCT.md).
8 |
9 |
10 | ## Process
11 |
12 | Before you submit your changes, please ensure that:
13 |
14 | - You have added your copyright below existing copyrights in the files you modified. New files should have only
15 | your copyright. See the License section below for more.
16 | - Changes have been tested locally to the extent possible.
17 |
18 | Please create a pull request in GitHub with your contribution. Changes must pass all required pull request checks
19 | on GitHub before they can be accepted.
20 |
21 |
22 | ## License
23 |
24 | By creating a pull request on GitHub, you agree to the [Developer Certificate of
25 | Origin](https://developercertificate.org), stating that you have the right to grant license to your contribution under
26 | the Apache 2.0 license.
27 |
28 | Copyright on contributions is retained by their author(s). Please add the author(s) copyright below existing copyrights
29 | in the license header at the top of the contributed source file(s). If you are doing the work for your employer, you
30 | should use your employer's copyright. If a file is newly added by you, it must contain the standard license header with
31 | your copyright. Please note that we do not list changes in each source file by copyright owner, as this becomes a burden
32 | to maintain.
33 |
34 | Contributing source code that is already licensed using a license other than Apache 2.0 is possible, but each
35 | case must be considered individually. If you are the owner of the source code, then you have the right to
36 | relicense to Apache 2.0. The most important thing is that the license is compatible with Apache 2.0. Examples
37 | are MIT, the BSD licenses, and similar. GPL-licensed code is expressly disallowed to be contributed, as the
38 | GPL is not compatible with Apache 2.0 (or any of the Apache-compatible licenses).
39 |
40 |
41 |
--------------------------------------------------------------------------------
/scripts/templates/c_blob_mbed.tmpl:
--------------------------------------------------------------------------------
1 | /* mbed Microcontroller Library
2 | * Copyright (c) 2017 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "flash_api.h"
18 | #include "flash_data.h"
19 | #include "critical.h"
20 |
21 | // This file is automagically generated
22 |
23 | #if DEVICE_FLASH
24 |
25 | // This is a flash algo binary blob. It is PIC (position independent code) that should be stored in RAM
26 | static uint32_t FLASH_ALGO[] = {
27 | {{algo.format_algo_data(4, 8, "c")}}
28 | };
29 |
30 | static const flash_algo_t flash_algo_config = {
31 | .init = {{'0x%x' % algo.symbols['Init']}},
32 | .uninit = {{'0x%x' % algo.symbols['UnInit']}},
33 | .erase_sector = {{'0x%x' % algo.symbols['EraseSector']}},
34 | .program_page = {{'0x%x' % algo.symbols['ProgramPage']}},
35 | .static_base = {{'0x%x' % algo.rw_start}},
36 | .algo_blob = FLASH_ALGO
37 | };
38 |
39 | static const sector_info_t sectors_info[] = {
40 | {%- for start, size in algo.sector_sizes %}
41 | {{ "{0x%x, 0x%x}" % (start + algo.flash_start, size) }},
42 | {%- endfor %}
43 | };
44 |
45 | static const flash_target_config_t flash_target_config = {
46 | .page_size = {{'0x%x' % algo.page_size}},
47 | .flash_start = {{'0x%x' % algo.flash_start}},
48 | .flash_size = {{'0x%x' % algo.flash_size}},
49 | .sectors = sectors_info,
50 | .sector_info_count = sizeof(sectors_info) / sizeof(sector_info_t)
51 | };
52 |
53 | void flash_set_target_config(flash_t *obj)
54 | {
55 | obj->flash_algo = &flash_algo_config;
56 | obj->target_config = &flash_target_config;
57 | }
58 |
59 | #endif
60 |
--------------------------------------------------------------------------------
/source/nxp/lpc4088_512kb_spifi/rom_drivers.h:
--------------------------------------------------------------------------------
1 | /* Definitions for ROM API for SPIFI in NXP MCUs
2 | * Copyright (c) 2010 NXP Semiconductors
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #ifndef ROM_DRIVERS_H_
18 | #define ROM_DRIVERS_H_
19 |
20 | #ifdef DIVROMD_PRESENT
21 | #include "divfuncs.h"
22 |
23 | typedef struct _DIVD {
24 | int32_t (*sdiv) (int32_t, int32_t);
25 | uint32_t (*udiv) (int32_t, int32_t);
26 | sdiv_t (*sdivmod) (int32_t, int32_t);
27 | udiv_t (*udivmod) (uint32_t, uint32_t);
28 | } DIVD;
29 | #endif /* DIVROMD_PRESENT */
30 |
31 | #ifdef PWRROMD_PRESENT
32 | #include "power_control.h"
33 | #endif /* PWRROMD_PRESENT */
34 |
35 | #ifdef USBROMD_PRESENT
36 | #include "mw_usbd_rom_api.h"
37 | #endif
38 |
39 | #ifdef SPIFIROMD_PRESENT
40 | #include "spifi_rom_api.h"
41 | extern const SPIFI_RTNS spifi_table;
42 | #endif
43 |
44 | typedef struct _ROM {
45 | #ifdef USBROMD_PRESENT
46 | const USBD_API_T * pUSBD;
47 | #else
48 | const unsigned p_usbd;
49 | #endif /* USBROMD_PRESENT */
50 |
51 | const unsigned p_clib;
52 | const unsigned p_cand;
53 |
54 | #ifdef PWRROMD_PRESENT
55 | const PWRD * pPWRD;
56 | #else
57 | const unsigned p_pwrd;
58 | #endif /* PWRROMD_PRESENT */
59 |
60 | #ifdef DIVROMD_PRESENT
61 | const DIVD * pDIVD;
62 | #else
63 | const unsigned p_promd;
64 | #endif /* DIVROMD_PRESENT */
65 |
66 | #ifdef SPIFIROMD_PRESENT
67 | const SPIFI_RTNS *pSPIFID;
68 | #else
69 | const unsigned p_spifid;
70 | #endif /*SPIFIROMD_PRESENT */
71 |
72 | const unsigned p_dev3;
73 | const unsigned p_dev4;
74 | } ROM;
75 |
76 | #endif /*ROM_DRIVERS_H_*/
77 |
--------------------------------------------------------------------------------
/source/nxp/spifi/FlashDev.h:
--------------------------------------------------------------------------------
1 | /* CMSIS-DAP Interface Firmware
2 | * Copyright (c) 2009-2013 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 | #ifndef FLASHDEV_H
17 | #define FLASHDEV_H
18 |
19 | // SPIFI Interfaces
20 | #if defined(LPC1800_SPIFI)
21 | // LPC18xx/LPC43xx SPIFI devices start at 0x14000000 or 0x80000000
22 | #define FLASH_START 0x14000000
23 | // Buffer to save sector contents on partial sector writes
24 | // Up to 72K on LPC4330/LPC4350, 40K on other LPC18xx/LPC43xx
25 | #define SECTOR_BUF ((char *)0x10080000)
26 | #else
27 | #error "Interface not implemented"
28 | #endif
29 |
30 | // SPIFI Devices
31 | // Use default for mbed HDK - Geometry defined in flash programmer
32 | #if defined(SPIFI_4M_64K)
33 | // SPIFI_4M_64K - 4MB flash, 64 x 64KB sectors (Spansion S25FL032P or equiv)
34 | #warning "SPIFI driver requires 64KB buffer"
35 | #define FLASH_DEV_NAME "LPC18xx/43xx SPIFI 4M/64K"
36 | #define FLASH_DEV_SIZE (4 * 1024 * 1024) // 4 MB
37 | #define FLASH_SECTOR_SIZE (64 * 1024)
38 | #elif defined(SPIFI_8M_4K)
39 | // SPIFI_8M_4K - 8MB flash, 2048 x 4KB sectors (Winbond W25Q64FV or equiv)
40 | #define FLASH_DEV_NAME "LPC18xx/43xx SPIFI 8M/4K"
41 | #define FLASH_DEV_SIZE (8 * 1024 * 1024) // 8 MB
42 | #define FLASH_SECTOR_SIZE (4 * 1024)
43 | #else // default
44 | // SPIFI_4M_4K - 4MB flash, 1024 x 4KB sectors (Winbond W25Q32FV or equiv)
45 | #define FLASH_DEV_NAME "LPC18xx/43xx SPIFI 4M/4K"
46 | #define FLASH_DEV_SIZE (4 * 1024 * 1024) // 4 MB
47 | #define FLASH_SECTOR_SIZE (4 * 1024)
48 | #endif
49 |
50 | #endif
51 |
--------------------------------------------------------------------------------
/source/nxp/lpc8xx_32kb/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* -----------------------------------------------------------------------------
2 | * Copyright (c) 2004 - 2014 ARM Ltd.
3 | *
4 | * This software is provided 'as-is', without any express or implied warranty.
5 | * In no event will the authors be held liable for any damages arising from
6 | * the use of this software. Permission is granted to anyone to use this
7 | * software for any purpose, including commercial applications, and to alter
8 | * it and redistribute it freely, subject to the following restrictions:
9 | *
10 | * 1. The origin of this software must not be misrepresented; you must not
11 | * claim that you wrote the original software. If you use this software in
12 | * a product, an acknowledgment in the product documentation would be
13 | * appreciated but is not required.
14 | *
15 | * 2. Altered source versions must be plainly marked as such, and must not be
16 | * misrepresented as being the original software.
17 | *
18 | * 3. This notice may not be removed or altered from any source distribution.
19 | *
20 | *
21 | * $Date: 20. August 2014
22 | * $Revision: V1.00
23 | *
24 | * Project: Flash Device Description for NXP LPC8xx Flash using IAP
25 | * --------------------------------------------------------------------------- */
26 |
27 | #include "FlashOS.h" // FlashOS Structures
28 |
29 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
30 |
31 | struct FlashDevice const FlashDevice = {
32 | FLASH_DRV_VERS, // Driver Version, do not modify!
33 | "LPC8xx IAP 32kB Flash", // Device Name
34 | ONCHIP, // Device Type
35 | 0x00000000, // Device Start Address
36 | 0x00008000, // Device Size (32kB)
37 | 256, // Programming Page Size
38 | 0, // Reserved, must be 0
39 | 0xFF, // Initial Content of Erased Memory
40 | 300, // Program Page Timeout 300 mSec
41 | 3000, // Erase Sector Timeout 3000 mSec
42 |
43 | // Specify Size and Address of Sectors
44 | 0x000400, 0x000000, // Sector Size 1kB (32 Sectors)
45 | SECTOR_END
46 | };
47 |
--------------------------------------------------------------------------------
/source/template/FlashPrg.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashPrg.c */
18 |
19 | #include "FlashOS.h"
20 | #include "FlashPrg.h"
21 |
22 | uint32_t Init(uint32_t adr, uint32_t clk, uint32_t fnc)
23 | {
24 | // Called to configure the SoC. Should enable clocks
25 | // watchdogs, peripherals and anything else needed to
26 | // access or program memory. Fnc parameter has meaning
27 | // but currently isnt used in MSC programming routines
28 | return 1;
29 | }
30 |
31 | uint32_t UnInit(uint32_t fnc)
32 | {
33 | // When a session is complete this is called to powerdown
34 | // communication channels and clocks that were enabled
35 | // Fnc parameter has meaning but isnt used in MSC program
36 | // routines
37 | return 1;
38 | }
39 |
40 | uint32_t BlankCheck(uint32_t adr, uint32_t sz, uint8_t pat)
41 | {
42 | // Check that the memory at address adr for length sz is
43 | // empty or the same as pat
44 | return 1;
45 | }
46 |
47 | uint32_t EraseChip(void)
48 | {
49 | // Execute a sequence that erases the entire of flash memory region
50 | return 1;
51 | }
52 |
53 | uint32_t EraseSector(uint32_t adr)
54 | {
55 | // Execute a sequence that erases the sector that adr resides in
56 | return 1;
57 | }
58 |
59 | uint32_t ProgramPage(uint32_t adr, uint32_t sz, uint32_t *buf)
60 | {
61 | // Program the contents of buf starting at adr for length of sz
62 | return 1;
63 | }
64 |
65 | uint32_t Verify(uint32_t adr, uint32_t sz, uint32_t *buf)
66 | {
67 | // Given an adr and sz compare this against the content of buf
68 | return 1;
69 | }
70 |
--------------------------------------------------------------------------------
/scripts/templates/py_blob_orig.tmpl:
--------------------------------------------------------------------------------
1 | """
2 | Flash OS Routines (Automagically Generated)
3 | Copyright (c) 2017-2018 ARM Limited
4 |
5 | Licensed under the Apache License, Version 2.0 (the "License");
6 | you may not use this file except in compliance with the License.
7 | You may obtain a copy of the License at
8 |
9 | http://www.apache.org/licenses/LICENSE-2.0
10 |
11 | Unless required by applicable law or agreed to in writing, software
12 | distributed under the License is distributed on an "AS IS" BASIS,
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | See the License for the specific language governing permissions and
15 | limitations under the License.
16 | """
17 |
18 | flash_algo = {
19 | 'load_address' : {{'0x%08x' % entry}},
20 |
21 | # Flash algorithm as a hex string
22 | 'instructions': [
23 | {{prog_header}}
24 | {{algo.format_algo_data(4, 8, "c")}}
25 | ],
26 |
27 | # Relative function addresses
28 | 'pc_init': {{'0x%08x' % (algo.symbols['Init'] + header_size + entry)}},
29 | 'pc_unInit': {{'0x%08x' % (algo.symbols['UnInit'] + header_size + entry)}},
30 | 'pc_program_page': {{'0x%08x' % (algo.symbols['ProgramPage'] + header_size + entry)}},
31 | 'pc_erase_sector': {{'0x%08x' % (algo.symbols['EraseSector'] + header_size + entry)}},
32 | 'pc_eraseAll': {{'0x%08x' % (algo.symbols['EraseChip'] + header_size + entry)}},
33 |
34 | 'static_base' : {{'0x%08x' % entry}} + {{'0x%08x' % header_size}} + {{'0x%08x' % algo.rw_start}},
35 | 'begin_stack' : {{'0x%08x' % stack_pointer}},
36 | 'begin_data' : {{'0x%08x' % entry}} + 0x1000,
37 | 'page_size' : {{'0x%x' % algo.page_size}},
38 | 'analyzer_supported' : False,
39 | 'analyzer_address' : 0x00000000,
40 | 'page_buffers' : [{{'0x%08x' % (entry + 4096)}}, {{'0x%08x' % (entry + 4096 + algo.page_size)}}], # Enable double buffering
41 | 'min_program_length' : {{'0x%x' % algo.page_size}},
42 |
43 | # Flash information
44 | 'flash_start': {{'0x%x' % algo.flash_start}},
45 | 'flash_size': {{'0x%x' % algo.flash_size}},
46 | 'sector_sizes': (
47 | {%- for start, size in algo.sector_sizes %}
48 | {{ "(0x%x, 0x%x)" % (start, size) }},
49 | {%- endfor %}
50 | )
51 | }
52 |
53 |
--------------------------------------------------------------------------------
/source/st/STM32WB55RC/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* -----------------------------------------------------------------------------
2 | * Copyright (c) 2021 ZeUGMA.
3 | *
4 | * This software is provided 'as-is', without any express or implied warranty.
5 | * In no event will the authors be held liable for any damages arising from
6 | * the use of this software. Permission is granted to anyone to use this
7 | * software for any purpose, including commercial applications, and to alter
8 | * it and redistribute it freely, subject to the following restrictions:
9 | *
10 | * 1. The origin of this software must not be misrepresented; you must not
11 | * claim that you wrote the original software. If you use this software in
12 | * a product, an acknowledgment in the product documentation would be
13 | * appreciated but is not required.
14 | *
15 | * 2. Altered source versions must be plainly marked as such, and must not be
16 | * misrepresented as being the original software.
17 | *
18 | * 3. This notice may not be removed or altered from any source distribution.
19 | *
20 | *
21 | * $Date: 16/06/2021
22 | * $Revision: V1.00
23 | *
24 | * Project: Flash Programming Functions for STMicroelectronics STM32WB55xx Flash
25 | * --------------------------------------------------------------------------- */
26 |
27 | /* History:
28 | * Version 1.00
29 | * Initial release
30 | */
31 |
32 |
33 | #include "FlashOS.h" // FlashOS Structures
34 |
35 | #ifdef STM32WB55xx
36 | struct FlashDevice const FlashDevice = {
37 | FLASH_DRV_VERS, // Driver Version, do not modify!
38 | "STM32WB55RC 256kB Flash", // Device Name (256 kB)
39 | ONCHIP, // Device Type
40 | 0x08000000, // Device Start Address
41 | 0x00040000, // Device Size in Bytes (256 kB)
42 | 4096, // Programming Page Size
43 | 0, // Reserved, must be 0
44 | 0xFF, // Initial Content of Erased Memory
45 | 100, // Program Page Timeout 100 mSec
46 | 6000, // Erase Sector Timeout 6000 mSec
47 |
48 | // Specify Size and Address of Sectors
49 | {
50 | {0x01000, 0x000000}, // Sector Size 4kB (256 Sectors)
51 | {SECTOR_END}
52 | }
53 | };
54 | #endif
--------------------------------------------------------------------------------
/source/st/STM32WB55RG/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* -----------------------------------------------------------------------------
2 | * Copyright (c) 2021 ZeUGMA.
3 | *
4 | * This software is provided 'as-is', without any express or implied warranty.
5 | * In no event will the authors be held liable for any damages arising from
6 | * the use of this software. Permission is granted to anyone to use this
7 | * software for any purpose, including commercial applications, and to alter
8 | * it and redistribute it freely, subject to the following restrictions:
9 | *
10 | * 1. The origin of this software must not be misrepresented; you must not
11 | * claim that you wrote the original software. If you use this software in
12 | * a product, an acknowledgment in the product documentation would be
13 | * appreciated but is not required.
14 | *
15 | * 2. Altered source versions must be plainly marked as such, and must not be
16 | * misrepresented as being the original software.
17 | *
18 | * 3. This notice may not be removed or altered from any source distribution.
19 | *
20 | *
21 | * $Date: 16/06/2021
22 | * $Revision: V1.00
23 | *
24 | * Project: Flash Programming Functions for STMicroelectronics STM32WB55xx Flash
25 | * --------------------------------------------------------------------------- */
26 |
27 | /* History:
28 | * Version 1.00
29 | * Initial release
30 | */
31 |
32 |
33 | #include "FlashOS.h" // FlashOS Structures
34 |
35 | #ifdef STM32WB55xx
36 | struct FlashDevice const FlashDevice = {
37 | FLASH_DRV_VERS, // Driver Version, do not modify!
38 | "STM32WB55RG 1024kB Flash", // Device Name (1024 kB)
39 | ONCHIP, // Device Type
40 | 0x08000000, // Device Start Address
41 | 0x00100000, // Device Size in Bytes (1024 kB)
42 | 4096, // Programming Page Size -- maybe 256 by default ? --
43 | 0, // Reserved, must be 0
44 | 0xFF, // Initial Content of Erased Memory
45 | 100, // Program Page Timeout 100 mSec
46 | 6000, // Erase Sector Timeout 6000 mSec
47 |
48 | // Specify Size and Address of Sectors
49 | {
50 | {0x01000, 0x000000}, // Sector Size 4kB (256 Sectors)
51 | {SECTOR_END}
52 | }
53 | };
54 | #endif
--------------------------------------------------------------------------------
/source/st/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* -----------------------------------------------------------------------------
2 | * Copyright (c) 2014 ARM Ltd.
3 | *
4 | * This software is provided 'as-is', without any express or implied warranty.
5 | * In no event will the authors be held liable for any damages arising from
6 | * the use of this software. Permission is granted to anyone to use this
7 | * software for any purpose, including commercial applications, and to alter
8 | * it and redistribute it freely, subject to the following restrictions:
9 | *
10 | * 1. The origin of this software must not be misrepresented; you must not
11 | * claim that you wrote the original software. If you use this software in
12 | * a product, an acknowledgment in the product documentation would be
13 | * appreciated but is not required.
14 | *
15 | * 2. Altered source versions must be plainly marked as such, and must not be
16 | * misrepresented as being the original software.
17 | *
18 | * 3. This notice may not be removed or altered from any source distribution.
19 | *
20 | *
21 | * $Date: 15. April 2014
22 | * $Revision: V1.00
23 | *
24 | * Project: Flash Device Description for ST Microelectronics STM32L15x Flash
25 | * --------------------------------------------------------------------------- */
26 |
27 | /* History:
28 | * Version 1.00
29 | * Initial release
30 | */
31 |
32 | #include "FlashOS.h" // FlashOS Structures
33 |
34 | #define FLASH_DRV_VERS (0x0100+VERS) // Driver Version, do not modify!
35 | #define DEVICE_NAME "STM32L151 256kB Flash"
36 |
37 | struct FlashDevice const FlashDevice = {
38 | FLASH_DRV_VERS, // Driver Version, do not modify!
39 | DEVICE_NAME, // Device Name (128 chars max)
40 | ONCHIP, // Device Type
41 | 0x08000000, // Device Start Address
42 | 0x00040000, // Device Size (256kB)
43 | 0x00000100, // Programming Page Size (256 bytes)
44 | 0x00000000, // Reserved, must be 0
45 | 0x00, // Initial Content of Erased Memory
46 | 0x00000064, // Program Page Timeout 100 mSec
47 | 0x00000BB8, // Erase Sector Timeout 3000 mSec
48 | {{0x00000100, 0x00000000}, // Sector Size {256 bytes, starting at address 0}
49 | {SECTOR_END}}
50 | };
51 |
52 |
--------------------------------------------------------------------------------
/source/st/STM32L475/FlashDev.c:
--------------------------------------------------------------------------------
1 | /* -----------------------------------------------------------------------------
2 | * Copyright (c) 2014 ARM Ltd.
3 | *
4 | * This software is provided 'as-is', without any express or implied warranty.
5 | * In no event will the authors be held liable for any damages arising from
6 | * the use of this software. Permission is granted to anyone to use this
7 | * software for any purpose, including commercial applications, and to alter
8 | * it and redistribute it freely, subject to the following restrictions:
9 | *
10 | * 1. The origin of this software must not be misrepresented; you must not
11 | * claim that you wrote the original software. If you use this software in
12 | * a product, an acknowledgment in the product documentation would be
13 | * appreciated but is not required.
14 | *
15 | * 2. Altered source versions must be plainly marked as such, and must not be
16 | * misrepresented as being the original software.
17 | *
18 | * 3. This notice may not be removed or altered from any source distribution.
19 | *
20 | *
21 | * $Date: 15. April 2014
22 | * $Revision: V2.00
23 | *
24 | * Project: Flash Programming Functions for STMicroelectronics STM32F4xx Flash
25 | * --------------------------------------------------------------------------- */
26 |
27 | /* History:
28 | * Version 1.00
29 | * Initial release
30 | *
31 | * Version 2.00 - 18/06/2021
32 | * This file has been modified to be compatible with the STM32L475, by Jonathan BAUDIN - ZeUGMA
33 | */
34 |
35 | #include "FlashOS.h" // FlashOS Structures
36 |
37 | #ifdef STM32L475VG
38 | struct FlashDevice const FlashDevice = {
39 | FLASH_DRV_VERS, // Driver Version, do not modify!
40 | "STM32L475VG 1024 kB Flash", // Device Name (1024 kB)
41 | ONCHIP, // Device Type
42 | 0x08000000, // Device Start Address
43 | 0x00100000, // Device Size in Bytes (1024 kB)
44 | 2048, // Programming Page Size
45 | 0, // Reserved, must be 0
46 | 0xFF, // Initial Content of Erased Memory
47 | 100, // Program Page Timeout 100 mSec
48 | 6000, // Erase Sector Timeout 6000 mSec
49 |
50 | // Specify Size and Address of Sectors
51 | {
52 | {0x00800, 0x000000}, // Sector Size 2kB (512 Sectors)
53 | {SECTOR_END}
54 | }
55 | };
56 | #endif
--------------------------------------------------------------------------------
/source/freescale/devices/MKW01Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW01Z128CHN4))
40 |
41 | #define KW01Z4_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW01Z4.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW01Z4_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW22D5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW22D512VHA5))
40 |
41 | #define KW22D5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW22D5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW22D5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW24D5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW24D512VHA5))
40 |
41 | #define KW24D5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW24D5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW24D5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW30Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW30Z160VHM4))
40 |
41 | #define KW30Z4_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW30Z4.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW30Z4_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW40Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW40Z160VHT4))
40 |
41 | #define KW40Z4_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW40Z4.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW40Z4_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK24F25612/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK24FN256VDC12))
40 |
41 | #define K24F25612_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MK24F25612.h"
45 | /* CPU specific feature definitions */
46 | #include "MK24F25612_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/nxp/lpc54608/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * Copyright 2016 - 2017 NXP
4 | * Redistribution and use in source and binary forms, with or without modification,
5 | * are permitted provided that the following conditions are met:
6 | *
7 | * o Redistributions of source code must retain the above copyright notice, this list
8 | * of conditions and the following disclaimer.
9 | *
10 | * o Redistributions in binary form must reproduce the above copyright notice, this
11 | * list of conditions and the following disclaimer in the documentation and/or
12 | * other materials provided with the distribution.
13 | *
14 | * o Neither the name of the copyright holder nor the names of its
15 | * contributors may be used to endorse or promote products derived from this
16 | * software without specific prior written permission.
17 | *
18 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
19 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
20 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
22 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
25 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
27 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 | *
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_LPC54608J512BD208) || defined(CPU_LPC54608J512ET180))
40 |
41 | #define LPC54608_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "LPC54608.h"
45 | /* CPU specific feature definitions */
46 | #include "LPC54608_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK70F12/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK70FN1M0VMJ12) || defined(CPU_MK70FX512VMJ12))
40 |
41 | #define K70F12_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MK70F12.h"
45 | /* CPU specific feature definitions */
46 | #include "MK70F12_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL28Z7/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL28Z512VDC7) || defined(CPU_MKL28Z512VLL7))
40 |
41 | #define KL28Z7_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKL28Z7.h"
45 | /* CPU specific feature definitions */
46 | #include "MKL28Z7_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKM14ZA5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKM14Z128AHH5) || defined(CPU_MKM14Z64AHH5))
40 |
41 | #define KM14ZA5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKM14ZA5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKM14ZA5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKM34ZA5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKM34Z128AHH5) || defined(CPU_MKM34Z64AHH5))
40 |
41 | #define KM34ZA5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKM34ZA5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKM34ZA5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW21D5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW21D256VHA5) || defined(CPU_MKW21D512VHA5))
40 |
41 | #define KW21D5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW21D5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW21D5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKW41Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKW41Z256VHT4) || defined(CPU_MKW41Z512VHT4))
40 |
41 | #define KW41Z4_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKW41Z4.h"
45 | /* CPU specific feature definitions */
46 | #include "MKW41Z4_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV31F12810/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV31F128VLH10) || defined(CPU_MKV31F128VLL10))
40 |
41 | #define KV31F12810_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKV31F12810.h"
45 | /* CPU specific feature definitions */
46 | #include "MKV31F12810_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV31F25612/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV31F256VLH12) || defined(CPU_MKV31F256VLL12))
40 |
41 | #define KV31F25612_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKV31F25612.h"
45 | /* CPU specific feature definitions */
46 | #include "MKV31F25612_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV31F51212/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV31F512VLH12) || defined(CPU_MKV31F512VLL12))
40 |
41 | #define KV31F51212_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKV31F51212.h"
45 | /* CPU specific feature definitions */
46 | #include "MKV31F51212_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKM33ZA5/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKM33Z128ALH5) || defined(CPU_MKM33Z128ALL5) || defined(CPU_MKM33Z64ALH5) || defined(CPU_MKM33Z64ALL5))
40 |
41 | #define KM33ZA5_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "MKM33ZA5.h"
45 | /* CPU specific feature definitions */
46 | #include "MKM33ZA5_features.h"
47 |
48 | #else
49 | #error "No valid CPU defined!"
50 | #endif
51 |
52 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
53 |
54 | /*******************************************************************************
55 | * EOF
56 | ******************************************************************************/
57 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKE15Z7/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKE15Z128VLH7) || defined(CPU_MKE15Z128VLL7) || defined(CPU_MKE15Z256VLH7) || \
40 | defined(CPU_MKE15Z256VLL7))
41 |
42 | #define KE15Z7_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MKE15Z7.h"
46 | /* CPU specific feature definitions */
47 | #include "MKE15Z7_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL43Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL43Z128VLH4) || defined(CPU_MKL43Z256VLH4) || defined(CPU_MKL43Z128VMP4) || \
40 | defined(CPU_MKL43Z256VMP4))
41 |
42 | #define KL43Z4_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MKL43Z4.h"
46 | /* CPU specific feature definitions */
47 | #include "MKL43Z4_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK65F18/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK65FN2M0CAC18) || defined(CPU_MK65FX1M0CAC18) || defined(CPU_MK65FN2M0VMI18) || \
40 | defined(CPU_MK65FX1M0VMI18))
41 |
42 | #define K65F18_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MK65F18.h"
46 | /* CPU specific feature definitions */
47 | #include "MK65F18_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK66F18/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK66FN2M0VLQ18) || defined(CPU_MK66FX1M0VLQ18) || defined(CPU_MK66FN2M0VMD18) || \
40 | defined(CPU_MK66FX1M0VMD18))
41 |
42 | #define K66F18_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MK66F18.h"
46 | /* CPU specific feature definitions */
47 | #include "MK66F18_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKE18F16/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKE18F256VLH16) || defined(CPU_MKE18F256VLL16) || defined(CPU_MKE18F512VLH16) || \
40 | defined(CPU_MKE18F512VLL16))
41 |
42 | #define KE18F16_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MKE18F16.h"
46 | /* CPU specific feature definitions */
47 | #include "MKE18F16_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK80F25615/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK80FN256CAx15) || defined(CPU_MK80FN256VDC15) || defined(CPU_MK80FN256VLL15) || \
40 | defined(CPU_MK80FN256VLQ15))
41 |
42 | #define K80F25615_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MK80F25615.h"
46 | /* CPU specific feature definitions */
47 | #include "MK80F25615_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/wiznet/W7500/FlashPrg.c:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | #include "FlashOS.h"
18 |
19 | #define IAP_ENTRY 0x1FFF1001
20 |
21 | #define IAP_ERAS 0x010
22 | #define IAP_ERAS_DAT0 (IAP_ERAS + 0)
23 | #define IAP_ERAS_DAT1 (IAP_ERAS + 1)
24 | #define IAP_ERAS_SECT (IAP_ERAS + 2)
25 | #define IAP_ERAS_BLCK (IAP_ERAS + 3)
26 | #define IAP_ERAS_CHIP (IAP_ERAS + 4)
27 | #define IAP_ERAS_MASS (IAP_ERAS + 5)
28 |
29 | #define IAP_PROG 0x020
30 | #define IAP_PROG_DAT0 (IAP_PROG + 0)
31 | #define IAP_PROG_DAT1 (IAP_PROG + 1)
32 | #define IAP_PROG_CODE (IAP_PROG + 2)
33 |
34 | void DO_IAP(unsigned long id, unsigned long dst_addr, unsigned char* src_addr, unsigned long size)
35 | {
36 | (*((volatile uint32_t *)(0xE000ED04))) = 0x00000000; // ICSR(Interrupt Control and State Register) of SCB(SystemControlBlock)
37 | (*((volatile uint32_t *)(0xE000E180))) = 0xffffffff; // ICER(Interrupt Clear-enable Register) of NVIC(Nested Vectored Interrupt Controller)
38 | (*((volatile uint32_t *)(0xE000E010))) &= ~(0x01); // SYST_CSR ( SystTick Control and Status Register)
39 |
40 | ((void(*)(unsigned long,unsigned long,unsigned char*,unsigned long))IAP_ENTRY)(id,dst_addr,src_addr,size);
41 | }
42 |
43 | int Init (unsigned long adr, unsigned long clk, unsigned long fnc)
44 | {
45 | return(0);
46 | }
47 |
48 | int UnInit (unsigned long fnc)
49 | {
50 | return (0);
51 | }
52 |
53 | int EraseChip (void)
54 | {
55 | DO_IAP(IAP_ERAS_CHIP,0,0,0);
56 | return (0); // Finished without Errors
57 | }
58 |
59 | int EraseSector (unsigned long adr)
60 | {
61 | DO_IAP(IAP_ERAS_SECT,adr,0,0);
62 |
63 | return (0); // Finished without Errors
64 | }
65 |
66 | int ProgramPage (unsigned long adr, unsigned long sz, unsigned char *buf)
67 | {
68 | DO_IAP(IAP_PROG_CODE,adr,(unsigned char*)buf,sz);
69 |
70 | return (0); // Finished without Errors
71 | }
72 |
73 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK22F51212/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK22FN512CAP12) || defined(CPU_MK22FN512VDC12) || defined(CPU_MK22FN512VLH12) || \
40 | defined(CPU_MK22FN512VLL12) || defined(CPU_MK22FN512VMP12))
41 |
42 | #define K22F51212_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MK22F51212.h"
46 | /* CPU specific feature definitions */
47 | #include "MK22F51212_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV10Z7/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV10Z16VFM7) || defined(CPU_MKV10Z16VLC7) || defined(CPU_MKV10Z16VLF7) || \
40 | defined(CPU_MKV10Z32VFM7) || defined(CPU_MKV10Z32VLC7) || defined(CPU_MKV10Z32VLF7))
41 |
42 | #define KV10Z7_SERIES
43 |
44 | /* CMSIS-style register definitions */
45 | #include "MKV10Z7.h"
46 | /* CPU specific feature definitions */
47 | #include "MKV10Z7_features.h"
48 |
49 | #else
50 | #error "No valid CPU defined!"
51 | #endif
52 |
53 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
54 |
55 | /*******************************************************************************
56 | * EOF
57 | ******************************************************************************/
58 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL46Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL46Z128VLH4) || defined(CPU_MKL46Z256VLH4) || defined(CPU_MKL46Z128VLL4) || \
40 | defined(CPU_MKL46Z256VLL4) || defined(CPU_MKL46Z128VMC4) || defined(CPU_MKL46Z256VMC4) || \
41 | defined(CPU_MKL46Z256VMP4))
42 |
43 | #define KL46Z4_SERIES
44 |
45 | /* CMSIS-style register definitions */
46 | #include "MKL46Z4.h"
47 | /* CPU specific feature definitions */
48 | #include "MKL46Z4_features.h"
49 |
50 | #else
51 | #error "No valid CPU defined!"
52 | #endif
53 |
54 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
55 |
56 | /*******************************************************************************
57 | * EOF
58 | ******************************************************************************/
59 |
--------------------------------------------------------------------------------
/source/FlashOS.h:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashOS.h */
18 |
19 | #ifndef FLASHOS_H
20 | #define FLASHOS_H
21 |
22 | #include "stdint.h"
23 |
24 | #ifdef __cplusplus
25 | extern "C" {
26 | #endif
27 |
28 | #define VERS 1 // Interface Version 1.01
29 | #define NAME_MAX 128 // Max size of the routine name
30 | #define PAGE_MAX 65536 // Max Page Size for Programming
31 | #define SECTOR_NUM 512 // Max Number of Sector Items
32 | #define SECTOR_END 0xFFFFFFFF, 0xFFFFFFFF
33 |
34 | // FlashDevice.devType interface mechanism
35 | #define UNKNOWN 0
36 | #define ONCHIP 1
37 | #define EXT8BIT 2
38 | #define EXT16BIT 3
39 | #define EXT32BIT 4
40 | #define EXTSPI 5
41 |
42 | /**
43 | @struct FlashSector
44 | @brief A structure to describe the size and start address of a flash sector
45 | */
46 | struct FlashSector {
47 | uint32_t szSector; /*!< Sector Size in Bytes */
48 | uint32_t adrSector; /*!< Address of Sector */
49 | };
50 |
51 | /**
52 | @struct FlashDevice
53 | @brief A structure to describe particulars of a flash memory sub-system
54 | and requirements of the driver
55 | */
56 | struct FlashDevice {
57 | uint16_t vers; /*!< Version Number and Architecture */
58 | char devName[NAME_MAX]; /*!< Device Name and Description */
59 | uint16_t devType; /*!< Device Type: ONCHIP, EXT8BIT, EXT16BIT, ... */
60 | uint32_t devAdr; /*!< Default Device Start Address */
61 | uint32_t szDev; /*!< Total Size of Device */
62 | uint32_t szPage; /*!< Programming Page Size */
63 | uint32_t res; /*!< Reserved for future Extension */
64 | uint8_t valEmpty; /*!< Content of Erased Memory */
65 | uint32_t toProg; /*!< Time Out of Program Page Function */
66 | uint32_t toErase; /*!< Time Out of Erase Sector Function */
67 | struct FlashSector sectors[SECTOR_NUM]; /*!< Entries to describe flash memory layout */
68 | };
69 |
70 | #ifdef __cplusplus
71 | }
72 | #endif
73 |
74 | #endif
75 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL02Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL02Z32CAF4) || defined(CPU_MKL02Z8VFG4) || defined(CPU_MKL02Z16VFG4) || \
40 | defined(CPU_MKL02Z32VFG4) || defined(CPU_MKL02Z16VFK4) || defined(CPU_MKL02Z32VFK4) || \
41 | defined(CPU_MKL02Z16VFM4) || defined(CPU_MKL02Z32VFM4))
42 |
43 | #define KL02Z4_SERIES
44 |
45 | /* CMSIS-style register definitions */
46 | #include "MKL02Z4.h"
47 | /* CPU specific feature definitions */
48 | #include "MKL02Z4_features.h"
49 |
50 | #else
51 | #error "No valid CPU defined!"
52 | #endif
53 |
54 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
55 |
56 | /*******************************************************************************
57 | * EOF
58 | ******************************************************************************/
59 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV11Z7/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV11Z128VLC7) || defined(CPU_MKV11Z128VFM7) || defined(CPU_MKV11Z64VLC7) || \
40 | defined(CPU_MKV11Z64VFM7) || defined(CPU_MKV11Z128VLF7) || defined(CPU_MKV11Z64VLF7) || \
41 | defined(CPU_MKV11Z128VLH7) || defined(CPU_MKV11Z64VLH7))
42 |
43 | #define KV11Z7_SERIES
44 |
45 | /* CMSIS-style register definitions */
46 | #include "MKV11Z7.h"
47 | /* CPU specific feature definitions */
48 | #include "MKV11Z7_features.h"
49 |
50 | #else
51 | #error "No valid CPU defined!"
52 | #endif
53 |
54 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
55 |
56 | /*******************************************************************************
57 | * EOF
58 | ******************************************************************************/
59 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL27Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL27Z128VFM4) || defined(CPU_MKL27Z256VFM4) || defined(CPU_MKL27Z128VFT4) || \
40 | defined(CPU_MKL27Z256VFT4) || defined(CPU_MKL27Z128VLH4) || defined(CPU_MKL27Z256VLH4) || \
41 | defined(CPU_MKL27Z128VMP4) || defined(CPU_MKL27Z256VMP4))
42 |
43 | #define KL27Z4_SERIES
44 |
45 | /* CMSIS-style register definitions */
46 | #include "MKL27Z4.h"
47 | /* CPU specific feature definitions */
48 | #include "MKL27Z4_features.h"
49 |
50 | #else
51 | #error "No valid CPU defined!"
52 | #endif
53 |
54 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
55 |
56 | /*******************************************************************************
57 | * EOF
58 | ******************************************************************************/
59 |
--------------------------------------------------------------------------------
/source/freescale/devices/MK64F12/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MK64FX512VDC12) || defined(CPU_MK64FN1M0VDC12) || defined(CPU_MK64FX512VLL12) || \
40 | defined(CPU_MK64FN1M0VLL12) || defined(CPU_MK64FX512VLQ12) || defined(CPU_MK64FN1M0VLQ12) || \
41 | defined(CPU_MK64FX512VMD12) || defined(CPU_MK64FN1M0VMD12))
42 |
43 | #define K64F12_SERIES
44 |
45 | /* CMSIS-style register definitions */
46 | #include "MK64F12.h"
47 | /* CPU specific feature definitions */
48 | #include "MK64F12_features.h"
49 |
50 | #else
51 | #error "No valid CPU defined!"
52 | #endif
53 |
54 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
55 |
56 | /*******************************************************************************
57 | * EOF
58 | ******************************************************************************/
59 |
--------------------------------------------------------------------------------
/source/onsemi/inc1/flash_map.h:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | * @file flash_map.h
4 | * @author Stef Servaes, Pierre Lebas
5 | * $Rev: 346 $
6 | * $Date: 2012-04-23 14:47:52 +0200 (Mon, 23 Apr 2012) $
7 | * @brief Flash controller HW register map
8 | ******************************************************************************
9 | * @copyright (c) 2012 ON Semiconductor. All rights reserved.
10 | * @internal
11 | * ON Semiconductor is supplying this software for use with ON Semiconductor
12 | * processor based microcontrollers only.
13 | *
14 | * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
15 | * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
16 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
17 | * ON SEMICONDUCTOR SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL,
18 | * INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
19 | * @endinternal
20 | *
21 | * @ingroup FLASH
22 | *
23 | * @details
24 | *
25 | * Flash controller HW register map description
26 | *
27 | *
28 | */
29 |
30 | //#ifdef CM3
31 | #include "system_ARMCM3.h"
32 | #include "core_cm3.h"
33 | //#endif
34 | #ifdef CM0
35 | #include
36 | #include
37 | #endif
38 |
39 | #if defined ( __CC_ARM )
40 | #pragma anon_unions
41 | #endif
42 |
43 | #ifndef FLASH_MAP_H_
44 | #define FLASH_MAP_H_
45 |
46 | typedef struct {
47 | union {
48 | struct {
49 | __I uint32_t FLASH_A_BUSY:1; /**< Busy A */
50 | __I uint32_t FLASH_B_BUSY:1; /**< Busy B */
51 | __I uint32_t FLASH_A_UNLOCK:1; /**< Unlock A */
52 | __I uint32_t FLASH_B_UNLOCK:1; /**< Unlock B */
53 | __I uint32_t FLASH_ERROR:3; /**< Attempt to erase bootloader */
54 | } BITS;
55 | __I uint32_t WORD;
56 | } STATUS;
57 | union {
58 | struct {
59 | __IO uint32_t FLASHB_PD:1;
60 | __IO uint32_t FLASHA_PD:1;
61 | __IO uint32_t REMAP:1;
62 | __IO uint32_t WR_INT_EN:1;
63 | __IO uint32_t ERASE_INT_EN:1;
64 | __IO uint32_t ERROR_INT_EN:1;
65 | __IO uint32_t WRITE_BLOCK:1;
66 | } BITS;
67 | __IO uint32_t WORD;
68 | } CONTROL;
69 | union {
70 | struct {
71 | __IO uint32_t PAGEERASE:1; /**< Erase a single page */
72 | __IO uint32_t MASSERASE:1; /**< MASS Erase */
73 | } BITS;
74 | __IO uint32_t WORD;
75 | } COMMAND;
76 | __IO uint32_t ADDR;
77 | __IO uint32_t UNLOCK1;
78 | __IO uint32_t UNLOCKA;
79 | __IO uint32_t UNLOCKB;
80 | union {
81 | struct {
82 | __I uint32_t INT_PEND:1; // Interrupt pending
83 | __I uint32_t INT_TYPE:3; // Interrupt type
84 | } BITS;
85 | __I uint32_t WORD;
86 | } INT_STATUS;
87 | } FlashReg_t, *FlashReg_pt;
88 |
89 | #endif /* FLASH_MAP_H_ */
90 |
--------------------------------------------------------------------------------
/source/FlashPrg.h:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /** @file FlashPrg.h */
18 |
19 | #ifndef FLASHPRG_H
20 | #define FLASHPRG_H
21 |
22 | #include "stdint.h"
23 |
24 | #ifdef __cplusplus
25 | extern "C" {
26 | #endif
27 |
28 | /** Initialize programming functions
29 | @param adr device base address
30 | @param clk clock frequency (Hz)
31 | @param fnc function code (1 - Erase, 2 - Program, 3 - Verify)
32 | @return 0 on success, an error code otherwise
33 | */
34 | uint32_t Init(uint32_t adr, uint32_t clk, uint32_t fnc);
35 |
36 | /** De-Initialize programming functions [optional]
37 | @param fnc function code (1 - Erase, 2 - Program, 3 - Verify)
38 | @return 0 on success, an error code otherwise
39 | */
40 | uint32_t UnInit(uint32_t fnc);
41 |
42 | /** Check region for erased memory
43 | @param adr address to start from
44 | @param sz the amount of memory to check
45 | @param pat the pattern of erased memory (usually 0xff)
46 | @return 0 on success, an error code otherwise
47 | */
48 | uint32_t BlankCheck(uint32_t adr, uint32_t sz, uint8_t pat);
49 |
50 | /** Perform a full chip erase
51 | @return 0 on success, an error code otherwise
52 | */
53 | uint32_t EraseChip(void);
54 |
55 | /** Erase a single sector of memory
56 | @param adr address of a sector to erase
57 | @return 0 on success, an error code otherwise
58 | */
59 | uint32_t EraseSector(uint32_t adr);
60 |
61 | /** Program data into memory
62 | @param adr address to start programming from
63 | @param sz the amount of data to program
64 | @param buf memory contents to be programmed
65 | @return 0 on success, an error code otherwise
66 | */
67 | uint32_t ProgramPage(uint32_t adr, uint32_t sz, uint32_t *buf);
68 |
69 | /** Verify contents in memory
70 | @param adr start address of the verification
71 | @param sz the amount of data to be verified
72 | @param buf memory contents to be compared against
73 | @return 0 on success, an error code otherwise
74 | */
75 | uint32_t Verify(uint32_t adr, uint32_t sz, uint32_t *buf);
76 |
77 | #ifdef __cplusplus
78 | }
79 | #endif
80 |
81 | #endif
82 |
--------------------------------------------------------------------------------
/source/toshiba/TZ10XX/system_ARMCM4.h:
--------------------------------------------------------------------------------
1 | /**************************************************************************//**
2 | * @file system_ARMCM4.h
3 | * @brief CMSIS Device System Header File for
4 | * ARMCM4 Device Series
5 | * @version V2.00
6 | * @date 18. August 2015
7 | ******************************************************************************/
8 | /* Copyright (c) 2011 - 2015 ARM LIMITED
9 |
10 | All rights reserved.
11 | Redistribution and use in source and binary forms, with or without
12 | modification, are permitted provided that the following conditions are met:
13 | - Redistributions of source code must retain the above copyright
14 | notice, this list of conditions and the following disclaimer.
15 | - Redistributions in binary form must reproduce the above copyright
16 | notice, this list of conditions and the following disclaimer in the
17 | documentation and/or other materials provided with the distribution.
18 | - Neither the name of ARM nor the names of its contributors may be used
19 | to endorse or promote products derived from this software without
20 | specific prior written permission.
21 | *
22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 | ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE
26 | LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
27 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
28 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
29 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
30 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
31 | ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
32 | POSSIBILITY OF SUCH DAMAGE.
33 | ---------------------------------------------------------------------------*/
34 |
35 |
36 | #ifndef SYSTEM_ARMCM4_H
37 | #define SYSTEM_ARMCM4_H
38 |
39 | #ifdef __cplusplus
40 | extern "C" {
41 | #endif
42 |
43 | extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
44 |
45 |
46 | /** @brief Setup the microcontroller system.
47 |
48 | Initialize the System and update the SystemCoreClock variable.
49 | */
50 | extern void SystemInit (void);
51 |
52 |
53 | /** \brief Update SystemCoreClock variable.
54 |
55 | Updates the SystemCoreClock with current core Clock
56 | retrieved from cpu registers.
57 | */
58 | extern void SystemCoreClockUpdate (void);
59 |
60 | #ifdef __cplusplus
61 | }
62 | #endif
63 |
64 | #endif /* SYSTEM_ARMCM4_H */
65 |
--------------------------------------------------------------------------------
/source/siliconlabs/EFM32GG/system_ARMCM3.h:
--------------------------------------------------------------------------------
1 | /**************************************************************************//**
2 | * @file system_ARMCM3.h
3 | * @brief CMSIS Device System Header File for
4 | * ARMCM3 Device Series
5 | * @version V2.00
6 | * @date 18. August 2015
7 | ******************************************************************************/
8 | /* Copyright (c) 2011 - 2015 ARM LIMITED
9 |
10 | All rights reserved.
11 | Redistribution and use in source and binary forms, with or without
12 | modification, are permitted provided that the following conditions are met:
13 | - Redistributions of source code must retain the above copyright
14 | notice, this list of conditions and the following disclaimer.
15 | - Redistributions in binary form must reproduce the above copyright
16 | notice, this list of conditions and the following disclaimer in the
17 | documentation and/or other materials provided with the distribution.
18 | - Neither the name of ARM nor the names of its contributors may be used
19 | to endorse or promote products derived from this software without
20 | specific prior written permission.
21 | *
22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 | ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE
26 | LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
27 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
28 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
29 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
30 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
31 | ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
32 | POSSIBILITY OF SUCH DAMAGE.
33 | ---------------------------------------------------------------------------*/
34 |
35 |
36 | #ifndef SYSTEM_ARMCM3_H
37 | #define SYSTEM_ARMCM3_H
38 |
39 | #ifdef __cplusplus
40 | extern "C" {
41 | #endif
42 |
43 | extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
44 |
45 |
46 | /** @brief Setup the microcontroller system.
47 |
48 | Initialize the System and update the SystemCoreClock variable.
49 | */
50 | extern void SystemInit (void);
51 |
52 |
53 | /** \brief Update SystemCoreClock variable.
54 |
55 | Updates the SystemCoreClock with current core Clock
56 | retrieved from cpu registers.
57 | */
58 | extern void SystemCoreClockUpdate (void);
59 |
60 | #ifdef __cplusplus
61 | }
62 | #endif
63 |
64 | #endif /* SYSTEM_ARMCM3_H */
65 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL27Z644/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL27Z32VDA4) || defined(CPU_MKL27Z64VDA4) || defined(CPU_MKL27Z32VFM4) || \
40 | defined(CPU_MKL27Z64VFM4) || defined(CPU_MKL27Z32VFT4) || defined(CPU_MKL27Z64VFT4) || \
41 | defined(CPU_MKL27Z32VLH4) || defined(CPU_MKL27Z64VLH4) || defined(CPU_MKL27Z32VMP4) || \
42 | defined(CPU_MKL27Z64VMP4))
43 |
44 | #define KL27Z644_SERIES
45 |
46 | /* CMSIS-style register definitions */
47 | #include "MKL27Z644.h"
48 | /* CPU specific feature definitions */
49 | #include "MKL27Z644_features.h"
50 |
51 | #else
52 | #error "No valid CPU defined!"
53 | #endif
54 |
55 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
56 |
57 | /*******************************************************************************
58 | * EOF
59 | ******************************************************************************/
60 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL05Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL05Z8VLC4) || defined(CPU_MKL05Z8VFM4) || defined(CPU_MKL05Z8VFK4) \
40 | || defined(CPU_MKL05Z16VLC4) || defined(CPU_MKL05Z16VFM4) || defined(CPU_MKL05Z16VFK4) \
41 | || defined(CPU_MKL05Z16VLF4) || defined(CPU_MKL05Z32VLC4) || defined(CPU_MKL05Z32VFM4) \
42 | || defined(CPU_MKL05Z32VFK4) || defined(CPU_MKL05Z32VLF4))
43 |
44 | #define KL05Z4_SERIES
45 |
46 | /* CMSIS-style register definitions */
47 | #include "MKL05Z4.h"
48 | /* CPU specific feature definitions */
49 | #include "MKL05Z4_features.h"
50 |
51 | #else
52 | #error "No valid CPU defined!"
53 | #endif
54 |
55 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
56 |
57 | /*******************************************************************************
58 | * EOF
59 | ******************************************************************************/
60 |
--------------------------------------------------------------------------------
/scripts/templates/c_blob.tmpl:
--------------------------------------------------------------------------------
1 | /* Flash OS Routines (Automagically Generated)
2 | * Copyright (c) 2009-2015 ARM Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | static const uint32_t {{name}}_flash_prog_blob[] = {
18 | {{prog_header}}
19 | {{algo.format_algo_data(4, 8, "c")}}
20 | };
21 |
22 | // Start address of flash
23 | static const uint32_t flash_start = {{"0x%08x" % algo.flash_start}};
24 | // Size of flash
25 | static const uint32_t flash_size = {{"0x%08x" % algo.flash_size}};
26 |
27 | /**
28 | * List of start and size for each size of flash sector - even indexes are start, odd are size
29 | * The size will apply to all sectors between the listed address and the next address
30 | * in the list.
31 | * The last pair in the list will have sectors starting at that address and ending
32 | * at address flash_start + flash_size.
33 | */
34 | static const uint32_t sectors_info[] = {
35 | {%- for start, size in algo.sector_sizes %}
36 | {{ "0x%08x, 0x%08x" % (start + algo.flash_start, size) }},
37 | {%- endfor %}
38 | };
39 |
40 | static const program_target_t flash = {
41 | {{'0x%08x' % (algo.symbols['Init'] + header_size + entry)}}, // Init
42 | {{'0x%08x' % (algo.symbols['UnInit'] + header_size + entry)}}, // UnInit
43 | {{'0x%08x' % (algo.symbols['EraseChip'] + header_size + entry)}}, // EraseChip
44 | {{'0x%08x' % (algo.symbols['EraseSector'] + header_size + entry)}}, // EraseSector
45 | {{'0x%08x' % (algo.symbols['ProgramPage'] + header_size + entry)}}, // ProgramPage
46 | {{'0x%08x' % (algo.symbols['Verify'] + header_size + entry)}}, // Verify
47 |
48 | // BKPT : start of blob + 1
49 | // RSB : blob start + header + rw data offset
50 | // RSP : stack pointer
51 | {
52 | {{'0x%08x' % (entry + 1)}},
53 | {{'0x%08x' % (entry + header_size + algo.rw_start)}},
54 | {{'0x%08x' % stack_pointer}}
55 | },
56 |
57 | {{'0x%08x' % entry}} + 0x00000A00, // mem buffer location
58 | {{'0x%08x' % entry}}, // location to write prog_blob in target RAM
59 | sizeof({{name}}_flash_prog_blob), // prog_blob size
60 | {{name}}_flash_prog_blob, // address of prog_blob
61 | {{'0x%08x' % algo.page_size}} // ram_to_flash_bytes_to_be_written
62 | };
63 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL25Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL25Z32VFM4) || defined(CPU_MKL25Z64VFM4) || defined(CPU_MKL25Z128VFM4) || \
40 | defined(CPU_MKL25Z32VFT4) || defined(CPU_MKL25Z64VFT4) || defined(CPU_MKL25Z128VFT4) || \
41 | defined(CPU_MKL25Z32VLH4) || defined(CPU_MKL25Z64VLH4) || defined(CPU_MKL25Z128VLH4) || \
42 | defined(CPU_MKL25Z32VLK4) || defined(CPU_MKL25Z64VLK4) || defined(CPU_MKL25Z128VLK4))
43 |
44 | #define KL25Z4_SERIES
45 |
46 | /* CMSIS-style register definitions */
47 | #include "MKL25Z4.h"
48 | /* CPU specific feature definitions */
49 | #include "MKL25Z4_features.h"
50 |
51 | #else
52 | #error "No valid CPU defined!"
53 | #endif
54 |
55 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
56 |
57 | /*******************************************************************************
58 | * EOF
59 | ******************************************************************************/
60 |
--------------------------------------------------------------------------------
/source/nxp/lpc54114/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * Copyright 2016 - 2017 NXP
4 | * Redistribution and use in source and binary forms, with or without modification,
5 | * are permitted provided that the following conditions are met:
6 | *
7 | * o Redistributions of source code must retain the above copyright notice, this list
8 | * of conditions and the following disclaimer.
9 | *
10 | * o Redistributions in binary form must reproduce the above copyright notice, this
11 | * list of conditions and the following disclaimer in the documentation and/or
12 | * other materials provided with the distribution.
13 | *
14 | * o Neither the name of the copyright holder nor the names of its
15 | * contributors may be used to endorse or promote products derived from this
16 | * software without specific prior written permission.
17 | *
18 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
19 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
20 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
22 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
25 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
27 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 | *
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_LPC54114J256BD64_cm4) || defined(CPU_LPC54114J256UK49_cm4))
40 |
41 | #define LPC54114_cm4_SERIES
42 |
43 | /* CMSIS-style register definitions */
44 | #include "LPC54114_cm4.h"
45 | /* CPU specific feature definitions */
46 | #include "LPC54114_cm4_features.h"
47 |
48 | #elif (defined(CPU_LPC54114J256BD64_cm0plus) || defined(CPU_LPC54114J256UK49_cm0plus))
49 |
50 | #define LPC54114_cm0plus_SERIES
51 |
52 | /* CMSIS-style register definitions */
53 | #include "LPC54114_cm0plus.h"
54 | /* CPU specific feature definitions */
55 | #include "LPC54114_cm0plus_features.h"
56 |
57 | #else
58 | #error "No valid CPU defined!"
59 | #endif
60 |
61 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
62 |
63 | /*******************************************************************************
64 | * EOF
65 | ******************************************************************************/
66 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKV58F22/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2016, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKV58F1M0CLL22) || defined(CPU_MKV58F1M0CLQ22) || defined(CPU_MKV58F1M0CMD22) || \
40 | defined(CPU_MKV58F1M0VLL22) || defined(CPU_MKV58F1M0VLQ22) || defined(CPU_MKV58F1M0VMD22) || \
41 | defined(CPU_MKV58F512CLL22) || defined(CPU_MKV58F512CLQ22) || defined(CPU_MKV58F512CMD22) || \
42 | defined(CPU_MKV58F512VLL22) || defined(CPU_MKV58F512VLQ22) || defined(CPU_MKV58F512VMD22))
43 |
44 | #define KV58F22_SERIES
45 |
46 | /* CMSIS-style register definitions */
47 | #include "MKV58F22.h"
48 | /* CPU specific feature definitions */
49 | #include "MKV58F22_features.h"
50 |
51 | #else
52 | #error "No valid CPU defined!"
53 | #endif
54 |
55 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
56 |
57 | /*******************************************************************************
58 | * EOF
59 | ******************************************************************************/
60 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # FlashAlgo
2 |
3 | Framework for building Arm "FLM" style flash programming algorithms.
4 |
5 |
6 | ## Other options
7 |
8 | Before you consider adding a flash algo here, you might wish to check if an open source flash algo already exists
9 | for your device or a similar device. Many of the FLM flash algos included in CMSIS Device Family Packs (DFPs) come with source code. For instance, the Keil DFPs include sources.
10 |
11 | You can download a DFP for your device from the official CMSIS-Pack list: [by pack](https://www.keil.com/dd2/pack/) or [by part number](https://www.keil.com/dd2/).
12 |
13 | DFPs extract as zips (change the extension). For the DFPs created by Keil, .FLM algos and code are under `./CMSIS/Flash/`. Other vendors may have algos in a different folder, and may or may not include source.
14 |
15 |
16 | ## Development Setup
17 |
18 | Skip any step where a compatible tool already exists
19 |
20 | 1. Install [Python 3.6 or later](https://www.python.org/downloads/) and make sure it's added to path
21 | 2. Install [Git](https://git-scm.com/downloads) and make sure it's added to path
22 | 3. Install a supported toolchain:
23 | 1. [GNU Arm Embedded](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm)
24 | 2. [Keil MDK-ARM](https://www.keil.com/download/product/)
25 | 4. Install GNU Make.
26 |
27 | ```
28 | $ git clone https://github.com/mbedmicro/FlashAlgo
29 | $ python3 -mvenv venv
30 | $ source venv/bin/activate
31 | $ pip install -r requirements.txt
32 | ```
33 |
34 | ## Develop
35 |
36 | ### GCC with Make
37 |
38 | 1. Update tools and generate project files. This should be done everytime you pull new changes
39 |
40 | ```
41 | $ progen build -t make_gcc_arm
42 | ```
43 |
44 | Add the project name(s) to the command if you only want to build a limited set of projects. You can list available projects with `progen list -f projects.yaml projects`.
45 |
46 | ### MDK
47 |
48 | ```
49 | $ progen generate -t uvision
50 | $ tools\launch_uvision.bat
51 |
52 | ```
53 | Now open the project file for the desired target in `.\projectfiles\uvision\\`
54 |
55 | To change the RAM base address to something other than the default value of 0x20000000, add the argument `--blob_start ` in "Projects ❱ Options ❱ User ❱ After Build/Rebuild section of the µVision project.
56 |
57 |
58 | ## Adding a new project
59 |
60 | For adding new targets start from template and use these docs...
61 |
62 | ## Contributions
63 |
64 | We welcome contributions! Please see the [contribution guidelines](CONTRIBUTING.md) for detailed requirements.
65 | In order to foster a healthy and safe community, all contributors are expected to follow the
66 | [code of conduct](CODE_OF_CONDUCT.md).
67 |
68 | To report bugs, please [create an issue](https://github.com/pyocd/FlashAlgo/issues/new) in the GitHub project.
69 |
70 |
71 |
--------------------------------------------------------------------------------
/source/arm/gfc100/Native_Driver/gfc100_process_spec_api.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2018 Arm Limited
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /**
18 | * \file gfc100_process_specific_api.h
19 | *
20 | * \brief Header file for the process specific part of the
21 | * GFC100 flash controller
22 | */
23 |
24 | #ifndef __GFC100_PROCESS_SPEC_API_H__
25 | #define __GFC100_PROCESS_SPEC_API_H__
26 |
27 | #ifdef __cplusplus
28 | extern "C" {
29 | #endif
30 |
31 | #include
32 |
33 | /**
34 | * \brief Sets timing parameters on the process specific part
35 | *
36 | * \param[in] reg_map_base Process specific register map base
37 | * \param[in] sys_clk System clock in Hz
38 | */
39 | void gfc100_proc_spec_set_eflash_timing(uint32_t reg_map_base,
40 | uint32_t sys_clk);
41 |
42 | /**
43 | * \brief Gets flash memory size
44 | *
45 | * \param[in] reg_map_base Process specific register map base
46 | *
47 | * \return Returns the size of the flash memory
48 | */
49 | uint32_t gfc100_proc_spec_get_eflash_size(uint32_t reg_map_base);
50 |
51 | /**
52 | * \brief Gets flash page size
53 | *
54 | * \param[in] reg_map_base Process specific register map base
55 | *
56 | * \return Returns the page size of the flash memory
57 | */
58 | uint32_t gfc100_proc_spec_get_eflash_page_size(uint32_t reg_map_base);
59 |
60 | /**
61 | * \brief Gets word width of the process specific part
62 | *
63 | * \param[in] reg_map_base Process specific register map base
64 | *
65 | * \return Returns word width of the process specific part
66 | */
67 | uint32_t gfc100_proc_spec_get_eflash_word_width(uint32_t reg_map_base);
68 |
69 | /**
70 | * \brief Gets number of info pages
71 | *
72 | * \param[in] reg_map_base Process specific register map base
73 | *
74 | * \return Returns the number of info pages from the extended area
75 | */
76 | uint32_t gfc100_proc_spec_get_num_of_info_pages(uint32_t reg_map_base);
77 |
78 | /**
79 | * \brief Gets process specific error bits
80 | *
81 | * \param[in] reg_map_base Process specific register map base
82 | *
83 | * \return Returns the error bits specified by the process specific part
84 | * of the controller.
85 | */
86 | uint32_t gfc100_proc_spec_get_error_cause(uint32_t reg_map_base);
87 |
88 | #ifdef __cplusplus
89 | }
90 | #endif
91 |
92 | #endif /* __GFC100_PROCESS_SPEC_API_H__ */
93 |
94 |
--------------------------------------------------------------------------------
/source/freescale/devices/MKL26Z4/fsl_device_registers.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2014 - 2015, Freescale Semiconductor, Inc.
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without modification,
6 | * are permitted provided that the following conditions are met:
7 | *
8 | * o Redistributions of source code must retain the above copyright notice, this list
9 | * of conditions and the following disclaimer.
10 | *
11 | * o Redistributions in binary form must reproduce the above copyright notice, this
12 | * list of conditions and the following disclaimer in the documentation and/or
13 | * other materials provided with the distribution.
14 | *
15 | * o Neither the name of Freescale Semiconductor, Inc. nor the names of its
16 | * contributors may be used to endorse or promote products derived from this
17 | * software without specific prior written permission.
18 | *
19 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
23 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 | */
30 |
31 | #ifndef __FSL_DEVICE_REGISTERS_H__
32 | #define __FSL_DEVICE_REGISTERS_H__
33 |
34 | /*
35 | * Include the cpu specific register header files.
36 | *
37 | * The CPU macro should be declared in the project or makefile.
38 | */
39 | #if (defined(CPU_MKL26Z128CAL4) || defined(CPU_MKL26Z32VFM4) || defined(CPU_MKL26Z64VFM4) || \
40 | defined(CPU_MKL26Z128VFM4) || defined(CPU_MKL26Z32VFT4) || defined(CPU_MKL26Z64VFT4) || \
41 | defined(CPU_MKL26Z128VFT4) || defined(CPU_MKL26Z32VLH4) || defined(CPU_MKL26Z64VLH4) || \
42 | defined(CPU_MKL26Z128VLH4) || defined(CPU_MKL26Z256VLH4) || defined(CPU_MKL26Z128VLL4) || \
43 | defined(CPU_MKL26Z256VLL4) || defined(CPU_MKL26Z128VMC4) || defined(CPU_MKL26Z256VMC4) || \
44 | defined(CPU_MKL26Z256VMP4))
45 |
46 | #define KL26Z4_SERIES
47 |
48 | /* CMSIS-style register definitions */
49 | #include "MKL26Z4.h"
50 | /* CPU specific feature definitions */
51 | #include "MKL26Z4_features.h"
52 |
53 | #else
54 | #error "No valid CPU defined!"
55 | #endif
56 |
57 | #endif /* __FSL_DEVICE_REGISTERS_H__ */
58 |
59 | /*******************************************************************************
60 | * EOF
61 | ******************************************************************************/
62 |
--------------------------------------------------------------------------------
/scripts/generate_blobs.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # Copyright (c) 2011-2017 Arm Limited
3 | # Copyright (c) 2021 Chris Reed
4 | #
5 | # Licensed under the Apache License, Version 2.0 (the 'License');
6 | # you may not use this file except in compliance with the License.
7 | # You may obtain a copy of the License at
8 | #
9 | # http://www.apache.org/licenses/LICENSE-2.0
10 | #
11 | # Unless required by applicable law or agreed to in writing, software
12 | # distributed under the License is distributed on an 'AS IS' BASIS,
13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | # See the License for the specific language governing permissions and
15 | # limitations under the License.
16 | #
17 | #
18 | # This script takes the path to file(s) created by an image conversion tool
19 | # (fromelf or arm-elf-objcopy) as input. These files (bin and text) are used
20 | # to create flash programming blobs (instruction arrays) which are then
21 | # loaded into the target MCU RAM. Generates files compatible with C programs
22 | # and python programs (DAPLink Interface Firmware and pyDAPFlash)
23 |
24 | import os
25 | import argparse
26 | from flash_algo import PackFlashAlgo
27 |
28 | # Header with a BKPT instruction.
29 | BLOB_HEADER = '0xE00ABE00, '
30 | HEADER_SIZE = 0x4
31 |
32 | STACK_SIZE = 0x200
33 |
34 | TEMPLATES = [
35 | ("c_blob.tmpl", "c_blob.c"),
36 | ("py_blob_orig.tmpl", "py_blob_orig.py"),
37 | ("py_blob.tmpl", "py_blob.py"),
38 | ("c_blob_mbed.tmpl", "c_blob_mbed.c")
39 | ]
40 |
41 | def str_to_num(val):
42 | return int(val,0) #convert string to number and automatically handle hex conversion
43 |
44 | def main():
45 | parser = argparse.ArgumentParser(description="Blob generator")
46 | parser.add_argument("elf_path", help="Elf, axf, or flm to extract "
47 | "flash algo from")
48 | parser.add_argument("--blob_start", default=0x20000000, type=str_to_num, help="Starting "
49 | "address of the flash blob. Used only for DAPLink.")
50 | args = parser.parse_args()
51 |
52 | with open(args.elf_path, "rb") as file_handle:
53 | algo = PackFlashAlgo(file_handle.read())
54 |
55 | print(algo.flash_info)
56 |
57 | template_dir = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'templates')
58 | output_dir = os.path.dirname(args.elf_path)
59 |
60 | # Allocate stack after algo and its rw data, rounded up.
61 | SP = args.blob_start + HEADER_SIZE + algo.rw_start + algo.rw_size + STACK_SIZE
62 | SP = (SP + 0x100 - 1) // 0x100 * 0x100
63 |
64 | data_dict = {
65 | 'name': os.path.splitext(os.path.split(args.elf_path)[-1])[0],
66 | 'prog_header': BLOB_HEADER,
67 | 'header_size': HEADER_SIZE,
68 | 'entry': args.blob_start,
69 | 'stack_pointer': SP,
70 | }
71 |
72 | for tmpl, name in TEMPLATES:
73 | template_path = os.path.join(template_dir, tmpl)
74 | output_path = os.path.join(output_dir, name)
75 | algo.process_template(template_path, output_path, data_dict)
76 |
77 |
78 | if __name__ == '__main__':
79 | main()
80 |
--------------------------------------------------------------------------------
/source/st/STM32WB55RC/inc/system_stm32wbxx.h:
--------------------------------------------------------------------------------
1 | /**
2 | ******************************************************************************
3 | * @file system_stm32wbxx.h
4 | * @author MCD Application Team
5 | * @brief CMSIS Cortex Device System Source File for STM32WBxx devices.
6 | ******************************************************************************
7 | * @attention
8 | *
9 | * © Copyright (c) 2019 STMicroelectronics.
10 | * All rights reserved.
11 | *
12 | * This software component is licensed by ST under Apache License, Version 2.0,
13 | * the "License"; You may not use this file except in compliance with the
14 | * License. You may obtain a copy of the License at:
15 | * opensource.org/licenses/Apache-2.0
16 | *
17 | ******************************************************************************
18 | */
19 |
20 | /** @addtogroup CMSIS
21 | * @{
22 | */
23 |
24 | /** @addtogroup stm32wbxx_system
25 | * @{
26 | */
27 |
28 | /**
29 | * @brief Define to prevent recursive inclusion
30 | */
31 | #ifndef __SYSTEM_STM32WBXX_H
32 | #define __SYSTEM_STM32WBXX_H
33 |
34 | #ifdef __cplusplus
35 | extern "C" {
36 | #endif
37 |
38 | #include
39 |
40 | /** @addtogroup STM32WBxx_System_Includes
41 | * @{
42 | */
43 |
44 | /**
45 | * @}
46 | */
47 |
48 |
49 | /** @addtogroup STM32WBxx_System_Exported_types
50 | * @{
51 | */
52 | /* The SystemCoreClock variable is updated in three ways:
53 | 1) by calling CMSIS function SystemCoreClockUpdate()
54 | 2) by calling HAL API function HAL_RCC_GetSysClockFreq()
55 | 3) each time HAL_RCC_ClockConfig() is called to configure the system clock frequency
56 | Note: If you use this function to configure the system clock; then there
57 | is no need to call the 2 first functions listed above, since SystemCoreClock
58 | variable is updated automatically.
59 | */
60 |
61 | extern uint32_t SystemCoreClock; /*!< System Clock Frequency */
62 |
63 | extern const uint32_t AHBPrescTable[16]; /*!< AHB prescalers table values */
64 | extern const uint32_t APBPrescTable[8]; /*!< APB prescalers table values */
65 | extern const uint32_t MSIRangeTable[16]; /*!< MSI ranges table values */
66 |
67 | #if defined(STM32WB55xx) || defined(STM32WB5Mxx) || defined(STM32WB35xx) || defined (STM32WB15xx) || defined (STM32WB10xx)
68 | extern const uint32_t SmpsPrescalerTable[4][6]; /*!< SMPS factor ranges table values */
69 | #endif
70 | /**
71 | * @}
72 | */
73 |
74 | /** @addtogroup STM32WBxx_System_Exported_Constants
75 | * @{
76 | */
77 |
78 | /**
79 | * @}
80 | */
81 |
82 | /** @addtogroup STM32WBxx_System_Exported_Macros
83 | * @{
84 | */
85 |
86 | /**
87 | * @}
88 | */
89 |
90 | /** @addtogroup STM32WBxx_System_Exported_Functions
91 | * @{
92 | */
93 |
94 | extern void SystemInit(void);
95 | extern void SystemCoreClockUpdate(void);
96 | /**
97 | * @}
98 | */
99 |
100 | #ifdef __cplusplus
101 | }
102 | #endif
103 |
104 | #endif /*__SYSTEM_STM32WBXX_H */
105 |
106 | /**
107 | * @}
108 | */
109 |
110 | /**
111 | * @}
112 | */
113 | /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
114 |
--------------------------------------------------------------------------------