The Puma
Joined: 23 Apr 2004 Posts: 227 Location: The Netherlands
|
|
Posted: Mon May 15, 2006 12:14 pm |
|
|
I have working sofar with this code
Code: |
#include <18F4620.h>
#use delay(clock=20000000)
#use rs232(baud=19200,parity=n,xmit=PIN_C6,rcv=PIN_C7,bits=8)
#fuses HS,NOWDT,NOBROWNOUT,NOPUT,NOLVP,DEBUG,NOSTVREN,NOPROTECT
#include <cu20045scpb-t23a.h>
void main() {
output_low(CU20045SCPB_BUSY);
printf("TEST");
delay_ms(1);
output_high(CU20045SCPB_BUSY);
} |
Code: |
#define CU20045SCPB_BUSY PIN_C0
void vfd_init() {
output_high(CU20045SCPB_BUSY);
delay_ms(2);
}
void vfd_send_byte(byte n) {
output_low(CU20045SCPB_BUSY);
printf(n);
delay_ms(2);
output_high(CU20045SCPB_BUSY);
}
void vfd_putc(char c) {
switch(c) {
default : vfd_send_byte(c); break;
}
}
|
But if i change to that it did't work anymore
What is the problem
Code: | #include <18F4620.h>
#use delay(clock=20000000)
#use rs232(baud=19200,parity=n,xmit=PIN_C6,rcv=PIN_C7,bits=8)
#fuses HS,NOWDT,NOBROWNOUT,NOPUT,NOLVP,DEBUG,NOSTVREN,NOPROTECT
#include <cu20045scpb-t23a.h>
void main() {
vfd_init();
vfd_putc("TEST");
}
|
|
|