 |
|
 |
| Parallax Forums > Public Forums > BASIC Stamp > Dual-Axis analog Joystick Help. | Forum Quick Jump
|
  |  Mikerocontroller Registered Member

       Date Joined Apr 2008 Total Posts : 176 | Posted 11/7/2009 12:36 AM (GMT -8) |   | | You should remove the joystick from the original circuit board. All those other components might be affecting your readings. Also be aware that your RCTIME variable could be overflowing. I have a similar joystick that I hacked from a Logitech gamepad controller. It has two 10K ohm potentiometers (X axis and Y axis) and a tactile switch (Z axis). I'm going to test mine this weekend and see what happens. | | Back to Top | | |
    |  Mikerocontroller Registered Member

       Date Joined Apr 2008 Total Posts : 176 | Posted 11/8/2009 10:37 PM (GMT -8) |   | | Using your basic schematic with a 10k ohm variable resistor and 4.7 uf capacitor I got the following readings: MIN: 1 CENTER: 10200 MAX:23000. This was done on a Basic Stamp HomeWork Board. This board has built-in 220 ohm resistors on each I/O pin so I was able to eliminate the series resistor. Like Mike said, you need some series resistance because the variable resistor can short the Stamp pin to ground. | | Back to Top | | |
 |  skylight Registered Member
        Date Joined Mar 2007 Total Posts : 389 | Posted 11/9/2009 12:06 AM (GMT -8) |   | | The 220 ohm IS in series the pin won't short to GND | | Back to Top | | |
 |  Mikerocontroller Registered Member

       Date Joined Apr 2008 Total Posts : 176 | Posted 11/9/2009 12:27 PM (GMT -8) |   | | What I meant to emphasize is that the 220 ohm resistor is for protection of the Stamp. I thought some newcomers may think it is a trimmer resistor. I was also pointing out that non-HomeWork Boards don't have built-in protection resistors. Sorry for the confusion. | | Back to Top | | |
 |  TheComputerCrew TheFritch
        Date Joined Oct 2009 Total Posts : 6 | Posted 11/11/2009 7:02 AM (GMT -8) |   | Update.
First, thanks for everyone's responses.
Next, I took Mikerocontroller's advice from post #3 and removed the joystick from the board. This was a success due to the fact that the PCB's circuitry was adulterating my pot readings.
After removing the joystick, a simple RCTIME circuit taken straight from the "What's a Microcontroller" text, page 151, did the trick. The only modifications to the circuit from the text were the substitution of the joystick for the rotating pot (obviously), and the substitution of a 100µf capacitor. This capacitor was able to give me readings (after scaling and offset) from 506 to 998. The readings before being modified by code were 17 and 632.
Also, I utilized the z-axis tact switch that is built into the lower portion of the xbox360 joystick. It worked very well.
Although very rudimentary and simple, this proves that I can utilize all the input devices off of this circuit board and integrate them onto a custom PCB that will fit back into the xbox360 controller. This will preserve the function of every button and switch as well as provide an implementation of this controller into robotics control. It would be much simpler to use the existing hardware, but, unfortunately, it doesn't look as though Microsoft's wireless encryption will be decoded anytime soon.
Thanks all!!

 Post Edited (TheComputerCrew) : 11/11/2009 3:08:44 PM GMT
| | Back to Top | | |
| Forum Information | Currently it is Friday, November 20, 2009 8:36 PM (GMT -8) There are a total of 393,723 posts in 55,520 threads. In the last 3 days there were 84 new threads and 703 reply posts. View Active Threads
| | Who's Online | This forum has 17685 registered members. Please welcome our newest member, Steve H. 57 Guest(s), 8 Registered Member(s) are currently online. Details Peter Jakacki, Mike Green, Ken Gracey (Parallax), aconz2, Cluso99, Little-endian, Rich_W8VK, Franklin |
Forum powered by dotNetBB v2.42EC SP2.02 dotNetBB © 2000-2009 |
|
|