You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

20 lines
213 B

  1. #include <pic.h>
  2. #include "config.h"
  3. #include "serial.h"
  4. #include "dac.h"
  5. __CONFIG(CONFIGWORD);
  6. void main(void) {
  7. CMCON = 7;
  8. GIE = 1;
  9. serial_init();
  10. dac_init();
  11. while(1)
  12. {
  13. dac_set(serial_get());
  14. }
  15. }