Velorexe / Unity-Android-Bluetooth-Low-Energy

A Unity Android plugin to support basic Bluetooth Low Energy interactions.
The Unlicense
101 stars 21 forks source link

license and android source code #19

Closed adabru closed 1 year ago

adabru commented 1 year ago

Hi @Velorexe 🙂,

do you have the android source code in another repository? And there is no license?

Do you know of any other android unity open source project? Someone asked in a project I try to support.

Velorexe commented 1 year ago

Hey @adabru

Yes, the Android source code is also on my profile and can be found right here: Android Bluetooth Low Energy Java Library.

Instructions on how to build is there as well, though if you need any help you can always contact me.

For the license, no, there is none. I should probably add one since I've had a previous inquiry about it as well. But it's completely open-source and can be distributed in any product. Credit is optional, appreciated, but not mandatory.

adabru commented 1 year ago

You were so quick in adding the license 😀 Thanks for the link!

Another question: How did you debug your java code? Did you do it from within Unity?

Velorexe commented 1 year ago

Unfortunately debugging a Java library from Unity is a mess, and since this is an Android project, debugging in the Editor also sucks. So I had to debug by building every single time, check the logs and check what could have caused the exception. I'm still looking for a better way, so if you find one, please let me know!

adabru commented 1 year ago

I've never done android development 🤷 What you write sounds frustrating.

You've already mostly separated your unity and android parts I guess. Also the interface is quite completely defined. Maybe it is an option to:

Velorexe commented 1 year ago

Oh actually, now that you mention it, I did use a small android app in the beginning and used that, the only problem with that is that you'd have to remove all Unity related code (getting context and such) from the library before compiling.

I could upload a version that checks if it uses Unity then provides the context in two different ways, then use that along with a lil' app to debug it. I'll look into it in the future, I'm currently looking at if I can turn this project in both a server and client setup.

adabru commented 1 year ago

you'd have to remove all Unity related code

Maybe you can provide a unity stub that just doesn't do anything.

Good luck 🙂