git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4609 35acf78f-673a-0410-8e92-d51de3d6d3f4
parent
f83c58d4a4
commit
10c2f63870
|
@ -170,29 +170,29 @@ static const GPTConfig gpt3cfg = {
|
||||||
static void print(char *p) {
|
static void print(char *p) {
|
||||||
|
|
||||||
while (*p) {
|
while (*p) {
|
||||||
chIOPut(&SD1, *p++);
|
chSequentialStreamPut(&SD1, *p++);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void println(char *p) {
|
static void println(char *p) {
|
||||||
|
|
||||||
while (*p) {
|
while (*p) {
|
||||||
chIOPut(&SD1, *p++);
|
chSequentialStreamPut(&SD1, *p++);
|
||||||
}
|
}
|
||||||
chIOWriteTimeout(&SD1, (uint8_t *)"\r\n", 2, TIME_INFINITE);
|
chSequentialStreamWrite(&SD1, (uint8_t *)"\r\n", 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void printn(uint32_t n) {
|
static void printn(uint32_t n) {
|
||||||
char buf[16], *p;
|
char buf[16], *p;
|
||||||
|
|
||||||
if (!n)
|
if (!n)
|
||||||
chIOPut(&SD1, '0');
|
chSequentialStreamPut(&SD1, '0');
|
||||||
else {
|
else {
|
||||||
p = buf;
|
p = buf;
|
||||||
while (n)
|
while (n)
|
||||||
*p++ = (n % 10) + '0', n /= 10;
|
*p++ = (n % 10) + '0', n /= 10;
|
||||||
while (p > buf)
|
while (p > buf)
|
||||||
chIOPut(&SD1, *--p);
|
chSequentialStreamPut(&SD1, *--p);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue