22 Kasım 2013 Cuma
Data visualizer for drone tracker
Did a hover test
Here is a video of the test
18 Kasım 2013 Pazartesi
Tangible paramter tuning thingy
When tuning PID parameters for the HCD flight controller I pretty much spend 2 evenings waiting for the program to recompile.
I would change some parameter a tiny bit, recompile, get the HCD in the air to evaluate and then repeat the process over and over.
At some point I realized that tuning the parameters in mid-air would be much more efficient.
For this i made this simple controller:
It's simply 6 faders hooked up to an Arduino. It transmits the 6 fader values to the flight controller software where they are scaled to the appropriate range and fed into the feedback controller in real time.
I would change some parameter a tiny bit, recompile, get the HCD in the air to evaluate and then repeat the process over and over.
At some point I realized that tuning the parameters in mid-air would be much more efficient.
For this i made this simple controller:
It's simply 6 faders hooked up to an Arduino. It transmits the 6 fader values to the flight controller software where they are scaled to the appropriate range and fed into the feedback controller in real time.
16 Kasım 2013 Cumartesi
The loop has been closed
After a lot of crashing and swearing in the lair closed-loop control of the HCDs has now been achieved!!
The rough control parameters has been established so autonomous take off, flight and landing can be continously reproduced.
Now I need to fine tune the flight controller software and package everything nicely into something others can use too.
Video
The rough control parameters has been established so autonomous take off, flight and landing can be continously reproduced.
Now I need to fine tune the flight controller software and package everything nicely into something others can use too.
Video
15 Kasım 2013 Cuma
Fly by wire
The tracking software then sent the joystick commands via. another Arduino with a BK2421 radio to a HCD.
This tells me that my tracking software is able to control a Quadcopter (for now with a little help from a pilot).
Next step is to create a control-loop that will enable me to fly one or more Quadrotors under complete software control.
Here is a video of one of the first tests.
Tracking flying quadcopter
The tracker is made using Kinect and OpenFrameworks. I use the Kinects color video image to track orientations and the depth camera for altitude.
The tracker locks on to colored tags made from pink post-it notes and use their position to select which part of the depth information is relevant.
It's all very experimental at the moment but seems promising.
The aim is to autonomously fly one or more HCD's in formation.
12 Kasım 2013 Salı
Controlling toy quadcopter(s) with Arduino
The last couple of days I have done some more work on the small toy quadcopters (now dubbed HCD for Hamster Cage Drone). The goal was to hack the communication so that they could be controlled using computer vision software. Basically the poor mans version of this (don't bother you have already seen it).
UPDATE: Use this modified code to be compatoble with SparkFuns NRF24L01 radio.
UPDATE: I have made a Arduino library for controlling this particular Quadrotor (may work with similar products). You will need to build this simple hardware (discribed on this page) to use the library. All parts (apart from Arduino) may be found inside the remote controller that comes with the quadcopter.
The first thing I did was to take the remote control handset apart to see what kind of radio system was used.
Inside was pretty much what you'd expect. A couple of cheap paper PCB's with not a lot on them.
The radio communication is handled by a small discrete radio module. After a lot of internet digging it turned out that the module was based on the BK2421 2.4GHz tranceiver IC. This also seem to be the choice for a lot of cheap RC toys coming out now.
With a datasheet for this chip and an oscilloscope it was simple enough to figure out the pin configuration for the SPI communication between the radio module and the handset.
Using an ArduinoUNO to eavesdrop on this comunication I was able to figure out the initialization and thereby the mode of communication. Here is a annotated list of the initialization sequence.
Without going into detail about the low level communication the following happen when the handset and
Quadcopter are turned on:
1) Handset broadcast it's unique network address or ID.
2) Quadcopter receives the broadcast it acknowledges this and start listening to data from that ID.
3) Upon acknowledge the handset then start transmitting flying data packet every 20 mS.
Multible Quadcopters can be controlled simultaneously by assigning them different addresses.
The passing of ID is done on one fixed radio channel and flying data is sent on one of about 12 random radio channels. The quadrotors seem to auto scan the radio channels until they find data.
Flying data is transmitted as 8 byte packets in following format:
Byte 0 = throttle 0-255
Byte 1 =Yaw 0-255
Byte 2 =Yaw_trim 0-128
Byte 3 = Pitch 0-255
Byte 4 = Roll 0-255
Byte 5 = Pitch_trim 0-128
Byte 6 = Roll_trim 0-128
Byte 7 = Fly/run 0=fly, 16=run (toggle button on handset)
Next I created a base station that would connect to the quadrotors. I happened to have some RFM-70 modules that contain the same BK2421 chip. Not reading the datasheet properly I initially thought that this module required 3.3V logic and hence all the resistors. They are not needed since the BK2421 has 5V tolerant data pins.
NOTE: CE goes to pin 8 (missing on drawing)
I eventually ended up with a much simpler set-up using just the module salvaged from the handset and an Arduino.
To enable future experimentation I have written a Arduino library for connecting to one or more of these quadcopters.
The library should work on any ATMEGA88 to ATMEGA328P based Arduino boards.
If you want to have a go yourself you may get the HCD's here or here among other places. These are just random hits on google, you may get them elsewhere.
Less crappy video here.
Please share if you find other toys that may be hacked using similar methods.
Happy hacking.
UPDATE: Use this modified code to be compatoble with SparkFuns NRF24L01 radio.
UPDATE: I have made a Arduino library for controlling this particular Quadrotor (may work with similar products). You will need to build this simple hardware (discribed on this page) to use the library. All parts (apart from Arduino) may be found inside the remote controller that comes with the quadcopter.
The first thing I did was to take the remote control handset apart to see what kind of radio system was used.
Inside was pretty much what you'd expect. A couple of cheap paper PCB's with not a lot on them.
The radio communication is handled by a small discrete radio module. After a lot of internet digging it turned out that the module was based on the BK2421 2.4GHz tranceiver IC. This also seem to be the choice for a lot of cheap RC toys coming out now.
With a datasheet for this chip and an oscilloscope it was simple enough to figure out the pin configuration for the SPI communication between the radio module and the handset.
Without going into detail about the low level communication the following happen when the handset and
Quadcopter are turned on:
1) Handset broadcast it's unique network address or ID.
2) Quadcopter receives the broadcast it acknowledges this and start listening to data from that ID.
3) Upon acknowledge the handset then start transmitting flying data packet every 20 mS.
Multible Quadcopters can be controlled simultaneously by assigning them different addresses.
The passing of ID is done on one fixed radio channel and flying data is sent on one of about 12 random radio channels. The quadrotors seem to auto scan the radio channels until they find data.
Flying data is transmitted as 8 byte packets in following format:
Byte 0 = throttle 0-255
Byte 1 =Yaw 0-255
Byte 2 =Yaw_trim 0-128
Byte 3 = Pitch 0-255
Byte 4 = Roll 0-255
Byte 5 = Pitch_trim 0-128
Byte 6 = Roll_trim 0-128
Byte 7 = Fly/run 0=fly, 16=run (toggle button on handset)
Next I created a base station that would connect to the quadrotors. I happened to have some RFM-70 modules that contain the same BK2421 chip. Not reading the datasheet properly I initially thought that this module required 3.3V logic and hence all the resistors. They are not needed since the BK2421 has 5V tolerant data pins.
NOTE: CE goes to pin 8 (missing on drawing)
I eventually ended up with a much simpler set-up using just the module salvaged from the handset and an Arduino.
To enable future experimentation I have written a Arduino library for connecting to one or more of these quadcopters.
The library should work on any ATMEGA88 to ATMEGA328P based Arduino boards.
If you want to have a go yourself you may get the HCD's here or here among other places. These are just random hits on google, you may get them elsewhere.
Less crappy video here.
Please share if you find other toys that may be hacked using similar methods.
Happy hacking.
10 Kasım 2013 Pazar
Kurtlar Vadisi Pusu 204 son bolum izle
Kurtlar Vadisi Pusu 204 bölüm izle bu hafta -da nefes kesen senaryosu ile kurtlar vadisi pusu 204 son bolum TV-de yayınlandıktan hemen sonra buradan izleye bilirsiniz.
Kurtlar Vadisi Pusu 204 bolum izle
Kurtlar Vadisi Pusu 204 son bolum izle
Kurtlar Vadisi Pusu 204 bölüm izle bu hafta -da nefes kesen senaryosu ile kurtlar vadisi pusu 204 son bolum TV-de yayınlandıktan hemen sonra buradan izleye bilirsiniz.
Kurtlar Vadisi Pusu 204 bolum izle
6 Kasım 2013 Çarşamba
Fun with cheap toy quadcopters
Got a whole bunch of these from an art festival I was involved in.
I have now started using them for all kinds of fun projects.
The first experiment was to remove the cage. Without the cage the little quads are really stable and capable of carrying a lot of weight.
Obviously i HAD to add a small wirerless camera. Here is the first result:
I am also hacking the communication protocol so that they may be controlled from a computer but more about that in later posts.
I have now started using them for all kinds of fun projects.
The first experiment was to remove the cage. Without the cage the little quads are really stable and capable of carrying a lot of weight.
Obviously i HAD to add a small wirerless camera. Here is the first result:
I am also hacking the communication protocol so that they may be controlled from a computer but more about that in later posts.
Kaydol:
Kayıtlar (Atom)