Commit 45501230 authored by Claes Sjofors's avatar Claes Sjofors

Start with qcom and no nethandler

parent e2e81d94
...@@ -125,4 +125,5 @@ ...@@ -125,4 +125,5 @@
091014 cs doc Links in Designer's Guide updated and code format added in html version. 091014 cs doc Links in Designer's Guide updated and code format added in html version.
091020 cs co wow_CreateList now with variable text size. 091020 cs co wow_CreateList now with variable text size.
091111 cs gdh Bugfix in nethandler SetObjectInfo and GetObjectInfo. 091111 cs gdh Bugfix in nethandler SetObjectInfo and GetObjectInfo.
091209 cs co Command line interpreter, command not converted to upper case any more. 091209 cs co Command line interpreter, command not converted to upper case any more.
\ No newline at end of file 091211 cs rtt rt_rtt runable on sev station to show qcom nodes and qcom applications.
\ No newline at end of file
...@@ -93,6 +93,13 @@ rtt_message('E',"Rtt is not connected to nethandler");\ ...@@ -93,6 +93,13 @@ rtt_message('E',"Rtt is not connected to nethandler");\
return RTT__NOPICTURE;\ return RTT__NOPICTURE;\
} }
#define IF_NOQCOM_RETURN \
if ( !(rtt_gdh_started || rtt_qcom_started)) \
{\
rtt_message('E',"Rtt is not connected to qcom or nethandler");\
return RTT__NOPICTURE;\
}
/* Type definitions */ /* Type definitions */
/* RTTSYS_GRAFCET ***/ /* RTTSYS_GRAFCET ***/
typedef struct { typedef struct {
...@@ -11086,7 +11093,7 @@ int RTTSYS_QCOM_APPL( menu_ctx ctx, ...@@ -11086,7 +11093,7 @@ int RTTSYS_QCOM_APPL( menu_ctx ctx,
pool_sQlink *al; pool_sQlink *al;
qdb_sAppl *ap; qdb_sAppl *ap;
IF_NOGDH_RETURN; IF_NOQCOM_RETURN;
/********************************************************** /**********************************************************
* The value of a parameter is changed. * The value of a parameter is changed.
...@@ -11720,7 +11727,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx, ...@@ -11720,7 +11727,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx,
qdb_sNode *np; qdb_sNode *np;
char timbuf[32]; char timbuf[32];
IF_NOGDH_RETURN; IF_NOQCOM_RETURN;
/********************************************************** /**********************************************************
* The value of a parameter is changed. * The value of a parameter is changed.
...@@ -11735,7 +11742,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx, ...@@ -11735,7 +11742,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx,
k = 0; k = 0;
l = 0; l = 0;
gdb_ScopeLock { qdb_ScopeLock {
for ( for (
nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh); nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh);
nl != &qdb->g->node_lh; nl != &qdb->g->node_lh;
...@@ -11814,7 +11821,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx, ...@@ -11814,7 +11821,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx,
} }
k++; k++;
} }
} gdb_ScopeUnlock; } qdb_ScopeUnlock;
for ( i = l; i < QCOM_NODES_PAGESIZE; i++) for ( i = l; i < QCOM_NODES_PAGESIZE; i++)
{ {
...@@ -11895,7 +11902,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx, ...@@ -11895,7 +11902,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx,
k = 0; k = 0;
l = 0; l = 0;
gdb_ScopeLock { qdb_ScopeLock {
for ( for (
nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh); nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh);
nl != &qdb->g->node_lh; nl != &qdb->g->node_lh;
...@@ -11974,7 +11981,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx, ...@@ -11974,7 +11981,7 @@ int RTTSYS_QCOM_NODES( menu_ctx ctx,
} }
k++; k++;
} }
} gdb_ScopeUnlock; } qdb_ScopeUnlock;
for ( i = l; i < QCOM_NODES_PAGESIZE; i++) for ( i = l; i < QCOM_NODES_PAGESIZE; i++)
{ {
...@@ -12690,7 +12697,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx, ...@@ -12690,7 +12697,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx,
qdb_sNode *np; qdb_sNode *np;
static pwr_tNodeId nid; static pwr_tNodeId nid;
IF_NOGDH_RETURN; IF_NOQCOM_RETURN;
/********************************************************** /**********************************************************
* The value of a parameter is changed. * The value of a parameter is changed.
...@@ -12702,7 +12709,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx, ...@@ -12702,7 +12709,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx,
menulist = (rtt_t_menu_upd *) ctx->menu; menulist = (rtt_t_menu_upd *) ctx->menu;
menu_ptr = menulist; menu_ptr = menulist;
gdb_ScopeLock { qdb_ScopeLock {
for ( for (
nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh); nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh);
nl != &qdb->g->node_lh; nl != &qdb->g->node_lh;
...@@ -12835,7 +12842,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx, ...@@ -12835,7 +12842,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx,
break; break;
} }
} }
} gdb_ScopeUnlock; } qdb_ScopeUnlock;
return RTT__SUCCESS; return RTT__SUCCESS;
...@@ -12873,7 +12880,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx, ...@@ -12873,7 +12880,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx,
menulist = (rtt_t_menu_upd *) ctx->menu; menulist = (rtt_t_menu_upd *) ctx->menu;
menu_ptr = menulist; menu_ptr = menulist;
gdb_ScopeLock { qdb_ScopeLock {
for ( for (
nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh); nl = pool_Qsucc(&sts, &qdb->pool, &qdb->g->node_lh);
nl != &qdb->g->node_lh; nl != &qdb->g->node_lh;
...@@ -13006,7 +13013,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx, ...@@ -13006,7 +13013,7 @@ int RTTSYS_QCOM_NODE( menu_ctx ctx,
break; break;
} }
} }
} gdb_ScopeUnlock; } qdb_ScopeUnlock;
break; break;
......
...@@ -20,9 +20,10 @@ ...@@ -20,9 +20,10 @@
#ifndef rt_rtt_functions_h #ifndef rt_rtt_functions_h
#define rt_rtt_functions_h #define rt_rtt_functions_h
/* Module rs_rtt_menu.c */ /* Module rt_rtt_menu.c */
int rtt_gdh_init( void); int rtt_gdh_init( void);
int rtt_qcom_init( void);
int rtt_initialize( char *username, int rtt_initialize( char *username,
char *password, char *password,
char *commandfile, char *commandfile,
...@@ -398,7 +399,7 @@ menu_ctx rtt_current_ctx(); ...@@ -398,7 +399,7 @@ menu_ctx rtt_current_ctx();
int rtt_logon_pict( unsigned long *chn, int rtt_logon_pict( unsigned long *chn,
unsigned long *priv); unsigned long *priv);
/* Module rs_rtt_crr.c */ /* Module rt_rtt_crr.c */
int rtt_crossref_signal( int rtt_crossref_signal(
unsigned long ctx, unsigned long ctx,
...@@ -432,7 +433,7 @@ int rtt_show_signals( ...@@ -432,7 +433,7 @@ int rtt_show_signals(
char *windowname, char *windowname,
int debug); int debug);
/* Module rs_rtt_command.c */ /* Module rt_rtt_command.c */
int rtt_get_do_test( pwr_tObjid objid, int rtt_get_do_test( pwr_tObjid objid,
int *on); int *on);
...@@ -619,7 +620,7 @@ int rttcmd_learn_func( menu_ctx ctx, ...@@ -619,7 +620,7 @@ int rttcmd_learn_func( menu_ctx ctx,
int *flag); int *flag);
int rtt_remove_blank( char *out_str, char *in_str); int rtt_remove_blank( char *out_str, char *in_str);
/* Module rs_rtt_alarm.c */ /* Module rt_rtt_alarm.c */
int rtt_alarm_send( int rtt_alarm_send(
char *alarm_text, char *alarm_text,
...@@ -647,7 +648,7 @@ int rtt_alarm_ack_last(); ...@@ -647,7 +648,7 @@ int rtt_alarm_ack_last();
int rtt_alarmlog_start( char *filename); int rtt_alarmlog_start( char *filename);
int rtt_alarmlog_stop(); int rtt_alarmlog_stop();
/* Module rs_rtt_logging.c */ /* Module rt_rtt_logging.c */
int rtt_logging_create( int rtt_logging_create(
menu_ctx ctx, menu_ctx ctx,
...@@ -698,7 +699,7 @@ int rtt_logging_delete( ...@@ -698,7 +699,7 @@ int rtt_logging_delete(
char *parameterstr); char *parameterstr);
int rtt_logging_close_files(); int rtt_logging_close_files();
/* Module rs_rtt_view.c */ /* Module rt_rtt_view.c */
int rtt_view( menu_ctx parent_ctx, int rtt_view( menu_ctx parent_ctx,
char *filename, char *filename,
...@@ -715,7 +716,7 @@ int rtt_view_buffer( ...@@ -715,7 +716,7 @@ int rtt_view_buffer(
char *intitle, char *intitle,
int type); int type);
/* Module rs_rtt_os.c */ /* Module rt_rtt_os.c */
int rtt_get_nodename( char *nodename, int size); int rtt_get_nodename( char *nodename, int size);
char *rtt_fgetname( FILE *fp, char *name, char *def_name); char *rtt_fgetname( FILE *fp, char *name, char *def_name);
...@@ -794,7 +795,7 @@ int rtt_replace_env( char *str, char *newstr); ...@@ -794,7 +795,7 @@ int rtt_replace_env( char *str, char *newstr);
int rtt_get_platform( char *platform); int rtt_get_platform( char *platform);
int rtt_get_hw( char *hw); int rtt_get_hw( char *hw);
/* Module rs_rtt_qiomod.c */ /* Module rt_rtt_qiomod.c */
int qio_assign( char *s, int *chn); int qio_assign( char *s, int *chn);
int qio_set_attr( int *chn); int qio_set_attr( int *chn);
...@@ -806,7 +807,7 @@ int qio_write( int *chn, int tmo, char *buf, int len); ...@@ -806,7 +807,7 @@ int qio_write( int *chn, int tmo, char *buf, int len);
#endif #endif
/* Module rs_rtt_cmdmode.c */ /* Module rt_rtt_cmdmode.c */
int rtt_store_symbols( char *filename); int rtt_store_symbols( char *filename);
int rtt_show_symbols( menu_ctx ctx); int rtt_show_symbols( menu_ctx ctx);
int rtt_replace_symbol( char *command, char *newcommand); int rtt_replace_symbol( char *command, char *newcommand);
...@@ -820,7 +821,7 @@ int rtt_attribute_func ( ...@@ -820,7 +821,7 @@ int rtt_attribute_func (
int *return_int, int *return_int,
char *return_string); char *return_string);
/* Module rs_rtt_rtc.c */ /* Module rt_rtt_rtc.c */
#ifdef OS_ELN #ifdef OS_ELN
int rtt_rtc( int function); int rtt_rtc( int function);
#endif #endif
......
...@@ -60,6 +60,7 @@ extern unsigned char rtt_AlarmReturn; ...@@ -60,6 +60,7 @@ extern unsigned char rtt_AlarmReturn;
extern unsigned char rtt_AlarmAck; extern unsigned char rtt_AlarmAck;
extern rtt_t_loggtable rtt_loggtable[ RTT_LOGG_MAXENTRY]; extern rtt_t_loggtable rtt_loggtable[ RTT_LOGG_MAXENTRY];
extern int rtt_gdh_started; extern int rtt_gdh_started;
extern int rtt_qcom_started;
extern char rtt_AlarmLastMessage[80]; extern char rtt_AlarmLastMessage[80];
extern char rtt_AlarmText1[80]; extern char rtt_AlarmText1[80];
extern char rtt_AlarmText2[80]; extern char rtt_AlarmText2[80];
...@@ -115,6 +116,7 @@ unsigned char rtt_AlarmReturn = 0; ...@@ -115,6 +116,7 @@ unsigned char rtt_AlarmReturn = 0;
unsigned char rtt_AlarmAck = 0; unsigned char rtt_AlarmAck = 0;
rtt_t_loggtable rtt_loggtable[ RTT_LOGG_MAXENTRY]; rtt_t_loggtable rtt_loggtable[ RTT_LOGG_MAXENTRY];
int rtt_gdh_started = 0; int rtt_gdh_started = 0;
int rtt_qcom_started = 0;
char rtt_AlarmLastMessage[80] = ""; char rtt_AlarmLastMessage[80] = "";
char rtt_AlarmText1[80] = ""; char rtt_AlarmText1[80] = "";
char rtt_AlarmText2[80] = ""; char rtt_AlarmText2[80] = "";
......
...@@ -340,6 +340,7 @@ int rtt_initialize( char *username, ...@@ -340,6 +340,7 @@ int rtt_initialize( char *username,
{ {
int sts; int sts;
int noneth = 0; int noneth = 0;
int qcom_only = 0;
rtt_init_state_table(); rtt_init_state_table();
...@@ -349,6 +350,11 @@ int rtt_initialize( char *username, ...@@ -349,6 +350,11 @@ int rtt_initialize( char *username,
noneth = 1; noneth = 1;
rtt_priv = RTT_PRV_SYS; rtt_priv = RTT_PRV_SYS;
} }
else if ( strcmp( username, "QCOMONLY") == 0) {
noneth = 1;
qcom_only = 1;
rtt_priv = RTT_PRV_SYS;
}
if ( !noneth) { if ( !noneth) {
sts = rtt_gdh_init(); sts = rtt_gdh_init();
...@@ -365,6 +371,9 @@ int rtt_initialize( char *username, ...@@ -365,6 +371,9 @@ int rtt_initialize( char *username,
exit(-1); exit(-1);
} }
} }
else if ( qcom_only) {
sts = rtt_qcom_init();
}
sts = rtt_recall_create( &rtt_recallbuff); sts = rtt_recall_create( &rtt_recallbuff);
if (EVEN(sts)) return sts; if (EVEN(sts)) return sts;
...@@ -440,6 +449,31 @@ int rtt_gdh_init() ...@@ -440,6 +449,31 @@ int rtt_gdh_init()
return RTT__SUCCESS; return RTT__SUCCESS;
} }
/*************************************************************************
*
* Name: rtt_gdh_init()
*
* Type int
*
* Type Parameter IOGF Description
*
* Description:
* This function initializes gdh for rtt.
*
**************************************************************************/
int rtt_qcom_init()
{
pwr_tStatus sts;
qcom_sAid aid;
qcom_Init( &sts, &aid, "rt_rtt");
if ( EVEN(sts)) return sts;
rtt_qcom_started = 1;
return RTT__SUCCESS;
}
/************************************************************************* /*************************************************************************
* *
* Name: rtt_configure() * Name: rtt_configure()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment