Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training




Loading

dynamic cgi

Posted by Nobody/Anonymous on December 6, 2005
hi
my probem is how dynamic cgi works:
at Folder fs and makefsdata it cally a funktion a, b or c in cgi.c.
e.g. it calls Statistics it wirtes how offten a testpage is opened by a user. at cgi.c the author writes " the statistics data is written into the uip appdata buffer". So the funktions reads the buffer.
but my question is where the data is written into the buffer? And How it works?

RE: dynamic cgi

Posted by Nobody/Anonymous on December 6, 2005
To create a CGI function:

1/ in the uip/fs/cgi directory create your new cgi script file using the uip documented notation. For example, to call cgi function 'd' use: "c d". You can copy the examples that are already there.

2/ in uip/cgi.c add your function name to the cgifunction cgitab structure. The first function in the structure is function 'a', the second function 'b', the third function 'c', etc.

3/ In the same file write the function that generates the dynamic data. Strings can be created using normal C functions (sprintf(), etc.). To send the data simply call
uip_send( astring, strlen( astrin ) );

where astring is the string you created that contains the dynamic data.

4/ Run makefsdata then recompile your project.

RE: dynamic cgi

Posted by Nobody/Anonymous on December 7, 2005
it looks good. how you descripe i seems to be in cgi.c to.
i will try it after i fexed cygwin. makefsdata is not wirking anymore:" exec :makefsdata: not found"
it was working before i reinstalled windows.

But is it possible to read data form a webpage like getchar to the buffer?

RE: dynamic cgi

Posted by Nobody/Anonymous on December 7, 2005
i try to generate a counter for my dynamic.
this counter i allcate to astring.
So i hoped on the webpage it will appear a incrementing counter. ( i used refersh to refresh my webpage). but the only thing happend is the error led flashes...
where is my misstake?


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists