2

Recent Posts

Pages: 1 2 3 4 5 ... 10
21
Software / Sharp IR Sensor with arduino
« Last post by Cheetofingers on April 19, 2014, 01:23:54 PM »
Hello, I am having trouble with the IR sensor.

I am trying to make a robot that runs 2 dc motors and 2 IR sensor with arduino.  I am using a breadboard, arduino uno, 2dc motor, 2 sharp infrared sensor (says 2Y0A21 for model?) and an h bridge chip.  The way I want to have it set up is the pin connected to the IR sensor will tell the motors to start or stop based on distance from the IR sensor. A chart i read online says the IR sensor is supposed to return a voltage to the pin based on the distance it reads. (around 3v max at 15cm )
http://3.bp.blogspot.com/-jd2TQQlOo1Q/TzKvUP5uE-I/AAAAAAAAAZ8/o_TNffud7_g/s1600/Slika04.jpg
 
When i first upload my code and have the sensor pointed in a direction, the motors will run based on how far the sensor is from something.  Right now it will only run when something is from 10cm -40cm (2V).  However they only work correctly RIGHT AFTER i upload my code to the arduino.  After that the motors will stay spinning or stay stopped.  Shouldn't the void loop just keep looping and get new values though? Or do I need to write another loop to constantly acquire new voltage values for the pin for when the distance changes? Any ideas?

Here is the code.
const int switchPin = 2;    // switch input
const int motor1Pin = 3;    // H-bridge leg 1 (pin 2, 1A)
const int motor2Pin = 4;    // H-bridge leg 2 (pin 7, 2A)
const int MOTOR1PIN = 5;
const int MOTOR2PIN = 6;
const int enablePin = 9;    // H-bridge enable pin
const int ENABLEPIN = 10;
int sensorpin = 0;
double value;
 void setup()
 {

    // set all the other pins you're using as outputs:
    pinMode(MOTOR1PIN, OUTPUT);
    pinMode(MOTOR2PIN, OUTPUT);
    pinMode(motor1Pin, OUTPUT);
    pinMode(motor2Pin, OUTPUT);
    pinMode(enablePin, OUTPUT);
    pinMode(ENABLEPIN, OUTPUT);

    // set enablePin high so that motor can turn on:
    digitalWrite(enablePin, HIGH);
    digitalWrite(ENABLEPIN, HIGH);
  }
  void loop()
  {
    value = analogRead(sensorpin);
    // if the sensor pin is greater than 2Volts
    if (value >2) {
      digitalWrite(motor1Pin, LOW);   // set leg 1 of the H-bridge low
      digitalWrite(motor2Pin, HIGH);  // set leg 2 of the H-bridge high
      digitalWrite(MOTOR1PIN, LOW);
      digitalWrite(MOTOR2PIN, HIGH);
    }
    else
    {
      digitalWrite(enablePin, LOW);
      digitalWrite(ENABLEPIN, LOW
    }
  }
22
Mechanics and Construction / robotics hand
« Last post by ansh on April 19, 2014, 05:08:19 AM »
I need some information about robotics hand. I want to know how does finger and thumb make for ROBOTIC hand.
I mean This is hard part for me,

1)which mechanical and electronic components are used to make thumbs and four finger ?
2) If anyone know about any link or thread please share
23
Electronics / Re: Power Boards
« Last post by jwatte on April 18, 2014, 10:40:13 AM »
If your servos are stalling, then they are not sufficiently specified to do the work they're intended to do. If you cut them off, they will not be able to hold the load.
If that is what you want to do, then you can try:
1) A 1.5A slow-blow fuse.
2) A 1.5A trip-point resettable PTC fuse.
3) A current sensor and a switch/relay of some sort.

The problem with 1) and 2) is that they are not particularly precise, and they are ambient temperature and duty cycle sensitive. Pololu has some nice current sensors for 3) based on the ACS line of Hall effect sensors. Like this one: http://www.pololu.com/product/1185
Read it with a microcontroller, and use a relay or power MOSFET to cut the power.
24
Misc / Re: Trash robot
« Last post by mickyjune26 on April 18, 2014, 07:47:29 AM »
FYI - I'll be following this blog as part of this project.  Someone is building a full-size TOtT (Take Out the Trash) robot.
25
Electronics / Re: Power Boards
« Last post by waltr on April 18, 2014, 07:25:31 AM »
What will be the power source?
Batteries?
AC Mains?

For servo power use a separate PS that has enough current capacity for all the servos.
For protection a self resettable fuze does work but it will take some time to reset.


The R-Pi and Arduino could use linear regulator chips (7805 type) or switching regulators (Pololu and other haves these). Again ensure that the regulator has enough current capacity plus some for the devices being powered. And if you use a linear regulator ensure to have enough heat sinking.
26
Electronics / Power Boards
« Last post by luc on April 17, 2014, 09:03:26 PM »
Hey guys,

Would any of you have suggestions / resources that would help me build a power board for a robot Im trying to build?
It'll need to power the following:

Raspberry Pi
Arduino
Dual Channel Serial Motor Controllers (2)
Servos (4)

Also, a problem in the past when trying to implement this bot was that the servos were immediately going to stall when a signal was sent to them.  The stall current is 1.5A, I believe.  What could I do to perhaps 'disconnect them' if they start to pull this much current?
27
Misc / Instructables - Robotic Camera Dolly System
« Last post by ServoCity on April 17, 2014, 01:28:39 PM »
The Instructables team did an awesome job of designing and implementing this robotic camera dolly system.  To view a complete build log/video and parts list visit http://www.instructables.com/id/Robotic-Camera-Dolly-System/.

The Robotic Camera Dolly System has these key features:
- The ability for real-time filming and stop motion photography.
- It is controllable via an easy-to-use touch screen.
- The system can pan, tilt and drive at the same time.
- All actions are repeatable thanks to servo motors and a DC drive motor with a rotary encoder.
- The dynamic Actobotics build system and open source Arduino-based hardware, allows it to be fully customizable to meet your own needs.


28
Software / Re: how to control robot via internet ?
« Last post by jwatte on April 16, 2014, 09:34:38 AM »
do you know the name of software?

I already included the name of the software to use for developing this in my answer. It is not a "ready made" solution, though.
29
Software / Re: how to control robot via internet ?
« Last post by gerard on April 15, 2014, 10:06:03 PM »
superdroid robots has a network control package that comes with everything you need to control your robot from around the world
http://www.superdroidrobots.com/shop/item.aspx/wifi-custom-control-interface-package/929/
it costs ONLY $1k !!!
30
Software / Re: how to control robot via internet ?
« Last post by ansh on April 15, 2014, 08:32:15 PM »
do you know the name of software?
Pages: 1 2 3 4 5 ... 10

Get Your Ad Here

data_list