GET/POST question
General
No replies yet. Be the first to reply.
Join the discussion.
General
No replies yet. Be the first to reply.
Join the discussion.
Share projects and connect with makers.
Joined before the site update? first.
New to WIZnet Makers?
We sent a verification link to your address. Open it to activate your account, then log in.
Accounts from this email provider are reviewed by an administrator after verification. Approval usually takes one business day.
Already have an account?
Enter your email address. If it belongs to an account, we'll send a link to set a new password. Members who joined before the site update use this to set their password.
If an account uses that address, we sent a link to set a new password. The link works once and expires in 30 minutes.
Know your password?
Need an account?
RE: GET/POST question
by roty ·
I got it by myself.
Set data ( Relx and LEDx on ) : curl -d “pin=x&val=0” 192.168.11.100/dout.cgi
Reset data ( Relx and LEDx off) : curl -d “pin=x&val=1” 192.168.11.100/dout.cgi
x = 0…7
RE: GET/POST question
by ThaHandy ·
On page “Getting Started Guide with WIZ550web” there is a line: “Users can learn how to control the H/W (I/O, UART, Registers and Etc.) using the web page.”
Would be better if these fictions where documented already for people who have no idea where to look.
Anyway. I did some digging around:
Issues I’ve found:
USART1 on page = UART2 on data sheet (Serial Port - Data) and
USART2 on page = UART1 on data sheet (Serial Port - AT command)
GET Commands
Example:
curl -G http://192.168.11.100/get_dio5.cgi or use web browser
widget.cgi (Get Basic Settings)
io.cgi (Get I/O all status, include pin 90,91 on-board LED)
io_alias.cgi (Get all I/O status. direction and port names)
adc.cgi (Get all ADC Status/values)
get_devinfo.cgi (Get Device info)
get_netinfo.cgi (Get Network info)
get_serial_data.cgi (Get serial data from buffer) (Console port)
get_uart0info.cgi Get Serial port 1 settings (UART1, Console)
get_uart1info.cgi Get Serial port 1 settings (UART2, AT command)
get_ain0.cgi ~ get_ain3.cgi (Get ADC info per port)
get_dio0.cgi ~ get_dio15.cgi (Get I/O status per port)
SET Set commands
Example:
curl -d “pin=5&val=1” http://192.168.11.100/set_diostate.cgi (Set I/O port 5 to On/High) or
curl -d “lip=192.168.11.100” http://192.168.11.100/config.cgi (to set only the “lip” parameter
config.cgi (Basic configure setup: Device name, LAN, UART2 = AT Port))
devicename=WIZ550WEB
dhcp=0
lip=192.168.11.100
gw=192.168.1.1
sub=255.255.255.0
dns=0.0.0.0
baudrate=0-9 (600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200, 230400)
databit=8,9
parity=0-2 (None, Odd, Even)
stopbit=1,2
flowcontrol=0-3 (None, CTS/RTS, RS422, RS485)
dout.cgi (Set I/O port On/Off)
pin=0-15,90,91 (I/O port number, 90/91=on-board led)
val=0 (High/On)
val=1 (Low/Off)
save_alias.cgi (Change name of I/O port)
pin=0-15 (I/O port number)
val=Digital IO #5
dir_change.cgi (Change I/O direction)
pin=0-15 (I/O port number)
val=0-2 (Not used,Input,Output)
tx_serial_data.cgi (Send serial data to UART1 = Console port)
data=text here
set_default_io_status.cgi (IO Settings Factory Reset and Reboot)
io_reset=1
set_devinfo.cgi (Configure Device name) **changes takes effect after reboot
devname=WIZ550WEB
set_netinfo.cgi (Configure Lan port) **changes takes effect after reboot
ip=192.168.11.100
gw=192.168.11.1
sub=255.255.255.0
dns=0.0.0.0
set_uart0info.cgi (Configure UART1= Console Port) **changes takes effect after reboot
baud=0-9 (600,1200,2400,4800,9600,19200,38400,57600,115200,230400)
databit=8,9
parity=0-2 (None,odd,even)
stopbit=1,2
flow=0-3 (None,CTS/RTS,RS422,RS485)
set_uart1info.cgi (Configure UART2 = AT port) **changes takes effect after reboot
baud=0-9 (600,1200,2400,4800,9600,19200,38400,57600,115200,230400)
databit=8,9
parity=0-2 (None,odd,even)
stopbit=1,2
flow=0-3 (None,CTS/RTS,RS422,RS485)
set_diodir.cgi (Change I/O direction. same as dir_change.cgi)
pin=0-15 (I/O port number)
val=0-2 (Not used,Input,Output)
set_diostate.cgi (Set I/O port On/Off. almost the same as dout.cgi)
pin=0-15 (I/O port number)
val=0 (Low/Off)
val=1 (High/On)
set_dioalias.cgi (Change name of I/O port. same as save_alias.cgi)
pin=0-15
val=Digital IO #5
Wiz Team, feel tree to add this in the Wiz Wiki
RE: RE: GET/POST question
by Kei ·
Hello, ThaHandy.
Thanks for your kind info
WIZ550web developer had previously created something related to the command.
First, we will release this and add your friendly comments.
If we release it, we will reply.
I answer two of the issues you have found.
Yes, That is correct. Value is invert.
This can be checked / changed in 624Line in userHandler.c.
I will discuss with existing developer on whether to change this to on = 1, off = 0.
Where in the data sheet does UART2 specify Serial Port - DATA?

