Converted part of header comments to english, changed license text

master
Ondřej Hruška 9 years ago
parent c8ad62ff81
commit 26201d6236
  1. 31
      LICENSE
  2. 12
      lib/INI_ADC.s
  3. 12
      lib/INI_AES.s
  4. 12
      lib/INI_BASE.s
  5. 12
      lib/INI_COMP.s
  6. 12
      lib/INI_CRC.s
  7. 12
      lib/INI_DAC.s
  8. 12
      lib/INI_DBGMCU.s
  9. 12
      lib/INI_DMA.s
  10. 12
      lib/INI_EXTI.s
  11. 12
      lib/INI_FLASH.s
  12. 12
      lib/INI_FSMC.s
  13. 10
      lib/INI_GPIO.s
  14. 12
      lib/INI_I2C.s
  15. 12
      lib/INI_LCD.s
  16. 12
      lib/INI_NVIC.s
  17. 12
      lib/INI_OPAMP.s
  18. 12
      lib/INI_PWR.s
  19. 12
      lib/INI_RCC.s
  20. 12
      lib/INI_RI.s
  21. 12
      lib/INI_RTC.s
  22. 10
      lib/INI_SCB.s
  23. 12
      lib/INI_SDIO.s
  24. 12
      lib/INI_SPI.s
  25. 12
      lib/INI_SYSCFG.s
  26. 10
      lib/INI_SYSTICK.s
  27. 12
      lib/INI_TIM.s
  28. 12
      lib/INI_USART.s
  29. 12
      lib/INI_USB.s
  30. 12
      lib/INI_WDG.s
  31. 56
      main.asm

