Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Tool chains For the STM32F4

Status
Not open for further replies.
Hah im lost with this stuff. How would i set a pin output ?

I see: GPIO port mode register (GPIOx_MODER) (x = A..I)

But there is no : GPIOD_MODER register in the include file...

I cant use the discovery.h file.. so many errors OMG heh I think its break time... then ill get back to this from scratch and see where i got lost :D
 
Code:
#include "stm32f4xx.h"
void delay(int temp2);

int temp;

void main()
{
  GPIOD->MODER   = 0x55555555;
  GPIOD->OSPEEDR = 0xAAAAAAAA;
  GPIOD->PUPDR   = 0x00;
  GPIOD->OTYPER  = 0xFFFF;
  while(1)
  {
    delay(100000);
    GPIOD->ODR = 0xFFFF;  

    delay(100000);
    GPIOD->ODR = 0x0000;

  }
}

void delay(int temp2)
{
  while(temp2--);
}

Ok this compiles ok , but doesnt work. I forgot i need to setup the clock and stuff heh.. but so far no errors :)
 
Ok i get a nice slow blink on LED8 which is by the Bottom USB MICRO connector...
Code:
#include "stm32f4xx.h"
void delay(int temp2);

int temp;

void main()
{
  RCC->CFGR = 0x80400001;
  RCC->AHB1ENR = 0x08;
  RCC->CR |= 0x10000;
  while(RCC->CR & 0x10000==0);

  GPIOD->MODER   = 0x55555555;
  GPIOD->OSPEEDR = 0xAAAAAAAA;
  GPIOD->PUPDR   = 0x00;
  GPIOD->OTYPER  = 0xFFFF;
  while(1)
  {
    delay(500000);
    GPIOD->ODR = 0xFFFF;  

    delay(500000);
    GPIOD->ODR = 0x0000;

  }
}

void delay(int temp2)
{
  while(temp2--);
}
 
Ok i can blink all LEDs ... YAY the problem was :

GPIOD->OTYPER = 0xFFFF;

Needs to be

GPIOD->OTYPER = 0x0000;

I will comment the entire code as well as i can and repost it here so all can see what it does.
 
Last edited:
Ok while writing comments i noticed some code i could change. Some values are not needed. Hope this helps someone out there:
Code:
#include "stm32f4xx.h"    //Include main header for MCU
void delay(int ticks);    //Used for delays

void main()
{
  //Bits 1:0 (01) HSE oscillator selected as system clock
  RCC->CFGR = 0x01;

  //Bit 3 GPIODEN: IO port D clock enable (1: IO port D clock enabled)
  RCC->AHB1ENR = 0x08;
  
  //Bit 16 HSEON: HSE clock enable (1: HSE oscillator ON)
  RCC->CR |= 0x10000;
  
  //Bit 17 HSERDY: HSE clock ready flag (1: HSE oscillator ready)
  while(RCC->CR & 0x20000==0);

  //GPIO port mode register (all PORTD = 01: General purpose output mode)
  GPIOD->MODER   = 0x55555555;
  
  //GPIO port speed reg. (all portd = 10: 50 MHz Fast speed)
  GPIOD->OSPEEDR = 0xAAAAAAAA;
  
  //GPIO port pull up - pull down reg (00: No pull-up, pull-down)
  GPIOD->PUPDR   = 0x00;
  
  //0: Output push-pull (reset state)
  GPIOD->OTYPER  = 0x00;
  while(1)
  {
    //My Crap Delay (~500,000 clks)
    delay(500000);
    
    //GPIO port output data register (ALL HIGH)
    GPIOD->ODR = 0xFFFF;  

    //My Crap Delay (~500,000 clks)
    delay(500000);
    
    //GPIO port output data register (ALL LOW)
    GPIOD->ODR = 0x0000;

  }
}

void delay(int ticks)
{
  while(ticks--);
}

Ok Tired as HECK! Its break time :D
 
Last edited:
Thanks Jason,

You inspired me so I tried again and I got the STLINK/V2 driver installed and working with Atollic TrueSTUDIO®/STM32 Lite. Your LED flashy program is now running on my board. Yippee!!!

Regards, Mike
 
Last edited:
TrueStudio test:
**** Build of configuration Debug for project BlinkIt ****