In the Schematic, you can see that UART2 = AT command, UART1 = Data.
Maybe it’s not what I’m looking for, so I would appreciate it if you let me know where you saw it.
Once again thank you for your kind info
RE: GET/POST question
by irina WIZnet ·
Dear ThaHandy,
Thank you for your great advice.
In fact, there is a guide for WIZ550web that has not been released. The reason was that the customer did not feel a great need.
However, I learned from your proposal that users could have needs more details guide. So, we will release some of the existing guides / tutorials.
http://wizwiki.net/wiki/doku.php?id=products:wiz550web:wiz550web_tutorial_kr
I hope you will review the link’s documentation and give me more advice.
Currently only Korean documents, but soon I will release English documents and additional contents.
(Depending on the schedule, the release may be slightly delayed.)
Again, Thank you sincerely.
Regards,
Eric
RE: GET/POST question
by ThaHandy ·
@ UART part, my bad.
When testing I’ve lost track on which is which.
I got confused by the name and thinking AT command was for console and Data was for port2.
So in my opinion:
UART1 = Console/Debug/Program port (RS232 on the dev board)
UART2 = Data/AT command port (RS485/422 on the dev board)
RE: GET/POST question
by Kei ·
Ok, When we update the wiki this time, I will add a description of the functions of UART1,2.
Thank you for your feedback
RE: GET/POST question
by Kei ·
I added it like below to Basic Webpages Demo
The reason I added it to the Getting Start category is that it only makes sense when using GitHub code.
RE: GET/POST question
by Kei ·
Tutorial that was originally written in Korean was translated into English.
In addition, I have included some of your suggestions in the tutorial, and I will discuss them with existing developers and add more.
Please refer to the english tutorial link.
Thanks!
RE: GET/POST question
by ThaHandy ·
Thank you for the tutorial, we’re getting there.
A few things:
curl -d “lip=192.168.11.100” http://192.168.11.100/config.cgi (to set only the “lip” parameter)example does not make sens if the config.cgi is not included in the example.set_uart0(and 1)info.cgi uses databit=8 or 9 not 0 or 1 (get_uart0(and 1)info.cgi its indeed 0 or 1)
And set_diostate.cgi, set_diodir.cgi, set_dioalias.cgi example are incomplete.
My SET commands are correct as far I know, as I have debugged all of them them using wireshark.
RE: RE: GET/POST question
by Kei ·
Oh, this is our mistake.
I will add and supplement the rest of the contents.
Thanks!