OTG Mouse for stable flight. [ now SPI not OTG ]
OTG Mouse for stable flight. [ now SPI not OTG ]
I was considering using the innards of a USB mouse and a web camera lens to create a system to prevent drift. Any ideas and thoughts would be useful. I'm not 100% sure what usb data lines are used for at the moment but I see them on the schematic. Anyone tried using the CPU as a USB “host” or in a OTG mode? Is it even possible?
Last edited by BillyBag2 on Thu Sep 05, 2013 9:14 am, edited 1 time in total.
Re: OTG Mouse for stable flight.
Hi,
Unfortunately the MCU doesn't support USB HOST or OTG, it's only supports device. But even if it did the image grabbed from the webcam would probably be way to big to use for processing. I would recommend getting a simple camera with low resotution, maybe something like this.
Unfortunately the MCU doesn't support USB HOST or OTG, it's only supports device. But even if it did the image grabbed from the webcam would probably be way to big to use for processing. I would recommend getting a simple camera with low resotution, maybe something like this.
Re: OTG Mouse for stable flight.
hey,
i think the easiest way would be to get an optocal flow sensor and hook it up to the i2c port.
Check out this: https://code.google.com/p/arducopter/wiki/AC2_OptFlow+
and this: https://github.com/diydrones/ardupilot/ ... pticalFlow
you can get the sensor here:
http://store.jdrones.com/Optical_flowse ... opt01a.htm
have fun;)
i think the easiest way would be to get an optocal flow sensor and hook it up to the i2c port.
Check out this: https://code.google.com/p/arducopter/wiki/AC2_OptFlow+
and this: https://github.com/diydrones/ardupilot/ ... pticalFlow
you can get the sensor here:
http://store.jdrones.com/Optical_flowse ... opt01a.htm
have fun;)
Re: OTG Mouse for stable flight.
Could not resist and I have ordered one. If I get it going I will try and remember to post some info.fizzlor wrote:hey,
i think the easiest way would be to get an optocal flow sensor and hook it up to the i2c port.
Check out this: https://code.google.com/p/arducopter/wiki/AC2_OptFlow+
and this: https://github.com/diydrones/ardupilot/ ... pticalFlow
you can get the sensor here:
http://store.jdrones.com/Optical_flowse ... opt01a.htm
have fun;)
Re: OTG Mouse for stable flight. (Ok, maybe SPI)
OK? Its arrived. (Please do not laugh) "Its a bit bigger than it looked on ebay."BillyBag2 wrote: Could not resist and I have ordered one. If I get it going I will try and remember to post some info.
I do not have any good scales to wiegh it. I'm guessing from the kitchen scales it is between 8-15 gms. The lens is quite heivy and quite substantial.
I need to get some blue tack or something the same wieght and an see if it can be carried by the flie.
I will also need to add an under carage to protect the lense, without adding even more wieght. May be a top off a plastic bottle fitted like a sun hood on the lens will mean that the top hits the ground and the lens id saved. The flie may even stand up on the top for takeoff.
I think I will try and get it running using software on a raspberry pi first. There is a lot of example software about. I think I will try and get it running as a 30x30 camera to start. Just to covince myself it is running. There is a common alternative to the raspberry pi with an arduino and a com port to the host PC. I could posibly do this as a test using the flie and replacing the RS232 comms link with the radio. This may be harder and I'm not sure I need the camera feature on the flie, just of testing, focus experiments etc.
http://code.google.com/p/bt-optical-flow-sensor/
https://github.com/x75/adsn3080-emd
Re: Mouse for stable flight. (adns3080)
I connected the adns-3080 to the rapberry pi and used the test code https://github.com/x75/adsn3080-emd , chopping out the bits that did not compile.
This code is very simple and does not do any setup. It appears to work fine. Did not try getting the image.
The code used the power on settings without any configuratio or srom update.
I will look into writing a driver for this for the flie.
This code is very simple and does not do any setup. It appears to work fine. Did not try getting the image.
The code used the power on settings without any configuratio or srom update.
I will look into writing a driver for this for the flie.
-
- Member
- Posts: 96
- Joined: Fri May 03, 2013 2:06 pm
Re: OTG Mouse for stable flight.
Re the camera Billybag2, It looks similar to the one I use:
http://forum.bitcraze.se/viewtopic.php?f=6&t=427

If so, the camera on that is listed as 1gram (excluding the cabling).
http://forum.bitcraze.se/viewtopic.php?f=6&t=427

If so, the camera on that is listed as 1gram (excluding the cabling).
Re: OTG Mouse for stable flight.
Ok? Power? The flie has 2.8v when disconnected from power and the vcom (I assume the battery power) is available. The device is 3.1 to 3.6 typical and has a 3.7 absolute Max rating. There is a "5v" regulator on the module board for working with a 5v supply. But I do not know the spec. I am guessing the 3.8v from the battery is too close to the 3.3v output of the regulator. So I think I am a bit snookered. I think it will survive with 2.8v but I am not sure it will operate.
Re: OTG Mouse for stable flight.
It looks like the voltage reg on the module has a ultra low droput voltage of 120 -200 mv. So VCOM from the battery is probably enough to drive the regulator.BillyBag2 wrote:So I think I am a bit snookered.

-
- Member
- Posts: 96
- Joined: Fri May 03, 2013 2:06 pm
Re: OTG Mouse for stable flight.
120-200mv should be fine. We've had people use a 200mv tx+75mv camera alright. The battery did take a hit though.