Search  
Tuesday, January 06, 2009 ..:: Forum ::.. Register  Login
 HomePage Minimize

 Print   

 Products Minimize

 Print   

 MSRS Minimize

 Print   

      
 RoboticsConnection Forum Minimize
SearchForum Home
  Discussions  Serializer Robot Controller  Communication w...
 Re: Communication with Serializer via XBee(TM)/XBee-PRO(TM) serial interface
 
 10/1/2007 1:09:16 AM
Umesh
12 posts


Re: Communication with Serializer via XBee(TM)/XBee-PRO(TM) serial interface

I am trying to connect Serializer board with Xbee.

A simple Temperature Sensor board.

 static Serializer serializer;
        static AmbientTemperatureSensor tempSensor;;

        static void Main(string[] args)
        {
            serializer = new Serializer();
            serializer.PortName = "COM55";

            tempSensor = new AmbientTemperatureSensor(serializer);
            tempSensor.Pin = AnalogPinId.Pin0;
            tempSensor.TemperatureChangedThreshold = 1;
            tempSensor.UpdateFrequency = 50;
            tempSensor.TemperatureChanged += new
                SerializerComponentEventHandler(tempSensor_TemperatureChanged);

            serializer.StartCommunication();

            while (true)
            {
                serializer.PumpEvents();
            }

            serializer.StopCommunication();
        }

        static void tempSensor_TemperatureChanged(SerializerComponent sender)
        {
             Console.WriteLine("Temp: {0}", tempSensor.Temperature);
        }
[In fact lots of errors in code for MSDN style documents]

I would able to trasmit data through Serializer, since when ever I say "serializer.PumpEvents(); " light in Xbee pro Doungle green LED keep blinks.

but the "tempSensor_TemperatureChanged" event never fires.

I think Xbee pro Usb doungle and Xbee Pro on Serilazer not able to communicat.

 

http://www.surveyor.com/cgi-bin/yabb2/YaBB.pl?num=1162331669

And this is the msg am reciving when i connect Xbee pro USB doungle with X-CTU software.


"Communication with modem..OK
Modem type=Name unknown (ID = 42949672481223980)
Modem firmware version ="

If anyone working or had same experiance please let me know

Please let me know how to make it work!

Thanks,

Tharanath Umesh.

 10/3/2007 10:52:09 PM
jason
158 posts
5th


Re: Communication with Serializer via XBee(TM)/XBee-PRO(TM) serial interface

Umesh,

Your application looks correct (except tempSensor has two semil-colons).

I would debug the XBee connection via Hyperterm.  Once you know it works, then you can move to using the .NET lib.

If the XBee connection is working, then you should be able to send any/all commands to Serializer and it work properly.

How are you changing the temperature of the sensor?  A HairDryer?  Your fingers?   My guess is that the event isn't firing because you're not communicating correctly w/ the Serializer.


Jason Summerour
President,
Summerour Robotics Corp
Microsoft MVP
www.roboticsconnection.com
 10/4/2007 12:31:12 AM
ringo
36 posts


Re: Communication with Serializer via XBee(TM)/XBee-PRO(TM) serial interface

Make sure both Xbee modules are set to the correct baud rate (same as the serializer). The default on the Xbee is 9600, the default on the serializer is 19200.

Once everything is set the same, figure out which com port the PC xbee is and open that in hyperterm. When the 2 Xbees connect, the RSSI led on the serializer will light up. the brighter it is the better the connection. The RSSI led is near the reset switch, you my have never noticed it. It only lights up when an Xbee is connected.

Once you are connected, try somehting simple in Hyperterm like "fw".

It should return something like 1.4.1

Once that is working, then work on your app.

Ringo

 

 


Ringo Davis, Hardware Technical Lead RoboticsConnection.com
  Discussions  Serializer Robot Controller  Communication w...

SearchSearch  Forum HomeForum Home    Print   

Copyright 2004-2007 Summerour Robotics Corp   Terms Of Use  Privacy Statement
DotNetNuke® is copyright 2002-2009 by DotNetNuke Corporation