Manta M5P + CB1: GPIO availability

Basic Information:

Printer Model: Ender5 plus
MCU / Printerboard: Manta M5P
Host / SBC: CB1

Fill out above information and in all cases attach your klippy.log file (use zip to compress it, if too big). Pasting your printer.cfg is not needed
Be sure to check our “Knowledge Base” Category first. Most relevant items, e.g. error messages, are covered there

Describe your issue:

Confused/lost!

Setting up Manta M5P with CB1. Would like to utilize native GPIO for peripheral control. Would appreciate thoughts on two questions:

1- which, if any, GPIO pins on the M5P are available for other uses?

2- I ran ‘gpioinfo’ and got the attached file list. It shows 2 gpiochips (0 & 1). Are they both on the CB1? How does one relate the unused lines on this list with the GPIO pins on the board?

Sorry, 3 questions!

Any insights or directions would be greatly appreciated.

GPIO.pdf (77.4 KB)

Hi @MattyKlem ,

According to this pinout, all the GPIO’s are available on the left side of the board.

That list shouldn’t be relevant to figure out the unused GPIO’s. See the 40-pin GPIO connector on the left side of the above pinout.

To configure with Klipper, see the below guide (it says it’s for RPi, but it should work for CB1 as well):

No, the Raspberry Pi instructions linked above won’t work with the CB1.

@MattyKlem

Take a look here for accessing the CB1 GPIOs:

For accessing GPIO information and support, search on “BTT Pi 1.2” as that’s what the CB1 is based on.

I have played around with the CB1 GPIOs over the years in terms of adding an ADXL345, the BTT SPI 3.5 display and my own Functional Test hardware/software and what I learned is that if you want consistent IO operations that are well documented with lots of people having experience with it, go with a genuine Raspberry Pi CM4 (and if you can’t find it there, look for Raspberry Pi 4B operation).

The CB1 is good if you just need an SBC for a Manta M#P without any IO other than USB and Ethernet: HMDI and CSI/DSI are not connected and, as noted above, the GPIO is wonky.

The CB2 is better with HDMI and a kind of working CSI/DSI but still not as good as a genuine Raspberry Pi SBC.

1 Like

Thanks for the info. I have the pinout for the connector you pointed out; I guess I was asking if all of the assigned GPIO pins are available for other uses, or are some/all serving internal functions?

Good link - thanks. When I bought this setup the RPi was backordered. Unfortunately, I’m tied into the CB1, with the current video setup and existing addresses.

IMG_4213.pdf (1.0 MB)

Looks good - sorry, I thought the HDMI wasn’t connected on the CB1 (memory is going).

Yeah, I don’t know what’s going on with the CM4 right now - I needed a few a couple of weeks ago and they were backordered here in Canada for my usual suppliers as well as Digi-Key and Mouser. I ended up buying CM5s (work pretty much the same, just faster and hotter).

Just doing a quick look and they’re back in stock - I usually get the CM4101000 (“lite” - not eMMC with WiFi).

Maybe this could help you, don’t try to find the GPIO addresses in the same place or under same name in CB1, than in a Raspberry Pi

20250202 Calculo de gpio pins en BTT Pi.txt (825 Bytes)

Appreciate the help!

After much digging, I found the following answers to the original questions:

1-GPIO0 refers to the pins on the CB1; GPIO1 refers to the pins on the M5P native processor. 2-All of the pins on the 40-pin connector originate with the CB1 and are free and available. 3-To address them, one needs to define the pin with the following format: !host:GPIO# and follow with ‘SET_PIN command to turn off or on with the following format: SET_PIN PIN=host:GPIO# VALUE=(#) with the first # the specific pin number and the second # as 0 for off and 1 for on.

Hope this helps others

1 Like

Sorry it’s not exactly this way, but if works, is a good way, here one example:

[temperature_fan BTT-Pi_CPU] # Temperatura interna del procesador de la BTT Pi, usada para controlar su propio ventilador, en función de la temperatura

pin: BTT-Pi:gpio211

max_power: 1.0

shutdown_speed: 0

sensor_type: temperature_host

target_temp: 40

max_temp: 85

min_temp: 5

control: pid

pid_kp: 1.0

pid_ki: 0.5

pid_kd: 2.0

off_below: 0.1 # Mantener apagado si la potencia aplicada está por debajo de este valor

min_speed: 0.15 # Por defecto la velocidad minima es 0.3 # 20250228

And another one:

[output_pin salida] # Pin en BTT Pi

pin: BTT-Pi:gpio75

shutdown_value: 0

value: 0

Looks good - thanks

I’ll give it a try this weekend…

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.