Replace HC-05 with Photon 2 BLE

I have an older project that uses a Photon and an HC-05 bluetooth 2 module for serial uart connection over the air. I'm looking to upgrade the project to a Photon 2 which has internal BLE. I'd like to replace the HC-05 with Photon 2 BLE without changing the bluetooth 2 app that communicates using short ASCII strings. I see that this problem has been solved for Particle devices that use Nordic chipsets, but I understand that the Photon 2 does not use Nordic. Will solutions for Argon etc. still work or Photon 2, or is there an alternative solution?

If the version for the Argon/Boron/B-SoM/Tracker (Nordic nRF52840) uses the standard Particle BLE API calls and does not bypass Device OS, it should work with few if any changes. The only exception is if it uses BLE long-range (coded PHY), which is not supported on RTL872x (P2/Photon 2).

If the code is bare-metal nRF52840 code, then it won't work, but then again it would also not work on the nRF52 Particle devices without removing Device OS and all Particle features, either.

@rickkas7 : Thanks for the quick reply. I found this earlier posting about your library, which I think is what I want:

Your response in this post seems to indicate that your library relies upon some special code that Nordic added to their SOC. So I was wondering if this solution would work on a Photon 2 which doesn't use Noridc?

My problem seems simple: I have an app that uses bluetooth 2 SPP to communicate with a robot. The old robot design uses an HC-05 bluetooth module on the robot end of the project. I'd like to re-work the robot to use a Photon 2 (the old robot used a Photon which is now out of production). Since Photon 2 has BLE, I thought about saving the cost of the HC-05 by using the internal BLE of Photon 2, but of course BLE does not support SPP. So - is there any (simple) solution to add SPP support to the Photon 2 that doesn't require extra hardware (like the HC-05)?

Sorry, the HC-05 works differently than I remembered. It uses the Bluetooth Serial Port Profile, which is deprecated. It's sitting directly on Bluetooth RFCOMM layer, and not Bluetooth LE (BLE) and cannot be implemented on either RTL872x or nRF52 devices.

The other post includes the Nordic-style serial port, which is different than the HC-05. It's a serial port protocol sitting on BLE, not directly as a Bluetooth Profile. The Nordic protocol isn't at all Nordic-specific, and that code does run on the P2/Photon 2, and is embedded in mobile apps like Adafruit Connect. It's different than the protocol use by the HC-05, however.

1 Like

Thanks. I understand the difference now.