An adapter or a tiny bridge board (with a driver that works on FreeBSD that can convert the I2C lines of the Cirque touchpad into an USB-HID adapter.

Hello.

I'm looking for a small touchpad to add to the FreeBSD based phone that I'm trying to build,that will use the radxa zero 3W as an arm64 board.

I found one nice touchpad that has a size of 1.6 x 1.6 cm :

https://www.cirque.com/news-and-events-blog/2023/11/13/cirque-creates-the-worlds-smallest-trackpad

The problem iis that currently it supports only I2C. So,what I need is an adapter or a tiny bridge board that converts I2C lines (on the Cirque touchpad) into an USB-HID adapter because I don't want to solder the wires to the board,but I want to connect the touchpad to the radxa board via USB. The electronic layout that I have in mind is the one below :

sample.png


I'm looking one adapter and a driver that works on FreeBSD. Better if it is already exists for sure than that I should ask to someone to write it from scratch.

I tried to look for the right combination between adapter and driver and I found this old thread :


He talked about the adapter below,that can be bought even today :


I'm not sure if I can use it in my specific scenario and what about the driver ?

Does it already exist for FreeBSD ? should it be written from scratch ?

Please give me some ideas and suggestions.
 
FT232H should work. I bought some but never needed them.
No soldering required.

I believe there is a Windows Utility you must use to set the FTDI device between various modes of GPIO or SPI or I2C.
 
FT232H should work. I bought some but never needed them.
No soldering required.

I believe there is a Windows Utility you must use to set the FTDI device between various modes of GPIO or SPI or I2C.

Thanks. What about the driver from usb to i2c on FreeBSD ? Should it be written from scratch or I can use it one that already exist. This one :


may work ?
 
I do believe Mister Wulf's work is already committed. I am using it on my laptop.

Code:
# dmesg | grep iic
ig4iic0: <Intel Cannon Lake-H I2C Controller-0> at device 21.0 on pci0
ig4iic0: Using MSI
iicbus0: <Philips I2C bus (ACPI-hinted)> on ig4iic0
ig4iic1: <Intel Cannon Lake-H I2C Controller-1> at device 21.1 on pci0
ig4iic1: Using MSI
iicbus1: <Philips I2C bus (ACPI-hinted)> on ig4iic1
iicbus1: <unknown card> at addr 0x2c
iichid0: <DELL0831:00 044E:1220 I2C HID device> at addr 0x2c irq 51 on iicbus1
hidbus0: <HID bus> on iichid0

I don't know how the FTDI extras work that you are asking about. GPIO and I2C functions.

EEPROM Programmer Utility for FreeBSD
 
Can I ask why you are not using Raxda Zero's I2C pins?
You can daisy chain devices on i2c as long as they have different addresses.
 
Mister Wulfs contribution works so well on X86 because of AHCI and Intel BIOS routines.
You would have to fire up the drivers manually on Arm64 with u-boot.
 
Can I ask why you are not using Raxda Zero's I2C pins?
You can daisy chain devices on i2c as long as they have different addresses.

Because I don't want to make soldering to the Radxa board.

You would have to fire up the drivers manually on Arm64 with u-boot.

Oh. I don't use u-boot on my radxa board,but the EDK2 UEFI code of Jared McNeill :


It seems that it is going to be very complicated and I presume very expensive.
 
Mister Wulfs contribution works so well on X86 because of AHCI and Intel BIOS routines.
You would have to fire up the drivers manually on Arm64 with u-boot.

Can I attach the i2c wires of the touchpad to the radxa board without soldering them ?
 
You are fine on the Zero3 end using GPIO pins Pin 3,5,7 and you have already dupont wires with female ends. Don't be afraid to cut them in half and merge with other wiring, You can twist wire right?

But this I2C device you want to use has a connector?

It seems that it is going to be very complicated and I presume very expensive.
Well UEFI EDK2 uses ACPI like X86 so you might avoid some work enabling modules versus u-boot.
I want to mention EDK2 has two methods to boot. (It is a setting in the EDK2 BIOS screens)

FDT
ACPI
+ Combined

So you can dig in there and learn some. FDT is the way u-boot works. (FDT) Flattened Device Tree needs a description of every component in system.
This is the DTB file. A descriptor of hardware to the OS.
But ACPI method uses Plug and Play device detection. No hardware description required. ACPI detects things instead of being described.
Even with ACPI EDK2 still requires a separate build for each board. It has board descriptors just in a different sense.

What "Combined" Method does I dunno. Part device tree and part ACPI....

 
Looking at the actual DTB is a good way to troubleshoot problems. Like seeing what bus is where.

sysctl -b hw.fdt.dtb | dtc -I dtb | more
You can also pipe this to a file and edit the file and re-compile and copy it back to system for permanent changes to DTB.
Decompile/Edit/Recompile
 
---> But this I2C device you want to use has a connector?

yes :

Screenshot_2025-06-08_01-38-53.jpg


I've put in hold the engineer who should connect the touchpad to the bridge board because I was not sure what to do with the driver. I'm not able to do what you suggest,so I should hire another engineer. Too many engineers and quotes for this kind of solution. It's a shame because I really love that kind of touchpad. It's very nice.

If you can tell me that it will work out of the box or with minor software modifications I can go on.
 
Can you tell me why the touchpad that I've chosen until now for the phone,this one :


works out of the box even on FreeBSD without the needing to install a driver ? I've just attached it via USB on my FreeBSD 14.2 system now and sbam,it worked.

What technology it uses to don't requires a driver ? and most of all,its technology can be "translated" for making work the cirque touchpad so that it does not require any driver ?
 
What technology it uses to don't requires a driver ?
USB does lookup (devd) on included VID (VendorID) and PID (ProductID) for USB support. If devd matches a device it assigns a driver.
If VID and PID is not compiled in kernel via usbdevs the device will not work. Some devices require additional driver support like u3g needs VID&PID entries for cell modems.
I am not sure if additional driver support is needed for pointing devices.

and most of all,its technology can be "translated" for making work the cirque touchpad so that it does not require any driver ?
Well it depends. If you go I2C you might need to add an overlay to let the system know 'it is there' to assign a driver. (Maybe moot if you use edk2 you must test this out)
You would also want to have HID stuff loaded whereas x86 loads them automatically upon device detection.
Booting the device on an x86 machine will help you determine what modules you need to manually load on ARM64.
 
iicbus0: <Philips I2C bus (ACPI-hinted)> on ig4iic0
For instance here is my x86 laptops entry. Notice ACPI-Hinted.
On ARM you will not see that with u-boot. Only when booting with EDK2 would you see this on ARM.

For example from my entry you can see you would need to load the ig4 driver manually on ARM via loader to get this working along with other modules cited.
 
For wiring you simply find out what connector that is and buy a pigtail.
Knowing the connector is essential

Pigtails come in different flavors. Number of pins and pitch of pins being the most important. They are simply connector with bare wires.
Just twist together with your dupont wires and boom. You have a connection... Harder is getting software working.

JST PH series is very common connector:
Here is a DIY kit. Shop Around there are many. Figure out your pin number and pitch on connector.
This kit uses 1.25mm pitch connectors to dupont. You need to check your i2c connector for details.
 
Booting the device on an x86 machine will help you determine what modules you need to manually load on ARM64.
If you are wondering how to do that I have a x86 Minnowboard and it has GPIO driver with i2c over pins. APU1/2/3 does not have i2c from what I remember.

I went to the website for the circular touchpad and couldn't find many details. I left feeling queasy about that one. I would look at more than one model pointing device.
Adafruit really has nice modular open gear. Most with programming examples.
 
If I want to skip the FreeBSD driver drama,I should choose a bridge that must look like a plan USB HID mouse so that the ums driver can be used. I went on Upwork and I've explained that I want this. I found only a lot of engineers who asked me a sum of money that started from $400. Since one day I want that the users of my phone will replicate the hardware setup,I can't ask them to spend $400 for producing the touchpad. The whole cost of the phone can't be more than 300 $,the touchpad can't be produced with an amount of money greater than 60$. How can I escape from this trap ?

An idea could be to don't use the bridge,but to attach the cirque touchpad directly to the pins of the radxa board. But where are those pins ? There aren't visible pins on top of my radxa.

Despite this,If I don't want to use a bridge board,how can I let that the touchpad was seen as a plain USB HID mouse ?
 
There aren't visible pins on top of my radxa.
I wish I could find those cheaply. Board without pins. All I could find was Zero3E with 40 pin header attached. None bare. I bought a load from the radxa store direct.

I know Pi Zero comes bare but I had not seen Zero3 bare.

You should get another board with pins. Soldering on the Zero3 would required precision.
 
I know Pi Zero comes bare but I had not seen Zero3 bare.

I found it on Alibaba. I got it because without the pins it has a lower profile,needed for a phone.

You should get another board with pins. Soldering on the Zero3 would required precision.

The idea of soldering wires can't be applicable,because I can't ask to the people who knows nothing about electronics to solder wires. For sure there will be users who can do it,but a lot of others who cannot. I can't exclude these ones from the equation. For the same reason a lot of engineers (of software and hardware tends to force me to solder wires to the boards : maybe because they are biased,call it "professional deformation". I can't do it. It is against the philosophy of the project and it's not my goal or area of expertise. In this situation I'm forced to play the role of the devil's advocate.

Furthermore you talked about to use a pigtail. Is it useful to attach the wires and not to solder the wires to the board ?
 
You seem to be building a device for finish product. That is not wise. You build prototypes to test concepts. Prototypes can have ugly look they are just for testing.
You work out concepts on prototypes and then move to manufacturing with kicad scematics and contract manufacturers.
 
On something as expensive as a cell phone you would have a limited run of finish design to test usability and durability as well as regulatory acceptance.

Does everyone love the backberry style keyboard? You elicit feedback. Should we proceed forward? It will cost alot.
 
I do not mean to demean your project I just think it is too ambitious. We have a person working on PinePhone who knows what they are doing.
OK it doesn't have the exact features you want. You are going to make some device and you can't solder, machine or code?
I hope you can see my pessimism.
I can solder and machine yet I only finish a handful of projects. And its not because I can't code. I have ADD probably. Always a new project to distract me.

Best of Luck

You really need to figure out how to do Voice over Data or VoLTE. Without that you ain't got a phone but a fancy tablet.
 
I think I have found a cheaper alternative. Let's explore it. It consists to embed together these products :

a) Adafruit Mini I2C Gamepad with seesaw - STEMMA QT / Qwiic : https://www.adafruit.com/product/5743
b) the proper Stemma Cable that can bought here : https://www.adafruit.com/search?q=stemma qt cable
c) HUB board : https://www.adafruit.com/product/5625

They don't talk about an USB connection. It does not seem to be necessary. The driver should be here :


Since it has been written in Python,should work easily on FreeBSD ?
 
Instead of re-inventing the wheel why not modify the PinePhone ? Add the Super Mario Keyboard and Trackpad....

Custom chassis same board saves you tons..
 
I hope you can see my pessimism.

I see it,yes. But if I focus my attention on it,I will stop working on my project. Is this what should happen ? Maybe it is a nicer idea to ignore it ?
 
Back
Top