I need to convert PWM analog out to TRUE analogOut

nah, everything works fine. still too much latency but that's not the fault of the circuit we just made. I've got another idea on how to solve that problem.

well at 9600 you would think that is fast enough but your delaying the process a considerable amount, I bet most of your latency would be eliminated by upping that to 115200 or something

well at 9600 you would think that is fast enough but your delaying the process a considerable amount, I bet most of your latency would be eliminated by upping that to 115200 or something

i'll try it but there is also some at the image processing end so either way i'll have to implement a new alg to take care of it.

I bet most of your latency would be eliminated by upping that to 115200 or something

actually that did get rid of about half of it. it still over aims though. even thought the video is running at 30fps there is still about a half second lag. anyone know how to bring analog video to an ADC so it can be processed on an FPGA?

heh if your struggling with transistor logic good luck designing what amounts to a cpu in software on a fpga

I dont even understand it and I have been working with its retarded cousin (clpd) for a few months now :wink:

hey how would I integrate a trackball mouse (one of those stationary mice that has a ball facing up that you roll around with your hand) into the existing circuit?

Assuming you have access to the opto-interrupters, you need four inputs, two from each axis. Then you need some code to interpret the meaning of the pulse sequence and timing. See Grumpy_Mike's tutorial: http://www.thebox.myzen.co.uk/Workshop/Rotary_Max.html

that article went over my head as usual. this tutorial looks helpful http://www.martijnthe.nl/2009/07/interfacing-an-optical-mouse-sensor-to-your-arduino/

You aren't changing the requirements yet again, are you?

nope. when the ball is moving right the joystick is moving all the way right. it should work just fine once it is all hooked up and programmed. after I figure out the details..

well the bottom line is that I'm trying to find the path of least resistance that results in a small optical trackball replacing the right thumb stick.

a regular optical mouse and an optical trackball mouse are essentially the same. they are just used differently. a trackball would be preferred because if it is small enough you can put it in place of the thumb stick. with a regular mouse you have to do more work relocating all of the controller right side buttons to the mouse since your hand won't be on the right side of the controller anymore.

i went out to radio shack a minute ago and got a cheap optical trackball mouse with a PS2 adapter on the end. this other tutorial Arduino Playground - Ps2mouse looks a little better. I think i can just solder lead wires on the end of the PS2 cable and plug them into the arduino

the code from the recent tutorial isn't working. there should be a way to tap into the chip directly. I tried to look it up but couldn't find anything.

I know the ps/2 mouse lib works fine

i'm using this code Arduino Playground - HomePage from this tutorial Arduino Playground - Ps2mouse.
I'm using the same pins and wired it the same way etc. the data i get back is always "1000 x=0 y=0" while moving the mouse around. the mouse is USB and optical but has a USB2PS2 adapter on it.

did it originally come with an adapter? those adapters are dumb and are relying on the chip inside the mouse to respond to ps2 commands or usb commands

so if the mouse is not both usb and ps2 compatible its not going to do anything

did it originally come with an adapter?

yea, it came new with it. it was even already on the end of the cable.

I found this pdf on the chip Redirect Notice

let me guess :-

went over my head as usual

I'm going to try soldering directly to clock and data on the chip instead of where it is supposed to be on the PS2 adapter.

that didn't fix it... after more messing around i found that the code was bad. found an example that actually works here: GitHub - kristopher/PS2-Mouse-Arduino: Arduino/Wiring Library for interfacing with a PS2 mouse. to get it to work you though have to use quotes to include the header file instead of angle brackets.

i got it all to work. after testing and tweaking it for about an hour I've come to the conclusion that it needs to be proportional. so what should I go with? a digital POT, low pass filter? can someone tells me what parts to get for a low pass filter?

I found this tutorial http://www.arduino.cc/en/Tutorial/SPIDigitalPot but it is for a 6 channel digipot and the mine are each one channel. If i had to guess I'd say that you just send the address as 0 still, followed by the 0-256 position.

here's the spec sheet on the chip http://ww1.microchip.com/downloads/en/DeviceDoc/11195c.pdf

should be similar to
http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1269918888/29#29

but depends on the exact part number a 4xx1x works differently