This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Problem with Wi-Fi communication and BLE communication?

Hi,

I am trying to send data to server using ESP8266 WiFi module interface with nRF52832 DK board via UART interface. My problem is when i sent AT command to ESP8266 it get respond but i want to set SSID name and Password of WiFi using android APP. So sir is it possible to communicate BLE as well as wifi using UART in nRF52832. Can you provide me some useful link or reference sample example tutorial for communicating wifi with nordic. I know this Link tutorial but this is not for ESP8266. Can i use other vendor library with nordic SDK for nRF52832.

  • I changes but still same problem can you give me example function and other function for ESP8266 response print on serial terminal. Thanks for your reply.....

  • Unfortunately I don't have an esp8266, nor do I have the time to make examples for you as the holiday season is coming up. I suggest that you take small steps and start with the simplest AT commands the esp8266 provides. Make sure that you are able successfully send the commands back and read response messages from the esp8266. I suppose there should be lots of people using the esp8266 and you will probably have better luck searching online for examples and libraries.

  • Hi Matt, Now i am able to connect ESP8266 with my router, but still i have facing problem for reading ESP8266 response in uart handle code. I have refere this functionuart_event_handle Can you please help me how i can read response in my terminal. Here is my function:

    void uart_event_handle(app_uart_evt_t * p_event)
    {
        static uint8_t data_wifi_array;
        static uint8_t index = 0;
        static uint8_t startreadwifiUART = 0;
        static uint8_t ind_datawifi_uart = 0;
        static uint8_t stringwifi[100];
        uint32_t   err_code;
        switch (p_event->evt_type)
        {
              case APP_UART_DATA_READY:
            	  UNUSED_VARIABLE(app_uart_get(&data_wifi_array));
            	  	  if(ind_datawifi_uart == 0)
            	  	    {
                        if(data_wifi_array == 0x0D)
                            {
                            startreadwifiUART=true;
                            memset(cmd_wifi_buff,0,UART_TX_BUF_SIZE);
                            }
                    }
    
                    if (startreadwifiUART)
                        {
                            cmd_wifi_buff[ind_datawifi_uart]=data_wifi_array;
                            ind_datawifi_uart++;
                         }
            break;
    
                    case APP_UART_TX_EMPTY:
                        if(index > 0)
                        {
                            err_code = app_uart_put(stringwifi[index]);
                            APP_ERROR_CHECK(err_code);
                            index++;
                        }
                    break;
    
            default:
                break;
                    }
            }
    
  • You start to accumulate the uart response when you get the first 0x0D, but when do you stop? i.e. when do you set startreadwifiUART back to 0? The same with index in the case APP_UART_TX_EMPTY: when do you set index back to 0?

  • I am little confuse when i need to set index 0 or other also, but i am still showing continuously ERROR or some tine busy.. , OK this message showing and i am not able to stop. I want to when i send AT it will show OK and then after that stop. can you please show me simple function for the same. or give me example. Thanks for your reply....

Related