Skip to content

108 Card Delete ​

The phone sends a delete command and card ID, ssm_touch responds successfully and deletes the specified card.

Sequence diagram ​

Mobile phone sends data ​

Byte16 ~ 10
DataCard IDitem code

item code : SSM_OS3_CARD_DELETE (108)

ssm_touch returns content ​

Byte210
Dataresitem_codetype
DescriptionCommand processing statusInstruction numberPush type

type : SSM2_OP_CODE_RESPONSE (0x07)

item code : SSM_OS3_CARD_DELETE (108)

res : CMD_RESULT_SUCCESS (0x00)

iOS, Android, ESP32 example ​

Android example ​

jsx
  override fun cardDelete(ID: String, result: CHResult<CHEmpty>) {
      if (checkBle(result)) return
      sendCommand(SesameOS3Payload(SesameItemCode.SSM_OS3_CARD_DELETE.value, ID.hexStringToByteArray())) { res ->
          L.d("hcia", "[cardDelete][ID]" + ID)
          result.invoke(Result.success(CHResultState.CHResultStateBLE(CHEmpty())))
      }
  }

iOS example ​

jsx
  func cardsDelete(ID: String, result: @escaping (CHResult<CHEmpty>)) {
        if (self.checkBle(result)) { return }

        sendCommand(.init(.SSM_OS3_CARD_DELETE,ID.hexStringtoData())) { _ in
            result(.success(CHResultStateNetworks(input: CHEmpty())))
        }
    }

ESP example ​

jsx