**** Internal Builder is used for build ****
arm-atollic-eabi-gcc -c -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -DUSE_STM32F4_DISCOVERY -DSTM32F4XX -DUSE_STDPERIPH_DRIVER -I../src -I..\Libraries\CMSIS\Include -I..\Libraries\Device\STM32F4xx\Include -I..\Libraries\STM32F4xx_StdPeriph_Driver\inc -O0 -ffunction-sections -fdata-sections -g -Wall -osrc\main.o ..\src\main.c
arm-atollic-eabi-gcc src\system_stm32f4xx.o src\stm32f4xx_it.o src\startup_stm32f4xx.o src\main.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_wwdg.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_usart.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_tim.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_syscfg.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_spi.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_sdio.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_rtc.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_rng.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_rcc.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_pwr.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_iwdg.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_i2c.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_hash_sha1.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_hash_md5.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_hash.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_gpio.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_fsmc.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_flash.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_exti.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_dma.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_dcmi.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_dbgmcu.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_dac.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_cryp_tdes.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_cryp_des.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_cryp_aes.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_cryp.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_crc.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_can.o Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_adc.o Libraries\STM32F4xx_StdPeriph_Driver\src\misc.o -lm -o BlinkIt.elf -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -T..\stm32_flash.ld -static -Wl,-cref,-u,Reset_Handler -Wl,-Map=BlinkIt.map -Wl,--gc-sections -Wl,--defsym=malloc_getpagesize_P=0x1000
C:\Program Files\Atollic\TrueSTUDIO for STMicroelectronics STM32 Lite 2.2.0\ide\jre\bin\java -jar C:\Program Files\Atollic\TrueSTUDIO for STMicroelectronics STM32 Lite 2.2.0\Tools\arm-atollic-reports.jar sizeinfo BlinkIt.elf
Report and converter tools only available in TrueSTUDIO Professional
Build complete for project BlinkIt
Time consumed: 882 ms.

Debug: STM32 Successufully completed reset operation

So all is well! Yay! Works nice. Feel great to have something that worked out.. (For free heh)
 
So bored... started making my own STM32F407.h file

Here is a preview of it so far... should make coding more easy. Since i have so much issues with the code samples that came with it. Remember this isnt complete and i doubt it will ever be 100% complete but this is something i will use. So you can use but at your own risk

Code:
#ifndef stm32f407_h
#define stm32f407_h

//------------------------------
//    RCC_CR Definitions
//------------------------------
#define PLLI2SRDY 0x8000000 //PLLI2S clock ready flag
#define PLLI2ISON 0x4000000 //PLLI2S enable 
#define PLLRDY    0x2000000 //Main PLL (PLL) clock ready flag
#define PLLON     0x1000000 //Main PLL (PLL) enable
#define CSSON     0x80000   //Clock security system enable
#define HSEBYP    0x40000   //HSE clock bypass
#define HSERDY    0x20000   //HSE clock ready flag
#define HSEON     0x10000   //HSE clock enable
#define HSIRDY    0x2       //Internal high-speed clock ready flag
#define HSION     0x1       //Internal high-speed clock enable

//------------------------------
//    RCC_CFGR Definitions
//------------------------------

//MCO2[1:0]: Microcontroller clock output 2
#define MCO2_SYSCLK 0x00000000 //System clock (SYSCLK) selected
#define MCO2_PLLI2S 0x40000000 //PLLI2S clock selected
#define MCO2_HSE    0x80000000 //HSE oscillator clock selected
#define MCO2_PLL    0xC0000000 //PLL clock selected

//MCO2PRE: MCO2 prescaler
#define MCO2PRE_2   0x20000000 //division by 2
#define MCO2PRE_3   0x28000000 //division by 3
#define MCO2PRE_4   0x30000000 //division by 4
#define MCO2PRE_5   0x38000000 //division by 5

//MCO1PRE: MCO1 prescaler
#define MCO1PRE_2   0x4000000 //division by 2
#define MCO1PRE_3   0x5000000 //division by 3
#define MCO1PRE_4   0x6000000 //division by 4
#define MCO1PRE_5   0x7000000 //division by 5

//I2SSRC: I2S clock selection
#define I2SSRC_PLLI2S 0x00      //PLLI2S clock used as I2S clock source
#define I2SSRC_ECLK   0x800000  //External clock mapped on the I2S_CKIN pin used as I2S clock source

//MCO1: Microcontroller clock output 1
#define MCO1_HSI   0x00         //HSI clock selected
#define MCO1_LSE   0x200000     //LSE oscillator selected
#define MCO1_HSE   0x400000     //HSE oscillator clock selected
#define MCO1_PLL   0x600000     //PLL clock selected

//RTCPRE: HSE division factor for RTC clock - Must be 1MHZ
#define RTCPRE     0x10000  //USE THIS VALUE TO SHIFT 2 to 31 EX: if HSE = 8Mhz then use (8<<RTCPRE) (0 or 1 - NO CLOCK)

