ModmataC  1.0
A C library for Arduino communication
blink.c
#include <ModmataC.h>
int main() {
// start serial connection with arduino, given a port, baud rate, and id
connectArduino("/dev/ttyACM0", 115200, 1);
// Set mode of pin 13 to OUTPUT
while(1) {
// Turn on LED
delay(1000);
// Turn off LED
delay(1000);
}
}
int connectArduino(char *port, int baudRate, int id)
Definition: ModmataC.c:93
void pinMode(uint8_t pinNum, uint8_t mode)
Definition: ModmataC.c:121
void delay(int millis)
Definition: ModmataC.c:56
void digitalWrite(uint8_t pinNum, uint8_t input)
Definition: ModmataC.c:143
#define HIGH
Definition: ModmataC.h:43
#define OUTPUT
Definition: ModmataC.h:40
#define LOW
Definition: ModmataC.h:42