Go Down

Topic: Arduino MEGA on another PCB (Read 1 time) previous topic - next topic

Hi,

I'm trying to make a PCB for my robot, and am using an Arduino MEGA to interface with sensors. To mount my MEGA onto the PCB, what I want to do is get the corresponding male pin layout for the MEGA on my PCB, and then stick the MEGA on my PCB upside down. I don't really want to measure it all out and draw it myself in EAGLE... is there some way I can use the existing MEGA EAGLE files to create the corresponding male pins?

I tried looking for this problem on the existing forums but couldn't find it (I didn't really know what words to use to search for it). I'm pretty sure, though, that this is not an uncommon problem...

luxy

Do you really need so much input/outputs? If not, you can use ATmega328 in DIL package. It is much simpler to integrate on PCB and you can use for example Arduino Uno as a programmer. If you don't want to go in stand alone version, you can use Arduino Nano. It is small enough and you can found Eagle scheme for it on Arduino page.

Tom Carpenter

Google 'Sparkfun Eagle Library', its on github and the outline and pin positions of a mega are in that library.

Edit: https://github.com/sparkfun/SparkFun-Eagle-Libraries
~Tom~

Hey Tom,

Yeah, I actually have the Sparkfun library, and it includes the Arduino MEGA on it. However, I don't think that's quite what I want (or if is, then I'm still confused as to how to use it). I'll attach a picture to show you what I mean.

Hey guys,

Thanks for the quick replies. Luxy, I think I do need the I/O, mostly for serial, actually. Analog and digital could have been handled by an Uno, but I need all three Tx/Rx.

Tom Carpenter

The outline has the pin headers on it aswell, correct?

If so, place it on the board, and then use the MIRROR command to flip it onto the bottom layer. This will simulate the mega board being upside down. As the pin headers are through hole, you can simply mount the header on the top of the board.
~Tom~

jonisonvespaa

you could try to use a bit of vero board

im not sure about the mega but the uno wont fit very well because the distance between the single way headers isnt 2.54mm pitch

but worth a try, better still learn to lay out a pcb and make your own

CrossRoads

You can take the mega schematic file, strip off all but the headers and use the layout that is left.
View it as plugging onto the mega board from above. Components on the bottom will be the parts you see when you flip it over and plug it onto the Mega. Components on the top will be the parts you won't see because they are between the boards.
Be sure to keep the ICSP header in place if you plan to do any bootloading without having to pry them apart.  Having all 86 pins plugged in makes for a pretty solid assembly.
The first picture here is an example of board that started out per the above.
http://www.crossroadsfencing.com/BobuinoRev17/
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

CrossRoads, that's exactly what I'm looking for! The only difference is that I want male pins, but the layout is the same. I'm getting an error trying to use the MIRROR command; it's telling me that it can't do it because "some objects extend outside the the allowed board area", and EAGLE Light won't do it for me.

Also, how do you separate the pads layer from the rest of the layers? I've done a couple of searches, but I don't even think I know how to ask my question properly.

Tom Carpenter

Ok, yeah, thats one of the annoying things about eagle.

There is a way around it though. If you select the mega footprint with the move tool, then while it is following the mouse, there is a button on the toolbar at the top which looks like a grid of 4 squares, the two on the left are shaded and there is a line down the middle. If you click that it will mirror the footprint and you can then place it down within the board outline.
~Tom~

CrossRoads

That board has male pins - they stick out the bottom to plug onto the Mega/Due.
You don't have to use female headers - you can use straight pins.
Doing it this way, with your components on the side shown (the top) you will be able to see your compenents for trouble shooting.
Otherwise, with components on the bottom, they will be inside the board sandwich and not accessible.

I wouldn't mirror anything. Take the Mega design, leave the header holes in place, and strip out the rest.

Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

All right guys, thanks very much for your help. I think I've got it figured out now.

One last question: how does one 'strip away other layers'?

CrossRoads

Viewing them, or actually deleting them?
Viewing, Edit:View & deselect them.
Deleting, deselect all but the one you want, use the X button (Edit:Delete) and start clicking away.

Or just start from this
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

Crossroads,

Thanks for the files. I'm actually getting a 503 error on them, but that's okay. I want to learn to do this myself; this is probably something I'll need to use again in the future.

Thanks all for all your help. I think (I hope...) I can take it from here. :)

CrossRoads

The 503 error is the forum - none of us can download attachments for the last few days.
PM me with e-mail, I'll send you the files if you want.
Key is getting headers all spaced & placed correctly.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

Go Up