Pages: [1] 2   Go Down
Author Topic: Sending/reading SMS with FBUS protocol  (Read 11736 times)
0 Members and 1 Guest are viewing this topic.
Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello everyone,

Today I registered me here at this very nice website.
I really like the things that are possible with the Arduino!!

I already ask a few things about Nokia LCD, but I also want to know if there is someone who has worked with the FBUS from a Nokia phone. Maybe there are libraries for easily sending/receiving a SMS with the Arduino...

Can someone help me with this?

Thanks in advance!!

With kind regards,

Atmoz (from the Netherlands)




Very nice thing, this Arduino gadget 8-)
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 14
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If possible, use a SonyEricsson phone instead. They have serial cables, and a simple Hayes-style AT interface for all communication with the phone. I.e. very easy to interface.
Logged

Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
If possible, use a SonyEricsson phone instead. They have serial cables, and a simple Hayes-style AT interface for all communication with the phone. I.e. very easy to interface.

Thanks for the inpunt ZingBerra, but the "problem" is that I have +/- 40 pieces of Nokia3310 overhere...
So if possible, I want to use them in my future projects...

Regards,
Atmoz
Logged

Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Does anyone know what hardware I can use to communicate between the Nokia 3310 and the Arduino?

I've tested a lot of hardware setups, but none of them work!

In software it seems I have to send 128 times 'U' or 0x55 in HEX. This is is to synchronize the UART in the phone with the microcontroller. Then for testing I send

Code:
1E 00 0C D1 00 07 00 01 00 03 00 01 60 00 72 D5

This sample frame is used to get the hardware and software version from a Nokia phone. When the hardware is good, the Nokia 3310 should reply back with some info. But nothing happens...

