Autor Tema: AGRADECIMIENTOS ESPECIALES  (Leído 1642 veces)

0 Usuarios y 1 Visitante están viendo este tema.

Desconectado DiegoSotomayor

  • PIC10
  • *
  • Mensajes: 3
AGRADECIMIENTOS ESPECIALES
« en: 19 de Junio de 2008, 00:14:02 »
hola
como estan todos... pues bueno
hace como una semana me adentre en los muy adentros de los misterios de los pics y todas esas cosas
y ahora por fin he terminado mi primer proyecto en un pic jajaja
la verdad no se si logren entenderme pero pues es la primera vez y la primera vez en algo siempre te deja asi como que "a que fregon soy"
jjajaja
he terminado mi semaforo claro que con las conttribuciones de algunos compañeros de aqui
sobre todo a leonpic y a firepic
que me han ayudado en mucho la verdad
por fin ya quizo hacerse mi semaforito para lo cual quisiera hacer dicha contribucion...
el que baje de aqui no estaba como que completo y mal programado asi que lo he reacomodado y aqui lo veran

      __CONFIG  _CP_OFF &  _WDT_OFF &  _PWRTE_ON &  _XT_OSC

      LIST P=16F84A
      INCLUDE <P16F84A.INC>

RB0   EQU   0   ; ROJ0_1
RB1   EQU   1   ; AMARILLO_1
RB2   EQU   2   ; VERDE_1
RB3   EQU   3   ; CRUCE_1

RB4   EQU   4   ; ROJO_2
RB5   EQU   5   ; AMARILLO_2
RB6   EQU   6   ; VERDE_2
RB7   EQU   7   ; CRUCE_2

   

CONTAD   EQU 10
CONTAD1   EQU   11
CONTAD2   EQU   12
   
   BSF   STATUS,5
   CLRF   TRISA
   CLRF   TRISB
   BCF   STATUS,5

INICIO   
   
   CLRF PORTA   
   CLRF   PORTB

SEMA1   

   BSF   PORTB,RB0   ; LUZ ROJA_1 ENCENDIDA
   BSF   PORTB,RB6   ; LUZ VERDE_2 ENCENDIDA
   BSF   PORTB,RB7   ; LUZ DE CRUCE_2 ENCENDIDA

   CALL   RETARDO

   BCF    PORTB,RB7   ; LUZ DE CRUCE_2 APAGADA
   BSF   PORTB,RB2   ; LUZ VERDE_1 ENCENDIDA   
   BCF   PORTB,RB0   ; LUZ ROJA_1 APAGADA

   CALL   RETARDO

   BCF   PORTB,RB6   ; LUZ VERDE_2 APAGADA

   CALL   RETARDO2

   BSF   PORTB,RB6   ; LUZ VERDE_2 ENCENDIDA

   CALL   RETARDO2

   BCF   PORTB,RB6   ; LUZ VERDE_2 APAGADA

   CALL   RETARDO2

   BSF   PORTB,RB6   ; LUZ VERDE_2 ENCENDIDA

   CALL   RETARDO2

   BCF   PORTB,RB6   ; LUZ VERDE_2 APAGADA
   CALL   RETARDO2

   BSF   PORTB,RB6   ; LUZ VERDE_2 ENCENDIDA

   CALL   RETARDO2

   BCF   PORTB,RB6   ; LUZ VERDE_2 APAGADA
   BSF   PORTB,RB5   ; LUZ AMARILLA_2 ENCENDIDA
   
   CALL   RETARDO

   BCF   PORTB,RB5   ; LUZ AMARILLA_2 APAGADA
   BSF   PORTB,RB4   ; LUZ ROJA_2 ENCENDIDA
   BSF   PORTB,RB3   ; LUZ DE CRUCE_1 ENCENDIDA

   CALL   RETARDO

   BCF   PORTB,RB2   ; LUZ VERDE_1 APAGADA
   BCF   PORTB,RB3   ; LUZ DE CRUCE_1 APAGADA
   
   CALL   RETARDO2
   
   BSF   PORTB,RB2   ; LUZ VERDE_1 ENCENDIDA   
   BSF   PORTB,RB3   ; LUZ DE CRUCE_1 ENCENDIDA
    
   CALL   RETARDO2

   BCF   PORTB,RB2   ; LUZ VERDE_1 APAGADA
   BCF   PORTB,RB3   ; LUZ DE CRUCE_1 APAGADA
   
   CALL   RETARDO2
   
   BSF   PORTB,RB2   ; LUZ VERDE_1 ENCENDIDA   
   BSF   PORTB,RB3   ; LUZ DE CRUCE_1 ENCENDIDA
   CALL   RETARDO2

   BCF   PORTB,RB2   ; LUZ VERDE_1 APAGADA
   BCF   PORTB,RB3   ; LUZ DE CRUCE_1 APAGADA
   
   CALL   RETARDO2
   
   BSF   PORTB,RB2   ; LUZ VERDE_1 ENCENDIDA   
   BSF   PORTB,RB3   ; LUZ DE CRUCE_1 ENCENDIDA
   
   CALL   RETARDO2

   BCF   PORTB,RB2   ; LUZ VERDE_1 APAGADA
   BCF   PORTB,RB3   ; LUZ DE CRUCE_1 APAGADA
   BSF   PORTB,RB1   ; LUZ AMARILLA_1 ENCENDIDA

   CALL   RETARDO2

   BSF   PORTB,RB0   ; LUZ ROJA_1 ENCENDIDA
   BCF   PORTB,RB1   ; LUZ AMARILLA_1 APAGADA
   BCF    PORTB,RB4   ; LUZ ROJA_2 APAGADA
   BSF   PORTB,RB6   ; LUZ VERDE_2 ENCENDIDA
   BSF   PORTB,RB7   ; LUZ DE CRUCE_2 ENCENDIDA

   CALL   RETARDO
   
   BCF   PORTB,RB7

   GOTO   INICIO

