##// END OF EJS Templates
commit before release
paul@pc-solar1.lab-lpp.local -
r25:68625add1e50 default
parent child
Show More
@@ -1,6 +1,6
1 #############################################################################
1 #############################################################################
2 # Makefile for building: bin/fsw
2 # Makefile for building: bin/fsw-gsa
3 # Generated by qmake (2.01a) (Qt 4.8.4) on: Fri Jun 28 07:59:21 2013
3 # Generated by qmake (2.01a) (Qt 4.8.4) on: Fri Jul 5 12:17:39 2013
4 # Project: fsw-qt.pro
4 # Project: fsw-qt.pro
5 # Template: app
5 # Template: app
6 # Command: /usr/bin/qmake-qt4 -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
6 # Command: /usr/bin/qmake-qt4 -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
@@ -10,7 +10,7
10
10
11 CC = sparc-rtems-gcc
11 CC = sparc-rtems-gcc
12 CXX = sparc-rtems-g++
12 CXX = sparc-rtems-g++
13 DEFINES = -DSW_VERSION_N1=0 -DSW_VERSION_N2=0 -DSW_VERSION_N3=0 -DSW_VERSION_N4=5 -DPRINT_MESSAGES_ON_CONSOLE
13 DEFINES = -DSW_VERSION_N1=0 -DSW_VERSION_N2=0 -DSW_VERSION_N3=0 -DSW_VERSION_N4=6 -DPRINT_MESSAGES_ON_CONSOLE -DGSA
14 CFLAGS = -pipe -O3 -Wall $(DEFINES)
14 CFLAGS = -pipe -O3 -Wall $(DEFINES)
15 CXXFLAGS = -pipe -O3 -Wall $(DEFINES)
15 CXXFLAGS = -pipe -O3 -Wall $(DEFINES)
16 INCPATH = -I/usr/lib64/qt4/mkspecs/linux-g++ -I. -I../src -I../header
16 INCPATH = -I/usr/lib64/qt4/mkspecs/linux-g++ -I. -I../src -I../header
@@ -78,9 +78,9 DIST = /usr/lib64/qt4/mkspecs/c
78 /usr/lib64/qt4/mkspecs/features/lex.prf \
78 /usr/lib64/qt4/mkspecs/features/lex.prf \
79 /usr/lib64/qt4/mkspecs/features/include_source_dir.prf \
79 /usr/lib64/qt4/mkspecs/features/include_source_dir.prf \
80 fsw-qt.pro
80 fsw-qt.pro
81 QMAKE_TARGET = fsw
81 QMAKE_TARGET = fsw-gsa
82 DESTDIR = bin/
82 DESTDIR = bin/
83 TARGET = bin/fsw
83 TARGET = bin/fsw-gsa
84
84
85 first: all
85 first: all
86 ####### Implicit rules
86 ####### Implicit rules
@@ -159,8 +159,8 qmake: FORCE
159 @$(QMAKE) -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
159 @$(QMAKE) -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
160
160
161 dist:
161 dist:
162 @$(CHK_DIR_EXISTS) obj/fsw1.0.0 || $(MKDIR) obj/fsw1.0.0
162 @$(CHK_DIR_EXISTS) obj/fsw-gsa1.0.0 || $(MKDIR) obj/fsw-gsa1.0.0
163 $(COPY_FILE) --parents $(SOURCES) $(DIST) obj/fsw1.0.0/ && (cd `dirname obj/fsw1.0.0` && $(TAR) fsw1.0.0.tar fsw1.0.0 && $(COMPRESS) fsw1.0.0.tar) && $(MOVE) `dirname obj/fsw1.0.0`/fsw1.0.0.tar.gz . && $(DEL_FILE) -r obj/fsw1.0.0
163 $(COPY_FILE) --parents $(SOURCES) $(DIST) obj/fsw-gsa1.0.0/ && (cd `dirname obj/fsw-gsa1.0.0` && $(TAR) fsw-gsa1.0.0.tar fsw-gsa1.0.0 && $(COMPRESS) fsw-gsa1.0.0.tar) && $(MOVE) `dirname obj/fsw-gsa1.0.0`/fsw-gsa1.0.0.tar.gz . && $(DEL_FILE) -r obj/fsw-gsa1.0.0
164
164
165
165
166 clean:compiler_clean
166 clean:compiler_clean
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -1,7 +1,7
1 TEMPLATE = app
1 TEMPLATE = app
2 # CONFIG += console v8 sim
2 # CONFIG += console v8 sim
3 # CONFIG options = verbose *** cpu_usage_report *** gsa
3 # CONFIG options = verbose *** cpu_usage_report *** gsa
4 CONFIG += console verbose
4 CONFIG += console verbose gsa
5 CONFIG -= qt
5 CONFIG -= qt
6
6
7 include(./sparc.pri)
7 include(./sparc.pri)
@@ -1,6 +1,6
1 <?xml version="1.0" encoding="UTF-8"?>
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE QtCreatorProject>
2 <!DOCTYPE QtCreatorProject>
3 <!-- Written by Qt Creator 2.4.1, 2013-07-05T07:07:58. -->
3 <!-- Written by Qt Creator 2.4.1, 2013-07-05T13:31:36. -->
4 <qtcreator>
4 <qtcreator>
5 <data>
5 <data>
6 <variable>ProjectExplorer.Project.ActiveTarget</variable>
6 <variable>ProjectExplorer.Project.ActiveTarget</variable>
@@ -53,7 +53,7 void init_default_mode_parameters( void
53 void init_housekeeping_parameters( void );
53 void init_housekeeping_parameters( void );
54
54
55 int spacewire_configure_link( void );
55 int spacewire_configure_link( void );
56 int spacewire_try_to_start(void);
56 int spacewire_wait_for_link(void);
57 void spacewire_set_NP(unsigned char val, unsigned int regAddr); // No Port force
57 void spacewire_set_NP(unsigned char val, unsigned int regAddr); // No Port force
58 void spacewire_set_RE(unsigned char val, unsigned int regAddr); // RMAP Enable
58 void spacewire_set_RE(unsigned char val, unsigned int regAddr); // RMAP Enable
59 void spacewire_compute_stats_offsets();
59 void spacewire_compute_stats_offsets();
@@ -20,7 +20,7 int configure_timer(gptimer_regs_t *gpti
20 void update_spacewire_statistics();
20 void update_spacewire_statistics();
21
21
22 // SERIAL LINK
22 // SERIAL LINK
23 int send_console_outputs_on_serial_port( void );
23 int send_console_outputs_on_apbuart_port( void );
24 int set_apbuart_scaler_reload_register(unsigned int regs, unsigned int value);
24 int set_apbuart_scaler_reload_register(unsigned int regs, unsigned int value);
25
25
26 // RTEMS TASKS
26 // RTEMS TASKS
@@ -50,7 +50,7
50 #define REGS_ADDR_WAVEFORM_PICKER 0x80000f20
50 #define REGS_ADDR_WAVEFORM_PICKER 0x80000f20
51
51
52 #define APBUART_CTRL_REG_MASK_DB 0xfffff7ff
52 #define APBUART_CTRL_REG_MASK_DB 0xfffff7ff
53 #define APBUART_SCALER_RELOAD_VALUE 0x00000050 // 25 MHz => about 38400
53 #define APBUART_SCALER_RELOAD_VALUE 0x00000050 // 25 MHz => about 38400 (0x50)
54
54
55 //**********
55 //**********
56 // IRQ LINES
56 // IRQ LINES
@@ -11,6 +11,13 struct apbuart_regs_str{
11 volatile unsigned int fifoDebug;
11 volatile unsigned int fifoDebug;
12 };
12 };
13
13
14 struct ahbuart_regs_str{
15 volatile unsigned int unused;
16 volatile unsigned int status;
17 volatile unsigned int ctrl;
18 volatile unsigned int scaler;
19 };
20
14 struct timer_regs_str
21 struct timer_regs_str
15 {
22 {
16 volatile unsigned int counter;
23 volatile unsigned int counter;
@@ -63,7 +63,7 rtems_task Init( rtems_task_argument ign
63 PRINTF("***************************\n")
63 PRINTF("***************************\n")
64 PRINTF("\n\n")
64 PRINTF("\n\n")
65
65
66 //send_console_outputs_on_serial_port();
66 //send_console_outputs_on_apbuart_port();
67 set_apbuart_scaler_reload_register(REGS_ADDR_APBUART, APBUART_SCALER_RELOAD_VALUE);
67 set_apbuart_scaler_reload_register(REGS_ADDR_APBUART, APBUART_SCALER_RELOAD_VALUE);
68
68
69 initLookUpTableForCRC(); // in tc_handler.h
69 initLookUpTableForCRC(); // in tc_handler.h
@@ -145,6 +145,10 rtems_task spiq_task(rtems_task_argument
145
145
146 lfrMode = (housekeeping_packet.lfr_status_word[0] & 0xf0) >> 4; // get the current mode
146 lfrMode = (housekeeping_packet.lfr_status_word[0] & 0xf0) >> 4; // get the current mode
147
147
148 status = spacewire_wait_for_link();
149
150 if (status != RTEMS_SUCCESSFUL)
151 {
148 //****************
152 //****************
149 // STOP THE SYSTEM
153 // STOP THE SYSTEM
150 spacewire_compute_stats_offsets();
154 spacewire_compute_stats_offsets();
@@ -158,10 +162,7 rtems_task spiq_task(rtems_task_argument
158
162
159 //***************************
163 //***************************
160 // RESTART THE SPACEWIRE LINK
164 // RESTART THE SPACEWIRE LINK
161 status = spacewire_try_to_start();
162 if (status != RTEMS_SUCCESSFUL) {
163 spacewire_configure_link();
165 spacewire_configure_link();
164 }
165
166
166 //*******************
167 //*******************
167 // RESTART THE SYSTEM
168 // RESTART THE SYSTEM
@@ -176,6 +177,7 rtems_task spiq_task(rtems_task_argument
176 //enter_mode(lfrMode, NULL); // enter the mode that was running before the SpaceWire interruption
177 //enter_mode(lfrMode, NULL); // enter the mode that was running before the SpaceWire interruption
177 }
178 }
178 }
179 }
180 }
179
181
180 void init_default_mode_parameters(void)
182 void init_default_mode_parameters(void)
181 {
183 {
@@ -446,7 +448,7 int spacewire_configure_link( void )
446 return RTEMS_SUCCESSFUL;
448 return RTEMS_SUCCESSFUL;
447 }
449 }
448
450
449 int spacewire_try_to_start(void)
451 int spacewire_wait_for_link(void)
450 {
452 {
451 unsigned int i;
453 unsigned int i;
452 int linkStatus;
454 int linkStatus;
@@ -91,7 +91,7 void update_spacewire_statistics()
91
91
92 }
92 }
93
93
94 int send_console_outputs_on_serial_port( void ) // Send the console outputs on the serial port
94 int send_console_outputs_on_apbuart_port( void ) // Send the console outputs on the apbuart port
95 {
95 {
96 struct apbuart_regs_str *apbuart_regs = (struct apbuart_regs_str *) REGS_ADDR_APBUART;
96 struct apbuart_regs_str *apbuart_regs = (struct apbuart_regs_str *) REGS_ADDR_APBUART;
97
97
@@ -106,7 +106,7 int set_apbuart_scaler_reload_register(u
106 struct apbuart_regs_str *apbuart_regs = (struct apbuart_regs_str *) regs;
106 struct apbuart_regs_str *apbuart_regs = (struct apbuart_regs_str *) regs;
107
107
108 apbuart_regs->scaler = value;
108 apbuart_regs->scaler = value;
109 PRINTF1("OK *** COM port scaler reload register set to %x\n", value)
109 PRINTF1("OK *** apbuart port scaler reload register set to 0x%x\n", value)
110
110
111 return 0;
111 return 0;
112 }
112 }
@@ -145,7 +145,7 rtems_isr waveforms_simulator_isr( rtems
145 // NORMAL
145 // NORMAL
146 case(LFR_MODE_NORMAL):
146 case(LFR_MODE_NORMAL):
147 if (rtems_event_send( Task_id[TASKID_WFRM], RTEMS_EVENT_MODE_NORMAL ) != RTEMS_SUCCESSFUL) {
147 if (rtems_event_send( Task_id[TASKID_WFRM], RTEMS_EVENT_MODE_NORMAL ) != RTEMS_SUCCESSFUL) {
148 PRINTF("ERR *** in waveforms_isr *** error sending event to WFRM\n");
148 PRINTF("ERR *** in waveforms_isr *** error sending event to WFRM\n")
149 }
149 }
150 break;
150 break;
151
151
General Comments 0
You need to be logged in to leave comments. Login now