Maybe funny to tell: Yesterday I've worked/tested on this from 08:00 in the morning till 23:00 in the evening :smiley smiley-razz and NO progress :'(

With Nokia 3310 FBUS cable it doesn't work, but also without FBUS cable, and with direct soldered cables into the phone it doesn't work. Because the Nokia 3310 data (FBUS) cable inverts the signal I use 2 transistors between Arduino and phone to also invert the signal. A picture of the setup:



To be complete, here the code what I used in the Arduino:

Code:
// ASCII Table
// by Nicholas Zambetti <http://www.zambetti.com>

void setup()
{
  Serial.begin(115200);

  // wait for the long string to be sent
  delay(100);
}
 
int number = 0; // first visible character '!' is #33
int var = 0;
int var2 = 0;
int incomingByte = 0;
 
void loop()
{

  while(var < 128){
    Serial.print(0x55, HEX);
    //delay(10);
  var++;
  }
  
  
  
  
  while(var2 < 1){
    
  // 1E 00 0C D1 00 07 00 01 00 03 00 01 60 00 72 D5
 
  delay(1000);
  
  //Serial.print("1E0CD10701030160072D5");
  
  
  Serial.print(0x1E, HEX);   //1E
  Serial.print(0x00, HEX);   //00
  Serial.print(0x0C, HEX);   //0C
  Serial.print(0xD1, HEX);   //D1
  Serial.print(0x00, HEX);   //00
  Serial.print(0x07, HEX);   //07
  Serial.print(0x00, HEX);   //00
  Serial.print(0x01, HEX);   //01
  Serial.print(0x00, HEX);   //00
  Serial.print(0x03, HEX);   //03
  Serial.print(0x00, HEX);   //00
  Serial.print(0x01, HEX);   //01
  Serial.print(0x60, HEX);   //60
  Serial.print(0x00, HEX);   //00
  Serial.print(0x72, HEX);   //72
  Serial.print(0xD5, HEX);   //D5
  
  
  
  //Serial.println(0);   //0
  //delay(1000);
  
  var2++;
  }
  
  
  if (Serial.available() > 0) {
            // read the incoming byte:
            incomingByte = Serial.read();

            // say what you got:
            //Serial.print("I received: ");
            Serial.print(incomingByte, HEX);
  }
 
}

I someone can help me would be VERY great!!

Thanks in advance,

Atmoz
Logged

Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


If you look at this website: http://www.embedtronics.com/nokia/fbus.html

And then by section "The F-Bus Protocol and Commands"

Is my code then correct?
I first send 128 times 0x55 and then the code to get the HW/SW version of the phone...

But I get no response from the phone...

Logged

Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


Someone? :-[

Logged

London
Offline Offline
Tesla Member
***
Karma: 10
Posts: 6250
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have no direct experience with interfacing to that phone but you could try adding a  100 microsecond delay after each send. The UART buffer is only 64 bytes long so its possible that half of those 0x55 characters are getting lost.

I assume you have checked the logic levels are correct and you have set DTR and cleared RTS.

I do have a few of these phones lying around doing nothing so would be interested to hear how you get on.

Good Luck!
Logged

Maastricht, The Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 96
Techno!!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


Thanks for the answer mem!

Quote
I have no direct experience with interfacing to that phone but you could try adding a  100 microsecond delay after each send. The UART buffer is only 64 bytes long so its possible that half of those 0x55 characters are getting lost.

Do you mean 100m uSec. between each 0x55?
And also between the get HW/SW version command?


Quote
I assume you have checked the logic levels are correct and you have set DTR and cleared RTS.

I do have a few of these phones lying around doing nothing so would be interested to hear how you get on.

Good Luck!

I don't use DTR and RTS (picture above). So there shouldn't be a problem.

Yes, you say it, I also have (a lot) Nokia 3310's lying around here...
It would be nice to make something nice with it ;D
Logged

London
Offline Offline
Tesla Member
***
Karma: 10
Posts: 6250
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Try sending the delay between each of the 0x55 bytes. My guess is that only about half of your 128 bytes are actually being sent, the rest are lost through buffer overflow. That's just a guess but its worth a try. You don't want any delay on the receive side.
Logged

0
Offline Offline
Full Member
***
Karma: 0
Posts: 227
Intransigent prototyper
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If I remember correctly FBUS is 3.3V so you may have to do some level-shifting.

D
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 1
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

WEll i have made the cable for fbus using the schematics now when i m sending the code it it is not sending me the right message. I am using Vb as the language for send the data using MsComm. I have initialized it using those 128 u's and all as well.

My Message
 "1E 00 0C D1 00 07 00 01 00 03 00 01 60 00 72 D5"

Result that i am getting
1E 00 00 D1 CF
1E 00 00 01 00 56 30 2E 31 31 2D 32 30 0A 48 2D 0A 63 20 4D 2E 01 3C

It is not the same one as mention in tutorial embetronics
http://www.embedtronics.com/nokia/fbus.html#part1
1E 0C 00 7F 00 02 D1 00 CF 71
1E 0C 00 D2 00 26 01 00 00 03 56 20 30 34 2E 34 35 0A 32 31 2D 30 36 2D 30 31 0A 4E 48 4D 2D 35 0A 28 63 29 20 4E 4D
50 2E 00 01 41 3F A4

Did the reason is that i have leaved out the MBUS pin empty and connected only fbus RX TX and gnd pins

Please Give me a Solution
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Any success? I want to do the exact same thing!

Regards,
Ken
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 8
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

I would also like to do this. Has anyone had any success? Is there such thing as a fbus library for Arduino?

Thanks,
Adam
Logged

Rome
Offline Offline
God Member
*****
Karma: 1
Posts: 987
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Damn NOKIA & FBUS!!  >smiley-sad

Can this link be useful to anybody? (and eventually to me once you figure out how to use fbus with arduino?  :smiley )
http://www.embedtronics.com/nokia/fbus.html

The downloadable test program also contain C++ source!
Logged

Ontario
Offline Offline
God Member
*****
Karma: 24
Posts: 860
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

For what it's worth, I have successfully used the referenced FBUS implementation with a 6110 and a UNIX computer, so I know the code works.

Incidentally, something I see in your picture and that has given me trouble in the past, is that you have both the tx/rx pins and the USB connected to something.  Both the phone and the USB will be attempting to assert onto the rx pin at the same time and this will affect your results.
« Last Edit: December 07, 2010, 05:13:14 pm by gardner » Logged

Pages: [1] 2   Go Up
Jump to: