summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Buesch <mb@bu3sch.de>2008-10-23 20:46:28 +0200
committerMichael Buesch <mb@bu3sch.de>2008-10-23 20:46:28 +0200
commit5d469653af9d29a7747d88225f65284fad71cd6f (patch)
tree2c2498274e2f3ce3bb85e20a18b03c011d3b52ae
parent55e576638e744b34021de662f0e8f4d9f5bbf6fd (diff)
downloadcnc-5d469653af9d29a7747d88225f65284fad71cd6f.tar.xz
cnc-5d469653af9d29a7747d88225f65284fad71cd6f.zip
pressure_control: Speeup link
Signed-off-by: Michael Buesch <mb@bu3sch.de>
-rw-r--r--pressure_control/firmware/remote.c6
-rwxr-xr-xpressure_control/remote/pctl-remote6
2 files changed, 6 insertions, 6 deletions
diff --git a/pressure_control/firmware/remote.c b/pressure_control/firmware/remote.c
index 97f72df..6607098 100644
--- a/pressure_control/firmware/remote.c
+++ b/pressure_control/firmware/remote.c
@@ -29,7 +29,7 @@
#include <avr/io.h>
-#define BAUDRATE 9600
+#define BAUDRATE 115200
static struct remote_message rx_msg;
@@ -303,8 +303,8 @@ static void usart_init(void)
UBRRL = lo8((CPU_HZ / 16 / BAUDRATE) * 2);
UBRRH = hi8((CPU_HZ / 16 / BAUDRATE) * 2) & ~(1 << URSEL);
UCSRA = (1 << U2X);
- /* 8 Data bits, 2 Stop bits, Even parity */
- UCSRC = (1 << URSEL) | (1 << UCSZ0) | (1 << UCSZ1) | (1 << UPM1) | (1 << USBS);
+ /* 8 Data bits, 1 Stop bit, No parity */
+ UCSRC = (1 << URSEL) | (1 << UCSZ0) | (1 << UCSZ1);
/* Enable transceiver and RX IRQs */
UCSRB = (1 << RXEN) | (1 << TXEN) | (1 << RXCIE);
/* Drain the RX buffer */
diff --git a/pressure_control/remote/pctl-remote b/pressure_control/remote/pctl-remote
index 2ddbfac..74805d9 100755
--- a/pressure_control/remote/pctl-remote
+++ b/pressure_control/remote/pctl-remote
@@ -24,10 +24,10 @@ from PyQt4.QtGui import *
# Serial communication port configuration
-CONFIG_BAUDRATE = 9600
+CONFIG_BAUDRATE = 115200
CONFIG_BYTESIZE = 8
-CONFIG_PARITY = PARITY_EVEN
-CONFIG_STOPBITS = 2
+CONFIG_PARITY = PARITY_NONE
+CONFIG_STOPBITS = 1
# The size of one message
MSG_SIZE = 12
bues.ch cgit interface