Moderadores: 51, guest2003, Renie, gpenga
tcpipchip escreveu:Mandei o link para ti.
TCPIPCHIP
tcpipchip escreveu:Só falta comprar
EXEMPLO PISCA LED
DIR(8) = 1 'define P0(8) como saída
DO 'Loop Infinito
IO(8) = 1 ' Liga o LED
WAIT(1000) ' Aguarda 1 segundo
IO(8) = 0 ' Desliga o LED
WAIT(1000) ' Aguarda 1 segundo
UNTIL 0
Welcome to ARMbasic Kernel[8.14] with Floating Point for the BASICchip
DIR(8) = 1 'define P0(8) como saída
DO 'Loop Infinito
IO(8) = 1 ' Liga o LED
WAIT(1000) ' Aguarda 1 segundo
IO(8) = 0 ' Desliga o LED
WAIT(1000) ' Aguarda 1 segundo
UNTIL 0
Programming Flash 1114...
ARMbasic[8.14b] on the PC.
*+
... ( 0.08K code + 0.00K string)/20K 0.00/2K data programmed
Executing...
tcpipchip escreveu:Um CHIP DIP28 + 1 PLACA sem componentes (conversor de RS232 para TTL)
Se voce quiser uma já montada, fica o conjunto por R$50,00
Para piscar um led em BASIC...
- Código: Selecionar todos
EXEMPLO PISCA LED
DIR(8) = 1 'define P0(8) como saída
DO 'Loop Infinito
IO(8) = 1 ' Liga o LED
WAIT(1000) ' Aguarda 1 segundo
IO(8) = 0 ' Desliga o LED
WAIT(1000) ' Aguarda 1 segundo
UNTIL 0
Abraços
TCPIPCHIP
' Defs from LPC1114.bas
#define SYSTICK_ISR *&H1000003C
#define ST_BASE_ADDR &HE000E000
#define ST_CTRL *(ST_BASE_ADDR + &H10)
#define ST_RELOAD *(ST_BASE_ADDR + &H14)
#define ST_CURR *(ST_BASE_ADDR + &H18)
INTERRUPT SUB SYSTICK
OUT(1) = not IN(1)
ENDSUB
SUB SetSysTick
SYSTICK_ISR = (Addressof SYSTICK) + 1
ST_RELOAD = 12000000 ' 48000000/12000000 = 1/4 second
ST_CURR = 0
ST_CTRL = &H7
ENDSUB
Main:
IO(1)=0
SetSysTick
While (1)
Loop
end
Usuários navegando neste fórum: Nenhum usuário registrado e 1 visitante