Communicating with smartphone via bluetooth module

Hello,

I working on a micro controller with arduino and I wanna be able to vary the speed of a motor with the input from a smartphone app via bluetooth. I managed to came up with a code that can read the data sent from the smartphone app, but instead of reading the number 255, it reads the digits individually, like:
2
5
5
I used the SoftwareSerial.h library so that I don’t have to keep removing the TX and RX every time I upload my code. But even without using the library, I got the same result, only getting the digits a lot faster and multiple times. Like
2
2
2
5
5
5
5
5
So I used the library, and initially read it as an integer, but it only gave me -1s no matter my input. Then I read it as a string, it gave me long weird numbers, then I tried reading as a character and that is how I got my
2
5
5
If you have any suggestion of a solution, I’ll be delighted to hear it :smiley:
p.s. please help me…

a much easier solution would be the 1sheeld approach as it is an arduino shield that uses bluetooth to connect to either iphone or android and controls many things especially motor speed just type in that name you will find that web site and a list of uses and libraries but you will need that board well worth it . in answer to your problem look at parsing the data info to get 255 not just 2 then 5

I tried bluetooth.parse(); but it says the library does not have a member named parse