exit(1);
}
}
+ return simPid;
}
void openSimulator (char **args, int nargs)
s = buffer + strlen(buffer) -1;
for ( i = 0 ; i < size ; i++ )
{
- sprintf(s," 0x%x", val & 0xff);
+ sprintf(s," 0x%lx", val & 0xff);
s += strlen(s);
val >>= 8;
}
case of bit variables which case it becomes
[address] [assembler bit address] [v] */
/* first skip thru white space */
- while (isspace(*resp)) resp++ ;
+ resp = trim_left(resp);
if (strncmp(resp, "0x",2) == 0)
resp += 2;
for (i = 0 ; i < size ; i++ )
{
/* skip white space */
- while (isspace(*resp)) resp++ ;
+ resp = trim_left(resp);
b[i] = strtol(resp,&resp,16);
}
char buff[128];
sprintf(buff,"file \"%s\"\n",s);
- printf(buff);
+ printf("%s",buff);
sendSim(buff);
waitForSim(500,NULL);
}