view fluid-mnf/target.h @ 311:9cecc930d78f

fluid-mnf: original source from TI, defenestrated line endings and rearranged directory structure, but no *.[ch] source file content changes yet
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 29 Feb 2020 05:36:07 +0000
parents
children 37b5f94de802
line wrap: on
line source

/******************************************************************************
 * FLUID (Flash Loader Utility Independent of Device)
 *
 * Copyright Texas Instruments, 2001.
 * Mads Meisner-Jensen, mmj@ti.com.
 *
 * Target Connection and Control
 *
 * $Id: target.h 1.8 Thu, 01 Aug 2002 11:17:20 +0200 mmj $
 *
 ******************************************************************************/


int target_uart_baudrate_divider_get(int clk, int bps);

int target_driver_init(int uart, int baudrate, char *flowcontrol);
int target_driver_baudrate(int baudrate);

int target_send(char *buf, int size);
int target_putchar(char ch);

int target_wait(int size, int time);
int target_recv(void *buf, int size);
int target_getchar(void);
int target_expect_char(char ch, int time);
void target_recv_reset(void);

int buf_put1(char *buf, unsigned char);
int buf_put2(char *buf, unsigned short data);
int buf_put4(char *buf, unsigned int data);
int buf_put2no(char *buf, unsigned short data);
int buf_put4no(char *buf, unsigned int data);

void error_proto(char ch, char chx);

void target_power(char state);
void target_reset(char state);

int target_trace_enable(int flag);
int target_trace(unsigned char ch);