How to send notifications from a phone to device connected via BLE - android

I am trying to develop a companion app for a project of mine.
I want this app to relay incoming notifications on my phone to a device connected via BLE. This device will then display the text data on a screen, similar to a heads up display so that I can use it in my car and not have to go through my phone while driving (also illegal of course).
I want to know what is required for my app to be able to get notifications, and send it via BLE to the already connected device. I'd also really like to know if this can be done for an iOS app since I would prefer to end up with the final app being built for iOS. If not, android is fine for now.
This device is an ESP32 and will run its own code to execute actions when text is received.
Thank you

Related

Interaction between Android Tablet to Android Phone and Android Tablet to Headphone/Helmet via Bluetooth

Bluetooth communication should happen between Android Tablet, Android Phone and Headphone/Headset/Helmet.
Android Phone: Responsible to send Incoming call and Media Infotainment data to the Android System (Tablet).
Android System (Tablet): is responsible to take actions [Media: (Play/Pause/Next/Previous) and Phone call: (Accept, Reject, Silence)] based on the data received from the Android Phone. Also send Map navigation instruction to the Headset/Helmet.
What I had tried so far,
RFCOMM connection between Android Table and Phone that send and receive data to and from Tablet to Phone. But doesn't allow to control phone to take actions sent from Tablet.
Possible approach
Bluetooth Headset profile will do the same thing, so any way to set Bluetooth profile while connection between Tablet and Phone will solve the Media and Incoming phone call requirements.
Is these possible? If so what are the possibilities to achieve the same?

Android app to send and receive a file automatically when get connected via bluetooth

I am new to android world.I want to design an android app in which all connections will be through bluetooth. It will works as follows
as I click some button like start it will connect to one of the paired devices(mobile) and get a file, store it somewhere and eventually disconnect with that device.Then it will connect to the second device, get a file, store it and then disconnect with that device and so on. It will repeat the same procedure for all the paired devices.
And later on I will replace those paired mobiles with sensors and will collect the the data.The whole process should be automatic without user's intervention.
Guys please help me. Is it possible for a mobile to send a file automatically as it connects to a particular mobile.

Android send notification message to device without client app installed on the device

I would like to know is there any way to send notification from a server to an Android device without a client app installed on the device. Does android OS has such functionality. Based on the answer here Does Android support near real time push notification? Google Cloud Messaging do similar things, but it seems the client app need to be installed on user mobile.
Basically what I want do when an android device comes in range of an iBeacon
I need to send the notification messages to the user mobile.
Is there any way to achieve it. Any possible solution?
Edit:
The real scenario is like,
I have the beacon placed in somewhere, when the a device comes in range of the beacon, some how I have to detect the device(if the device Bluetooth is on) and get some id of the device send notification from cloud server. Where as the device(Android phone) don't know the beacon is there, or there is no app installed on the device to detect the beacon.
I am not sure whether it's possible to achieve the above goal in such a scenario.
Please let me know your valuable feedback.
Chrome 42 or higher for Android supports push notifications from websites, which allows you to send notifications without installing an app.
If you're specifically looking to start notifications from a beacon, Chrome 49 added support for beacons

Android local voice service

As we all know, you can use an Android phone to dial a number to make a phone call.
Is there any way using the Android SDK to dial a number, but connected to a service running locally on the device?
My aim is to create some sort of interactive voice service (running locally on the phone), that could be used with bluetooth device that only support making phone calls...
My back up plan would be to run an Asterisk server in the house to handle this, but it would be nice to have something running on the phone instead.
Thanks

Android app to detect incomming IM

I am building a small robot that I can drive around outside of bluetooth range -- so I want to send signals via the internet. The eyes and ears are an old Droid phone (running android 2.2.3). I can get the phone to talk to a bluetooth module to control the robot (tap the left button, it sends the letter L to the bluetooth, which turns the robot etc etc). I have got Skype or Tango to both give me video and sound to a pc, so that problem is sorted. The thing I cannot solve is how to send e.g. the letter L over the internet and for the phone to know what I sent. I wrote an app that checks the contents of a WebDB every second (it works), but that app stops running when I power up the video chat application. So the question is...how can I get my old Android phone to know that someone via the internet has sent the letter L via Skype or some other way, and for that to happen while I'm also running a video chat application? PS...my phone has no number, no carrier, and can't receive sms messages or calls.
You wrote:
I wrote an app that checks the contents of a WebDB every second (it works), but that app stops running when I power up the video chat application.
So the answer is simple. Write an Android Service that runs on the background and polling the internet. Read about android service, and you can see a real example in the ApiDemos. Good luck!

Categories

Resources