Jack Crossfire's blog View Details
Archive for October, 2013
Posted by Jack Crossfire | Oct 23, 2013 @ 11:58 PM | 6,232 Views

Looking over the exams for the MIT algorithms course on the recommended video feed is pretty intimidating. Each problem is as substantial as a research paper. It seems hopeless to ever finish all the problems in the allotted time, but most everyone employed in the software business nowadays had to pass the same course & take the same tests. It's the same test at MIT as the lowliest Cal state university.

They all have to master the asymptotic analysis, all the sorting algorithms, all the proofs. Proofs were always a great challenge. Doing asymptotic analysis in the required time requires memorizing the patterns & formulas, memorizing the differences between T(), O(), theta() & omega(). MIT requires it for all students, but others only require it for CS.

Nowadays, there's a wealth of previous exams & alternative descriptions of the material. 20 years ago, there was no wikipedia, google, or goo tube. We just had the lectures & our textbooks. It was almost cheating to have a previous exam. Professors have probably compensated by making the problems harder.

It helps to remember the same amount of work is involved in most any bachelor's degree & you already did that amount of work. Over time, you get used to learning 3 new concepts every 2 days, a white board covered in mathematical notation, sustaining that intensity for 14 weeks at a time. The number of hours of...Continue Reading
Posted by Jack Crossfire | Oct 23, 2013 @ 12:49 AM | 6,401 Views
Wifi Cam Returns (3 min 10 sec)

With bluetooth replacing wifi for connectivity needs, decided to recycle a retired flight computer into a simple wifi cam. It took a long time to get the wifi software to work, years ago, so it was worth having some kind of demo of it. It goes from 3fps of 640x480 color to 14fps of 320x240 greyscale. It consumes 0.3A at 5V.

It's a complete waste, as commercial wifi cams go. A modern gopro can stream higher quality video at 30fps. There are many hardware video compressors which could do the job in less space. Economically, it's still probably the cheapest thing which can get some kind of moving pictures to a phone.

It was supposed to be the cheapest, smallest circuit, suitable for fitting on a monocopter & transmitting to a baseline phone without any external adapters. The flight software, video compression & communication would all be run on a single chip.
Posted by Jack Crossfire | Oct 21, 2013 @ 07:51 PM | 6,085 Views
Was surprised to find someone was still studying bias cancellation in gyros. Only Analog Devices still produces bias cancelling gyros & they only produce a handful. The world has migrated to super cheap, high bias gyros because position sensing has gotten good enough to compensate for bad gyro sensing.

They're still selling the original analog, single axis gyros at the original price, but have been selling a digital version in an easily soldered SOIC package. They still advertize an extremely low 16 deg drift over an hour for the digital version. It still costs 10x the Invensense version. For a GPS denied environment with real bad position sensing, it might be worth it.

If you have a real high resolution optical flow system that updates really slowly because of processing power, there might be a benefit to using the accelerometer data to get short term updates.

Went over more of the Arducopter source code. They call the fusion of position sensing with accerometer data "inertial navigation." It's in AP_InertialNav.cpp. It seems to add earth frame acceleration data to historic GPS data through a convoluted system of weights & delay lines. Its advantage relies on GPS having a 400ms lag.

_position_correction & _position_error are the key variables. _position_correction is updated when the accelerometer is updated. _position_error is updated when the GPS is updated. They both feed back into each other. The earth frame...Continue Reading
Posted by Jack Crossfire | Oct 19, 2013 @ 09:29 PM | 7,542 Views

CastAR VR / AR System - The 18 Month Story (18 min 57 sec)

Google recommended this video. Long ago after she disappeared from Goo Tube, there was a story about her getting sh*tcanned from a startup that was doing this ridiculously complicated VR project & now she was trying to sell it alone. It sounded like they hired her to do this idea which they thought of, then she got attached to it, but in actuality it was her idea all along.

There must have been a huge ergonomical benefit to using head mounted projectors, a head mounted webcam, retro reflective material, IR leds, active shutter lenses. The only obvious advantage is including practical objects in the VR world.

Detecting head position is a huge win for VR glasses. It's hard to see why no-one has done it. It's very hard to track the position of an indoor object, but VR glasses aren't constrained by the requirements of a flying vehicle. The ambient lighting can be controlled. The update rate doesn't have to be fast.

She does it with a glasses mounted camera detecting ground based LEDs. It would have been much easier to use a ground based camera tracking glasses mounted LEDs. The problem no-one can solve is convergence detection.

She doesn't seem to have a final product in mind, just endlessly trying to reduce the size, but something really complicated with no obvious goal is the kind of thing that makes money from the crowd. She conceded that the reflective material is too...Continue Reading
Posted by Jack Crossfire | Oct 18, 2013 @ 07:46 PM | 6,478 Views
Getting digital audio from the CP33 was extremely hard & pushed the limit of the available parts. It's still extremely hard to capture 2.8 megabits of loose data in a general purpose microcontroller. Ideally, it would be done with an FPGA. There's no regret in taking 4 years to do it. It couldn't have been done without an oscilloscope.

Once you solder the wrapping wire in the tight confines of the piano & get the bits streaming out USB, it's definitely worth it. The sound from the digital intermediate is amazing.

The CP33 outputs very hissy analog, but internally uses 24 bit 44.1khz. The internal signal is not adjusted based on volume, so the amplifier stage takes an extremely faint signal from the DAC for all volume levels.

Yamaha CP33 digital output (0 min 57 sec)

The digital intermediate contains the entire decay of each note all the way down to 0, with no hissing & barely any quantization noise. There is only a very slight hissing when the envelope is still loud enough to amplify the hissing of the original microphone. The digital output contains harmonics from the original CF-III not audible in the analog output.

It's a shame so many electronic instruments over the last 40 years were professionally recorded from their horrible analog outputs when a pristine digital intermediate was always available, inside the wiring. There was never an easy way to get at the digital intermediate.

There was no optical output or...Continue Reading
Posted by Jack Crossfire | Oct 16, 2013 @ 10:19 PM | 6,950 Views
Finally discovered the CP33 can be plugged into USB & recorded with arecordmidi. The result can by played back through the CP33's synthesizer using aplaymidi. Should have gotten around to that, 4 years ago.

After many days of banging on Cubase, Ivory, Virtualbox, alsa-utils, & waiting for Adsense prerolls, finally got the CP33 output to feed through a German Steinway synthesizer. Audio doesn't work on VirtualBox, so everything has to be rendered. Cubase crashes a lot.

Unfortunately, Ivory truncates the notes to 1.4 seconds, pedaling or no pedaling. This might be a problem with the pirated version, the virtual machine, or an obscure Cubase setting. The Mystic synthesizer in Cubase doesn't have the truncation problem.

There might be another piano synthesizer, but the only problem with the CP33 sound is the extreme hissing. It's otherwise a better sound than Ivory. The Ivory sound is more out of tune & uneven. It might just bring out finer detail in the velocity. The problems are masked by ambiance & EQ. People like Ivory because of the realism, not because of how ideal the sound is.

The CP33 sound now has a lot of history to it. It's the sound of the Jesus Heroine's era. There's a lot of motivation to keep it instead of changing to a Steinway.

Ivory is everywhere & nowhere. There are no recordings of complete performances, no documented problems with it, no documented presets for it. The default settings are...Continue Reading
Posted by Jack Crossfire | Oct 15, 2013 @ 10:44 PM | 6,489 Views
Asus sent an external GPS module for their obsolete broken tablet, so it was time to feel sorry for whoever spent a lot of time designing this & whoever was desperately waiting for the GPS module.

Lawyers have gotten good enough that those kinds of defects now get you sued. The GPS & camera didn't work. The wifi was inferior. Asus designed an external GPS module as compensation, since they couldn't afford to give everyone a new tablet that fixed everything.

...Continue Reading
Posted by Jack Crossfire | Oct 13, 2013 @ 06:12 AM | 6,232 Views
For a good time, go to:


Pretty intimidating material. Only watched lecture 4 & it started out understandable, but when he got to analyzing complexity, it fried my brain.

Before 2010, job interviews emphasized experience. Show us what you've done & demos. There was very little theory.

After 2010, job interviews resembled lecture 4 a lot more. Show us the complexity of an algorithm. Optimize a sorting algorithm without the aid of the computer or Goog searches that you would have in the actual job. They wanted a lot more theoretical knowledge & there was little value to experience.

Clearly, the people getting jobs had mastered the very intimidating material. Everyone who founded a startup that got bought out & made them rich had mastered the theoretical material.

1 problem is they've been overwhelmed with applicants since 2010 & have to resort to very difficult interview questions that represent nothing about the job, just to weed through the noise. The other problem is technology has gotten a lot more algorithm focused, after 2010.

Most people in the workforce now are designing algorithms that analyze massive amounts of data, intelligently determine what advertizement to show, intelligently determine what newsfeed items to show, intelligently plan a route for car navigation, intelligently drive a car, develop intelligent responses for a program like Siri.

There's a lot less pushing of 1...Continue Reading
Posted by Jack Crossfire | Oct 11, 2013 @ 08:07 PM | 6,429 Views

It was a long week of stackoverflow searches, IntentServices, AudioRecorders, AudioTracks, AlertDialogs, & Eclipse configuration. For all the emphasis on higher level languages, every new software framework takes more steps to accomplish less.

1 problem is no-one can ever memorize every high level function. In a low level language, there was a small number of functions which you could remember & build up into a high level function that documented itself. Now that a program is made of thousands of unique, high level functions, every line of code is a black box which requires a long Google search to find the meaning of.

There was a time when using a library meant -I, -L, -l flags. All the errors used to be on 1 console. Now, it takes pages & pages of obscure Eclipse configuration windows, Java runtime compliance settings, using the dex2jar utility, then jar to view the contents of the output, sorting out the multiple streams of errors from console, problems, & logcat.

Google has gone through a few iterations & still hasn't figured out how libraries should be compiled. Now, they only compile the src directory. Every user of the library has to recompile the gen directory. So some bits of the library go in the library & some bits go into the mane program. The automatic mechanism of compilation never works. You can't view all the configuration windows of 2 projects side by side. So far, it's taken manually copying the project....Continue Reading
Posted by Jack Crossfire | Oct 11, 2013 @ 03:42 PM | 6,336 Views

NASA was obviously done when the Constellation program was canceled. They might have been done when the shuttle was canceled, but no other program was ever going to be justifiable once the clear goal of putting a human on the moon was taken out.

Old timers can still remember an age when they were putting 28 humans per year in space, launching 1 million pounds of shuttles per year. They're never going to launch a vehicle of their own again. The idea of another large rocket came from congress, but the buck stopped with Obama, who wanted no more vehicles & NASA to focus on just pension plans. In the fullness of time, congress never funded what they wanted & the pension plan agency is what they got.
Posted by Jack Crossfire | Oct 09, 2013 @ 08:16 PM | 6,262 Views
Finally got around to uploading the Android apps & Linux utilities which have accumulated over the years. Manely, the microphone monitoring app & the CPU Usage app are necessary for survival on Android.


A lot of small utilities build up over a lifetime of programming. Some of them were for technologies that no longer exist, like a utility for recovering files from a damaged CD-R or a utility for viewing analog TV.

For a long time, the Goog was good at buying out every startup & providing every utility you could possibly need. There weren't a lot of functions a phone could possibly do, which the Goog didn't already provide in the giant settings menu for everyone in the world. We were all equal.

That's started ending, as they've become more profit driven & the mane driver of innovation, Steve Jobless hasn't been around. Maps no longer allow offline viewing. The Play store charges $25 to start uploading. Adsense is no longer pure text or diffused banners, but giant bright red banners filling the entire window & making apps look horrible. It might be the return to the age when writing a program could give you power that no-one else had.

It's definitely a return to the age of not having any money. When you don't have any money, pure software & game programming gets a lot more attractive than robotics & UAV's.
Posted by Jack Crossfire | Oct 09, 2013 @ 04:00 AM | 6,051 Views

Caved in & ran the 14.8 miles to watch Gravity in IMAX 3D. It wasn't very realistic, the characters had a hard time staying focused, but it kept moving. There's a definite trend of this generation losing focus in their writing & movies.

It was almost entirely computer animated.

The computer animation was a lot better than a few years ago. The leap in triangle count & resolution of motion capture is definitely showing. Didn't notice the 3D after a while. It probably did contribute to the immersion, because after the movie, running home looked fake.

