uart_posix.c rework

* added some LED handling in appmain.c (helped with debugging)
* finally replaced the infamous device unlink by msleep(1000)
* fixed some format strings in comms.c (with -DCOMMS_DEBUG)
* made uart_receive() and uart_send() behave as described in header
* some formating
This commit is contained in:
pwpiwi 2020-01-27 13:28:34 -05:00
commit d2ca5dbfe8
5 changed files with 119 additions and 143 deletions

View file

@ -88,6 +88,8 @@ extern bool uart_receive(const serial_port sp, uint8_t* pbtRx, size_t pszMaxRxLe
/* Sends a buffer to a given serial port.
* pbtTx: A pointer to a buffer containing the data to send.
* szTxLen: The amount of data to be sent.
*
* Returns TRUE if all data could be sent within 30ms.
*/
extern bool uart_send(const serial_port sp, const uint8_t* pbtTx, const size_t szTxLen);
@ -99,5 +101,5 @@ bool uart_set_speed(serial_port sp, const uint32_t uiPortSpeed);
*/
extern uint32_t uart_get_speed(const serial_port sp);
#endif // _PM3_UART_H_
#endif // PM3_UART_H__