Android Tutorial B4A-Bridge a new way to connect to your device

Status
Not open for further replies.

Torby

Member
Licensed User
Longtime User
When I tell the bridge on my android to allow bluetooth connection, it buzzzes 6 times buzzzzz buzzzzz buzzzzz buzzzzzzzzzzzzzzzzzzzzzzzz buzz buzz

It also does this when I stop the bridge from my pc. Perhaps it's just an annoying feature of my Samsung "Charge?"

(I'm loving your product.)
 

BLOKKER

Member
Licensed User
Longtime User
Can you explain please why B4A bridge wants access to phone calls and identity? I can imagine that an apk submitted by bridge is demanding such rights because of design. However B4A bridge is merely a transfer program that launches the installer after successful transferring the apk and do some nifty debugging when the transferred app is running so I can't figger out what the reason is that B4A bridge wants access to something that is not realy needful for its function.
 
Last edited:

qsrtech

Active Member
Licensed User
Longtime User
I'm pretty sure I tried to use bridge on a device with LAN vs wifi and it wouldn't seem to connect. Does it only work with wifi? I'm not sure how it could make any difference.
 

leitor79

Active Member
Licensed User
Longtime User
Hi!

I'm trying to use b4a bridge, I start it on my android, start wireless, go to b4a ide, tools, b4a bridge - connect wireless, set the device IP as shown on b4a bridge, the state on the status bar changes to "connected", but when I run the project... the app is installed on my bluestack app player instance I'm running on my pc (where I have never installed b4a bridge).

Also, I use the "logs" tab, I click "connect", a dialog appears with 2 items, my b4a bridge session and some "emulator-xxxx". I hit the b4a bridge session, I see the log of my device (and updates as my screen goes blank or when I turn it on), but in spite of that, when I run the app it is shown on the bluestacks app player.

Any ideas?


Regards!


PS: I did not try turn the bluestacks app player of since I need it running.
 

leitor79

Active Member
Licensed User
Longtime User
Thanks, Erel.

Since I made the question a few days ago, I've already shut down and turn on my PC, and the problem was gone. But I'll take your advice if it happens again.

Regards!
 

gudino jose luis

Active Member
Licensed User
Longtime User
I had the same problem connecting my device (huawei or samsung tablet)
but with these step fix:

1) the device is off
3) go to the command line (cmd)
2) ping the device, eg 192.168.0.100 -t
3) minimize window command line (cmd)
3) turn on the device
4) turn on dipositive expect and see on the command line the device to answer: Response from 192.168.1.0.100 : byte = 32 .....
5) connect b4a-bridge
6) No close command line (cmd)

Greetings (sorry for my bad English)
 
Last edited:

kiki78

Active Member
Licensed User
Longtime User
Hello Erel,

I start today to continue my development on new tablet.
As I use USB OTG to connect to external device I need B4A Bridge.
I use it without problem on previous tablet since one year.
On new one I can connect with B4A Bridge, install program, but I never see log.
I also try to connect via USB and this work normally with correct log.
I make a little program with OSLibrary that show Device property.

On fresh started tablet this is what I obtain in B4A Log with B4A Bridge and Filter uncheck.
B4X:
LogCat connected to: B4A-Bridge: unknown MPQC1114-138723275017319
--------- beginning of /dev/log/main
error opening trace file: No such file or directory (2)
loaded /system/lib/egl/libEGL_VIVANTE.so
loaded /system/lib/egl/libGLESv1_CM_VIVANTE.so
loaded /system/lib/egl/libGLESv2_VIVANTE.so
Enabling debug mode 0
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Service (service1) Create **
** Service (service1) Start **
GC_CONCURRENT freed 237K, 8% free 6274K/6791K, paused 2ms+2ms, total 27ms
Connected to B4A-Bridge (Wifi)
** Activity (main) Pause, UserClosed = false **
Installing file.
PackageAdded: package:b4a.example

This is what I obtain with USB Cable (with Filter check)
B4X:
LogCat connected to: 0123456789ABCDEF
--------- beginning of /dev/log/main
--------- beginning of /dev/log/system
** Activity (main) Create, isFirst = true **
Device = gs702a
** Activity (main) Resume **

B4A 3.50, Bridge 2.09

Have you an idea ?
 

Attachments

  • Log with USB Cable Without Filter.zip
    19.1 KB · Views: 463

kiki78

Active Member
Licensed User
Longtime User
I just test it and that's work on Debug mode. Thank you Erel for quick response

For information, my previous tablet (Samsung Galaxy Note 10.1) is with version 4.1.2 and show log in Release mode also.
The new one is 4.1.1.

Another difference is when Filter is uncheck, I only see very small log on new one as opposed than Note or also with USB cable.
Is it normal ?
 

Sannie72

Member
Licensed User
Longtime User
Hello Erel,

I found an odd behaviour with B4A-Bridge v2.09 since I installed the latest B4A version 3.50. I am a registered user. Before 3.50 everything worked fine.
Now the following happens:
I can connect without a problem over WiFi. When I hit F5 (or Alt-1) a screen appears on the device showing the permissions of the new app. At the bottom of this screen there are two buttons: 'Cancel' and 'Install'. The Cancel button works as expected, but the Install button does not respond. Also changing the orientation of the device does not help. Logcat shows the following:
B4X:
LogCat connected to: B4A-Bridge: samsung GT-I9300-352993059312512
--------- beginning of /dev/log/main
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Service (service1) Create **
** Service (service1) Start **
** Activity (main) Pause, UserClosed = false **
** Activity (main) Resume **
Connected to B4A-Bridge (Wifi)
Streams_terminated
Connected to B4A-Bridge (Wifi)
Installing file.
** Activity (main) Pause, UserClosed = false **
Running B4A version 3.50 on Windows 7 Enterprise SP1, mobile device Samsung GT-I9300.
What can I do to make this work again?
 

Sannie72

Member
Licensed User
Longtime User
It is most probably not related to a change in v3.50. Does it happen with any app you try to install?
I tried also with a completely new project; I created a hello world with one activity and a label, but that also does not work. USB works fine, but B4A-Bridge in Wireless mode does not.
I get to the point where I have to click 'Install', but the button does not respond.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…