@ -1,27 +1,10 @@
The MIT License (MIT)
Contributors:
Copyright (c) 2010 Michal Tomáš - part of the example program
Copyright (c) 2015 Petr Douša - conversion of CMSIS defintions to assembler
Copyright (c) 2015 Ondřej Hruška - library cleanup, bit-banding & missing definitions
Copyright (c) 2010 Michal Tomáš - část vzorového programu
Copyright (c) 2015 Petr Douša - základ knihovny dle CMSIS
Copyright (c) 2015 Ondřej Hruška - doplnění knihovny, Makefile
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
The library can be freely used for educational and non-commercial purposes,
provided the copyright notices and header comments are retained.
Since a substantial portion of the library is derived from STM32 CMSIS, the original
license conditions should be respected.

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_ADC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro ADC
; FILE : INI_ADC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro ADC
;
; Analog to Digital Converter (ADC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,13 +1,15 @@
;********************************************************************************
; SOUBOR : INI_AES.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro AES (crypto);
; FILE : INI_AES.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro AES (crypto);
; ! Modul je pouze v STM32L162 !
;
; Advanced Encryption Standard (AES)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,11 +1,13 @@
;********************************************************************************
; SOUBOR : INI_BASE.S
; AUTOR : Ondrej Hruska
; DATUM : 10/2015
; POPIS : Zakladni soubor knihovny. Musi byt includovat pred vsemi ostatnimi.
; FILE : INI_BASE.S
; AUTHOR : Ondrej Hruska
; DATE : 10/2015
; DESCR : Zakladni soubor knihovny. Musi byt includovat pred vsemi ostatnimi.
; Soubor definuje rozdeleni adresniho prostoru a adresy periferii.
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_COMP.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro COMP (analogovy komparator)
; FILE : INI_COMP.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro COMP (analogovy komparator)
;
; Analog Comparators (COMP)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_CRC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro CRC (checksum generator)
; FILE : INI_CRC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro CRC (checksum generator)
;
; CRC calculation unit (CRC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_DAC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro DAC (digitalne-analogovy prevodnik)
; FILE : INI_DAC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro DAC (digitalne-analogovy prevodnik)
;
; Digital to Analog Converter (DAC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_DBGMCU.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro DBGMCU (Debug MCU control)
; FILE : INI_DBGMCU.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro DBGMCU (Debug MCU control)
;
; Debug MCU (DBGMCU)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_DMA.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro DMA (Direct memory access)
; FILE : INI_DMA.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro DMA (Direct memory access)
;
; DMA Controller (DMA)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_EXTI.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro EXTI (ext. interrupt)
; FILE : INI_EXTI.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro EXTI (ext. interrupt)
;
; External Interrupt/Event Controller (EXTI)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************
;****************************************************************************

@ -1,13 +1,15 @@
;********************************************************************************
; SOUBOR : INI_FLASH.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro FLASH
; FILE : INI_FLASH.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro FLASH
;
; FLASH, DATA EEPROM and Option Bytes Registers
; (FLASH, DATA_EEPROM, OB)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_FSMC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro FSMC (ext. memory communication)
; FILE : INI_FSMC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro FSMC (ext. memory communication)
;
; Flexible Static Memory Controller
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,11 +1,13 @@
;****************************************************************************
; SOUBOR : INI_GPIO.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; FILE : INI_GPIO.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
;
; General Purpose IOs (GPIO)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;****************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_I2C.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro I2C
; FILE : INI_I2C.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro I2C
;
; Inter-integrated Circuit Interface (I2C)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_LCD.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro LCD
; FILE : INI_LCD.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro LCD
;
; LCD Controller (LCD)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_NVIC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro NVIC (system preruseni)
; FILE : INI_NVIC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro NVIC (system preruseni)
;
; Nested Vectored Interrupt Controller (NVIC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_OPAMP.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro OPAMP
; FILE : INI_OPAMP.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro OPAMP
;
; Operational Amplifier (OPAMP)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_PWR.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro PWR (napajeni, sleep...)
; FILE : INI_PWR.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro PWR (napajeni, sleep...)
;
; Power Control (PWR)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_RCC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro RCC (nastaveni hodin)
; FILE : INI_RCC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro RCC (nastaveni hodin)
;
; Reset and Clock Control (RCC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************
;****************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_RI.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro RI (analogove propojky)
; FILE : INI_RI.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro RI (analogove propojky)
;
; Routing Interface (RI)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_RTC.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro RTC (obvod realneho casu)
; FILE : INI_RTC.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro RTC (obvod realneho casu)
;
; Real-Time Clock (RTC)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,11 +1,13 @@
;****************************************************************************
; SOUBOR : INI_SCB.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; FILE : INI_SCB.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; System Control Block (SCB)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;****************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_SDIO.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro SDIO
; FILE : INI_SDIO.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro SDIO
;
; SD host Interface
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_SPI.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro SPI
; FILE : INI_SPI.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro SPI
;
; Serial Peripheral Interface (SPI)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_SYSCFG.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro SYSCFG (EXTI routing atd.)
; FILE : INI_SYSCFG.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro SYSCFG (EXTI routing atd.)
;
; System Configuration (SYSCFG)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,11 +1,13 @@
;****************************************************************************
; SOUBOR : INI_SYSTICK.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; FILE : INI_SYSTICK.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
;
; System Timer (SysTick)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;****************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_TIM.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro TIM (casovace)
; FILE : INI_TIM.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro TIM (casovace)
;
; Timers (TIM)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_USART.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro USART
; FILE : INI_USART.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro USART
;
; Universal Synchronous Asynchronous Receiver Transmitter (USART)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,12 +1,14 @@
;********************************************************************************
; SOUBOR : INI_USB.S
; AUTOR : Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro USB
; FILE : INI_USB.S
; AUTHOR : Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro USB
;
; Universal Serial Bus (USB)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,14 +1,16 @@
;********************************************************************************
; SOUBOR : INI_WWDG.S
; AUTOR : Petr Dousa, Ondrej Hruska
; DATUM : 10/2015
; POPIS : Bitove masky ridicich registru pro WWDG
; FILE : INI_WWDG.S
; AUTHOR : Petr Dousa, Ondrej Hruska
; DATE : 10/2015
; DESCR : Bitove masky ridicich registru pro WWDG
;
; Window WATCHDOG (WWDG)
;
; Independent WATCHDOG (IWDG)
;
; Toto je soucast knihovny pro STM32L100 vyvijene na Katedre mereni FEL CVUT.
; Part of an assembler library for STM32L100, based on the STM32 CMSIS.
; Developed for educational purposes at the Department of Measure of CTU in Prague.
; See the LICENSE file for detailed terms of use.
;********************************************************************************

@ -1,11 +1,10 @@
;***************************************************************************************************
;*
;* Misto : CVUT FEL, Katedra Mereni
;* Prednasejici : Doc. Ing. Jan Fischer,CSc.
;* Predmet : A4M38AVS, A4B38NVS
;* Vyvojovy Kit : STM32L100 DISCOVERY (STM32L100RC)
;* Datum : 12/2010, 10/2015
;* Autor : Michal TOMAS (2010), Ondrej Hruska (2015)
;* Place : CVUT FEL, Katedra Mereni
;* Lecturer : Doc. Ing. Jan Fischer,CSc.
;* Subject : A4M38AVS, A4B38NVS
;* Development kit : STM32L100 DISCOVERY (STM32L100RC)
;* Authors : Michal TOMAS (2010), Ondrej Hruska (2015)
;*
;***************************************************************************************************
@ -41,13 +40,14 @@ __use_two_region_memory
;* Called by the startup script before calling __main
;***************************************************************************************************
SystemInit
SystemInit PROC
EXPORT SystemInit ; Export the address to startup script
PUSH {LR}
BL RCC_CNF ; Configure clock sources
BL GPIO_CNF ; Configure GPIO power and pin settings
BL SYSTICK_CNF ; Configure SysTick timer
POP {PC}
ENDP
@ -55,7 +55,7 @@ SystemInit
;* Interrupt handlers...
;***************************************************************************************************
SysTick_Handler
SysTick_Handler PROC
EXPORT SysTick_Handler ; Export the address to startup script (replaces a WEAK stub)
PUSH {LR}
@ -72,6 +72,7 @@ SysTick_Handler
; STR R1, [R0]
POP {PC}
ENDP
@ -82,11 +83,8 @@ SysTick_Handler
;* __main is called only once, and does not return!
;***************************************************************************************************
__main
__main PROC
EXPORT __main ; Export the address to startup script
ENTRY ; Marks the program entry point (shouldnt be here)
LOOP ; Main loop
; turn LED on
LDR R0, =BB_GPIOC_ODR_8 ; bit-banding address
@ -107,6 +105,7 @@ LOOP ; Main loop
BL DELAY
B LOOP
ENDP
@ -116,7 +115,7 @@ LOOP ; Main loop
;* Sets PC08 and PC09 as outputs, PA0 as input.
;**************************************************************************************************
GPIO_CNF
GPIO_CNF PROC
PUSH {R0,R1,LR}
; Enable GPIO peripheral timing
@ -139,10 +138,12 @@ GPIO_CNF
LDR R0, =GPIOA_MODER
LDR R1, [R0]
BIC R1,R1, #GPIO_MODER_0
ORR R1,R1, #(GPIO_MODER_0 & GPIO_MODER_INPUT); Write the "input" pattern into the bit config area
; Write the "input" pattern into the bit config area
ORR R1,R1, #(GPIO_MODER_0 & GPIO_MODER_INPUT)
STR R1, [R0]
POP {R0,R1,PC}
ENDP
@ -152,7 +153,7 @@ GPIO_CNF
;* Configures SysTick to fire a SysTick interrupt at 1 Hz
;**************************************************************************************************
SYSTICK_CNF
SYSTICK_CNF PROC
PUSH {R0, R1, LR}
; Use the core clock (undivided)
@ -176,6 +177,7 @@ SYSTICK_CNF
STR R1, [R0]
POP {R0, R1, PC}
ENDP
@ -185,7 +187,7 @@ SYSTICK_CNF
;* Inputs: R0 = number of loop cycles
;**************************************************************************************************
DELAY
DELAY PROC
PUSH {R2, LR} ; Push the changed registers & link register
WAIT_OUTER ; Outer loop
@ -199,16 +201,17 @@ WAIT_INNER SUBS R2, R2, #1 ; Decrement INNER loop counter
BNE WAIT_OUTER ; Continue the loop if not done
POP {R2, PC} ; Pop & return
ENDP
;***************************************************************************************************
;* Konfigurace systemovych hodin a hodin periferii
;* Clock configuration
;*
;* Nastavi hodiny na HSI 16 MHz
;* Set clock speed to 16 MHz
;**************************************************************************************************
RCC_CNF
RCC_CNF PROC
PUSH {R0, R1, LR}
; Flash timing configuration
@ -221,26 +224,14 @@ RCC_CNF
ORR R1, R1, #(FLASH_ACR_PRFTEN :OR: FLASH_ACR_LATENCY)
STR R1, [R0]
; Nastavit hodinove vstupy
LDR R0, =RCC_CR
; Additional RCC_CR config
; LDR R1, [R0]
; LDR R2, =RCC_CR_RTCPRE ; clear RTC prescaler
; BIC R1, R1, R2
; ; HseByp allows to use external clock source with HSEON
; LDR R2, =(RCC_CR_RTCPRE_DIV2 :OR: RCC_CR_HSEBYP)
; ORR R1, R1, R2
; STR R1, [R0]
; Power on HSI (runs from MSI on start)
LDR R0, =RCC_CR
LDR R1, [R0]
ORR R1, R1, #RCC_CR_HSION
STR R1, [R0]
; Wait for HSIRDY
ALIGN
NO_HSI_RDY LDR R1, [R0]
TST R1, #RCC_CR_HSIRDY
BEQ NO_HSI_RDY
@ -254,6 +245,7 @@ NO_HSI_RDY LDR R1, [R0]
STR R1, [R0]
POP {R0, R1, PC}
ENDP
;**************************************************************************************************

Loading…
Cancel
Save