Klipper Firmware Fails to Start on Custom STM32F070 Board

Thank Kevin,

That helps explain how the decision process works.

I’ll follow up when I have my boards and have (hopefully) gotten them working.

Happy New Year!



There is another issue: when selecting STM32F070 as the MCU in menuconfig , the .config file contains the entry CONFIG_MCU="stm32f070xb" . This leads to everything being configured specifically for stm32f070xb . While this is not necessarily a problem and can be manually adjusted as needed, rewriting everything and performing tests would only make sense if the PR is accepted. Otherwise, investing time into this process would clearly be impractical.

1 Like

The issue is also that the STM32F070x6 only has one SPI, while the initialization in spi.c assumes at least two SPI interfaces. Coming back to the PR: if it were accepted, it would make it possible to use my custom PCB. This particular MCU was chosen because it is inexpensive and fully meets the functional requirements of the device.

Overall, all of your assumptions were correct from the beginning, and unfortunately, as sometimes happens, I overlooked some details during the design of my PCB.

A huge thank you to all of you for your support. I couldn’t respond for some time, and your clarifications to other participants were truly outstanding.

I’m glad you could confirm what I’m seeing.

I think the STM32F070F6P6 is interesting and can see value in it for a simple/cheap peripheral interface.

So, I spent a couple of days over my Christmas holidays designing a board based on it:

When it comes in, I’ll look at the Klipper firmware Kconfig file and try to go through the process of adding the correct STM32F070x6 build parameters and see if I can get my board working.

Let us know how you’re making out and I don’t expect to see the boards for a few weeks (I will submit them tomorrow for fab and assembly) but I’ll keep you up to date as to my progress.

1 Like


But there may be two variants of the microcontroller, for example:

( ) STM32F042
(X) STM32F070xB
(X) STM32F070x6
( ) STM32F072

Are you not considering this option?
This MCU, due to its low cost, is ideal for various applications such as sensors, accelerometers, servos. In general, for any application as an expansion board.
At a price of $0.70 per hundred, it’s a very attractive solution, but your hesitation regarding the feasibility of the update request might be the only reason why a potentially large number of useful devices won’t get a chance.

I wanted to take a look at your developments, but unfortunately, your domain is parked. If I understand correctly, and judging by the level shifters near each port, is this an expansion board for various applications and an accelerometer at the same time? It’s just that, without seeing the bottom layer, I can’t understand what the screw terminals are for—could they be for additional power supply?
I’m very interested to learn more :blush:

Read Kevin’s response again - he wants a user base of at least 100 before committing to a new MCU. That seems reasonable and I don’t think it’s worth his effort unless there are boards built specifically with the MCU and people are using/buying them.

Otherwise, he will get inundated (and probably is already) with people asking for support of MCUs.

I don’t think it’s an unreasonable position.

Take a look at LCSC - you can get a single STM32F070F6P6 for considerably less than $0.70. That’s what got me excited about them.

I guess you’re looking at 3dapothecary.xyz - I’m not turning on the website until I have something to sell/display on it.

Here’s the board’s schematic:

2025_01_05-KIO_SCH.pdf (118.5 KB)

It’s jumbled because the board came together over the past week and I decided to try a) putting everything on a single page rather than a hierarchical format over several pages which would only have one or two circuits on it, b) make the PCB as small as possible (it’s 36mm square which is a bit bigger than my goal of 30mm which wasn’t possible because the connectors wouldn’t fit in the targeted space if they were put on the perimeter) and c) I haven’t done a two sided PCB in about twenty years so I thought it would be an interesting challenge. The board was designed for minimal cost and the component selection reflects that.

The board features are:

  • Accelerometer using LIS2DW12TR (nice part and much cheaper than the ADXL345)
  • Two traditional 3D Printer 3Pin 5V sensor inputs in the yellow headers
  • Two traditional NeoPixel 3Pin drivers using the white headers
  • Thermistor input with 4k7 pullup to 3V3 using the 2Pin red header
  • SSR/N-Channel MOSFET control using the 3Pin Screw Terminal Block (The pins are 5V, open drain transistor output and GND). The 5V Terminal can either be used as the SSR control positive voltage or provide a positive voltage on the open drain output by using a pull up and then it can be used with a N-Channel MOSFET board as was discussed elsewhere. The genesis for this feature should be pretty obvious if you look at the discussions happening here over the past week.
  • Status/indicator LED
  • DFU Buttons
  • SWD Header
  • Backside has all Pin IO information:

I’m reasonably pleased with how it came out. I would have liked it to be a few mm smaller and there are a couple of spots on the backside that I wish I could have figured out how to minimize the breaks in the ground plane but it was a fun exercise on multiple levels.

1 Like

The price is exactly what attracted me☺️. There is a demand for such devices in my group. Of course, compiling firmware manually is not an issue, but I would prefer having official MCU support.

1 Like

Heya,

I don’t know if you’ve been following this thread:

Could you try out the patch that @koconnor came up with for the STM32F070x6?

I’ve just done it for my board and it works quite nicely with the USB interface.