Skip to content

Instantly share code, notes, and snippets.

@looxonline
Last active April 2, 2024 16:08
Show Gist options
  • Save looxonline/89e79b2554771eee8aa8b6492f30400d to your computer and use it in GitHub Desktop.
Save looxonline/89e79b2554771eee8aa8b6492f30400d to your computer and use it in GitHub Desktop.

BIQU BX RASPBERRY PI TIDY INTEGRATION MOD

The BIQU BX is advertised as "RPi integrated". This statement can understandably cause a lot of confusion as to what it actually means. Some people have an expectation that it means that the pi will not need to connect to the front USB port of the machine. Others may have a different expectation.

The reality is that the integration comes in the form of a very clean mounting solution for the Pi combined with the ability to power and interface with the pi using the machine (touch interface). The USB port on the back of the TFT that connects to the pi does not offer a serial link back to the motherboard. It simply interfaces with a little MCU (CH554G) that translates the I2C signals from the touch controller on the TFT into signals that the pi can understand over USB. If you want the raspberry pi to communicate with the motherboard in order to send and receive commands (hint: you do) then you are still going to need a USB cable running from the pi to the micro USB port on the front of the machine....or are you...???

IMG_2037

WHAT YOU WILL NEED

In order to have an installation free from a front USB cable (as you see in the above image) you'll need nothing more than three dupont jumper wires with a male pin on one end and a female receptacle on the other (although I recommend making/buying at least 4 for reasons that will be explained later). The image below shows an example of the type of wires. They should be about 15cm long but you can use longer ones and tidy them up or shorter ones and join them together.

cable_m_f

HOW TO DO IT - HARDWARE

This is a very simple mod so you should be able to get it done in just a few minutes. It involves hardware and firmware. First, let's handle the hardware. The steps are provided below and then pictures illustrating those steps follow.

  1. Turn the BX off.
  2. Lift it up and feed the male ends of your dupont wires into the opening that the LCD cable feeds through. Route them over the top of the motor drivers.
  3. Plug the ends of the dupont cables into GND, RX and TX on the WiFi connector. Note that GND is not essential but I recommend using it since it will likely offer a cleaner ground to the pi and reduce bit errors. Take note of what colour connects to what pin.
  4. With the wires plugged in, run them neatly around the motor driver heatsinks and then use the existing loop on the underside of the case to secure them alongside the LCD cable.
  5. Connect GND to GND on the pi. TX on the BX (I'm about to start beatboxing) to RX on the pi and finally RX on the BX to TX on the pi. Don't connect RX to RX and TX to TX. Resist the urge.
  6. You're done for the hardware part.

IMG_2034

IMG_2035

IMG_2033

IMG_2036

GPIO-Pinout-Diagram-2

HOW TO DO IT - FIRMWARE

You'll need to use one of my custom firmware branches to get this to work. You can find them here: https://github.com/looxonline/Marlin

HOW TO DO IT - PI FIRMWARE

Finally you'll need to make some minor mods to the raspberry pi.

  1. Either place the raspberry pi SD card into your laptop and edit the config.txt file on the boot partition or ssh into your pi and edit the same file in /boot/config.txt. Choose an option that is easiest for you.
  2. Simply place the following two lines at the bottom of your config.txt file:
  3. enable_uart=1
  4. dtoverlay=disable-bt
  5. Now you have no choice but to ssh into your pi because the next step needs it. If you are on mac or linux you can ssh into the pi by opening a terminal window and typing ssh [email protected] and then using "raspberry" as the password. If you are on windows you can use putty to ssh into the pi. You'll need to know the ip address of the pi on your local network and you can use the same credentials (UN: pi PWD: raspberry) to get in over ssh.
  6. Once the ssh terminal is open type "sudo raspi-config" into the command line and hit enter. Enter the same password you used to log in when prompted to do so.
  7. Within the config menu navigate to "Interface Options" --> Serial port
  8. When it asks whether you would like the shell to be accessible over serial say NO.
  9. When it asks if you would like the serial port hardware to be enabled say YES.
  10. Reboot the pi once you are done.
  11. After the reboot access the octoprint web interface.
  12. Click on the little spanner at the top of the web interface.
  13. On the "Serial Connection" menu item enter /dev/ttyAMA0 into the box labeled "Additional serial ports".
  14. Reboot the pi once more.

Screenshot 2021-02-21 at 13 50 51

Screenshot 2021-02-21 at 13 51 22

WRAP UP

That's it! You should be able to simply tap the TFT when running in pi mode, wait a few seconds and hear the two beeps as it connects to the motherboard. I've tested this mod on highly detailed prints that span more than 24 hours and I've not had an issue so the communications are stable and reliable.

Oh...and about that fourth wire that I said would be useful. Keep it handy because the next little tweak I am working on is a way to safely and automatically cause the pi to shut down as soon as you flick off the power switch. Coming soon...

@janstanka
Copy link

@varazir
Copy link

varazir commented Mar 27, 2023

Looks like they fixed this with the new V3 display, I have connected my PI to the UART port on the back of the screen. No need to add new cables. I can control and print from octoprint.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment