- command_print( cmd_ctx, "Example: STM32 has 2 taps, the cortexM3(len4) + boundaryscan(len5)");
- command_print( cmd_ctx, "jtag newtap stm32 cortexm3 ....., thus creating the tap: \"stm32.cortexm3\"");
- command_print( cmd_ctx, "jtag newtap stm32 boundary ....., and the tap: \"stm32.boundary\"");
- command_print( cmd_ctx, "And then refer to the taps by the dotted name.");
-
- newargs[0] = Jim_NewStringObj( interp, "jtag", -1 );
- newargs[1] = Jim_NewStringObj( interp, "newtap", -1 );
- sprintf( buf, "chip%d", jtag_tap_count() );
- newargs[2] = Jim_NewStringObj( interp, buf, -1 );
- sprintf( buf, "tap%d", jtag_tap_count() );
- newargs[3] = Jim_NewStringObj( interp, buf, -1 );
- newargs[4] = Jim_NewStringObj( interp, "-irlen", -1 );
- newargs[5] = Jim_NewStringObj( interp, args[0], -1 );
- newargs[6] = Jim_NewStringObj( interp, "-ircapture", -1 );
- newargs[7] = Jim_NewStringObj( interp, args[1], -1 );
- newargs[8] = Jim_NewStringObj( interp, "-irmask", -1 );
- newargs[9] = Jim_NewStringObj( interp, args[2], -1 );
-
- command_print( cmd_ctx, "NEW COMMAND:");
- sprintf( buf, "%s %s %s %s %s %s %s %s %s %s",
- Jim_GetString( newargs[0], NULL ),
- Jim_GetString( newargs[1], NULL ),
- Jim_GetString( newargs[2], NULL ),
- Jim_GetString( newargs[3], NULL ),
- Jim_GetString( newargs[4], NULL ),
- Jim_GetString( newargs[5], NULL ),
- Jim_GetString( newargs[6], NULL ),
- Jim_GetString( newargs[7], NULL ),
- Jim_GetString( newargs[8], NULL ),
- Jim_GetString( newargs[9], NULL ) );
-
- e = jim_jtag_command( interp, 10, newargs );
- if ( e != JIM_OK ){
- command_print( cmd_ctx, "%s", Jim_GetString( Jim_GetResult(interp), NULL ) );
+ command_print(cmd_ctx, "Example: STM32 has 2 taps, the cortexM3(len4) + boundaryscan(len5)");
+ command_print(cmd_ctx, "jtag newtap stm32 cortexm3 ....., thus creating the tap: \"stm32.cortexm3\"");
+ command_print(cmd_ctx, "jtag newtap stm32 boundary ....., and the tap: \"stm32.boundary\"");
+ command_print(cmd_ctx, "And then refer to the taps by the dotted name.");
+
+ newargs[0] = Jim_NewStringObj(interp, "jtag", -1 );
+ newargs[1] = Jim_NewStringObj(interp, "newtap", -1 );
+ sprintf(buf, "chip%d", jtag_tap_count() );
+ newargs[2] = Jim_NewStringObj(interp, buf, -1 );
+ sprintf(buf, "tap%d", jtag_tap_count() );
+ newargs[3] = Jim_NewStringObj(interp, buf, -1 );
+ newargs[4] = Jim_NewStringObj(interp, "-irlen", -1 );
+ newargs[5] = Jim_NewStringObj(interp, args[0], -1 );
+ newargs[6] = Jim_NewStringObj(interp, "-ircapture", -1 );
+ newargs[7] = Jim_NewStringObj(interp, args[1], -1 );
+ newargs[8] = Jim_NewStringObj(interp, "-irmask", -1 );
+ newargs[9] = Jim_NewStringObj(interp, args[2], -1 );
+
+ command_print(cmd_ctx, "NEW COMMAND:");
+ sprintf(buf, "%s %s %s %s %s %s %s %s %s %s",
+ Jim_GetString(newargs[0], NULL ),
+ Jim_GetString(newargs[1], NULL ),
+ Jim_GetString(newargs[2], NULL ),
+ Jim_GetString(newargs[3], NULL ),
+ Jim_GetString(newargs[4], NULL ),
+ Jim_GetString(newargs[5], NULL ),
+ Jim_GetString(newargs[6], NULL ),
+ Jim_GetString(newargs[7], NULL ),
+ Jim_GetString(newargs[8], NULL ),
+ Jim_GetString(newargs[9], NULL ) );
+
+ e = jim_jtag_command(interp, 10, newargs );
+ if (e != JIM_OK ){
+ command_print(cmd_ctx, "%s", Jim_GetString(Jim_GetResult(interp), NULL ) );