Changeset 19 for webserver/example

Show
Ignore:
Timestamp:
08/12/09 10:41:35 (15 years ago)
Author:
phil
Message:

first display of button presses,
stubs for calculations,
removed calls of unused example functions

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley

    • Property svn:ignore set to
      *.bak
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley/ARM Flash Debug

    • Property svn:ignore set to
      *.d
      *.elf
      RTOSDemo.ld
      RTOSDemo.map
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley/RTOSDemo.hzp

    r17 r19  
    22<solution Name="RTOSDemo" version="2"> 
    33  <project Name="RTOSDemo"> 
    4     <configuration Name="Common" Target="LPC2368" arm_architecture="v4T" arm_core_type="ARM7TDMI-S" arm_linker_stack_size="10" arm_linker_svc_stack_size="1024" arm_simulator_memory_simulation_filename="$(TargetsDir)/Philips_LPC210X/LPC2000SimulatorMemory.dll" arm_simulator_memory_simulation_parameter="LPC23;0x80000;0x8000;0x10000;0x10000" arm_target_debug_interface_type="ARM7TDI" arm_target_flash_loader_file_path="$(TargetsDir)/Philips_LPC210X/Release/Loader_lpc2300.elf" arm_target_flash_loader_type="LIBMEM RPC Loader" arm_target_loader_parameter="12000000" build_remove_unused_symbols="No" c_additional_options="" c_preprocessor_definitions="GCC_ARM7;SUPERVISOR_START;VECTORED_IRQ_INTERRUPTS;PACK_STRUCT_END=__attribute__((packed));ALIGN_STRUCT_END=__attribute__((aligned(4)))" c_system_include_directories="$(StudioDir)/include;$(PackagesDir)/include" c_user_include_directories=".;$(ProjectDir)\\..\\..\\Source\\include;$(ProjectDir)\\..\\..\\Source\\GCC\\ARM7_LPC2000;$(ProjectDir)\\..\\Common\\Include;$(ProjectDir)\\LCD;$(ProjectDir)\\webserver;$(ProjectDir)\\..\\Common\\ethernet\\uIP\\uip-1.0\\uip" gcc_entry_point="reset_handler" gcc_optimization_level="None" link_include_startup_code="No" linker_additional_files="$(PackagesDir)/lib/liblpc2000$(LibExt)$(LIB)" linker_memory_map_file="$(TargetsDir)/Philips_LPC210X/Philips_LPC2368_MemoryMap.xml" linker_printf_fmt_level="long" oscillator_frequency="12MHz" project_directory="" project_type="Executable" property_groups_file_path="$(TargetsDir)/Philips_LPC210X/propertyGroups23xx.xml"/> 
     4    <configuration Name="Common" Target="LPC2368" arm_architecture="v4T" arm_core_type="ARM7TDMI-S" arm_linker_stack_size="10" arm_linker_svc_stack_size="1024" arm_simulator_memory_simulation_filename="$(TargetsDir)/Philips_LPC210X/LPC2000SimulatorMemory.dll" arm_simulator_memory_simulation_parameter="LPC23;0x80000;0x8000;0x10000;0x10000" arm_target_debug_interface_type="ARM7TDI" arm_target_flash_loader_file_path="$(TargetsDir)/Philips_LPC210X/Release/Loader_lpc2300.elf" arm_target_flash_loader_type="LIBMEM RPC Loader" arm_target_loader_parameter="12000000" build_remove_unused_symbols="No" c_additional_options="" c_enforce_ansi_checking="No" c_preprocessor_definitions="GCC_ARM7;SUPERVISOR_START;VECTORED_IRQ_INTERRUPTS;PACK_STRUCT_END=__attribute__((packed));ALIGN_STRUCT_END=__attribute__((aligned(4)))" c_system_include_directories="$(StudioDir)/include;$(PackagesDir)/include" c_user_include_directories=".;$(ProjectDir)\\..\\..\\Source\\include;$(ProjectDir)\\..\\..\\Source\\GCC\\ARM7_LPC2000;$(ProjectDir)\\..\\Common\\Include;$(ProjectDir)\\LCD;$(ProjectDir)\\webserver;$(ProjectDir)\\..\\Common\\ethernet\\uIP\\uip-1.0\\uip" gcc_entry_point="reset_handler" gcc_optimization_level="None" link_include_startup_code="No" linker_additional_files="$(PackagesDir)/lib/liblpc2000$(LibExt)$(LIB)" linker_memory_map_file="$(TargetsDir)/Philips_LPC210X/Philips_LPC2368_MemoryMap.xml" linker_printf_fmt_level="long" oscillator_frequency="12MHz" project_directory="" project_type="Executable" property_groups_file_path="$(TargetsDir)/Philips_LPC210X/propertyGroups23xx.xml"/> 
    55    <configuration Name="RAM" Placement="RAM" linker_section_placement_file="$(StudioDir)/targets/sram_placement.xml" target_reset_script="SRAMReset()"/> 
    66    <configuration Name="Flash" Placement="Flash" arm_target_flash_loader_file_path="$(TargetsDir)/Philips_LPC210X/Release/Loader_lpc2300.elf" arm_target_flash_loader_type="LIBMEM RPC Loader" linker_section_placement_file="$(StudioDir)/targets/flash_placement.xml" target_reset_script="FLASHReset()"/> 
     
    4545    <folder Name="System Files"> 
    4646      <file Name="crt0.s" file_name="$(StudioDir)/source/crt0.s"/> 
    47       <file Name="Philips_LPC230X_Startup.s" file_name="$(TargetsDir)/Philips_LPC210X/Philips_LPC230X_Startup.s"/> 
     47      <file Name="Philips_LPC230X_Startup.s" file_name="$(TargetsDir)/Philips_LPC210X/Philips_LPC230X_Startup.s"> 
     48        <configuration Name="Common" c_preprocessor_definitions="STARTUP_FROM_RESET"/> 
     49      </file> 
    4850      <file Name="LPC230x.c" file_name="$(TargetsDir)/Philips_LPC210X/LPC230x.c"/> 
    4951      <file Name="Philips_LPC210X_Target.js" file_name="$(TargetsDir)/Philips_LPC210X/Philips_LPC210X_Target.js"> 
     
    5860      </file> 
    5961      <file Name="list.c" file_name="../../Source/list.c"/> 
    60       <file Name="queue.c" file_name="../../Source/queue.c"/> 
     62      <file Name="queue.c" file_name="../../Source/queue.c"> 
     63        <configuration Name="Common" c_enforce_ansi_checking="No"/> 
     64      </file> 
    6165      <file Name="port.c" file_name="../../Source/portable/GCC/ARM7_LPC23xx/port.c"/> 
    6266      <file Name="portISR.c" file_name="../../Source/portable/GCC/ARM7_LPC23xx/portISR.c"> 
     
    98102    <configuration Name="ARM Flash Release" c_preprocessor_definitions="STARTUP_FROM_RESET" gcc_optimization_level="Optimize For Size"/> 
    99103    <configuration Name="THUMB Flash Debug" arm_linker_fiq_stack_size="0" arm_linker_heap_size="0" arm_linker_stack_size="0" arm_linker_svc_stack_size="512"/> 
     104    <folder Name="EnergyMeters"> 
     105      <file file_name="../../Source/EnergyMeters/Meters_ISRs.c"/> 
     106      <file file_name="../../Source/EnergyMeters/Meters.c"/> 
     107    </folder> 
    100108  </project> 
    101109  <configuration Name="ARM Flash Debug" inherited_configurations="ARM;Flash;Debug"/> 
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley/RTOSDemo.hzs

    r17 r19  
    2020  <ProjectSessionItem path="RTOSDemo;RTOSDemo" name="unnamed" /> 
    2121  <ProjectSessionItem path="RTOSDemo;RTOSDemo;Demo Source" name="unnamed" /> 
     22  <ProjectSessionItem path="RTOSDemo;RTOSDemo;EnergyMeters" name="unnamed" /> 
     23  <ProjectSessionItem path="RTOSDemo;RTOSDemo;FreeRTOS.org Source" name="unnamed" /> 
     24  <ProjectSessionItem path="RTOSDemo;RTOSDemo;System Files" name="unnamed" /> 
     25  <ProjectSessionItem path="RTOSDemo;RTOSDemo;uIP Source" name="unnamed" /> 
    2226 </Project> 
    2327 <Register1> 
    24   <RegisterWindow openNodes="" binaryNodes="" unsignedNodes="" visibleGroups="CPU - Current Mode" decimalNodes="" octalNodes="" asciiNodes="" /> 
     28  <RegisterWindow openNodes="CPU - Current Mode" binaryNodes="" unsignedNodes="" visibleGroups="CPU - Current Mode" decimalNodes="" octalNodes="" asciiNodes="" /> 
    2529 </Register1> 
    2630 <Register2> 
    27   <RegisterWindow openNodes="" binaryNodes="" unsignedNodes="" visibleGroups="CPU - Current Mode" decimalNodes="" octalNodes="" asciiNodes="" /> 
     31  <RegisterWindow openNodes="CPU - Current Mode" binaryNodes="" unsignedNodes="" visibleGroups="CPU - Current Mode" decimalNodes="" octalNodes="" asciiNodes="" /> 
    2832 </Register2> 
    2933 <Register3> 
     
    4145 </Watch1> 
    4246 <Watch2> 
    43   <Watches active="0" update="Never" /> 
     47  <Watches active="0" update="Never" > 
     48   <Watchpoint linenumber="57" radix="10" name="s" expression="s" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     49   <Watchpoint linenumber="55" radix="10" name="h" expression="h" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     50   <Watchpoint linenumber="56" radix="10" name="m" expression="m" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     51  </Watches> 
    4452 </Watch2> 
    4553 <Watch3> 
    46   <Watches active="0" update="Never" /> 
     54  <Watches active="1" update="Never" /> 
    4755 </Watch3> 
    4856 <Watch4> 
    49   <Watches active="1" update="Never" > 
    50    <Watchpoint linenumber="125" radix="-1" name="led_1_state" expression="led_1_state" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/arm7_lpc2368_rowley/partest/partest.c" /> 
     57  <Watches active="0" update="Never" > 
     58   <Watchpoint linenumber="54" radix="10" name="s" expression="s" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     59   <Watchpoint linenumber="139" radix="16" name="partstNUM_LEDS" expression="partstNUM_LEDS" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/arm7_lpc2368_rowley/partest/partest.c" /> 
     60   <Watchpoint linenumber="53" radix="16" name="xLastMeterTaskRunTime" expression="xLastMeterTaskRunTime" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     61   <Watchpoint linenumber="131" radix="-1" name="xFlashRate" expression="xFlashRate" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/common/minimal/flash.c" /> 
     62   <Watchpoint linenumber="54" radix="10" name="h" expression="h" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     63   <Watchpoint linenumber="54" radix="10" name="s" expression="s" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     64   <Watchpoint linenumber="53" radix="16" name="xLastMeterTaskRunTime" expression="xLastMeterTaskRunTime" filename="d:/freertosexample/source/energymeters/meters.c" /> 
     65   <Watchpoint linenumber="42" radix="16" name="EXTINT" expression="EXTINT" filename="d:/freertosexample/source/energymeters/meters_isrs.c" /> 
     66   <Watchpoint linenumber="55" radix="10" name="m" expression="m" filename="d:/freertosexample/source/energymeters/meters.c" /> 
    5167   <Watchpoint linenumber="131" radix="-1" name="xLastFlashTime" expression="xLastFlashTime" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/common/minimal/flash.c" /> 
    52    <Watchpoint linenumber="131" radix="-1" name="xFlashRate" expression="xFlashRate" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/common/minimal/flash.c" /> 
    5368   <Watchpoint linenumber="139" radix="-1" name="uxLED" expression="uxLED" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/arm7_lpc2368_rowley/partest/partest.c" /> 
    5469   <Watchpoint linenumber="0" radix="-1" name="xStart" expression="xStart" filename="" /> 
    55    <Watchpoint linenumber="139" radix="16" name="partstNUM_LEDS" expression="partstNUM_LEDS" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/arm7_lpc2368_rowley/partest/partest.c" /> 
     70   <Watchpoint linenumber="125" radix="-1" name="led_1_state" expression="led_1_state" filename="c:/dokumente und einstellungen/birdy/desktop/freertos/demo/arm7_lpc2368_rowley/partest/partest.c" /> 
     71   <Watchpoint linenumber="37" radix="10" name="xLastMeterTaskRunTime" expression="xLastMeterTaskRunTime" filename="d:/freertosexample/source/energymeters/meters.c" /> 
    5672  </Watches> 
    5773 </Watch4> 
    5874 <Files> 
    59   <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="C:\Dokumente und Einstellungen\birdy\Desktop\FreeRTOS\Demo\Common\Minimal\semtest.c" y="200" path="C:\Dokumente und Einstellungen\birdy\Desktop\FreeRTOS\Demo\Common\Minimal\semtest.c" left="0" selected="0" name="unnamed" top="189" /> 
    60   <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="C:\Dokumente und Einstellungen\birdy\Desktop\repo\webserver\example\freeRTOS\Demo\ARM7_LPC2368_Rowley\main.c" y="48" path="C:\Dokumente und Einstellungen\birdy\Desktop\repo\webserver\example\freeRTOS\Demo\ARM7_LPC2368_Rowley\main.c" left="0" selected="1" name="unnamed" top="37" /> 
     75  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freertosexample\source\tasks.c" y="1327" path="D:\freertosexample\source\tasks.c" left="0" selected="0" name="unnamed" top="1316" /> 
     76  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Source\EnergyMeters\Meters.c" y="25" path="D:\freeRTOSexample\Source\EnergyMeters\Meters.c" left="0" selected="0" name="unnamed" top="21" /> 
     77  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Source\EnergyMeters\Meters_ISRs.c" y="18" path="D:\freeRTOSexample\Source\EnergyMeters\Meters_ISRs.c" left="0" selected="0" name="unnamed" top="0" /> 
     78  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Demo\Common\Minimal\flash.c" y="132" path="D:\freeRTOSexample\Demo\Common\Minimal\flash.c" left="0" selected="0" name="unnamed" top="120" /> 
     79  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\emac.c" y="25" path="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\emac.c" left="0" selected="0" name="unnamed" top="14" /> 
     80  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\uIP_Task.c" y="227" path="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\uIP_Task.c" left="0" selected="0" name="unnamed" top="210" /> 
     81  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freertosexample\demo\arm7_lpc2368_rowley\webserver\EMAC_ISR.c" y="23" path="D:\freertosexample\demo\arm7_lpc2368_rowley\webserver\EMAC_ISR.c" left="0" selected="0" name="unnamed" top="15" /> 
     82  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\main.c" y="121" path="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\main.c" left="0" selected="0" name="unnamed" top="108" /> 
     83  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Demo\Common\Minimal\semtest.c" y="215" path="D:\freeRTOSexample\Demo\Common\Minimal\semtest.c" left="0" selected="0" name="unnamed" top="203" /> 
     84  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Source\queue.c" y="467" path="D:\freeRTOSexample\Source\queue.c" left="0" selected="0" name="unnamed" top="454" /> 
     85  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Source\include\targets\LPC23xx.h" y="771" path="D:\freeRTOSexample\Source\include\targets\LPC23xx.h" left="0" selected="0" name="unnamed" top="756" /> 
     86  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="D:\freeRTOSexample\Source\portable\GCC\ARM7_LPC23xx\portISR.c" y="82" path="D:\freeRTOSexample\Source\portable\GCC\ARM7_LPC23xx\portISR.c" left="0" selected="0" name="unnamed" top="69" /> 
     87  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="2" debugPath="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\httpd-cgi.c" y="219" path="D:\freeRTOSexample\Demo\ARM7_LPC2368_Rowley\webserver\httpd-cgi.c" left="0" selected="1" name="unnamed" top="207" /> 
     88  <SessionOpenFile useTextEdit="1" useBinaryEdit="0" codecName="Latin1" x="0" debugPath="C:\Dokumente und Einstellungen\birdy\Lokale Einstellungen\Anwendungsdaten\Rowley Associates Limited\CrossWorks for ARM\packages\targets\Philips_LPC210X\Philips_LPC230X_Startup.s" y="18" path="C:\Dokumente und Einstellungen\birdy\Lokale Einstellungen\Anwendungsdaten\Rowley Associates Limited\CrossWorks for ARM\packages\targets\Philips_LPC210X\Philips_LPC230X_Startup.s" left="0" selected="0" name="unnamed" top="6" /> 
    6189 </Files> 
    62  <ARMCrossStudioWindow activeProject="RTOSDemo" autoConnectTarget="Macraigor Wiggler (20 Pin)" debugSearchFileMap="" fileDialogInitialDirectory="C:\E\Dev\FreeRTOS\Demo\ARM7_LPC2368_Rowley\webserver" fileDialogDefaultFilter="*.c" autoConnectCapabilities="388479" debugSearchPath="" buildConfiguration="ARM Flash Debug" /> 
     90 <ARMCrossStudioWindow activeProject="RTOSDemo" autoConnectTarget="Macraigor Wiggler (20 Pin)" debugSearchFileMap="" fileDialogInitialDirectory="D:\freeRTOSexample\Source\EnergyMeters" fileDialogDefaultFilter="*.c" autoConnectCapabilities="388479" debugSearchPath="" buildConfiguration="ARM Flash Release" /> 
    6391</session> 
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley/main.c

    r17 r19  
    8181 
    8282 
     83void setRTC(void); 
     84void startRTC(void); 
     85 
    8386/* 
    8487 * Checks the status of all the demo tasks then prints a message to the 
     
    98101extern void vuIP_Task( void *pvParameters ); 
    99102 
     103/*  
     104 * The task that handles the electricity meter handling/calculations. 
     105 */ 
     106extern void vMeters_Task( void *pvParameters ); 
     107 
    100108/* 
    101109 * The LCD is written two by more than one task so is controlled by a  
     
    113121int main (void) 
    114122{ 
    115         /* Setup the led's on the MCB2300 board */ 
    116         vParTestInitialise(); 
    117  
    118         /* Create the queue used by the LCD task.  Messages for display on the LCD 
    119         are received via this queue. */ 
    120         xLCDQueue = xQueueCreate( mainQUEUE_SIZE, sizeof( xLCDMessage ) ); 
    121  
    122         /* Create the lwIP task.  This uses the lwIP RTOS abstraction layer.*/ 
    123     xTaskCreate( vuIP_Task, ( signed portCHAR * ) "uIP", mainBASIC_WEB_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY - 1, NULL ); 
    124  
     123  startRTC(); /* start the RTC */ 
     124 
     125  /* Setup the led's on the MCB2300 board */ 
     126  vParTestInitialise(); 
     127 
     128  /* Create the queue used by the LCD task.  Messages for display on the LCD 
     129  are received via this queue. */ 
     130  xLCDQueue = xQueueCreate( mainQUEUE_SIZE, sizeof( xLCDMessage ) ); 
     131 
     132  /* Create the lwIP task.  This uses the lwIP RTOS abstraction layer.*/ 
     133  xTaskCreate( vuIP_Task, ( signed portCHAR * ) "uIP", mainBASIC_WEB_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY - 1, NULL ); 
     134 
     135//  vStartBlockingQueueTasks( mainBLOCK_Q_PRIORITY ); 
     136  vStartMetersTask( mainBLOCK_Q_PRIORITY ); 
    125137        /* Start the standard demo tasks. */ 
    126        vStartBlockingQueueTasks( mainBLOCK_Q_PRIORITY ); 
    127     vCreateBlockTimeTasks(); 
    128     vStartLEDFlashTasks( mainFLASH_PRIORITY ); 
    129     vStartSemaphoreTasks( mainSEM_TEST_PRIORITY ); 
    130     vStartPolledQueueTasks( mainQUEUE_POLL_PRIORITY ); 
    131     vStartIntegerMathTasks( mainINTEGER_TASK_PRIORITY ); 
     138//  vStartBlockingQueueTasks( mainBLOCK_Q_PRIORITY ); 
     139//  vCreateBlockTimeTasks(); 
     140  vStartLEDFlashTasks( mainFLASH_PRIORITY ); 
     141//  vStartSemaphoreTasks( mainSEM_TEST_PRIORITY ); 
     142//  vStartPolledQueueTasks( mainQUEUE_POLL_PRIORITY ); 
     143//  vStartIntegerMathTasks( mainINTEGER_TASK_PRIORITY ); 
    132144 
    133145        /* Start the tasks defined within this file/specific to this demo. */ 
    134     xTaskCreate( vCheckTask, ( signed portCHAR * ) "Check", configMINIMAL_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY, NULL ); 
    135        xTaskCreate( vLCDTask, ( signed portCHAR * ) "LCD", configMINIMAL_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY - 1, NULL ); 
     146 //   xTaskCreate( vCheckTask, ( signed portCHAR * ) "Check", configMINIMAL_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY, NULL ); 
     147    xTaskCreate( vLCDTask, ( signed portCHAR * ) "LCD", configMINIMAL_STACK_SIZE, NULL, mainCHECK_TASK_PRIORITY - 1, NULL ); 
    136148 
    137149        /* The suicide tasks must be created last as they need to know how many 
    138150        tasks were running prior to their creation in order to ascertain whether 
    139151        or not the correct/expected number of tasks are running at any given time. */ 
    140     vCreateSuicidalTasks( mainCREATOR_TASK_PRIORITY ); 
     152 //   vCreateSuicidalTasks( mainCREATOR_TASK_PRIORITY ); 
     153 
    141154 
    142155        /* Start the scheduler. */ 
     
    245258} 
    246259 
    247  
    248  
    249  
    250  
     260void setRTC(void) 
     261
     262/* 
     263  This function needs to be called when the RTC battery was replaces 
     264 
     265  SEC 6 Seconds value in the range of 0 to 59 R/W 0xE002 4020 
     266  MIN 6 Minutes value in the range of 0 to 59 R/W 0xE002 4024 
     267  HOUR 5 Hours value in the range of 0 to 23 R/W 0xE002 4028 
     268  DOM 5 Day of month value in the range of 1 to 28, 29, 30, 
     269  or 31 (depending on the month and whether it is a 
     270  leap year).[1] 
     271  R/W 0xE002 402C 
     272  DOW 3 Day of week value in the range of 0 to 6[1] R/W 0xE002 4030 
     273  DOY 9 Day of year value in the range of 1 to 365 (366 for 
     274  leap years)[1] 
     275  R/W 0xE002 4034 
     276  MONTH 4 Month value in the range of 1 to 12 R/W 0xE002 4038 
     277  YEAR 12 Year value in the range of 0 to 4095 R/W 0xE002 403C 
     278*/ 
     279  RTC_SEC = 00; 
     280  RTC_MIN = 22; 
     281  RTC_HOUR = 17; 
     282  RTC_DOM = 11; 
     283  RTC_DOW = 2-1; 
     284  RTC_DOY = 223; 
     285  RTC_MONTH = 8; 
     286  RTC_YEAR = 2009; 
     287
     288 
     289void startRTC(void) 
     290
     291  // Initial RTC Function 
     292  RTC_CCR  = 0; // Reset All Bit Control 
     293  RTC_CCR |= 0x00000010; // CLKSRC = 1 = Used EXT 32.768 KHz 
     294  RTC_CCR |= 0x00000002; // Reset   Clock 
     295  RTC_CCR &= 0xFFFFFFFD; // Release Reset 
     296  RTC_CCR |= 0x00000001; // Start RTC Clock      
     297
  • webserver/example/freeRTOSexample/Demo/ARM7_LPC2368_Rowley/webserver/httpd-cgi.c

    r14 r19  
    208208static char cCountBuf[ 32 ]; 
    209209long lRefreshCount = 0; 
     210extern basementGasReading; 
     211extern rtcHOURS; 
     212extern rtcMINUTES; 
     213extern rtcSECONDS; 
    210214static unsigned short 
    211215generate_rtos_stats(void *arg) 
    212216{ 
    213         lRefreshCount++; 
    214         sprintf( cCountBuf, "<p><br>Refresh count = %d", lRefreshCount ); 
    215     vTaskList( uip_appdata ); 
    216         strcat( uip_appdata, cCountBuf ); 
    217    
    218         return strlen( uip_appdata ); 
     217  lRefreshCount++; 
     218 
     219  sprintf( cCountBuf, "<p><br>Refresh count = %d<p><br>Pulse Counter = %d at %02u:%02u:%02u", lRefreshCount, basementGasReading, rtcHOURS, rtcMINUTES, rtcSECONDS ); 
     220  strcat( uip_appdata, cCountBuf ); 
     221  vTaskList( uip_appdata ); 
     222  strcat( uip_appdata, cCountBuf ); 
     223   
     224  return strlen( uip_appdata ); 
    219225} 
    220226/*---------------------------------------------------------------------------*/