RETARDO

   MOVLW    D'50'
   GOTO RETARDO_1DECIMA

RETARDO_1DECIMA
   
   MOVWF   CONTAD
   
RETARDO1EXT2
   
   MOVLW D'100'
   MOVWF CONTAD1

RETARDO1EXT
   
   MOVLW D'249'
   MOVWF CONTAD2

RETARDO1INT
   
   DECFSZ   CONTAD2,1
   GOTO    RETARDO1INT
   DECFSZ   CONTAD1,1
   GOTO    RETARDO1EXT
   DECFSZ   CONTAD,1
   GOTO   RETARDO1EXT2
   RETURN

RETARDO2

   MOVLW    D'5'
   GOTO RETARDO_1DECIMA

RETARDO_2DECIMA
   
   MOVWF   CONTAD
   
RETARDO2EXT2
   
   MOVLW D'100'
   MOVWF CONTAD1

RETARDO2EXT
   
   MOVLW D'249'
   MOVWF CONTAD2

RETARDO2INT
   
   DECFSZ   CONTAD2,1
   GOTO    RETARDO1INT
   DECFSZ   CONTAD1,1
   GOTO    RETARDO1EXT
   DECFSZ   CONTAD,1
   GOTO   RETARDO1EXT2
   RETURN

   
   END

jajaj algo simple pero sirve perfectamente... pruebenlo y si tienen algunas inovaciones me las hacen saber
otra vez muchas gracias por ayudarme con mi proyecto y pues a disfrutar ahora si de mis vacaciones jajaja
cuidence mucho y gracias =D

Desconectado firepic

  • Colaborador
  • PIC24H
  • *****
  • Mensajes: 1130
    • JC Servicios
Re: AGRADECIMIENTOS ESPECIALES
« Respuesta #1 en: 19 de Junio de 2008, 00:29:02 »
Pues por mi parte no te preocupes, aquí estamos para ayudarnos...
Yo he recibido muchísima ayuda también y pues trato de corresponder ayudando a quien pueda...
Y qué bien, se nota que estás muy satisfecho por tu proyecto, felicitaciones diego!  :-/
Da mucho gusto cuando uno logra hacer su primer programita que funciona y uno dice: guao! esto lo he hecho yo!  :D
Es una sensación muy agradable, todos la hemos vivido y por eso nos quedamos pegados al mundo de los microcontroladores...
Disfruta tus vacaciones y espero que puedas seguir participando activamente en el foro.
Saludos, nos leemos!  :mrgreen:
"Por la presunción solo se ocasiona una lucha, pero con los que consultan juntos hay sabiduría" (Proverbios 13:10).
Visita Mi Sitio Web

Desconectado Leon Pic

  • Colaborador
  • DsPIC30
  • *****
  • Mensajes: 3610
    • Impresiones en 3D
Re: AGRADECIMIENTOS ESPECIALES
« Respuesta #2 en: 19 de Junio de 2008, 16:20:56 »
Al igual que firepic, por mi parte no hay nada que agradecer.

Y si, sabemos que se siente hacer andar el primer proyecto, una gran alegría. Y ahora viene lo mejor, ir complicándose las cosas.


FELICITACIONES POR LOGRAR LA PRIMER META.
Jesús dijo, yo soy el CAMINO, la VERDAD y la VIDA, nadie llega al PADRE si no es por mi.