[SOLVED]Interesting problem

Post here all questions related to LibMaple core if you can't find a relevant section!
ag123
Posts: 1655
Joined: Thu Dec 19, 2019 5:30 am
Answers: 24

Re: [SOLVED]Interesting problem

Post by ag123 »

enableDebugPorts() is
https://github.com/rogerclarkmelbourne/ ... ug.cpp#L39

Code: Select all

void enableDebugPorts(void) {
    afio_cfg_debug_ports(AFIO_DEBUG_SW_ONLY);
}
u'd just need to check your connections again ;)
and only the SWD pins are enabled

for the other pins if you want to use them, make sure you set the pinMode() for them or they may just be input pins
miki
Posts: 26
Joined: Mon Jan 27, 2020 3:39 pm

Re: [SOLVED]Interesting problem

Post by miki »

Lol!
Looks like my core is old.

I use
void enableDebugPorts(void) {
afio_cfg_debug_ports(AFIO_DEBUG_FULL_SWJ);
}
and working

while.
afio_cfg_debug_ports(AFIO_DEBUG_SW_ONLY); is not.
*********************************************************************
edit:
using first

afio_cfg_debug_ports(AFIO_DEBUG_FULL_SWJ);//enableDebugPorts()
and after

afio_cfg_debug_ports(AFIO_DEBUG_SW_ONLY);

works well now
Ageorgiev86
Posts: 2
Joined: Mon Jan 02, 2023 8:31 am

Re: [SOLVED]Interesting problem

Post by Ageorgiev86 »

Hello
I am a newbie and have the following problem. I recently bought STM32F407VET6 and after configuring DFU mode, it was not recognized as STM32 bootloader but as APM32 ISP DFU mode. Is there any way to flash the factory firmware

Best Regards
Anton Georgiev
GonzoG
Posts: 403
Joined: Wed Jan 15, 2020 11:30 am
Answers: 27
Location: Prudnik, Poland

Re: [SOLVED]Interesting problem

Post by GonzoG »

There is no "factory firmware". They come out of factory without any firmware.

The APM32 is not a STM chip and probably won't work with stm32duino.
Ageorgiev86
Posts: 2
Joined: Mon Jan 02, 2023 8:31 am

Re: [SOLVED]Interesting problem

Post by Ageorgiev86 »

Works with stm32duino. through a serial port it recognizes it as a stm processor and in a stm32cubeprogrammer. The problem is that when I try to connect via USB, it recognizes it as APM32 ISP DFU mode and cannot be programmed. Is there a chance if I reprogram with slink that something will change?
ag123
Posts: 1655
Joined: Thu Dec 19, 2019 5:30 am
Answers: 24

Re: [SOLVED]Interesting problem

Post by ag123 »

just imho, for starters, get a real STM32 board; and chip to start with
there is a list on the stm32duino core repository
https://github.com/stm32duino/Arduino_Core_STM32
the 'preferred'' boards are like STM32F401 Nucleo or F411 Nucleo boards.
They are reasonably priced, has rather generous amount of sram and flash (compared to 'stm32f103c8 blue pills 20k sram 64k flash) and is decently fast - has the 'ART accelerator' and FPU.

The 'clone' chips are for 'advanced' users who is willing to work with possibly undocumented chips.
Technically, you would need to search or request from the APM32 manufacturer for the APM32 reference manuals and specs sheets - pinouts + all other details etc to work with APM32 chips. There is no assurance if any 'clone' chips is after all 'similar' in any way to a stm32, any 'assurance' would need to come from the APM32 manufacturer if you can even find their documents shared publicly.
There are also cases of partial documentation and many parts are undocumented, or in a worse case where documented features and functionality don't match that of a real device. Those things happens.

In all practicality, I'd guess any 3rd party can license ARM IP and design the IO extensions (e.g. gpio, uart, spi, i2c, adc etc ) and make their own ARM based microcontrollers.
GonzoG
Posts: 403
Joined: Wed Jan 15, 2020 11:30 am
Answers: 27
Location: Prudnik, Poland

Re: [SOLVED]Interesting problem

Post by GonzoG »

Ageorgiev86 wrote: Mon Jan 02, 2023 3:01 pm Works with stm32duino. through a serial port it recognizes it as a stm processor and in a stm32cubeprogrammer. The problem is that when I try to connect via USB, it recognizes it as APM32 ISP DFU mode and cannot be programmed. Is there a chance if I reprogram with slink that something will change?
No, it's not a case of different firmware, it's different hardware.
If you must use USB to flash firmware, you can try HID bootloader.
Post Reply

Return to “General discussion”