//PPRE2: APB high-speed prescaler (APB2)
#define PPRE2_DIV0  0x00      //AHB clock not divided
#define PPRE2_DIV2  0x8000    //AHB clock divided by 2
#define PPRE2_DIV4  0xA000    //AHB clock divided by 4
#define PPRE2_DIV8  0xC000    //AHB clock divided by 8
#define PPRE2_DIV16 0xE000    //AHB clock divided by 16

//PPRE1: APB Low speed prescaler (APB1)
#define PPRE1_DIV0  0x00      //AHB clock not divided
#define PPRE1_DIV2  0x1000    //AHB clock divided by 2
#define PPRE1_DIV4  0x1400    //AHB clock divided by 4
#define PPRE1_DIV8  0x1800    //AHB clock divided by 8
#define PPRE1_DIV16 0x1C00    //AHB clock divided by 16


#endif

Remember THIS IS A PREVIEW OF IT... THIS IS MY VERSION... HAND CODED... WILL ONLY ADD WHAT I THINK I MIGHT USE...

:) So tired heh, i have been working on this all morning. I even made a new program just to convert the binary bits
 
Last edited:
Oh just looked a the price of this MCU alone and its $17 WOW but this demo board is $19.5 hmmm... somethings not right

I would simply buy the demo board and remove all parts. I would spend $2 extra but get these off the board also.

$8.13 - STM32F103C8T6 - ST Uses as ST-LINK
$4.15 - LIS302DL - ST MEMS motion sensor, 3-axis digital output accelerometer
$4.71 - MP45DT02 - ST MEMS audio sensor, omnidirectional digital microphone
$6.39 - CS43L22 - audio DAC with integrated class D speaker driver
Two pushbuttons - SMT
USB OTG with micro-AB connector
USB Mini B Connector
Eight LEDs
Regulators
Crystals
Expensive CAPS (larger ones)

Ill order one and remove all the parts and share the pictures... in fact ill try to record the whole process.
Also since this is all pre-programmed and you have schematics in PDF you can remake the STLINK part and make a stand alone programmer!
 
Last edited:
I had a look at Crossworks It looks good it a lot easier to use then TrueStudio. TrueStudio lets you use the lite mode and Crossworks gives you 30 days $150.00 to buy a
Personal Licenses are for individuals such as hobbyists and students who do not make a profit from the use of CrossWorks.
Or
$1500.00
Commercial Licenses are for customers that need to develop products on a commercial basis;
 
Yeah , $150 isnt too bad... the $1500 i myself consider that for when i sell some code or something. If i create code or a device which uses code created using crossworks i would think all is fair using the Hobby license if i dont make enough to pay for it.

Now if i make something and i brings in $2000 or more i would purchase that license. I know that might seem unethical to use a Hobbyist license for selling use but i dont consider it commercial usage unless i sell it on the market or something. Like if i not planning on making a lot of money then why should i have to pay what i dont have. Im broke as hell right now. If someone asked me to develop something using crossworks and they would pay me $200... you damn right i will sell it and collect my money. Why? Because i paid for the license already. Even if its not a commercial license. The software is the same. Meaning its not fair to charge me more for something because i plan on making money with it. If that was the case they should have a FREE Version and a Licensed Version. There should be no IN BETWEEN crap :)

Anyway those are my thoughts :)

Im not sure if you have seen this movie: Mr. Deeds...

Brandon Molale is the COMPANY and Adam Sandler is the USER

https://www.youtube.com/watch?v=ihpe07LoOx0

0:49 Seconds in upto 1:03... if i played well i should get paid more...
 
Last edited:
Jason,

The STM32F4-Discovery board is only $16.25 at Mouser (zero stock at the moment) so I suspect ST Micro is subsidizing the heck out of these demo' boards. One thing I find interesting is that their previous STM32VL-Discovery board with 24-MHz Cortex M3 (128kB flash/8 kB RAM) is still available for only $9.88 and this would probably make for a nice inexpensive project base board too.

Your header looks good. I've only just started looking at the equates and structures in the header so it's going to be awhile before I'm proficient at anything. Setting up the buss and port speeds isn't entirely intuitive to me so I suspect a long learning curve ahead but I'm still very geeked.

Ultimately, I'd like to build an emulated Apple ][ computer (my first computer - March 1979). I'm hoping to use one of the DMA channels and some of the high speed RAM for a monochrome 600x480 VGA display. I'd also like to use an SD card as a pseudo drive and perhaps build an SPI interface for an Apple 3.5" disk drive. Big dreams, I know (grin).

Anyway, thank you very much for the intellectual and moral support on this STM32F4-Discovery board. I really, really appreciate it.

Cheerful regards, Mike
 
