@mgladkov, it should be possible using @ScruffR’s software serial code though I am not sure which pins are RX and TX on the shield. You could try flipping them in your code.
I noticed that you are not “priming” the BLE board by sending an “AT” command after you set the board rate. This allows the board to auto-set it’s baud rate and ensures the device is responding.
The only prerequisite for ParticleSoftSerial to work correctly is that the RX pin needs to be interrupt-capable.
With A0 as RX pin this would need D2 to not use interrupts concurrently.
With A1 as RX pin this would need A3 to not use interrupts concurrently.
I’m pretty new to electronics and might not understand that correctly.
What I’m trying to do is connect BLE Grove Device to Electron Asset Tracker v2 device with Grove sensor port that exposes A0 and A1 pins.
Documentation says that Asset Tracker itself uses RX/TX pins to connect to Electron. I’m not using any other pins only those Electron uses to communicate with Asset Tracker.
Tried sending “AT” command right after setting rate.
Tried swapping the RX/TX pins in the code.
Tried using SCL/SDA pins with SoftSerial.
Tried to use C2/C3 pins with Serial4 (Electron’s additional serial pins).
And I’m getting nothing back. BUT, if I wire RX to TX on the same board, I get the command I’m sending back, so it looks like Electron has these pins working correctly.
Do you have any other suggestions? Maybe some direction I could be taking in debugging this?
Seems the default baudrate is 115Kbaud so you can’t use the software serial library. You will need to connect to a hardware serial port on the Electron directly and modify your software accordingly.
And you can also set the startup baudrate to be stored permanently for next bootup.
But since we don't even know wheter or not the board works at all, I'd suggest you start with Serial1 on the default RX/TX pins on the Electron without the AssetTracker Shield.
Once you got the BLE board working with that you can move to ParticleSoftSerial, and after that re-introduce the AssetTracker Shield.