go_away

Author Topic: Basics about IR sensors  (Read 3836 times)

0 Members and 1 Guest are viewing this topic.

Offline ukeshTopic starter

  • Full Member
  • ***
  • Posts: 107
  • Helpful? 0
Basics about IR sensors
« on: March 19, 2009, 10:06:56 AM »
hi..!
Im new to robotics and im not used to the technical words about robotics(sorry). I Recently bought an Multipurpose IR Sensor/Transreceiver and robot controller board with atmega32. how do i connect the sensor to the board to use it as an receiver so that it can be used to control the motors.

the pic of the sensor:http://robokits.co.in/shop/index.php?main_page=product_info&cPath=11&products_id=94

thnx in advance..

Offline pomprocker

  • Supreme Robot
  • *****
  • Posts: 1,431
  • Helpful? 16
  • Sorry miss, I was giving myself an oil-job.
Re: Basics about IR sensors
« Reply #1 on: March 19, 2009, 10:20:30 AM »
Read the datasheet of the sensor, and the datasheet of the microcontroller.

I am going to assume that because it has 4 pin connectors that is needs either regulated 3.3v or regulated 5v on one pin. GND to MCU on another pin, and two pins are for TX and RX for UART.

Offline ukeshTopic starter

  • Full Member
  • ***
  • Posts: 107
  • Helpful? 0
Re: Basics about IR sensors
« Reply #2 on: March 19, 2009, 10:41:06 AM »
Read the datasheet of the sensor, and the datasheet of the microcontroller.

I am going to assume that because it has 4 pin connectors that is needs either regulated 3.3v or regulated 5v on one pin. GND to MCU on another pin, and two pins are for TX and RX for UART.
thnx for the reply...

Ya it does uses 5v supply. i am going to use an remote to control the motor. so il hav to use only 3 pins( 1 for gnd, another for supply, another for signals) rite? pls correct me if am wrong.

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: Basics about IR sensors
« Reply #3 on: March 19, 2009, 03:18:07 PM »
Hi,

The #1 skill you need to make anything robotics (and almost anything else in this world) is, without doubt, the skill of reading!

From the web page you linked to:
Quote
Features

Modulated 38KHz receiver
555 timer for generating output frequency
Range setting potentiometer
Up to 20cm range for white object
Can differentiate between dark and light colours
IR led can be controlled externally though jumper setting (Through microcontroller, PC or any other circuit)
3 wire interface for simple obstacle and line sensor
4 wire interface for IR Transreceiver

From the manual that can be downloaded from that page:
Quote
• Pin 1:
 GND

• Pin 2:
 VCC (Provide +5V)

• Pin 3:
 Output terminal
 (TTL compatible output, Logic 0: when sensor receives IR modulated light, Logic 1: Normally or reflected light intensity is very less)

• Pin 4:
 Input pin for transmitter  Applicable whenever the ext/int selection jumper is put between 2-3 pins.
 Just provide any digital signal to this pin the sensor will automatically modulate the same in 38KHz IR light signal and transmit.
 If your signal logic at this pin is logic 1 then the transmitter will transmit nothing. So it is a inverted logic protocol but works fine with UART signals since the level +10V is logic 0 and 10V is logic 1.
 You can send any digital signals like UART and RC5 etc. You can also create and decode your own protocol of wireless transmission.

Under "Pin 4" it should have read "So it is a inverted logic protocol but works fine with UART signals since the level +10V is logic 0 and -10V is logic 1."
Regards,
Søren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

Offline ukeshTopic starter

  • Full Member
  • ***
  • Posts: 107
  • Helpful? 0
Re: Basics about IR sensors
« Reply #4 on: March 20, 2009, 08:08:11 AM »
Hi,

The #1 skill you need to make anything robotics (and almost anything else in this world) is, without doubt, the skill of reading!

From the web page you linked to:
Quote
Features

Modulated 38KHz receiver
555 timer for generating output frequency
Range setting potentiometer
Up to 20cm range for white object
Can differentiate between dark and light colours
IR led can be controlled externally though jumper setting (Through microcontroller, PC or any other circuit)
3 wire interface for simple obstacle and line sensor
4 wire interface for IR Transreceiver

From the manual that can be downloaded from that page:
Quote
• Pin 1:
 GND

• Pin 2:
 VCC (Provide +5V)

• Pin 3:
 Output terminal
 (TTL compatible output, Logic 0: when sensor receives IR modulated light, Logic 1: Normally or reflected light intensity is very less)

• Pin 4:
 Input pin for transmitter  Applicable whenever the ext/int selection jumper is put between 2-3 pins.
 Just provide any digital signal to this pin the sensor will automatically modulate the same in 38KHz IR light signal and transmit.
 If your signal logic at this pin is logic 1 then the transmitter will transmit nothing. So it is a inverted logic protocol but works fine with UART signals since the level +10V is logic 0 and 10V is logic 1.
 You can send any digital signals like UART and RC5 etc. You can also create and decode your own protocol of wireless transmission.

Under "Pin 4" it should have read "So it is a inverted logic protocol but works fine with UART signals since the level +10V is logic 0 and -10V is logic 1."


thnx man. I read the text and it was very confusing. thats why asked here. so i read the data sheet of the atmega 32. in portB i have decide to connect the sensor. Gnd-Gnd, Vcc-Vcc, and the pin 4 of the sensor to any one the ports like PB 1 on the MC. is this correct??

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: Basics about IR sensors
« Reply #5 on: March 20, 2009, 07:20:52 PM »
Hi,

[...] and the pin 4 of the sensor to any one the ports like PB 1 on the MC. is this correct??
Nope, input and output is seen from the IR module, not the µcontroller.

Pin 4 is input (to the IR module), which means that you send a signal INto the module

Pin 3 is an output (going OUT from the module to the controller), "0" when it sees IR light, "1" when it don't (or rather; when it's under a certain level)
Regards,
Søren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

 


Get Your Ad Here