Follow along with the video below to see how to install our site as a web app on your home screen.
Nota: This feature currently requires accessing the site using the built-in Safari browser.
Define Osc 4
CMCON = 7
TrisA=%00001111
TrisB=%00000000
PORTA = %00000000
PORTB = %00000000
repetir var byte
cartel:
for repetir = 1 to 1000
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %11111111:pauseus 300
portb = 0:pause 2
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %01111110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %00000000:pauseus 300
portb = 0:pause 2
portb = %11111110:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %11111110:pauseus 300
portb = 0:pause 4
next repetir
for repetir = 1 to 1000
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pause 2
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001110:pauseus 300
portb = 0:pause 2
portb = %10001110:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %01110001:pauseus 300
portb = 0:pause 2
portb = %11111110:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %11111110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011001:pauseus 300
portb = 0:pauseus 300
portb = %00101001:pauseus 300
portb = 0:pauseus 300
portb = %01001001:pauseus 300
portb = 0:pauseus 300
portb = %10001110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011000:pauseus 300
portb = 0:pauseus 300
portb = %00100100:pauseus 300
portb = 0:pauseus 300
portb = %01000010:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011000:pauseus 300
portb = 0:pauseus 300
portb = %00100100:pauseus 300
portb = 0:pauseus 300
portb = %01000010:pauseus 300
portb = 0:pauseus 300
portb = %11111111:pauseus 300
portb = 0:pause 4
next repetir
goto cartel
end
Define Osc 4
CMCON = 7
TrisA=%00001111
TrisB=%00000000
PORTA = %00000000
PORTB = %00000000
repetir var byte
cartel:
[B]pause 500[/B]
for repetir = 1 to 1000
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %00010000:pauseus 300
portb = 0:pauseus 300
portb = %11111111:pauseus 300
portb = 0:pause 2
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %01111110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %10000000:pauseus 300
portb = 0:pauseus 300
portb = %00000000:pauseus 300
portb = 0:pause 2
portb = %11111110:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %11111110:pauseus 300
portb = 0:pause 4
next repetir
for repetir = 1 to 1000
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pause 2
portb = %01111110:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001110:pauseus 300
portb = 0:pause 2
portb = %10001110:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %10001001:pauseus 300
portb = 0:pauseus 300
portb = %01110001:pauseus 300
portb = 0:pause 2
portb = %11111110:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %00010001:pauseus 300
portb = 0:pauseus 300
portb = %11111110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011001:pauseus 300
portb = 0:pauseus 300
portb = %00101001:pauseus 300
portb = 0:pauseus 300
portb = %01001001:pauseus 300
portb = 0:pauseus 300
portb = %10001110:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011000:pauseus 300
portb = 0:pauseus 300
portb = %00100100:pauseus 300
portb = 0:pauseus 300
portb = %01000010:pauseus 300
portb = 0:pauseus 300
portb = %10000001:pauseus 300
portb = 0:pause 2
portb = %11111111:pauseus 300
portb = 0:pauseus 300
portb = %00011000:pauseus 300
portb = 0:pauseus 300
portb = %00100100:pauseus 300
portb = 0:pauseus 300
portb = %01000010:pauseus 300
portb = 0:pauseus 300
portb = %11111111:pauseus 300
portb = 0:pause 4
next repetir
goto cartel
end
Pues si tienes razon en eso, para eso estoy usando un receptor de 38KHz segun vi en la web pues usas el pic con el que mandas la señal y lo llevas al reset de un 555 modulado a 38Khz y el sera el portador de la informacion y el pic lo codifica pero loq nose es si con SERIN y SEROUT se logre enviar los datos. Mira esto:
Saludos mecatrodatos la verdad era lo que buscaba una pagina donde encontrar de manera clara y sencilla la explicacion hacerca de PicBasic me han servido de mucho tus ejemplos para asi darme una idea de lo que vaya a realizar, tenia una pregunta amigo, se pueden transmitir datos via infrarrojos a otro pic con esos sensores de 3 pines que funcionan a 38KhZ?
Bueno el circuito que he dejado es muy sencillo 4 pulsadores y transmiten 3 codigos a b c el pic receptor compara y si es asi muestra en el lcd las letras a b c y el ultimo pulsador para limpiar, bueno espero que me puedas ayudar con esa duda, pues echando un vistazo por la web vi esto:
http://1.bp.blogspot.com/_vrRq6_c_e.../s1600/Esquema+emisor-receptor+infrarojos.png
Hola Dario
A mi se me ocurre que hagas una pausa antes de comenzar un nuevo desplazamiento...
mas o menos asi...
Código:Define Osc 4 CMCON = 7 TrisA=%00001111 TrisB=%00000000 PORTA = %00000000 PORTB = %00000000 repetir var byte cartel: [B]pause 500[/B] for repetir = 1 to 1000 portb = %11111111:pauseus 300 portb = 0:pauseus 300 portb = %00010000:pauseus 300 portb = 0:pauseus 300 portb = %00010000:pauseus 300 portb = 0:pauseus 300 portb = %00010000:pauseus 300 portb = 0:pauseus 300 portb = %11111111:pauseus 300 portb = 0:pause 2 portb = %01111110:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %01111110:pauseus 300 portb = 0:pause 2 portb = %11111111:pauseus 300 portb = 0:pauseus 300 portb = %10000000:pauseus 300 portb = 0:pauseus 300 portb = %10000000:pauseus 300 portb = 0:pauseus 300 portb = %10000000:pauseus 300 portb = 0:pauseus 300 portb = %00000000:pauseus 300 portb = 0:pause 2 portb = %11111110:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %11111110:pauseus 300 portb = 0:pause 4 next repetir for repetir = 1 to 1000 portb = %01111110:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pause 2 portb = %01111110:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %10001110:pauseus 300 portb = 0:pause 2 portb = %10001110:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %10001001:pauseus 300 portb = 0:pauseus 300 portb = %01110001:pauseus 300 portb = 0:pause 2 portb = %11111110:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %00010001:pauseus 300 portb = 0:pauseus 300 portb = %11111110:pauseus 300 portb = 0:pause 2 portb = %11111111:pauseus 300 portb = 0:pauseus 300 portb = %00011001:pauseus 300 portb = 0:pauseus 300 portb = %00101001:pauseus 300 portb = 0:pauseus 300 portb = %01001001:pauseus 300 portb = 0:pauseus 300 portb = %10001110:pauseus 300 portb = 0:pause 2 portb = %11111111:pauseus 300 portb = 0:pauseus 300 portb = %00011000:pauseus 300 portb = 0:pauseus 300 portb = %00100100:pauseus 300 portb = 0:pauseus 300 portb = %01000010:pauseus 300 portb = 0:pauseus 300 portb = %10000001:pauseus 300 portb = 0:pause 2 portb = %11111111:pauseus 300 portb = 0:pauseus 300 portb = %00011000:pauseus 300 portb = 0:pauseus 300 portb = %00100100:pauseus 300 portb = 0:pauseus 300 portb = %01000010:pauseus 300 portb = 0:pauseus 300 portb = %11111111:pauseus 300 portb = 0:pause 4 next repetir goto cartel end