Support for ESP8266 and Firebase - firebase

I am trying to connect to Firebase from an ESP8266 microcontroller. This device has limited RAM and can't handle large TLS fragments. The developer who supports TLS for ESP8266 implemented Maximum Fragment Length Negotiation only to find that Firebase servers ignore it. Is somebody at Firebase listening? Can anything be done to turn on this option on your servers?
You can see the discussion here, towards the bottom.

I use some Esp8266's with Firestore to monitor my foil tunnel for tomatoes and it works good.
I use the Firebase-ESP-Client from mobizt.
https://github.com/mobizt/Firebase-ESP-Client

Related

Can I use HTTPS and SSE client libraries on Arduino PORTENTA Machine Control board?

I am looking for simple board for IoT professional projects. I bumped into the Arduino PORTENTA Machine Control board a while back, but I cannot get some things sorted out:
What libraries can I use on this board (mainly SSE and HTTPS libraries)?
Does it have enough computational power to do HTTPS requests (not HTTP but HTTPS)?
What am I trying to achieve:
I am trying to build a project around Google’s Firestore / Firebase.
I need to communicate to it via REST API.
Google enables only HTTPS communication with their databases – and
normal Arduino boards can’t do HTTPS requests because they do not
have enough power.
So, I need either SSE client + HTTPS requests library to run on the
PORTENTA board OR Firebase Realtimedatabase library (I know the
library is built on HTTPS requests – but if it’s not compatible I can
recreate it with SSE client and HTTPS requests).
Other info:
By SSE I mean Server Send Events for Realtime communication and
updates to the board :)
I have no problem programming it in native Arduino language or in Micropython.
The answer below states that I can use those libraries if the board is supported - but I don't know how to know if the board is supported :/
I have never heard that Arduino lacks the power for HTTPS requests and Arduino have documentation on how to make HTTPS requests for many of their official boards: https://arduinogetstarted.com/tutorials/arduino-https-request
If you are using an unsupported board you will have to route the traffic to another host first. Either another Arduino or an ESP to act as the main host/client that it can communicate to access external resources such as Firebase.

Why use mqtt server for BLE gateway?

I have a BLE temperature sensor, which should send measurements to an ESP32 via a BLE connection and my plan was that the ESP32 could send the measurements via WiFi to my database (Firebase Realtime Database). However, I have seen from a few tutorials that a mqtt server would be neccesary (see the screenshot below - link to the video: https://www.youtube.com/watch?v=PBYCG-ypvRY). Could someone please explain to me why the mqtt component is neccesary? Currently I am measuring temperatures using my ESP32 (without the BLE temperautre sensors) and sending them directly to the database, so I am confused as to why with BLE I would need a mqtt server.
Thanks for your help in advance!
You don't need MQTT. It's just one of the IoT-friendly protocol alternatives (like HTTPS, AMQP, CoAP, homebrew, etc) available to you for device-to-server communication. There are pros and cons to each one. It's up to you to choose whatever solution is relevant to your system.
If you've already implemented the Firebase HTTPS interface and it does the job, you're done.
If you are having problems, note that the Google IoT Core also prescribes MQTT (or, alternatively HTTPS) as an underlying messaging protocol - used together with the Device SDK for Embedded C. But this is for people who want to have a large-scale authentication and management solution for their devices. By all means, stick to your existing solution if it works.

Multiple connections on one BLE beacon

I have a single BLE beacon and I try to connect to it with multiple Android phones in order to get the RSSI, and see who is the closest to it.
But, just after the first phone connect to the beacon (via a BluetoothGatt), the beacon never appears from the scan again in the scan results of the other phones, so they cannot connect to it too.
The only solution I see is to scan without connection and get the RSSI from the scan result, but I don't think that is an elegant solution.
Is there a way to have multiple connection to a single BLE beacon and get the RSSI ?
Thank you
It's up to the BLE device to decide if it supports more than one connection. If it only wants to support one connection, it can be programmed to stop advertising when a connection is established. From a client perspective, there's not much you can do about that. If you can modify the firmware in the beacon, you can add support for multiple connections.
Otherwise there is nothing wrong with using the rssi in the advertising packet (although you can't make use of BLE security (pairing / bonding)).

WEBRTC peer connection blocked by UAE?

I have implemented basic WEBRTC peer connection between two clients and uses RTCPeerConnection and getUserMedia APIs for it. I am fetching Audio tracks only from the stream.
Even though my signalling works, ice agents are shared, streams are shared as well.
The audio comes out distorted completely.
However, if I utilize a VPN on one device the other device can hear the audio coming from the device with VPN very clearly with no hiccups.
NOTE:
I tried this with only stun and with a combination of stun and turn servers(viagenie).
Can someone tell me how do i debug the issue, what to look for?
Is my ISP involved in messing around with the media stream? (I live in the UAE.)
Thanks in advance!
i think the problem is UAE ISP block the STUN/TURN PORT (3478,5766 ...)
you can try to use 443/80 port?

How to spoof individual BLE packets

I'm doing a security analysis project on an IoT device that uses an unencrypted BLE connection (with ATT protocol) and I want to spoof an individual BLE packet with the source address of an already connected device. Is there some tool or API that would allow me to do this easily? I've already tried gatttool and spooftooph but they seem to be connection based and don't allow you to send out single packets with modified fields (as far as I could tell).
You will need some hardware where you can access the radio peripheral directly. What you basically need to do is to find or write a ble sniffer firmware, with the modification that it at a given moment sends a packet on the connection it is currently listening to. But note that the signal strength must be stronger than the original device's signal so it doesn't interfere.
The only open source project I'm aware of is Ubertooth. You will also be able to do this with an nRF52 but then you need to write your own sniffer firmware since Nordic Semiconductor's is closed source.
I can't comment on Emils reply yet, < 50 rep:
Nordic Semis nRF Sniffer v2 needs only the nRF52DK and wireshark to work as a general BLE sniffer. At 40$ it's not that expensive. I know for a fact they will release a new dongle soon that will sell for ~10-15 bucks if you can wait a a month or two.

Resources