Skip to content

Latest commit

 

History

History

ESPTouch

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

EspTouch

Example

APIs

  • Create task instance

    ESPTouchTask *task = [[ESPTouchTask alloc] initWithApSsid:apSsid andApBssid:apBssid andApPwd:apPwd];
    [task setEsptouchDelegate:delegate]; // Set result callback
    [Task setPackageBroadcast:YES]; // if YES send broadcast packets, else send multicast packets
  • Execute task

    int expectCount = 1;
    NSArray * results = [task executeForResults:expectCount];
    ESPTouchResult *first = [results objectAtIndex:0];
    if (first.isCancelled) {
        // User cancel the task
        return;
    }
    if (first.isSuc) {
        // EspTouch successfully
    }
  • Cancel task

    [task interrupt];