larsbrinkhoff / xForth

Experimental Forth cross compiler for tiny devices
GNU General Public License v3.0
61 stars 14 forks source link

Test STM8S207RBT6 #61

Open larsbrinkhoff opened 4 years ago

larsbrinkhoff commented 4 years ago

I got a STM8S207RBT6 board. It was recommended by @TG9541, thanks! It's a performance STM8S with plenty of room: 128K flash, 6K RAM, and 2K EEPROM.

larsbrinkhoff commented 4 years ago

Start by checking the old STM8S103 test program. There was some bit rot. With that fixed, I can program the device and get a blinking LED.

However, with the 207 part, I get this from stm8flash. It's likely some addresses have to be adjusted.


Determine FLASH area
Writing Intel hex file 562 bytes at 0x8000... Tries exceeded
larsbrinkhoff commented 4 years ago

Reading the flash contents seems to work fine though. Memory protection?

https://github.com/TG9541/stm8ef/wiki/STM8S-Programming#resetting-stm8s-devices-to-factory-defaults

larsbrinkhoff commented 4 years ago

I read out the option bytes and they are all 00 which ought to be good.

larsbrinkhoff commented 4 years ago

Tested writing "00 00 ff 00 ff 00 ff 00 ff 00 ff" to option bytes as pointed out in URL above and elsewhere, and now I can write to flash.

TG9541 commented 4 years ago

Hi Lars, just noticed the @ - good that it works!