element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
RoadTests & Reviews
  • Products
  • More
RoadTests & Reviews
RoadTest Forum [RoadTest] "Freescale RD3803MMA7660FC Review - Serial Communication"
  • Blogs
  • RoadTest Forum
  • Documents
  • RoadTests
  • Reviews
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join RoadTests & Reviews to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 17 replies
  • Subscribers 2566 subscribers
  • Views 1394 views
  • Users 0 members are here
  • rd3803mma7660fc
  • freescale
  • accelerometer
  • serial
Related

[RoadTest] "Freescale RD3803MMA7660FC Review - Serial Communication"

espanholito
espanholito over 15 years ago

Hello all,

 

First of all i would like to thank Alistair for giving me this opportunity to test this equipment.

 

I received my kit yesterday, and soon started exploring it.

 

As Xavier CHAZE said in the other discution(http://www.element-14.com/community/message/6561#6561), this kit is compose by three components: a freescale uC, a FTDI USB-serial chip, and the  accelerometer.

 

Also with the kit is some documentation and a cd to install a applications which allows to explore some of the features of the accelerometer, like tilt, shake, tap, and orientation detection.

 

As there are already some reviews on this kit, i decided not to talk about what others have already talk, and start to discover a bit of the kit. First i have installed the freescale application which didn't work on my windows 7 x64:(

I had to install it on a windows xp machine to work.

 

As the kit has a USB-Serial Converter, you can develop your computer applications to "talk" to the freescale uC in order to receive the sensor data. And this was what I have done, first I had to discover the communications parameteres:

 

Baudrate: 38400

Data Bits: 8

Stop Bits: 1

Parity: None

Handshake: None

 

Then, using a serial port monitor I spied the communication beetween the freescale application and the board.

 

In order to start receiving data from the board you have to send a couple of bytes:

 

Hexadecimal:

 

0x20; 0x48; 0x54; 0x31; 0x53; 0x31; 0x41; 0x41; 0x0D

0x20; 0x48; 0x54; 0x31; 0x53; 0x31; 0x41; 0x41; 0x0D

0x20; 0x73; 0x31; 0x41; 0x41; 0x0D

0x20; 0x62; 0x37; 0x41; 0x41; 0x0D

 

As you can see, all the messages start with 0x20 and end with 0x41; 0x41; 0x0D

 

From this point the uC will start to send the accelerometer data. Each message starts with 0x20; 0x43 and ends with 0x41; 0x41; 0x0D

 

Till this point i still haven't time to explore more of the kits commands, but hope to post them here soon.

 

Best Regards,

Marcos

  • Sign in to reply
  • Cancel
Parents
  • amri_amin
    amri_amin over 15 years ago

    Hello all,

     

    You'll find in attachement, a .net projet (compiles with VS2005 or Sharpdevelop) consisting of a library(reversed from freescale software) implementing the protocol communication with eval board and a demo program that autodetects port used by the board and registers to a callback outputing register values( refer to datasheet for decoding register values).

    Next step is to interface the library with a 3D game.

    Best regards

    Attachments:
    MMA7660.zip
    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 15 years ago in reply to amri_amin

    Hi Amine,

     

    I have not tried your code as I have no compiler for it but when browsing through I noticed:

     

    public string setConnection(string port, string handshakeID)
            {
                Exception exception;
                SCIPort = new SerialPort();
                try
                {
                    SCIPort.PortName = port;
                    SCIPort.BaudRate = 0x9600;
                    SCIPort.DataBits = 8;
                    SCIPort.Parity = Parity.None;
                    SCIPort.StopBits = StopBits.One;
                    SCIPort.NewLine = "AA\r";
                }

     

     

    while in the documentation the rate is 38400, do you get good values with your code?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • amri_amin
    amri_amin over 15 years ago in reply to Former Member

    Hi elias,

     

    The baud rate is written in hexadecimal fomat, so 0x9600 in hexa equals 38400 in decimal.

    to compile the code, you can use the open source sharpdevelop ide with the .net framework from microsoft.

     

    BR.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 15 years ago in reply to amri_amin

    Hi Amine,

     

    That explains it image

     

    I downloaded sharpdevelop indeed but as I have a 64bit OS I got errors.

     

    Elias

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • Former Member
    Former Member over 15 years ago in reply to amri_amin

    Hi Amine,

     

    That explains it image

     

    I downloaded sharpdevelop indeed but as I have a 64bit OS I got errors.

     

    Elias

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube