Forum Replies Created
-
AuthorPosts
-
MichaelKeymaster
Well, if you have no programming experience, you probably shouldn’t start by writing video games. I mean, it takes years to become a proficient programmer, and there’s no shortcuts. I’m not sure what to tell you other than to get some books on C/C++ and learn programming concepts and the language. You need to walk before you run. Know what I mean?
MichaelKeymasterBenny, I’m not sure why you are experiencing this issue. I have not experienced that. Sometimes the LM1881 chip seems to lose the sync, and I’ve restored it by flipping the overlay switch. You might try adjusting the small potentiometer R4 slightly to see if you get better stability.
I’m almost sure this is not a code problem, but an issue with the LM1881 losing track of the sync from the composite input.
MichaelKeymasterYes, I successfully decoded closed caption data from the composite output of an HD channel. I used my Tivo HD. I was kind of surprised it worked.
MichaelKeymasterOh, I see. The ATmega168 has half the memory of the ATmega328. So you have to lower the resolution down to maybe 144×64. That will use 768 bytes of memory for the frame buffer. Maybe you could try that? For experiments like the Overlay Demo, you’d have to adjust the coordinates of the drawing to fit on the smaller grid. The Frame Capture project should work unmodified (except change resolution).
MichaelKeymasterThanks for the heads-up. The mega is not supported at all, as the processor’s features are not brought out to the pins. See http://nootropicdesign.com/ve/whynotmega.html
What kind of microcontroller is in the Seeeduino 1.1?
MichaelKeymasterI understand what you are trying to accomplish. I don’t think the ATmega328 is fast enough to sample an analog waveform fast enough to figure out its frequency (color). The color of each pixel is defined by the voltage waveform at that moment. The ADC in the Arduino takes several clock cycles to perform an analog conversion, so you’d never be able to sample fast enough to learn about the waveform in the timespan of a pixel. If the color of the whole screen is similar, perhaps there’s a way to sample it quickly and deduce the frequency. This would involve writing assembly I think.
I’m not sure what other hardware would accomplish this, but probably a chip that is designed to process a composite signal. Certainly not the $3 ATmega328 and $1.50 LM1881 chips.MichaelKeymasterThe one with the long shaft is 10K, the small one is 100K. See parts list.
MichaelKeymasterIt’s not possible to interpret or generate color with the very limited hardware in an Arduino. The TVout library uses 1-bit depth low res video, and it generates a composite signal by bit-banging it out digital pin 7. Primitive but effective. My enhancements that allow capture of information use the primitive method of measuring the voltage on the incoming signal relative to a threshold. If the voltage is higher than the threshold, then the pixel is “on”, otherwise off. This is the job of the ATmega328 analog comparator. All very primitive because of the hardware.
MichaelKeymasterThe resolution is limited by the amount of memory in the ATmega328 microcontroller. It only has 2K of SRAM, so 1-bit depth (monochrome) resolution of 128×96 consumes 1.5K. You can go a little higher, like 136×96 or maybe 136×104, but you need to leave some SRAM for your program variables, stack, etc.
No color, only monochrome. This hardware cannot generate the analog waveforms required for color.
MichaelKeymasterSorry about the slow response. Spammers have been attacking my forum, so the legit questions are getting lost in a sea of garbage.
Only Space Invaders/Pong requires the special version of TVout distributed on my site. Asteroids will run with the Beta1 version of TVout library from Google Code at
http://code.google.com/p/arduino-tvout/downloads/detail?name=TVoutBeta1.zipI tried to explain that on the games page but I know it’s a bit confusing.
http://nootropicdesign.com/hackvision/games.htmlMichaelKeymasterYes, well that does indicate that something is wrong with the first assembly. Perhaps you can carefully check some things like:
– your soldering joints. Especially the resistors and diodes in the upper right of the board. The video behavior you describe indicates there could be a short.
– are your diodes installed in the correct direction?
– did you put the adhesive backing on the board? If not, the timing gets messed up if you touch the board near the crystal.
– can you check the solder connections near the crystal and 22pF capacitors? That could mess up timing.Please feel free to send me high res photos of the board. I’m happy to look it over.
MichaelKeymasterHmm, that’s very strange. I have not heard of that behavior before, and Hackvision was tested on PAL TVs in the UK (and I have lots of PAL customers). It’s especially strange that you see this behavior on 2 different tvs. Is the image stable and clear, but just scrolling vertically? Or is it unstable horizontally and all messy?
You could try soldering the 75 ohm resistor in place, but I kind of doubt that would fix it. Do you have access to any other TVs?
Also, do you have a USB-Serial programming cable? If so, we could change some video timings and recompile.
MichaelKeymasterOuch, thanks for pointing out the bad links. I fixed them. That’s the second time I’ve experienced a link problem on my site — something is clobbering them (probably when I use an online editor or something).
The .pde files in the Toolduino source are actually Processing source code, not Arduino source. Arduino is modeled after the Processing project, and they chose the same source code suffix (I don’t think that was a good idea…).
MichaelKeymasterIf the voltage across the middle pin and left pin (as viewed from the top) of the voltage regulator is that high, then I think it is defective or damaged. I tested a bunch of vregs from the same batch I sent to the UK, and the output was always between 4.99 and 5.02V. I’m not sure if that higher output of 5.8V to 6V would cause problems with the ATmega, but it certainly could — especially since you said you measured 8V once at the ATmega.
One more step I’d like you to take: can you send me a picture of your 9V adapter label? I just want to double check it. Just email it to michael @ nootropicdesign.com
I think the best course of action is that I replace your whole Hackvision. We’ll work it out over email.
As for the adapter — an unregulated power supply will output significantly higher voltage than advertised when there is no load. My 9V supply outputs over 12V with no load. When attached to a Hackvision, the output measures over 10V, so your experience is normal.
MichaelKeymasterThe voltage regulator output pin is the leftmost pin, and the GND is the center pin. There should be 5V across them. Sounds like your voltage regulator is outputing 5.8V? That’s much higher than the datasheet would indicate:
http://www.jameco.com/Jameco/Products/ProdDS/51182.PDFThe ATmega328 should tolerate 6V maximum, but the datasheet indicates that input voltage should be 4.5-5.5V. I wonder if the regulator is bad.
-
AuthorPosts