Difference between revisions of "Component: Webserver (WIZ810MJ) (Comms: Networking)"
From Flowcode Help
Jump to navigationJump to search| Line 15: | Line 15: | ||
| Webserver component designed to work with the WIZ810MJ module from Wiznet, as used in the version 2 EB023 E-block and MIAC System Industrial Addon. Provides a very simple interface to allow webpages to be hosted from hardware or simulation. | Webserver component designed to work with the WIZ810MJ module from Wiznet, as used in the version 2 EB023 E-block and MIAC System Industrial Addon. Provides a very simple interface to allow webpages to be hosted from hardware or simulation. | ||
| − | ==Component  | + | ==Component Source Code== | 
| − | + | Please click here for the component source code: [https://www.flowcode.co.uk/wikicopy/componentsource/FC_Comp_Source_WebServer_EB023-00-2.fcfx FC_Comp_Source_WebServer_EB023-00-2.fcfx] | |
| ==Detailed description== | ==Detailed description== | ||
| + | |||
| + | |||
| Line 34: | Line 36: | ||
| ==Examples== | ==Examples== | ||
| + | |||
| + | |||
| Line 488: | Line 492: | ||
| | width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]] | ||
| | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''   | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''   | ||
| + | |- | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | HTML Source | ||
| |- | |- | ||
| |- | |- | ||
| Line 534: | Line 542: | ||
| |- | |- | ||
| | colspan="2" | Embedded HTML code used for page 4  | | colspan="2" | Embedded HTML code used for page 4  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Connections | ||
| + | |- | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| + | | width="90%" | Channel | ||
| + | |- | ||
| + | | colspan="2" | SPI Channel selector  | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| + | | width="90%" | Prescale | ||
| + | |- | ||
| + | | colspan="2" | Prescale option selector  | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-5-icon.png]] | ||
| + | | width="90%" | MOSI | ||
| + | |- | ||
| + | | colspan="2" | SPI Data Out Pin SDO - Also Known as Master Out Slave In (MOSI) when used in Master mode.  | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-5-icon.png]] | ||
| + | | width="90%" | MISO | ||
| + | |- | ||
| + | | colspan="2" | SPI Data In Pin SDI - Also Known as Master In Slave Out (MISO) when used in Master mode.  | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-5-icon.png]] | ||
| + | | width="90%" | CLK | ||
| + | |- | ||
| + | | colspan="2" | SPI Clock Pin CLK - The Clock signal is driven by the SPI master.  | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-5-icon.png]] | ||
| + | | width="90%" | CS / SS | ||
| + | |- | ||
| + | | colspan="2" | Chip Select / Slave Select Pin  Master Mode: General purpose output pin used to select the remote SPI device. Slave Mode: Hardware chip select pin input used to select the SPI device.   | ||
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-type-5-icon.png]] | ||
| + | | width="90%" | Int Pin | ||
| + | |- | ||
| + | | colspan="2" | Interrupt pin connection on Wiznet module  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Gateway IP | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | ||
| Line 554: | Line 605: | ||
| |- | |- | ||
| | colspan="2" | IP address of the gateway to the internet if applicable.  | | colspan="2" | IP address of the gateway to the internet if applicable.  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Subnet Mask | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | ||
| Line 574: | Line 629: | ||
| |- | |- | ||
| | colspan="2" | Subnet mask of the server - usually 255.255.255.0  | | colspan="2" | Subnet mask of the server - usually 255.255.255.0  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | IP Address | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | ||
| Line 594: | Line 653: | ||
| |- | |- | ||
| | colspan="2" | IP address of the server - usually 192.168.0.x or 192.168.1.x  | | colspan="2" | IP address of the server - usually 192.168.0.x or 192.168.1.x  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | MAC Address | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-14-icon.png]] | ||
| Line 624: | Line 687: | ||
| |- | |- | ||
| | colspan="2" | MAC address of the server  | | colspan="2" | MAC address of the server  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Substitutions | ||
| + | |- | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Outgoing | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| Line 644: | Line 715: | ||
| |- | |- | ||
| | colspan="2" | Number of bytes to reserve for data string.  | | colspan="2" | Number of bytes to reserve for data string.  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Incoming | ||
| + | |- | ||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| Line 655: | Line 730: | ||
| | colspan="2" | Number of bytes to reserve for data string.  | | colspan="2" | Number of bytes to reserve for data string.  | ||
| |- | |- | ||
| − | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | 
| − | | width="90%" |  | + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Simulation | 
| |- | |- | ||
| − | |||
| |- | |- | ||
| − | | width="10%" align="center" | [[File:Fc9-type- | + | | width="10%" align="center" | [[File:Fc9-type-10-icon.png]] | 
| − | | width="90%" |  | + | | width="90%" | Label | 
| |- | |- | ||
| − | | colspan="2" |  | + | | colspan="2" | Label used to help identify the component on the panel.  | 
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| − | | width="90%" | API | + | | width="90%" | Sim Type | 
| + | |- | ||
| + | | colspan="2" | Decides how to perform the simulation of the component. TCP IP - Communicates using the Windows TCP IP communications DLL SPI / API - Communicates using the CAL SPI to allow the communications to be analysed and debugged.  | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]] | ||
| + | | width="90%" style="background-color:#EAE1EA; color:#4B008D;" | TCP Simulation | ||
| |- | |- | ||
| − | |||
| |- | |- | ||
| | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | | width="10%" align="center" | [[File:Fc9-type-16-icon.png]] | ||
| Line 674: | Line 752: | ||
| |- | |- | ||
| | colspan="2" | List of network interfaces connected to the PC.  Sets which interface we are communicating via.  | | colspan="2" | List of network interfaces connected to the PC.  Sets which interface we are communicating via.  | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| |} | |} | ||
Revision as of 17:52, 9 November 2022
| Author | Matrix Ltd. | 
| Version | 2.0 | 
| Category | Comms: Networking | 
Contents
Webserver component
Webserver component designed to work with the WIZ810MJ module from Wiznet, as used in the version 2 EB023 E-block and MIAC System Industrial Addon. Provides a very simple interface to allow webpages to be hosted from hardware or simulation.
Component Source Code
Please click here for the component source code: FC_Comp_Source_WebServer_EB023-00-2.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Downloadable macro reference
|   | WM_CH_MR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | WM_CH_PORT | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | WM_TXMEM | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | MIAC_Module_SetData | 
|  - BYTE | Count | 
|  - BYTE | D0 | 
|  - BYTE | D1 | 
|  - BYTE | D2 | 
|  - BYTE | D3 | 
|  - BYTE | D4 | 
|  - BYTE | D5 | 
|  - VOID | Return | 
|   | WM_CH_RX_RSR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | MIAC_Module_GetData | 
|  - BYTE | Index | 
|  - BYTE | Return | 
|   | SetOutValue | 
| Set the value of an outbound substitution string | |
|  - BYTE | index | 
|  - STRING | value | 
|  - VOID | Return | 
|   | Send_Embedded_HTML_Page4 | 
|  - VOID | Return | 
|   | MIAC_Module_Message | 
|  - UINT | CAN_ID | 
|  - UINT | CMD_ID | 
|  - BYTE | Return | 
|   | Send_Embedded_HTML_Page3 | 
|  - VOID | Return | 
|   | Send_Embedded_HTML_Page2 | 
|  - VOID | Return | 
|   | WM_CH_IR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | Send_Embedded_HTML_Page1 | 
|  - VOID | Return | 
|   | GetInValue | 
| Returns the string value of a Request parameter | |
|  - BYTE | index | 
|  - STRING | Return | 
|   | MIAC_Module_PushData | 
|  - BYTE | Data | 
|  - VOID | Return | 
|   | CreateServerSocket | 
| Creates a listening socket on the selected channel and port ready to accept incoming web page requests. | |
|  - BYTE | Channel | 
|  - UINT | Port | 
|  - BYTE | Return | 
|   | WM_CH_CR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | WM_CH_TX_WR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | IncRxPtr | 
|  - BYTE | Channel | 
|  - VOID | Return | 
|   | CheckSocketActivity | 
| Checks for activity on the server socket and serves out the webpages to any requesting parties. | |
|  - BYTE | Return | 
|   | WM_CH_SR | 
|  - BYTE | ch | 
|  - UINT | Return | 
|   | WM_RXMEM | 
|  - BYTE | ch | 
|  - UINT | Return | 








