Route fix

So, ignore the fact that it looks like shainerz is committing everything. Didn't change the name, oops. You can test route # (where # is a node you want the routing table from), and try it out. You have to pull libio and libcsp for all the code changes. Results at: https://gist.github.com/TheFlyingCouch/23c37cbf388f4246a575

@bryanyw 
I believe I have addressed your issues (I presume see below comment has to
do with how I should check the return value of csp_transaction). I may want
to choose a different CSP error code if status isn't 1 or greater, but
that's about it...


On Mon, Jun 16, 2014 at 6:04 PM, Bryan Wong <notifications@github.com>
wrote:

> In src/csp_route.c:
>
> > + * @param[out]	int8_t 	return code
> > +*/
> > +int8_t csp_route_print_remote_table(uint8_t node) {
> > +	//sizeof(csp_route_info) = 11, so 14*12 = 164 bytes
> > +	int routes_requested = 14;
> > +	int status;
> > +	uint32_t timeout = 1000;//just chose smallish value, can change
> > +	uint8_t routes_left,k,i = 0;
> > +	uint8_t params[2];
> > +	status = csp_transaction(CSP_PRIO_NORM,node,CSP_GET_ROUTE,timeout, NULL,
> > +	 0, &routes_left, sizeof(routes_left));
> > +	if(status == 0){
> > +		printf("Error or incoming length wrong\r\n");
> > +		return CSP_ERR_TX;
> > +	}
> > +	else if(status < 0){
>
> see below comment
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/nsat/libcsp/pull/2/files#r13838745>.
>



-- 
Sean Horton
(979) 421-2399