Hello Meghana, welcome to the grey hair forum
Are you sure the output from the potentiometer is an integer? If the value type is not correct, that is going to cause an issue similar to your description.
Secondly, use SerialBT thus:
SerialBT.print(n);
SerialBT.println();
Now then, the time span. At such a speed (100 milliseconds) the delay() function should not be used - it could have an adverse effect on the readings. It must also be the case that the App timing must be faster, allowing the app to receive and process a value before the next value arrives. I can't see what you have set the Clock in your App to, but that always requires experimentation, starting with a much longer time period and tweaking faster if required. The human eye cannot tolerate 100 millisecond value changes so I suggest you set the time period to be longer - the longest that the project can accept.
What is the Bluetooth version number of your ESP32 WEMOS LOLIN?
It might be using BLE.......
When receiving the data, you need to tell the App what the data delimiter is. In my example above it is SerialBT.println() = ASCII Char 10.
Also, the 'Bytes available to receive' Block is exactly that - a flag stating there are bytes, but it does not necessarily mean it holds all of the bytes. We use the math symbol -1 to ensure all bytes are read.
Assuming your ESP32 isn't running BLE, the above tweaks should fix your issue.
To replace delay() (You will need to change this to suit your SerialBT output):
//Fake data stream to demo elapsed milliseconds timing
//vars
unsigned long lgUpdateTime;
void setup()
{
Serial.begin(9600);
lgUpdateTime = millis();
}
void loop()
{
if(millis() - lgUpdateTime > 1000) //Loop approx every 1 second
{
lgUpdateTime = millis();
//Bluetooth to App
Serial.print("Hello");
Serial.print("|"); //Value delimiter
Serial.print("World");
Serial.print("|");
Serial.println(); //This empty last line tells App "End of Data" = Ascii LineFeed Char Number 10
}
}