/* Write a string of bytes through the software UART. */
int32_t swuart_write_string(struct swuart_dev *dev, uint8_t *string, uint32_t size)
/* Write a string of bytes through the software UART. */
int32_t swuart_write_string(struct swuart_dev *dev, uint8_t *string, uint32_t size)
{
	uint32_t i;
	int32_t check;
	for(i = 0; i < size; i++) {
		check = swuart_write_char(dev, &string[i]);
		if(check != 0)
			return check;
		swuart_delay(dev, dev->half_period);
		swuart_delay(dev, dev->half_period);
	}
	return 0;
}