Go Down

Topic: Enough pins (Read 1 time) previous topic - next topic

CdRskuLL

Hi peeps,

Just want to check before ordering everything that I'm not going to run out of pins :-)

I'm building a bot (3d printed) which when I have something workable going to upload for everyone to join in. I'm looking at the electronics side at the moment and I'm tight on space so have a nano to work with.

My aim is to make a bot with 16 servos / tilt sensor / wifi for PC communication (wrote in vb.net) + more sensors I've yet to decide on.

So.. the board is a nano (for size)
Tilt sensor is a MMA7361 Three Axis Accelerometer (connected to A0,A1,A2 and Aref)
The wifi I have yet to buy but was looking at http://www.ebay.com/itm/130542318415?ssPageName=STRK:MESELX:IT&_trksid=p3984.m1558.l2649
The servo board I've been looking at also uses the UART..

I'm new to all this so any help would be appreciated :-)

O.. also if you could recommend some neat sensors / voice recognition etc.. then too might help :-)

I can't afford a NAO bot.. so I'm build one myself called FreeBOT.. :-)

thanks,

Steve

PaulS

The Nano has 14 digital pins, including the two used for serial communication, and 8 analog pins, which can also be used as digital pins (at least 6 of them can, anyway).

16 servos need 16 pins. The three axis accelerometer needs three pins. That WiFi modules needs two pins. That is using 21 of the 20 or 22 pins you have.

You mention a servo board but have said nothing about it. If you can offload the servos to that board, and use SoftwareSerial to talk to it, then you should have enough pins.

CrossRoads

2 of the analog pins, A6 & A7, are analog input only.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

PaulS

Quote
2 of the analog pins, A6 & A7, are analog input only.

I wasn't sure about that. Nothing on the Nano page says for certain that any of the analog pins could be used as digital pins, but, since it is a 328-based device, I knew that 6 of them could be used as digital pins.

CrossRoads

Yup, right on page 4. Analog inputs to the ADC on the TQFP part.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

CdRskuLL

Hiya,

thanks for the reply's. Sorry the servo control board I was looking at was a 24 version of this one http://www.ebay.co.uk/itm/32-Channel-Servo-USB-Controller-board-for-arduino-MCU-PIC-/250998651279

I want to add as many sensors as I can.. so the more free pins the better. I've heard about a serial software port so thanks for that.. will do some reading on it.

I'm taking it one step at a time at the moment... just printing and building mmy lower bot first and seeing how it goes.

thanks

Steve

msb4180

#6
Nov 09, 2012, 12:58 am Last Edit: Nov 09, 2012, 05:49 am by leandro4b Reason: 1
Since you are using the computer along with the board, I'd suggest BitVoicer for the speech recognition features (http://www.bitsophia.com/BitVoicer.aspx). It will help to save pins.

DuaneB

You can do 20 servos this way for about 60 cents -

http://rcarduino.blogspot.com/2012/10/arduino-serial-servos-20-servos-4-pins.html

The most costly part of having a lot of servos is powering them. I would start looking into powering your project now.

Duane B

rcarduino.blogspot.com
Read this
http://rcarduino.blogspot.com/2012/04/servo-problems-with-arduino-part-1.html
then watch this
http://rcarduino.blogspot.com/2012/04/servo-problems-part-2-demonstration.html

Rcarduino.blogspot.com

Go Up