Hi
As part of a test rig circuit I'm doing using flowcode 8 and a PIC micro has any one done, or can suggest best way to achieve the following reliably.
programming a ST micro (STM8) using the SWIM protocol an 8K hex file stored on an SD card (or other storage).
On previous test rigs I used an external laptop and ST-LINK programmer but I want to eliminate this.
Below are several methods, I'm sure there are more
1.) a USB interface to external programmer such as ST-LINK,
2.) directly programming using SWIM pins connected directly to the pic.
3.) program using SPI interface from this website http://kuku.eu.org/?projects/stm8spi/st ... _toc_head6
in circuit programming of ST micro using swim
-
- Posts: 28
- Joined: Wed Sep 26, 2018 2:15 pm
- Has thanked: 3 times
- Been thanked: 3 times
- Contact:
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: in circuit programming of ST micro using swim
Hello,
It sounds possible. I do something similar on the EB2 BL0061 board to program the on-board ST-ARM using it's built in bootloader.
If you look at the EB2 datasheet then the schematic for the board is included there. I connect to the chip using SPI and also via UART for backup. The programming is currently done using the UART connection plus a few of the IO.
Changing the source so that it comes from a file on an SD card rather than steamed via USB should be possible.
Here are my firmware files I created to facilitate programming the ST32 device, hopefully they are useful for you.
If you need more then I can maybe help but I might have to share files in private to avoid loosing EB2 IP.
I've not done ST8 so not sure how compatible these are. Probably not at all
It sounds possible. I do something similar on the EB2 BL0061 board to program the on-board ST-ARM using it's built in bootloader.
If you look at the EB2 datasheet then the schematic for the board is included there. I connect to the chip using SPI and also via UART for backup. The programming is currently done using the UART connection plus a few of the IO.
Changing the source so that it comes from a file on an SD card rather than steamed via USB should be possible.
Here are my firmware files I created to facilitate programming the ST32 device, hopefully they are useful for you.
If you need more then I can maybe help but I might have to share files in private to avoid loosing EB2 IP.
I've not done ST8 so not sure how compatible these are. Probably not at all
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 28
- Joined: Wed Sep 26, 2018 2:15 pm
- Has thanked: 3 times
- Been thanked: 3 times
- Contact:
Re: in circuit programming of ST micro using swim
Hi Ben
thanks for that, unfortunately any stm8 less than 16Kb does not have the ST bootloader. this means a user bootloader has to be written and programmed in somehow before spi programming can be used. we are using an 8K STM8
thanks for that, unfortunately any stm8 less than 16Kb does not have the ST bootloader. this means a user bootloader has to be written and programmed in somehow before spi programming can be used. we are using an 8K STM8