Jump to content
  • Advertisement


  • Content count

  • Joined

  • Last visited

Community Reputation

1999 Excellent

About benryves

  • Rank

Personal Information

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. benryves

    Programmers talk "Alien"

  2.   Liquid should not be coming out - make sure you keep the can upright and don't hold the button down, use short bursts. I don't think the liquid should cause any significant problems beyond making the dust a bit harder to remove, just don't get it on you - it's extremely cold and may give you a burn. It's not a very good idea to cool down your expensive electronics in this way, though it can be useful to detect overheating components when designing your own electronic circuits. In such cases the can is designed to let the liquid out.   It hopefully goes without saying that you shouldn't breathe the gas in, either!
  3. benryves

    Repairing a PlayStation controller to USB adaptor

    Sorry for not getting back to you sooner, but I'm not really sure what the problem could be! Have you tried with a different controller, or does it do the same with all of them?
  4. benryves

    Repairing a PlayStation controller to USB adaptor

    Digital I/O lines on microcontrollers often include protection diodes - here's an example from the ATmega168 datasheet: If you don't connect the positive power supply pin but have a positive voltage on the data pin (Pxn in the above example) current will flow through the upper diode into the positive power supply rail and the microcontroller will switch on. However, this power supply is generally unreliable (if the data line goes low, as data lines are wont to do, the device loses power - not to mention data signals are not usually rated to the hundreds of milliamps a controller will need to run) and so only works accidentally (if at all) and can lead to strange behaviour - in the case of my adaptors there was no connection to the PS2 controller's power supply (pin 5) thanks to the missing diode but there was a connection to its data pins and the controller was therefore being powered via its data pins. Interestingly the rumble feature did also partially work, but the analogue feature didn't work at all, so it does sound somewhat similar to your issue.
  5. benryves

    Repairing a PlayStation controller to USB adaptor

    That's interesting, are you able to measure the voltage between ground and pin 5 of the PlayStation connectors to ensure that the controllers are powered? What happens if you press the "Analog" button on the controllers - does the LED blink at all? It's curious that they used a surface mount diode instead of a through-hole one, too, I'm not sure how good a connection that will have made.
  6. benryves

    Repairing a PlayStation controller to USB adaptor

    Thank you, and that's interesting information - I'm glad to hear yours works for you. Mine worked slightly better when plugged into a powered USB hub, so I guess they can be quite sensitive to voltage levels and particular controllers.
  7. I recently purchased an inexpensive PlayStation controller USB adaptor for my PC. Several reviews confirmed that it was compatible with the controller's analogue joysticks so I thought it would be what I was after. Life is rarely that easy with cheap electronics, unfortunately! When it arrived I plugged it in and Windows installed the appropriate HID drivers for it automatically, but as much as I waggled the joysticks on a connected DualShock 2 controller the axis preview in Control Panel remained resolutely in the zero position. PlayStation controllers have an "Analog" button that can be pressed to toggle between digital and analogue modes, but any attempts to press this resulted in the "Analog" light briefly flashing before immediately switching off again. Thinking it may be a driver issue I tried to install the drivers from the mini CD that had been included with the adaptor. My PC could not read the disc (it appeared to be scratched, and was not very well protected in postage) so I hunted around online until I found a package that worked using the device's USB ID (VID_0810&PID_0001). This enabled the controller's rumble/vibration feature, but I still couldn't get analogue input to work. Thinking that if one driver package could add vibration support, another might add analogue support I contacted the Amazon seller to ask them if they could send me a copy of the correct drivers - they instead chose to send me a whole other unit in the post. In the meantime, I experimented with another controller plugged into the adaptor. I was surprised to find that with two controllers plugged in at once I could enable analogue mode on one of the controllers. This made me think there could be a power issue - the second controller increased the capacitance across the power supply, which would make it more resilient to voltage spikes and reduce ripple that could be causing the controller to reset out of analogue mode. This was further confirmed by plugging the adaptor with a single controller into a powered USB hub - in this scenario the controller would only leave analogue mode when vibrating. I checked the power supply pins on the controller ports and was very surprised to see that there was apparently nothing connected to pin 5, which is supposed to deliver +5V to the controllers. At this point I decided to dismantle the adaptor to see what was going on. On the inside of the adaptor I could see that several components had been omitted. This could be to blame on cost-cutting measures (e.g. the LEDs D1 and D2 which are purely cosmetic) but the removal of D3 puzzled me the most - this diode is connected between USB VCC and the controller port pin 5, and is presumably responsible for providing power to the connected controller. I put this down to an oversight at the factory, and soldered a 1N4001 rectifier diode in the marked place. The above image shows a close-up of the place the missing diode should appear - D3 is indicated by a silk-screened diode symbol. Unsurprisingly the 1N4001 silicon diode has far superior characteristics to the silk-screen diode it replaced. With the diode in place both controller ports started working flawlessly, even allowing me to use a wireless Guitar Hero controller receiver (though not the whammy bar - Guitar Hero controllers lack the "Analog" button to manually enable the analogue mode and instead rely on the PlayStation to enable it via software). Whilst I had the soldering iron out I thought I should add the missing LEDs, once again using the existing markings to establish the correct polarity: If the markings are unclear, the anode (+) is always to the left when viewing the bottom of the circuit board when the other markings are upright. As the enclosure is blue and I seem to remember some fuss being made of the PlayStation 2's blue LED when it first came out I opted to use two blue LEDs with 1K5 resistors. I do not have any surface-mount resistors but through-hole ones fit quite easily though they can be a little fiddly to solder down. When the replacement adaptor arrived in the post I was surprised to see that (once again) the diode D3 was missing and it demonstrated the same problems as the other one I'd fixed. I find it unlikely that the same mistake could be made twice, so this seems to be a genuine cost-cutting measure. Microcontroller I/O pins often have an internal protection diode between them and the positive power supply, which is how I assume the circuit works at all when the controllers are left unpowered - a small amount of current flows from the I/O (data) pins to the positive rail via these protection diodes, which is just enough to let the controller work in digital mode but once they draw more current (e.g. when sampling analogue inputs or driving the vibration motors) the voltage droops far enough for the controller to reset and leave analogue mode. With these fixes in place I now have two working PlayStation USB adaptors for the price of one (and two 1N4001 diodes). I'm still rather perplexed by why there's such a blatent flaw in the hardware, but it is at least an easy fix which is why I've written it up. In summary: if your cheap PlayStation to USB adaptor ("Twin USB Vibration Gamepad", "Twin USB Joystick") is not working correctly, unscrew it and see if D3 is missing. If it is, solder a 1N4001 or similar diode between the two holes left for that purpose.
  8. benryves

    Serial connection

    There's no inherent danger other than extremely inefficient code. ;-)
  9. benryves

    Serial connection

    Nice work, but those digitalWrites give me the fear! Try [url="http://arduino.cc/en/Reference/PortManipulation"]http://arduino.cc/en/Reference/PortManipulation[/url] :-)
  10. benryves

    Checking out OurBricks

    [quote name='henrikbennetsen' timestamp='1321983924'] @benryves: Opera is on board as well but you currently need version 12. They actually also posted a really nice [url="http://dev.opera.com/articles/view/an-introduction-to-webgl/"]Intro to WebGL[/url] that I'd recommend checking out. [/quote]I am using the latest version of 12 (as the top line of the screenshot reports), so am not sure why I get that exception. The other WebGL demos I tried have worked - maybe this is something that needs to be fixed on Opera's end, though, so I guess I'll wait and see. :-)
  11. benryves

    Checking out OurBricks

    Looks very nice. :-) I hope they'll get it working in Opera soon; [url=http://i41.tinypic.com/2rokqh5.gif]here's a screenshot from the console of how far it currently gets[/url].
  12. benryves

    Laserstrike for Zen X-Fi 2

    Thank you very much for you kind words! :-)
  13. benryves

    Laserstrike for Zen X-Fi 2

    It's been a long time since I posted about any of my projects for the simple reason that I haven't had any real time to work on them this year. Work commitments have not been particularly kind to my free time and there has been no progress on my 3D engine for TI calculators or any new electronics projects. I did, however, replace my ailing Zen Xtra digital audio player with a Zen X-Fi 2 earlier in the year. The X-Fi 2 supports simple application development in Lua, a language I had no experience with, so I spent a few days in April knocking together a game as a learning project. I've always been fond of Kevin Ng's Laserstrike and it seemed a good fit for a device with a touch screen. [media][/media] I used the smaller levels from Badga's Laser Mayhem as it let me use larger tiles, otherwise it would be tricky to tap the correct block on the X-Fi 2's 3" screen. Having not used Lua before the code is far from brilliant (for some reason I chose to represent the level as a string rather than an array, by way of example) but it works well enough and has occasionally kept me occupied on bus and train journeys. Rather than let the game stagnate on my hard disk drive I added a final bit of polish and have released it on my website. If you'd like to try the game but do not own an X-Fi 2 (which would be almost everyone reading this) you can play it in the Zen X-Fi 2 Application Development Kit (extract the game to C:\Creative\ZEN X-Fi2\Applications) but be warned that the simulator is a little buggy (it doesn't detect touch input in the 16 rows and columns at the top and left edges of the screen for starters). Fingers crossed I can get more time for what I enjoy doing in 2012. I have plenty of fun ideas, but little time to put them into practice!
  14. benryves

    New Video

    That looks ace. :-)
  15. benryves

    Back in Classic Black

    [quote name='Alpha_ProgDes' timestamp='1298149518'] I would be great if you could fix the atrocious font colors for quotes and code snippets.Also, some of the buttons (or images that act as buttons) don't show unless you mouseover them. An example is the Show All and Add Comment buttons for the editor. [/quote]If you mean the inline font colours that some people include in their posts then there's not much I can do about that - they're inline styles, and take precedence over anything in the stylesheet. A userscript may be useful here to strip out colours from posts. I'm not sure where these misbehaving "Show All" and "Add Comment" buttons can be found, though - could you please link to an example?
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!