baby-o and RS232 Frsky

Support for the A-Star and the Orangutan family of robot controllers.

baby-o and RS232 Frsky

Postby erik46 » Sun Sep 12, 2010 11:03 am

I am familiar with using the Baby-O with the LCD. From Frsky I aquired a telemetry receiver that sends back the contents of the receiver voltage and drive battery voltage in a RS232 format.

I want to capture these values and show them in the LCD.

I never used this before and do not know where to start, any suggestions are welcome.
Attachments
FrSky Instruction Manual for Two Way System (4).pdf
Frsky protocol
(22.85 KiB) Downloaded 392 times
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby ryantm » Mon Sep 13, 2010 9:18 am

Hello.

The PDF you attached to your post seems incomplete. One thing you should make sure you are aware of is that RS232 voltage levels are specified to vary from -25 to +25V, which is well beyond what the AVR IO pins can handle. The level shifter on page 1 of the PDF seems to be addressing this.

- Ryan
User avatar
ryantm
Pololu Employee
 
Posts: 1268
Joined: Mon May 19, 2008 12:00 pm
Location: Las Vegas, NV

Re: baby-o and RS232 Frsky

Postby erik46 » Mon Sep 13, 2010 11:26 am

The receiver sends back two analog inputs and any other rs232 input from the model to the transmitter, On the back of the transmitter module there is a connector with the rs232 output, positive and ground. The battery pack in the transmitter is 9,6 Volts.

Thanks for the tip, I will check the voltage output from the transmitter. I found PD0 and PD1 to be the Rx and Tx.

Still no clue where to start, any links are welcome.
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby goober » Mon Sep 13, 2010 2:23 pm

erik46 wrote:The receiver sends back two analog inputs and any other rs232 input from the model to the transmitter, On the back of the transmitter module there is a connector with the rs232 output, positive and ground. The battery pack in the transmitter is 9,6 Volts.

Thanks for the tip, I will check the voltage output from the transmitter. I found PD0 and PD1 to be the Rx and Tx.

Still no clue where to start, any links are welcome.


I'm looking into something like this, and found some references that I'm finding helpful, maybe they'll do you some good.

Atmel has an application note on using the UART in C at http://www.atmel.com/dyn/resources/prod_documents/doc1451.pdf

It's pretty slim, but comes with some example code http://www.atmel.com/dyn/resources/prod_documents/avr306.zip

Also, look at the section on the Universal Serial Interface in the data sheet for the 328p

Joe
goober
 
Posts: 48
Joined: Mon Jun 28, 2010 3:42 pm

Re: baby-o and RS232 Frsky

Postby DavidEGrayson » Mon Sep 13, 2010 2:34 pm

To go along with the list of links goober supplied, I'd like to mention that the Pololu AVR C/C++ Library supports serial communication with the UART on the Baby Orangutan. If you just use our library you won't need to worry about the low-level details of how the UART works. For more information, see these pages:

http://www.pololu.com/docs/0J20/6.j
http://www.pololu.com/docs/0J18/10

--David Grayson
DavidEGrayson
Pololu Employee
 
Posts: 2730
Joined: Thu Apr 03, 2008 11:30 am
Location: Las Vegas, NV

Re: baby-o and RS232 Frsky

Postby erik46 » Tue Sep 14, 2010 9:42 am

I found a forum post that explains me how to extract the right values at

http://www.avrfreaks.net/index.php?name ... c&p=745766
Last edited by erik46 on Fri Oct 08, 2010 10:42 am, edited 1 time in total.
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby erik46 » Tue Sep 28, 2010 11:20 am

I looked into the pololu library, the example is about setting up the connection and receiving the data. This part should work as long as the baudrate matches the Frsky. When the number goes into the buffer it should be possible to extract it from the buffer and show it on the display.

Anyone having done that?
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby erik46 » Wed Oct 13, 2010 12:24 pm

Finished,

I had to figure out a lot of technical challenges, it works and can be adapted to your use.

I implemented an interrupt driven uart and 7 segment display. The whole story is in the pdf.

Have fun, first flight scheduled next sunday, it will be sunny but cold.
Attachments
My Frsky dashboard.pdf
(510.67 KiB) Downloaded 448 times
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby ryantm » Wed Oct 13, 2010 2:39 pm

I'm glad you got it working. That is a cool writeup and some nice looking pictures. Would it be alright if we include your project in our Community Projects page?

-Ryan
User avatar
ryantm
Pololu Employee
 
Posts: 1268
Joined: Mon May 19, 2008 12:00 pm
Location: Las Vegas, NV

Re: baby-o and RS232 Frsky

Postby erik46 » Thu Oct 14, 2010 8:01 am

That is ok with me.

I try to make such a wrap-up on all my projects, it helps when a project is re-opened after a long period. And it saves me a lot of time when my teammates want to copy my setup.

Telemetry is hot in the RC world, most projects I found are quite advanced. Hopefully this simple dashboard will encourage other people to take up the challenge.
erik46
 
Posts: 72
Joined: Wed Oct 15, 2008 10:50 am

Re: baby-o and RS232 Frsky

Postby ryantm » Thu Oct 21, 2010 10:36 am

Hello.

We posted a little description and link to this forum post about your project on our Community Projects page.

- Ryan
User avatar
ryantm
Pololu Employee
 
Posts: 1268
Joined: Mon May 19, 2008 12:00 pm
Location: Las Vegas, NV


Return to A-Star and Orangutan Robot Controllers

Who is online

Users browsing this forum: No registered users and 4 guests