Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Cressi: Bluetooth Android via Homemade ESP32 BT-Serial to IRDA bridge. #4147

Open
hb9eue opened this issue Mar 28, 2024 · 0 comments

Comments

@hb9eue
Copy link

hb9eue commented Mar 28, 2024

Hi Devs

Sorry for being to lazy to dig into the depths of the source.

I own a Cressi Leonardo and recently got Cressi Donatello for another family member.

The Cressi Leonardo uses serial IRDA @115200 baud for communication with it's vendor specific, very expensive RS232 cradle.
An ESP32 with a TFDU4101 can also do IRDA for a fraction of that price.

I tinkered around a bit, and after commenting out DTR/RTS toggles, which are required to initialize the vendor craddle, but which of course cause the USB-Serial interface of an ESP32 bord to reboot, I got import for the Leonardo working!

The newly purchased Donatello is advertised to communicate via Bluetooth-Serial! Yeah!

What a disappointment, when I realized you once more have to buy a very expensive additional bluetooth interface. But wait, the Donatello has some hole at the exact same location on which the Leonardo has it's IRDA interface. Is that Bluetooth vendor interface a simple IRDA to Bluetooth-Serial interface?

Let's comment out the DTR/RTS toggles in libdivecomputer for the goa/donatello model.

Success! I immediately can connect to the donatello and get's it's firmware version and modell information. (no dives yet).

And ESP32 has bluetooth too. So why not try to reconstruct that vendor bluetooth to IRDA interface with an ESP32 and then use Bluetooth-Serial to import the dives. In theory, that should also work from the subsurface anrdoid app.

Unfortunately I am stuck with the android app. I am able to pair Android to my ESP32 with the Bluetooth-Serial service. And I am able to select the bluetooth device in subsurface android.

But it looks like android is never properly opening the serial connection when I select 'import'. On the USB serial monitor on the ESP32 which I now can use to log some debugging information, I never get any data via bluetooth serial from the android app.

When I select the Bluetooth Device in subsurface andoid, vendor and type of the divecomputer also are being preset to something that is probably deducted from the BT MAC Address of my ESP32.

So that makes me wonder. Does the android app somehow check the MAC address of the BT device somehow defaults to only speak the BT protocol associated with that MAC address?

-Benoit-

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant