Browse Source

Lower baud rate

Avoid exhausting the buffer of the USB->Serial interface of the Arduino
UNO.
master
mid-kid 3 years ago
parent
commit
ec35bf70ae
  1. 2
      arduino/Makefile
  2. 2
      arduino/source/main.c
  3. 2
      client/source/main.c

2
arduino/Makefile

@ -34,7 +34,7 @@ upload: $(name).hex $(name).lst
.PHONY: screen
screen: upload
minicom -D $(SERIAL) -b 2000000
minicom -D $(SERIAL) -b 500000
%.hex: $(dir_build)/%.elf
$(OBJCOPY) -O ihex -R .eeprom $< $@

2
arduino/source/main.c

@ -188,7 +188,7 @@ int main(void)
//PCMSK1 = _BV(PCINT9);
// Initialize the program
serial_init(2000000);
serial_init(500000);
pinmode(PIN_MOSFET, OUTPUT);
writepin(PIN_MOSFET, LOW);
cart_init();

2
client/source/main.c

@ -55,7 +55,7 @@ int main(int argc, char *argv[])
puts(sp_get_port_name(port));
if (sp_open(port, SP_MODE_READ_WRITE) != SP_OK ||
sp_set_baudrate(port, 2000000) != SP_OK ||
sp_set_baudrate(port, 500000) != SP_OK ||
sp_set_flowcontrol(port, SP_FLOWCONTROL_NONE) != SP_OK) {
serial_error("Failed to open port");
return 1;

Loading…
Cancel
Save