Audio VGA hack
Samson found a tutorial on Audio VGA Hack and asked me to check it out. It looked pretty cool and I found a couple VGA cables sitting at home. Time to get busy...
First I cut up one of the 2 VGA cables. The color of the wires seems completely different than the tutorial. There were 15 pins plus the outer metal part on the VGA port; however, there were 18 different wires inside my cables, with some sharing the same colors. I had to use a multimeter and labeled each cable accordingly. I supposed different manufacturers may have used different color schemes over the year.
1. I had connected the cable as the tutorial described and my computer did not recognize the CRT monitor. I checked all the connections with a multimeter to verify signals come though each of them. All the wires were then soldered and reconnected, except the first 3 pins (R/G/B signals) and an extension from pin 5 (ground) was made.
2. Cut up an audio cable with a 3.5mm stereo headphone jack. Tip (left channel) is the red wire, ring (right channel) is the white wire and sleeve (ground/sheild) is the black wire. I also bought a 2-way headphone jack splitter: one connected to Arduino, the other to a computer speaker to monitor the sound output.
3. Connected a normal VGA cable to computer and set the display in mirror mode. Plug in the "hacked" VGA cable.
4. Connect Red (or White) audio wire to Analog In 1 of Arduino; connect Black audio wire to Analog In 0. Connect Pin 1, 2 & 3 of the VGA cable to the Digital 4, 5 & 6 of Arduino. Attach Arduino with USB, load the code supplied by the tutorial...
Thanks to the help of Assistant Professor Dr. Oscar Au; he explained the whole process in great details. This hack only work for monitor with horizontal sync signals, thus the horizontal strips, i.e. CRT monitor. To further modify the setup...
- The higher the input volume, more color and strips.
- In order to show more green strips, connect Pin 2 (Green) of the VGA cable to a lower number of the Digital Out of Audrino; for example, Digital 1 would have a higher frequency to show green than connected with Digital 5. Alternatively, connect Pin 3 (Blue) of the VGA cable to a Digital 1 for more blue. See photo below.
- The height of the strips can be increased by adding delay to the script. Delay value of 5 seemed too think already. Modified code below.
DDRD = B11111111;
}
byte last = 0;
void loop() {
PORTD = analogRead(0); // 0 - 255
delay(1); // i.e. 0 - 5
}
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home