Skip to content
Snippets Groups Projects
Unverified Commit ff623dfb authored by CNLohr's avatar CNLohr Committed by GitHub
Browse files

Merge pull request #213 from hexeguitar/master

Issue #212 fixes - examples fail to compile
parents 45d5e010 207010be
No related branches found
No related tags found
No related merge requests found
......@@ -16,7 +16,11 @@ int main()
// PC4 is T1CH4, 50MHz Output PP CNF = 10: Mux PP, MODE = 11: Out 50MHz
GPIOC->CFGLR &= ~(GPIO_CFGLR_MODE4 | GPIO_CFGLR_CNF4);
GPIOC->CFGLR |= GPIO_CFGLR_CNF4_1 | GPIO_CFGLR_MODE4_0 | GPIO_CFGLR_MODE4_1;
// turn the HSE on
RCC->CTLR |= RCC_HSE_ON;
// Wait till HSE is ready
while(!(RCC->CTLR & RCC_HSERDY));
while(1)
{
switch(count)
......
......@@ -4,8 +4,8 @@
#define FUNCONF_TINYVECTOR 1
#define CH32V003 1
#define FUNCONF_USE_HSE 1
#define FUNCONF_USE_HSE 0
#define FUNCONF_USE_HSI 1
#endif
#endif // _FUNCONFIG_H
......@@ -8,7 +8,9 @@
#include<stdint.h> //uintN_t support
#include"../ch32v003fun/ch32v003fun.h"
#ifndef APB_CLOCK
#define APB_CLOCK FUNCONF_SYSTEM_CORE_CLOCK
#endif
/*######## library usage and configuration
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment