Commit graph

48 commits

Author SHA1 Message Date
iceman1001 13cd6ab61a add support for higher speeds. 2019-05-18 21:38:21 +02:00
Philippe Teuwen 362d7b6956 Fix win32 uart_receive disconnected device error code (@iceman) 2019-05-16 13:16:23 +02:00
Philippe Teuwen b5e4a60a15 timeout reconfiguration: flag was never cleared and some more changes:
* clear newtimeout_pending flag
* fix initial newtimeout_pending flag value on win32
* remove all _atomic as anyway a load+clear wouldn't be atomic and we're not in a critical situation: just one writer seldomly called on reconnect
* move new timeout poll to uart_recv for faster deployment
* remove redundant uart_reconfigure_timeouts(UART_FPC_CLIENT_RX_TIMEOUT_MS);
2019-05-16 12:35:40 +02:00
iceman1001 b206ecfad3 chg: revert logic 2019-05-16 07:44:52 +02:00
iceman1001 27c556b69a fix: now compiles on mingw 2019-05-16 07:32:34 +02:00
Philippe Teuwen b4e8be82f4 remove spMutex, use atomic test&set instead 2019-05-16 00:29:30 +02:00
Philippe Teuwen 7928a82434 uart_win32: Remove debug msgs 2019-05-10 07:46:49 +02:00
Philippe Teuwen 68e5b3c355 style 2019-05-08 01:35:51 +02:00
iceman1001 7785dcbce4 chg: less fallbacks 2019-05-07 12:05:37 +02:00
iceman1001 61d250a7f8 add: 'hw connect' - lets you connect to a specified serial port. If already connected, it disconnects current port before. 2019-05-07 11:05:05 +02:00
iceman1001 29a160c905 reconnect version2 yolo 2019-05-06 22:41:00 +02:00
iceman1001 a49ae2d0ce FIX: slow reconfigure on mingw of serial port 2019-05-03 21:33:00 +02:00
Philippe Teuwen 4f11ef048f style 2019-05-01 01:38:52 +02:00
iceman1001 f8f39d6196 fix: passing a struct. 2019-04-30 22:03:20 +02:00
Philippe Teuwen dbf5e74069 Fix "control reaches end of non-void function" warning 2019-04-30 21:48:14 +02:00
iceman1001 e1063e2836 chg: reconfigure uart timeouts when compiled for FPC and connecting over USB. 2019-04-30 12:57:44 +02:00
iceman1001 26c953aee8 MINGW, uart speed up when compiling with FPC support 2019-04-30 09:47:21 +02:00
Philippe Teuwen 12937884f6 move uart_speed to conn struct and display baudrate only for real UART 2019-04-27 01:15:52 +02:00
Philippe Teuwen 4aa1b49493 fix uart_posix: bytecound must be 32b 2019-04-21 01:05:02 +02:00
Philippe Teuwen 6e744043f5 usart working... when debugged... 2019-04-21 00:44:19 +02:00
iceman1001 7912f7494b init array 2019-04-14 19:44:55 +02:00
Philippe Teuwen 9a7bba2438 Move UART open msg to avoid flood in wait mode 2019-04-14 18:49:19 +02:00
Philippe Teuwen 04c0384d3e Testing pm3 communication 2019-04-14 17:25:17 +02:00
Philippe Teuwen 21be6d4400 FPC: got RX working, got client over usart somehow working..., see detailed commit msg
* using WITH_FPC:
  * activate basic usart
  * no double buffer for now, no interrupt
  * usart_dataavailable/usart_readbuffer/usart_writebuffer, to demo it:
    * pm3 client over USB, minicom over usart
    * analyse a d 414243
* using WITH_FPC_HOST:
  * it implies WITH_FPC as it's based on it
  * control pm3 with client over usart
  * EXPERIMENTAL! still some frame desync issues
  * you can connect both from usart & USB with two pm3 clients
    * actually you *have* to connect USB for the moment because
      it's used to send debug messages about buggy usart... See Dbprintf_usb below
  * "sessions": msgs are directed to the latest client to have sent a cmd
  * Dbprintf_usb macro to send msgs to USB client to help debugging usart...
  * We now have an option to run client at different speed as usart is 115200:
    client/proxmark3 /dev/ttyUSB0 -b 115200
  * Consequently, argc,argv handling is a bit revamped, it was so messy...
  * USB and flashing are still at 460800, don't try flashing over usart yet ^^
