Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
#include <Arduino.h>
int getChar(FILE *fp) {
while (!(Serial.available()))
return (;
int putChar(char c, FILE *fp) {
if (c == '\n') {
putChar((char)'\r', fp);
return 0;
void setup() {
fdevopen(putChar, getChar);
printf("Hello %s!", "there")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.