Last edited:
Nice, i didnt even know about that other board. The STM32VL, I will definitely get that one too!
Those are BIG DREAMS my friend lol would love to see some progress on it. Sounds oh too interesting!

Mike me being able to help you and others is a big surprise to me, you guys are the ones who helped me learn a ton and i should be thanking you all. So THANKS a ton...

BTW they are not giving these away anymore for free :( Just checked. A friend on mines wanted one.
 
So Tired... update
Code:
#ifndef stm32f407_h
#define stm32f407_h

//----------------------------------------------------------
//    RCC clock control register (RCC_CR)
//----------------------------------------------------------
#define PLLI2SRDY 0x8000000 //PLLI2S clock ready flag
#define PLLI2ISON 0x4000000 //PLLI2S enable 
#define PLLRDY    0x2000000 //Main PLL (PLL) clock ready flag
#define PLLON     0x1000000 //Main PLL (PLL) enable
#define CSSON     0x80000   //Clock security system enable
#define HSEBYP    0x40000   //HSE clock bypass
#define HSERDY    0x20000   //HSE clock ready flag
#define HSEON     0x10000   //HSE clock enable
#define HSIRDY    0x2       //Internal high-speed clock ready flag
#define HSION     0x1       //Internal high-speed clock enable

//----------------------------------------------------------
//    RCC PLL configuration register (RCC_PLLCFGR)
//----------------------------------------------------------
    //ADD IT HERE
//----------------------------------------------------------
//    RCC clock configuration register (RCC_CFGR)
//----------------------------------------------------------

//MCO2[1:0]: Microcontroller clock output 2
#define MCO2_SYSCLK 0x00000000 //System clock (SYSCLK) selected
#define MCO2_PLLI2S 0x40000000 //PLLI2S clock selected
#define MCO2_HSE    0x80000000 //HSE oscillator clock selected
#define MCO2_PLL    0xC0000000 //PLL clock selected

//MCO2PRE: MCO2 prescaler
#define MCO2PRE_2   0x20000000 //division by 2
#define MCO2PRE_3   0x28000000 //division by 3
#define MCO2PRE_4   0x30000000 //division by 4
#define MCO2PRE_5   0x38000000 //division by 5

//MCO1PRE: MCO1 prescaler
#define MCO1PRE_2   0x4000000 //division by 2
#define MCO1PRE_3   0x5000000 //division by 3
#define MCO1PRE_4   0x6000000 //division by 4
#define MCO1PRE_5   0x7000000 //division by 5

//I2SSRC: I2S clock selection
#define I2SSRC_PLLI2S 0x00      //PLLI2S clock used as I2S clock source
#define I2SSRC_ECLK   0x800000  //External clock mapped on the I2S_CKIN pin used as I2S clock source

//MCO1: Microcontroller clock output 1
#define MCO1_HSI   0x00         //HSI clock selected
#define MCO1_LSE   0x200000     //LSE oscillator selected
#define MCO1_HSE   0x400000     //HSE oscillator clock selected
#define MCO1_PLL   0x600000     //PLL clock selected

//RTCPRE: HSE division factor for RTC clock - Must be 1MHZ
#define RTCPRE     0x10000  //USE THIS VALUE TO SHIFT 2 to 31 EX: if HSE = 8Mhz then use (8<<RTCPRE) (0 or 1 - NO CLOCK)

//PPRE2: APB high-speed prescaler (APB2)
#define PPRE2_DIV0  0x00      //AHB clock not divided
#define PPRE2_DIV2  0x8000    //AHB clock divided by 2
#define PPRE2_DIV4  0xA000    //AHB clock divided by 4
#define PPRE2_DIV8  0xC000    //AHB clock divided by 8
#define PPRE2_DIV16 0xE000    //AHB clock divided by 16

//PPRE1: APB Low speed prescaler (APB1)
#define PPRE1_DIV0  0x00      //AHB clock not divided
#define PPRE1_DIV2  0x1000    //AHB clock divided by 2
#define PPRE1_DIV4  0x1400    //AHB clock divided by 4
#define PPRE1_DIV8  0x1800    //AHB clock divided by 8
#define PPRE1_DIV16 0x1C00    //AHB clock divided by 16

//HPRE: AHB prescaler
//Caution: The clocks are divided with the new prescaler factor from 1 to 16 AHB cycles after HPRE write.
//Caution: The AHB clock frequency must be at least 25 MHz when the Ethernet is used.
#define HPRE_DIV0   0x00      //0xxx: system clock not divided
#define HPRE_DIV2   0x80      //system clock divided by 2
#define HPRE_DIV4   0x90      //system clock divided by 4
#define HPRE_DIV8   0xA0      //system clock divided by 8
#define HPRE_DIV16  0xB0      //system clock divided by 16
#define HPRE_DIV64  0xC0      //system clock divided by 64
#define HPRE_DIV128 0xD0      //system clock divided by 128
#define HPRE_DIV256 0xE0      //system clock divided by 256
#define HPRE_DIV512 0xF0      //system clock divided by 512

//----------------------------------------------------------
//    RCC clock interrupt register (RCC_CIR)
//----------------------------------------------------------

//CSSC: Clock security system interrupt clear
#define CSSC_CLR   0x800000   //Clock security system interrupt clear - This bit is set by software to clear the CSSF flag.
#define PLLI2SRDYC 0x200000   //PLLI2S ready interrupt clear - This bit is set by software to clear the PLLI2SRDYF flag.
#define PLLRDYC    0x100000   //Main PLL(PLL) ready interrupt clear - This bit is set by software to clear the PLLRDYF flag.
#define HSERDYC    0x80000    //HSE ready interrupt clear - This bit is set by software to clear the HSERDYF flag
#define HSIRDYC    0x40000    //HSI ready interrupt clear - This bit is set by software to clear the HSIRDYF flag
#define LSERDYC    0x30000    //LSE ready interrupt clear - This bit is set by software to clear the LSERDYF flag
#define LSIRDYC    0x10000    //LSI ready interrupt clear - This bit is set by software to clear the LSIRDYF flag
#define PLLI2SRDYIE_ON  0x2000     //PLLI2S ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by PLLI2S lock
#define PLLRDYIE   0x1000     //Main PLL (PLL) ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by PLL lock.
#define HSERDYIE   0x800      //HSE ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by the HSE oscillator
#define HSIRDYIE   0x400      //HSI ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by the HSI oscillator stabilization.
#define LSERDYIE   0x200      //LSE ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by the LSE oscillator stabilization.
#define LSIRDYIE   0x100      //LSI ready interrupt enable - Set and cleared by software to enable/disable interrupt caused by LSI oscillator stabilization.
#define CSSF       0x80       //Clock security system interrupt flag - Set by hardware when a failure is detected in the HSE oscillator. Cleared by software setting the CSSC bit.
#define PLLI2SRDYF 0x20       //PLLI2S ready interrupt flag - Set by hardware when the PLLI2S locks and PLLI2SRDYDIE is set. Cleared by software setting the PLLRI2SDYC bit.
#define PLLRDYF    0x10       //Main PLL (PLL) ready interrupt flag. Set by hardware when PLL locks and PLLRDYDIE is set.Cleared by software setting the PLLRDYC bit.
#define HSERDYF    0x08       //HSE ready interrupt flag. Set by hardware when External High Speed clock becomes stable and HSERDYDIE is set.Cleared by software setting the HSERDYC bit.
#define HSIRDYF    0x04       //HSI ready interrupt flag Set by hardware when the Internal High Speed clock becomes stable and HSIRDYDIE is set.
#define LSERDYF    0x02       //LSE ready interrupt flag Set by hardware when the External Low Speed clock becomes stable and LSERDYDIE is set
#define LSIRDYF    0x01       //LSI ready interrupt flag Set by hardware when the internal low speed clock becomes stable and LSIRDYDIE is set. Cleared by software setting the LSIRDYC bit.

//----------------------------------------------------------
//    RCC AHB1 peripheral reset register (RCC_AHB1RSTR)
//----------------------------------------------------------
#define OTGHSRST   0x20000000  //USB OTG HS module reset Set and cleared by software.
#define ETHMACRST  0x2000000   //Ethernet MAC reset Set and cleared by software.
#define DMA2RST    0x400000    //DMA2 reset Set and cleared by software.
#define DMA1RST    0x200000    //DMA2 reset Set and cleared by software.
#define CRCRST     0x1000      //CRC reset Set and cleared by software.
#define GPIOIRST   0x100       //IO port I reset Set and cleared by software.
#define GPIOHRST   0x80        //IO port H reset Set and cleared by software.
#define GPIOGRST   0x40        //IO port G reset Set and cleared by software.
#define GPIOFRST   0x20        //IO port F reset Set and cleared by software.
#define GPIOERST   0x10        //IO port E reset Set and cleared by software.
#define GPIODRST   0x08        //IO port D reset Set and cleared by software.
#define GPIOCRST   0x04        //IO port C reset Set and cleared by software.
#define GPIOBRST   0x02        //IO port B reset Set and cleared by software.
#define GPIOARST   0x01        //IO port A reset Set and cleared by software.


#endif
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top