Commit Graph

9 Commits

Author SHA1 Message Date
Kevin O'Connor 4f07ee4d92 pyhelper: Add ability to route error messages to python logging
Instead of writing error messages to stderr, route them into the
python code and use the standard python logging system.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-30 21:19:43 -05:00
Kevin O'Connor b14db404b5 pyhelper: Move helper functions from serialqueue.c to new file
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-30 13:33:16 -05:00
Kevin O'Connor 7cb71df02c mcu: Be careful to free memory allocated in C code
Free steppersync, stepcompress, and commandqueue objects.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-30 13:33:16 -05:00
Kevin O'Connor 0d43d269ed serialhdl: Fully deallocate serialqueue on disconnect
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-29 21:58:48 -05:00
Kevin O'Connor 72c4f353e6 serialqueue: Kick the background thread from serialqueue_exit
Wake the background thread up when exiting - as this makes the exit
complete faster (and have more predictable timing).

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-29 18:49:12 -05:00
Kevin O'Connor 4d6830a373 serialqueue: Fix possible memory leak in serialqueue_extract_old()
Make sure to free all messages even if the requested size is smaller
than the number of messages.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-11-29 18:49:12 -05:00
Kevin O'Connor 777a0b817b serialhdl: Calculate baudadjust from MCU's baud instead of host baud
Store the baud rate the MCU is configured for in the "identify" data
and use that rate when calculating the baudadjust parameter.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-07-16 21:33:35 -04:00
Kevin O'Connor 38f1d78e1b serialqueue: Add debugging helper functions for dumping a binary buffer
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-06-05 10:52:46 -04:00
Kevin O'Connor f582a36e4d Initial commit of source code.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2016-05-25 11:37:40 -04:00