@@ -32,14 +32,44 @@ blocks the I2C bus**. The push button is for reset. The CPU runs on 3.3V, a
3232linear regulator is integrated on the board. The micro USB connector is only
3333for (5V) power supply, the data lines are not connected.
3434
35- ![ Schematic of the STMS103 board] ( stm8blue-schematic.png )
36-
3735All CPU pins are easily accessible on (optional) pin headers (pitch 2.54mm,
3836perfect for breadboards).
3937
4038They are very similar to the [ ESP14 Wifi-boards] ( esp14.md ) and
4139most programs will work fine on those chinese gems as well.
4240
41+ ## Connection to the flash tool
42+
43+ I am using the ST-Link V2 compatible flash tool in the green plastic
44+ housing. The one in the metal housing uses a different pinout.
45+
46+ Connection to the flashtool:
47+
48+ Signal name |P3 on CPU board |Green flash tool|Metal flash tool
49+ ------ |:-----: |:-----: |:-----:
50+ 3V3 |1 |2 | 7
51+ SWIM |2 |5 | 5
52+ GND |3 |7 | 3
53+ NRST |4 |9 | 1
54+
55+
56+
57+ ## Crap alert
58+
59+ Due to bad PCB production quality, some more recent lots (as of 2020) of the
60+ stm8blue boards seem to have either no working connection to GND on the SWIM
61+ connector or a short circuit from the SWIM pin to GND.
62+
63+ ![ A nasty short to GND] ( bad-etching.jpg ) The SWIM pin is shortend to GND
64+
65+ Try connecting GND to the other GND board pin or power the board via USB.
66+
67+ Most boards ship with a pre-programmed blinky. If the LED blinks when the
68+ board is powered via USB but doesn't when it is only connected to the flash
69+ tool, your board is probably missing the GND connection.
70+
71+
72+
4373## Unlocking a write protected MCU
4474
4575My breakout boards came preprogrammed with a blink program and with active
@@ -65,28 +95,6 @@ another software package (see
6595[ issue #85 ] ( https://github.com/tenbaht/sduino/issues/85 ) ).
6696
6797
68- ## Connection to the flash tool
69-
70- I am using the ST-Link V2 compatible flash tool in the green plastic
71- housing. The one in the metal housing uses a different pinout.
72-
73- Connection to the flashtool:
74-
75- Signal name |P3 on CPU board |Green flash tool|Metal flash tool
76- ------ |:-----: |:-----: |:-----:
77- 3V3 |1 |2 | 7
78- SWIM |2 |5 | 5
79- GND |3 |7 | 3
80- NRST |4 |9 | 1
81-
82- *** Crap alert:*** Some lots of the stm8blue boards seem to have no working
83- connection to GND on the SWIM connector!
84-
85- If the board does not respond to the flash tool when only powered from the
86- SWIM connector, try powering it from the the USB connector or the power pin
87- instead.
88-
89-
9098
9199## Pin number mappings
92100
@@ -176,3 +184,9 @@ to drive the LED by writing a zero to the output register.
176184
177185D5/D6 (PA1/PA2, OscIn/OscOut) are weaker than the other pins. Try avoiding
178186these pins for LEDs and other higher current applications.
187+
188+
189+ ## Schematic
190+
191+ ![ Schematic of the STMS103 board] ( stm8blue-schematic.png )
192+
0 commit comments