Showing posts with label mac. Show all posts
Showing posts with label mac. Show all posts

Sunday, August 30, 2015

Modding an Apple Mac Pro Power Supply

 I got an old Mac Pro power supply to replace my puny old Dell.  The thing is massive!  79A of 12V power, that's over 900 watts!!

But, there's a catch.  Like all things Apple, it's a beautifully crafted, high quality unit.  And unlike the rats-nest wiring associated with PC power supplies, it's got a single clean wiring harness which is sadly undocumented on the Internet.
 I guessed the large connectors would be for 12V and ground.  Measuring the voltages would indicate the polarity.  BUT  How to turn the unit on?  I was looking for the equivalent of the PC's Green PWR Wire, the one that if shorted out turns on the power supply.

Going strictly by guess, I started shorting out pairs of connections.  I figured it couldn't do much harm, since none of the wires would be carrying current if the PWR wire were not engaged.
Using a paper clip, I quickly found the pair of PWR,GND connection.  I'm not sure which one is which, but for my purposes it doesn't really matter.  I made a note of the connections so that I'll be able to recreate them when I cons up a connector to the charger.

The outside big connectors are both GND, and the inside big connectors are both +12.2V.  The PWR/GND pair is the outside small connectors, second from the bottom.  The connector is oriented so the left side is smooth, and the right side has the edge.
A slight bit of fiddling showed that the small curve of a paper clip was the perfect size to connect PWR/GND.  I snapped a picture of it and will cover it with tape to ensure it stays put.

That's it for the experiment phase.  I'll use the flat blades from an old extension cord to bodge up a connector for 4mm bullets which is what my power supply uses.  I'll update when I do that!

Note: I think it's this model:  Apple 661-5011 980 WATTS POWER SUPPLY


Here's a video walkthrough:



blogodex = {"toc" : "Power Supplies", "idx" : ["Mac", "charging", "power", "electronics"]};

Tuesday, August 5, 2014

MacOS FTTI Installation

Here's the installation guide. On page 3, use this link to get the dmg and select the appropriate file for your MacOS version.  10.9 seems to work with the release for 10.8.  You want the one that creates the virtual com port.



Here's the error I was getting:

avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding 


blogodex = {"idx" : ["FTDI", "MacOS FTDI Drivers"]};

Friday, May 25, 2012

Building ArduPilot Mega on Mac

Here how I set up Arduino to compile ArduPlane and ArduCopter on the Mac.

Install Arduino

Download ArduPlane and create a working directory

  • Get the newest copy of Arduplane from the Ardupilot repository.  I grabbed version 2.34.
  • My home directory is /Users/mh, and my working directory is /Users/mh/apm
  • Change to the working directory and unzip ArduPlane-2.34.zip.
  • You should see these directories.  There's some others that you can ignore.
/Users/mh/apm/ArduPlane-2.34
/Users/mh/apm/ArduPlane-2.34/ArduPlane
/Users/mh/apm/ArduPlane-2.34/libraries


Connect your APM to the computer via USB

  • IF YOUR APM IS ON AN AIRCRAFT, DISCONNECT THE AIRCRAFT BATTERIES OR REMOVE THE PROPS!
  • No kidding, the props can spin up unexpectedly and send you to the hospital for stitches!



Run Arduino and configure the environment

  • Run the Arduino program.  Restart it if it was already running so that it can see the APM USB connection.
  • Set the CPU type: Tools / Board / Arduino Mega 2560 (AtMega 1280 for APM1)
  • Set the APM serial port: Tools / Serial Port / /dev/tty.*usb*  The name will vary, look for tty and usb.
  • Set the sketchbook location:  Arduino / Preferences... / Sketchbook Location
  • Set it to the unzipped directory; In my case: /Users/mh/apm/ArduPlane-2.34
  • Quit Arduino and Restart.
  • Double check that the above three settings are still good.

Compile (Verify) the ArduPlane software

  • File / Open... and navigate to /Users/mh/apm/ArduPlane-2.34/ArduPlane
  • Open ArduPlane.pde.  This will give you a window with several files opened in tabs.
  • Click the Verify button.
  • After a while, you should get a message like "Binary sketch size: 157,232 bytes (of a 258,048 byte maximum)"

Upload to APM

  • Click the Upload button.
  • You should see the APM serial light blink furiously
  • You should get the message "*******"

Working on the Arducopter software

  • note: There's some unorthogonality with the downloaded Arducopter zip file.  There's no intermediate directory with a version number.
  • Grab the newest copy of ArduCopter from the ArduCopter repository. I grabbed version 2.5.5.
  • Unzip ArduCopter-2.5.5.zip  in some scratch directory.  This will give you two directories, Arducopter and libraries.  libraries is identical to the ArduPlane version, so you can ignore it.
  • Delete the directory ArduPlane-2.34/ArduCopter
  • Copy ArduCopter to ArduPlane-2.34.
  • You should see the directory ArduPlane-2.34/ArduCopter.
  • In Arduino, open the file ArduPlane-2.34/ArduCopter/ArduCopter.pde.
  • Compile and Upload as described above!

Working with git

  • The Arduplane projects are hosted on Google Code.  Get a Google account if you don't have one.
  • Instructions for checking out are on the ArduPilot source page.
  • You don't need to grab ArduCopter separately.  It will be in the ArduCopter directory as described above.  If you do grab it, it will have a single file pointing you to the ArduPlane repository.
Using command line tools
  • There are notes in README.txt
  • tl;dr: cd ArduPlane; make configure; edit ../config.mk; make; make upload
  • I had to edit the following entry in libraries/AP_Common/Arduino.mk to add the -C parameter.
upload: $(SKETCHHEX)        $(AVRDUDE) -c $(UPLOAD_PROTOCOL) -p $(MCU) -P $(PORT) -b$(UPLOAD_SPEED) -U flash:w:$(SKETCHHEX):i -C /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf