Jump to content


Photo

Tp link router as ip telemetry, HD camera and manual control


  • Please log in to reply
67 replies to this topic

#1 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 10:58 AM

Hello,
this is a great day!

I just finished to mod a really small tp link router (usb, wifi and serial) to be able to make the bridge between the gcs and the openpilot board.

The router look like this :
Posted Image
And inside:

Posted Image
It is really small and light.
On this I putted an openwrt distribution with webcam driver on which I plugged a logitech pro 9000 webcam :
Posted Image
which is able to stream HD video... ;)

After some soldering I succeded in getting the serial lines out and some scripting skill (which normally I have not), I did the bridge using ser2net between the gcs tcp telemetry option and the serial lines...
And.. bingo, it works!!!!
the gcs is getting the openpilot board data and I can also stream the live view of the webcam
Posted Image
On his picture the openpilot board is the cutom one at the bottom...
Posted Image
So, what next...

-dismentle the camera to light it, I only need the pcb, the sensor and the optic, shorten his cable.
-put an usb hub on the router to be able to plug the openpilot in HID usb mode to free the mainport of the telemetry
-remove any unecessary components, like usb plugs
-put a real antenna on the router to increase the range, why not an amplifier
-developp an iphone, android app to control everything...
-add a qt widget with the streamed video

And ... tada ... you have an ardrone like, but much better ;)

#2 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 11:02 AM

here is a short video :



it looks laggy for the video, becaus my pc is an old one which is very slow, but indestructible, which is great on the field ;)

#3 dankers

dankers

    Head Lemon Coordinator

  • Members
  • PipPipPip
  • 11032 posts
  • Country: flag of Australia Australia


Posted 20 May 2012 - 11:44 AM

That's looking great, nice work. For sure keep this thread updated, I'd love to see where you take this.

#4 KD4WEN

KD4WEN

    Advanced Member

  • Members
  • PipPipPip
  • 60 posts
  • LocationLas Vegas when home
  • Country: flag of United States United States

Posted 20 May 2012 - 01:40 PM

I am very interested in this. Good work. I have been waiting on the release of the Sony GoPro Wifi backpack. But you have carried it to the next level. If you would build another I would gladly buy one setup and working even in rough form.

#5 Galad

Galad

    Advanced Member

  • Members
  • PipPipPip
  • 37 posts
  • Country: flag of France France


Posted 20 May 2012 - 01:58 PM

Hi Fertito

Nice Hijack, I love that :-) ! You used the TL-WR703N (32MB ram) version, right ? not TL-WR702N (16MB ram) advertised on TP-Link website.
Trex 450 Flybarless uRondo CopterControl, Dragonus Flybar, Blade mCP X, Quad CopterControl, AXN Floater, Spektrum DX8, Phoenix RC, CNC, ....

#6 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 02:14 PM

hello, yes the 703, the 702 has not enough ram to make openwrt run...

#7 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 03:26 PM

I am very interested in this. Good work. I have been waiting on the release of the Sony GoPro Wifi backpack. But you have carried it to the next level. If you would build another I would gladly buy one setup and working even in rough form.

next level is that, instead of a webcam, i'm planing on using an AVCAP to catch the hd composite video signal of the gopro... ;)

I dismanteled my logitech webcam, it is really light, it will be nice ;)

#8 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 03:44 PM

first try on my quad : (propeller-less, of course)



I have lot of latency via wifi compared at usb, maybe I should slow down telemetry link to have more control, it looks like the board is loosing frames...

When I'll have made it work with the usb-hid instead of serial it will be better...

#9 D-Lite

D-Lite

    Core Team

  • Members
  • PipPipPip
  • 1648 posts
  • Country: flag of Germany Germany


Posted 20 May 2012 - 06:55 PM

I like this very much. Great job and a good and simple approach to have video + telemetry in one link.

I have lot of latency via wifi compared at usb, maybe I should slow down telemetry link to have more control, it looks like the board is loosing frames...


At what speed are you running the serial link between the Wifi router and CopterControl? In my tests with GCS controlled flights, it worked best at 57600 baud. At 115200, CopterControl started to lose incoming bytes which very much looked like increased latency.

#10 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 20 May 2012 - 07:06 PM

That's it, I'm runing at 115200 bauds... I'll try to slow it down.
Thanks.

#11 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 21 May 2012 - 11:33 AM

the openwrt router is also compatible with 3G modem, see what's next? ;)

#12 A*Morale

A*Morale

    Core Developer

  • Members
  • PipPipPip
  • 816 posts
  • LocationRome/Italy
  • Country: flag of Italy Italy


Posted 21 May 2012 - 12:41 PM

You can try to enable USB VCP telemetry instead of hid so that it should work out of the box.
Alessio my Blog
Posted Image

#13 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 21 May 2012 - 01:17 PM

You're right that'ld be the best, but I things it is a little too much hardcore for me...

I'll try...

#14 A*Morale

A*Morale

    Core Developer

  • Members
  • PipPipPip
  • 816 posts
  • LocationRome/Italy
  • Country: flag of Italy Italy


Posted 21 May 2012 - 02:06 PM

I have to check how to enable openwrt's Virtual com port support (i.e. supports serial over usb, it does as it works with 3G usb modems).
Than from the CopterControl hardware configuration page on GCS you have to choose Telemetry for the USB VCP combobox so that the board is seen as a USB Serial port.
Be sure to have a firmware compiled with the clear setting option just to be on the safe side is something goes wrong :)
Alessio my Blog
Posted Image

#15 A*Morale

A*Morale

    Core Developer

  • Members
  • PipPipPip
  • 816 posts
  • LocationRome/Italy
  • Country: flag of Italy Italy


Posted 21 May 2012 - 02:11 PM

Ok, here is a page that refers to 3G modem but you can take the part related to usb-serial.
http://wiki.openwrt.org/doc/recipes/3gdongle
Basically you have to install the module for the usb controller(probably kmod-usb2 is ok) and then kmod-usb-serial,
At that point you have to tell to the serial mod that the CopterControl is a serial device.

Follow the openwrt wiki page as it should be simple.
Alessio my Blog
Posted Image

#16 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 21 May 2012 - 03:50 PM

it is ok on the openwrt side ;)
it is on coptercontrol side that it doesn't run, I don't have this combo box, and I'm sure my firmware doesn't have this option ;)

#17 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 21 May 2012 - 08:08 PM

so made a try at 57600bds with a good PC, it works fine, a small latency but should be ok.

I would like to try another things, usbip, but I have no space left on the router...

will try to compile coptercontrol with a usb cdc driver...

#18 A*Morale

A*Morale

    Core Developer

  • Members
  • PipPipPip
  • 816 posts
  • LocationRome/Italy
  • Country: flag of Italy Italy


Posted 22 May 2012 - 09:02 AM

Look for the "next" branch in git.
Alessio my Blog
Posted Image

#19 fertito

fertito

    Developer

  • Members
  • PipPipPip
  • 754 posts
  • LocationGrenoble, France
  • Country: flag of France France

Posted 22 May 2012 - 11:15 AM

hello,
it is sad to say, but I don't know how to use Git correctly... except the clone function...

#20 A*Morale

A*Morale

    Core Developer

  • Members
  • PipPipPip
  • 816 posts
  • LocationRome/Italy
  • Country: flag of Italy Italy


Posted 22 May 2012 - 12:12 PM

Here in the wiki there is a short guide:
http://wiki.openpilo...etting the code
Alessio my Blog
Posted Image