13
Basic Stamp OEM module By Wilmer Arellano

Basic Stamp OEM module

  • Upload
    mireya

  • View
    101

  • Download
    2

Embed Size (px)

DESCRIPTION

Basic Stamp OEM module. By Wilmer Arellano. P0-P15 I/O. Reset Input (RES). 5.5 – 15V input (Vin). Ground- 0V (Vss). Regulated 5V (Vdd). The BASIC Stamp 2 OEM is a discreet component version of the BS2 which may be purchased in kit form. - PowerPoint PPT Presentation

Citation preview

Page 1: Basic Stamp OEM module

Basic StampOEM module

By Wilmer Arellano

Page 2: Basic Stamp OEM module

2

The BASIC Stamp 2 OEM is a discreet component version of the BS2 which may be purchased in kit form.

The male header provides the means to ‘plug-it’ into your own board, or connect to other boards.

Regulated 5V (Vdd)

Ground- 0V (Vss)

5.5 – 15V input (Vin)

Reset Input (RES)

P0-P15 I/O

Power the board with EITHER:A) 5.5-15VDC on Vin. This will also provide 5VDC regulated output on Vdd.

B) Regulated 5V Input on Vdd.

Page 3: Basic Stamp OEM module

Using the breadboard (Socket board)

The bread board has many strips of metal (copper usually) which run underneath the board.

The metal strips are laid out as shown in orange. The long top and bottom row of holes are usually used for power supply connections.

To use the bread board, the legs of components are placed in the holes (the sockets). The holes are made so that they will hold the component in place. The circuit is built by placing components and connecting them together with jumper wires.

Page 4: Basic Stamp OEM module

22

0 O

hm

OEM BASIC Stamp 2sx

5V

Ground

9V

Page 5: Basic Stamp OEM module

Connection220 Ohm resistor should be connected to pin P4 of the OEM Basic Stamp 2sx.

“+” (long) lead of LED should be connected to opposite side of the resistor. The other (short) lead of the LED goes to “-” 220 Ohm

LED

9 V battery

Page 6: Basic Stamp OEM module
Page 7: Basic Stamp OEM module

' {$STAMP BS2sx}' {$PBASIC 2.5}

Green: 'Label Or point were you can RETURNLOW 4 'Set pin 4 an output pin and low voltage "0"PAUSE 1000 'Pause 1000 msHIGH 4 'Set pin 4 an output pin and high voltage "1"PAUSE 1000 'Pause 1000 msGOTO Green

Flashing LED

Page 8: Basic Stamp OEM module

' {$STAMP BS2sx}' {$PBASIC 2.5}start:HIGH 0HIGH 1HIGH 2HIGH 3HIGH 4HIGH 5HIGH 6HIGH 7HIGH 8HIGH 9HIGH 10HIGH 11HIGH 12HIGH 13HIGH 14HIGH 15PAUSE 100LOW 0LOW 1LOW 2LOW 3LOW 4LOW 5LOW 6LOW 7LOW 8LOW 9LOW 10LOW 11LOW 12LOW 13LOW 14LOW 15PAUSE 100GOTO start

Code to test your microcontroller

Page 9: Basic Stamp OEM module

OEM BASIC Stamp 2sx Wiring diagram

Note:

- is connection to negative pole of the battery

22

0 O

hm

22

0 O

hm

22

0 O

hm

22

0 O

hm

Pushbutton

Buzzer

LED

LED LED

OUT

PIRMotionsensor

9 V battery

CO

M p

ort

Mic

rocon

troller

ch

ip

15

KO

hm

Page 10: Basic Stamp OEM module

' {$STAMP BS2sx}' {$PBASIC 2.5}

Green: 'Label Or point were you can RETURNLOW 4 'Set pin 4 an output pin and low voltage "0"PAUSE 1000 'Pause 1000 msHIGH 4 'Set pin 4 an output pin and high voltage "1"PAUSE 1000 'Pause 1000 msDEBUG ? IN0 'Input the value of pin 1PAUSE 1000 'Pause 1000 msGOTO Green

Flashing LED + Switch Input

Page 11: Basic Stamp OEM module

Making Sound

' {$STAMP BS2sx}' {$PBASIC 2.5}start:FREQOUT 1, 10000, 1000PAUSE 1000GOTO start

Page 12: Basic Stamp OEM module

Making Sound

' {$STAMP BS2}' {$PBASIC 2.5}start:HIGH 1PAUSE 5LOW 1PAUSE 5GOTO start

Page 13: Basic Stamp OEM module

CAR 1 ' {$STAMP BS2sx} ' {$PBASIC 2.5}

PAUSE 5000 HIGH 10 LOW 11 start: HIGH 4 HIGH 8 LOW 9 PAUSE 3000 LOW 4 LOW 8 PAUSE 3000 HIGH 9 PAUSE 3000 LOW 9 PAUSE 3000 GOTO start