This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

BLE Test from PC

Dear all

is there any possibility to use PC to test the nrf51822, Instead of Android/ios app?

preferably a lib to be used with Java, so one can have some test cases.

What am I trying to do?

I'd like to test the firmware locally with my PC before sending a tag to develop Android/ios app. But is seems that BLE library for java is not available (for pc at least).

There are some solutions like:

  • lib for pyton
  • masteremulator.dll , but it is a C++ lib so I cannot access it via JNA
  • tx/rx lib, but it is a low level interface, that will send/receive byte buffers.

anyone having the same "problem" .

Thank you OL

EDIT: more precisely I'm searching a GATT Server Library

Parents
  • I'm not aware of any BLE libraries for Java, but I'd just like to highlight that the Master Emulator API is C# based, not C++. If you absolutely want to use Java, it doesn't really help you though, but for now, this API is the only one I know about, and the best we have to offer. As you probably know, it's installed into C:\Program Files (x86)\Nordic Semiconductor\Master Emulator\2.1.7.8226 with the Master Control Panel.

    Edit: It also seems as if it may be possible to trick Java into calling C# code, but I'm uncertain how that would work with Master Emulator's many callback and event functions...

  • I was afraid complexity of the DLL might make that difficult, yes... Unfortunately, I don't yet have anything like that.

    The only option I can think of, if you're feeling adventurous, is to try to implement something by doing raw HCI commands from Java, directly to the serial port exposed by the Master Emulator firmware. This would however be completely unsupported: I can't help with the exact commands or responses, and things may break with future versions, with you getting to keep both pieces. You'd therefore have to reverse-engineer the protocol MCP uses to talk to the dongle by looking at the messages in its log file, and try to recreate those in your own Java application. But if you only need specific scenarios, and you only want to verify that those keep working with future firmware versions, that may actually be doable...

Reply
  • I was afraid complexity of the DLL might make that difficult, yes... Unfortunately, I don't yet have anything like that.

    The only option I can think of, if you're feeling adventurous, is to try to implement something by doing raw HCI commands from Java, directly to the serial port exposed by the Master Emulator firmware. This would however be completely unsupported: I can't help with the exact commands or responses, and things may break with future versions, with you getting to keep both pieces. You'd therefore have to reverse-engineer the protocol MCP uses to talk to the dongle by looking at the messages in its log file, and try to recreate those in your own Java application. But if you only need specific scenarios, and you only want to verify that those keep working with future firmware versions, that may actually be doable...

Children
No Data
Related