2019-04-02 22:06:10 +02:00
Philippe Teuwen 1b2601a48a Add missing EOF LF 2019-03-12 00:12:26 +01:00
Philippe Teuwen 961d929f4d changing {} style to match majority of previous style 2019-03-10 11:20:22 +01:00
Philippe Teuwen 0373696662 make style 2019-03-10 00:00:59 +01:00
Philippe Teuwen 1fe75f2481 zlib, uart: fix mix of spaces & tabs 2019-03-09 11:15:18 +01:00
Philippe Teuwen 60f292b18e remove spurious spaces & tabs at end of lines 2019-03-09 08:59:13 +01:00
iceman1001 99b6087b01 chg: use calloc 2019-01-30 21:16:20 +01:00
Chris f8c33af1da CHG: FPC connector tests. Device -> Client communications works.
Adjust  armsrc/Makefile   and client/Makefile  to include  the  -DWITH_FPC  flag to compile with FPC enabled.
2018-11-20 10:58:32 +01:00
Chris 24eaac8681 CHG: the thread comms refactoring from offical pm3 repo
chg: FPC com speed limited to 115200 when compiled with FPC
chg: USART remake (@drandreas)
2018-09-06 21:43:20 +02:00
iceman1001 57337fe941 chg: add some error messages in order to debug better. 2018-03-31 10:46:06 +02:00
iceman1001 9ba8655953 chg: lesser error message flooding 2018-02-05 15:58:18 +01:00
iceman1001 a82d5bf708 chg: // took settings from libnfc/buses/uart.c
sp->ct.ReadIntervalTimeout         = 30;
	sp->ct.ReadTotalTimeoutMultiplier  = 0;
	sp->ct.ReadTotalTimeoutConstant    = 30;
	sp->ct.WriteTotalTimeoutMultiplier = 30;
	sp->ct.WriteTotalTimeoutConstant   = 0;

chg: textual
chg: removed imp of upcase to builtin function _strupr
2018-01-09 16:52:43 +01:00
iceman1001 c9f7ba2ab0 ADD: increased debug messages in order to see when commnunications break down between device and client.
Before it silently just broke and you just didn't know what happend..
2017-12-21 10:16:21 +01:00
iceman1001 994248265d FIX: changing the result booleran when sending over serial. 2017-10-29 19:22:03 +01:00
iceman1001 53333f22c8 fix: hw status (and USB comm in general) PR #434 : (@pwpiwi) 2017-10-20 16:32:42 +02:00
iceman1001 16028f7d33 CHG: appmain now calls cmd_recieve as it should
CHG: flasher -  removed unneeded parameter to function
CHG: flasher - increased limit to fpga-files that can be loaded
FIX: main client,  wrong windows define fixed.
CHG: device side - recieve usb command does not always get 544 bytes.  usb packages can be incomplete.
CHG: usb_cdc.c also got piwi's changes.
CHG: uart_posix.c removed a debug value
CHG: uart_win32.c clean up.
2017-10-17 20:58:17 +02:00
iceman1001 fa2aba1532 fix: no length tests... 2017-10-12 12:24:53 +02:00
iceman1001 78ebac8e6f chg: more debug... 2017-10-12 11:35:34 +02:00
iceman1001 85eb7c2cc6 chg: reverting tests 2017-10-11 13:01:16 +02:00
iceman1001 480c0d0ba0 CHG: pm3 device will be identified on win10 automatic without drivers. Sadly no com port... 2017-10-11 12:46:38 +02:00
iceman1001 4e728dc0f9 rename variable 2017-10-10 15:01:04 +02:00
iceman1001 b4a03581c2 CHG: adjustments to the USB reading part. 2017-10-05 15:55:08 +02:00
iceman1001 08bf63c748 fix: double free shouldn't happen now 2017-09-26 22:22:23 +02:00
iceman1001 b18920b9f9 CHG: enables proxmark3 client to reconnect to serial port without exiting / restarting. 2017-09-26 17:04:25 +02:00
iceman1001 6519ae6f88 part of monstermerge... 2017-07-27 20:48:49 +02:00