Obviously, the ISS, hubble, & chinese space station can't be traversed in a space suit or a Soyuz capsule. The internet squeemed over that one.
Posted by Jack Crossfire | Oct 08, 2013 @ 06:03 AM | 6,433 Views
So the microphone monitoring crisis evolved into a simple app which shows the microphone level. You can view it during a phone call to know if the microphone is working.

It can optionally feed the microphone to the speaker & add simple reverb. As usual for a JAVA SDK, compatibility with every version of Android on every phone is a hideous mess.

The minimum playback buffer reported is not always a multiple of the recording buffer, which requires recording 2 full buffers before playback can begin, creating an unnecessary delay. Sometimes it can be forced to use a smaller playback buffer than the reported size, but not consistently enough. None of the sizes are powers of 2, but strange numbers like 3712, 7526.

The free ride with Goog now ends at the Play store. It costs $25 initially to upload anything on the Play store. The Goog has so far not required an annual fee. Their history of making paid services free makes one reluctant to pay up.

Every programming job nowadays requires you to have something on the Play store, so it's caused lots & lots & lots of guys to pay the fee & upload millions of apps.

There are many microphone monitoring apps that look a lot better & have a lot more features, but none with useful level meters. Adding some more effects, a useless graphic EQ, & different options for the microphone routing would make it competitive, but it's a road of useless features for popularity.

The world just needs a microphone monitor for verifying the microphone is working. There are also microphone oscilloscopes which would have done the job.
Posted by Jack Crossfire | Oct 07, 2013 @ 07:15 PM | 6,516 Views
Having a self monitoring headset for the phone has been a long running battle. Commercial headsets don't monitor their own microphone.

Another attempt at a self monitoring phone headset failed. The phone's microphone connector appeared to be flaky, so making the headset use bluetooth was the next step.

Bluetooth sound quality was horrible. The absolute lowest samplerate is used. Microphone gain was too low. The stock microphone seemed to have much higher gain. The deal breaker was RF interference from the bluetooth chip coming out of the monitoring amplifier.

...Continue Reading
Posted by Jack Crossfire | Oct 04, 2013 @ 01:14 AM | 7,780 Views
Posted by Jack Crossfire | Oct 03, 2013 @ 01:24 AM | 5,918 Views
Px4flow waypoint navigation 2 (3 min 53 sec)

All fully autonomous flights with just the px4flow, sonar, & barometer determining position. That's probably the most aggressively something has ever flown itself using optical flow. Optical flow has previously just been used for aiding a human pilot in a hover.

With the maximum velocity limited to 0.3m/s, the horizontal navigation starts to scream. 0.25m/s is probably the upper limit for consistent navigation. 0.6 to 1.0m seems to be the useful altitude range.

There was an attempt to use just the gyro for heading. It was slightly better, but still not as consistent as a mast.
Posted by Jack Crossfire | Oct 02, 2013 @ 05:37 AM | 5,913 Views

AeroVironment (AVAV) Cuts Jobs in UAS Segment

Another one bites the dust. With $685,000 in severance packages, it's probably a large section of the company. Once, Aerovironment & Lockheed competed in a micro UAV competition.

AeroVironment/DARPA Nano Hummingbird UAV flying (1 min 45 sec)

Aero created a miniature ornithopter, a mechanical marvel, & won the contest.

Lockheed Martin 30cm-span Samarai 'maple seed' UAV (1 min 38 sec)
...Continue Reading
Posted by Jack Crossfire | Oct 02, 2013 @ 01:49 AM | 6,253 Views

So the PX4flow has a very low top speed. 0.25m/s was the fastest it could move before it stopped detecting movement at all & flew either away or much farther than it was programmed to.

Your luck depends entirely on the type of carpet. Its top speed in the plush apartment carpet seemed to be higher than the finely colored office carpet. Its sweet altitude has been 1m over all carpets.

More Microquad Crashes (0 min 36 sec)

Then, there were issues with the maximum turn rate being real low before it exploded. Suspect the microquad has much better performance than this, but it needs very precise tuning.

The attempt to offset the magnetometer to compensate for motor current failed. The turns were still way off. The only solution is a mast with a 2nd chip, but it wouldn't be crash proof or aligned perfectly after repairs, making it still error prone. The mane problem is the limited velocity for position sensing.

The flight time with the PX4flow weighing it down was slightly better than the Syma X1 at 7 minutes.

Px4flow waypoint navigation (11 min 43 sec)
...Continue Reading