W5500 Problems by open and sending UDP
Ethernet Chips
No replies yet. Be the first to reply.
Join the discussion.
Ethernet Chips
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: W5500 Problems by open and sending UDP
by jim ·
Actually, I don’t understand your code well.
Why don’t you upload your real code?
I will make sure that after your uploading.
I don’t know if that helps.
Thanks.
RE: W5500 Problems by open and sending UDP
by steve ·
Ok, here is my code:
First my Open UDP function:
int8_t UDP_OpenPort(uint8_t sn, uint16_t port)
{
int8_t tmp = 0;
int8_t retVal = UDP_OPEN_ERROR;
}
Next my function where sending UDP frames out:
int8_t UDP_Send(ipMessage_t *message)
{
int8_t tmp = 0;
int8_t retVal = UDP_TRANSMISSION_NOT_COMPLETE;
}
Here is my init function of the chip:
uint8_t ECI_InitComInterface(uint8_t *mac, uint8_t *ip, uint8_t *subnetMask, uint8_t *gateway, uint8_t *dns, bool bootFromFlash)
{
int8_t retValSetInfo = -1;
int8_t retValGetInfo = -1;
int8_t tmp;
uint8_t memsize[2][8] = { { 2, 2, 2, 2, 2, 2, 2, 2 }, { 2, 2, 2, 2, 2, 2, 2, 2 } };
uint8_t retVal = INIT_FAILED;
}
And here is my main:
int main(void)
{
/* USER CODE BEGIN 1 */
/* USER CODE END 1 */
/* MCU Configuration----------------------------------------------------------*/
/* Reset of all peripherals, Initializes the Flash interface and the Systick. */
HAL_Init();
/* Configure the system clock */
SystemClock_Config();
/* Initialize all configured peripherals */
MX_GPIO_Init();
MX_SPI1_Init(); //For EEPROM
MX_SPI2_Init(); //For W5500
/* USER CODE BEGIN 2 /
/ EEPROM Init*/
EEPROM_25LC320_InitEeprom();
/* USER CODE END 3 */
}
The ECI_Run task is a TCP/ UDP Loopbackserver (works good).
But if you look at the section before the while(1), you se I init the interface open the UDP Port an want to send a Frame. In debugging step-by-step it works really good, but when I let run my microcontroller with full speed (release) no frame would send
I hope you can help me! Bechause I would even go so far as to say that this is a Bug of the W5500.
Steve
RE: RE: W5500 Problems by open and sending UDP
by jim ·
I checked your code. but I didn’t found suspicious part.
You have to check SPI interface between W5500 and your MCU again.
(SPI mode, SPI clock, SPI option or connection status etc…)
If you need to verify your schematic file, please send an email to support@wiznet.io with your file.
I know W5500 is sold about one million per year.
I think there is a problem in your porting carefully.
If you need to example codes, please refer to the following link.
Those are official products.
Thanks.