Dave Heavy Industries » Tan http://www.daveheavyindustries.com Dave Heavy Industries - blog Mon, 12 Aug 2013 00:24:10 +0000 en-US hourly 1 http://wordpress.org/?v=3.6 Operation Parrot Drone – Introduction http://www.daveheavyindustries.com/2011/03/09/op-parot-drone-introduction/ http://www.daveheavyindustries.com/2011/03/09/op-parot-drone-introduction/#comments Wed, 09 Mar 2011 02:41:24 +0000 admin http://wp.daveheavyindustries.com/?p=132 Well.. I picked up one of these amazing devices last year direct from china.. Loads of fun. A friend in my building did the same and plenty of dog fights later, we had some engine failures (after discovering the flying just above another drone makes their drown drop to the ground... conflicting altitude sensor??). While they are being fixed... I decided to have a think about what I'd like to get out of the drones...

This project will be broken up into parts.

1 - Additional Range

well, this one is easy. While at the park, I'd like to get about 500meters out of the unit, rather than the 100 (or so) it gets currently. I'm thinking that I'll start small(ish) and attach a Cisco access point to a car battery via an inverter with some 10db antennas and see how far we can extend the range. From here a world of signal boosters and specialized antennas opens up - But I'm going to suggest the AP1232 should be more than enough for our purposes. This will give us the ability to be Xmeters from the AP and the drone to be Xmeters from the AP... so we'll have quite a large effective range radius. Car battery means we'll get a few hours of fun and can leave this unit somewhere, covered in gaff while we killĀ each otherĀ at distance.

2 - Long distance remote control

by Long distance... I mean other side of the city. I work at west end and live int he valley - I'd love to be able to fly the drone from work, via a tunnel of sorts, or at least a vpn - shouldn't be hard at all I'd imagine, again the Cisco AP will become a client to the Parrot Drone, encapsulated dot1q to my PC which will see the drone interface as a subint.

3 - Autonomous Flight

Well... this is the most complicated, and a combination of the other two. I want the drone to be able to fly by coordinate and follow waypoints around a large zone and come back to land. Sounds simple? a few issues here - 1. drone doesn't have GPS. 2. if it did, GPS probably isn't accurate enough. 3. I don't know anything about this kind of automation.

more to come!

AR Parrot Drone @ WOW

Spare AR Parrot Drone Battery @ WOW (highly recommended)

Networking Brokers (where I keep getting cheap second hand cisco aps for these little projects)

 

[facebook_ilike]


 

]]>
http://www.daveheavyindustries.com/2011/03/09/op-parot-drone-introduction/feed/ 0
Distance between two points with curvature http://www.daveheavyindustries.com/2011/02/25/distance-between-two-points-with-curvature/ http://www.daveheavyindustries.com/2011/02/25/distance-between-two-points-with-curvature/#comments Fri, 25 Feb 2011 05:19:06 +0000 admin http://wp.daveheavyindustries.com/?p=120 The earth isn't flat. Sometimes you feel like over engineering a simple problem just because you can.

Late last year I put together a mobile web interface and used google maps for a store locator. I also had to use ASP Classic.
In the mids of this it struck me that a customer might find they were a few meters off from the actual distance from their current position, to what I'm reporting. Clearly this just won't do -so I re-worked it to compensate....in ASP CLASSIC, where most of the math is non existent.

enjoy!

Const M_PI = 3.14159265358979323846
Const earth_radius = 6371
Function Log2(X)
Log2 = Log(X) / Log(2)
End Function
function deg2rad(x)
deg2rad = x * M_PI / 180
end function
function rad2deg(x)
rad2deg = x * 180 / M_PI
end function
Function atan2(ys,xs)
Dim theta
If xs <> 0 Then
theta = Atn(ys / xs)
If xs < 0 Then
theta = theta + pi
End If
Else
If ys < 0 Then
theta = 3 * pi / 2 '90
Else
theta = pi / 2 '270
End If
End If
atan2 = theta
End Function
function distance_between(a_lat,a_lon,b_lat,b_lon)
dim dLat, dLon
dLat = deg2rad(a_lat - b_lat)
dLon = deg2rad(a_lon - b_lon)
dim a, c, r, a1
a = (sin(dLat/2) * sin(dLat/2)) + ( cos( deg2rad(a_lat) ) * cos( deg2rad(b_lat))) * ( sin(dLon/2 ) * sin(dLon/2) )
aa = 1-a
c = 2 * atan2 ( a^(1/2), aa^(1/2) )
d = earth_radius * c
distance_between = d
end function

[facebook_ilike]

]]>
http://www.daveheavyindustries.com/2011/02/25/distance-between-two-points-with-curvature/feed/ 0