Add darp5 firmware

This commit is contained in:
Jeremy Soller
2020-01-15 21:02:41 -07:00
parent 9aadf50764
commit 5d10775877
43 changed files with 2472 additions and 201 deletions

View File

@ -0,0 +1,20 @@
#include <stdio.h>
#ifdef SERIAL_DEBUGGER
#include <mcs51/8051.h>
#endif
#ifdef I2C_DEBUGGER
#include <ec/i2c.h>
#endif
int putchar(int c) {
unsigned char byte = (unsigned char)c;
#ifdef SERIAL_DEBUGGER
SBUF = byte;
#endif
#ifdef I2C_DEBUGGER
i2c_send(&I2C_0, I2C_DEBUGGER, &byte, 1);
#endif
return (int)byte;
}