code: def get_mtype_and_number_from_code(si, sensor_code):
      
      mtype_and_ory, x, y, z = sensor_code.split("-")
      if mtype_and_ory[-1] in "XYZ" and "ACCX" not in si:  # Need to support old sensor_file.json files.
          mtype = mtype_and_ory[:-1]
      else:
          mtype = mtype_and_ory
      for m_number in si[mtype]:
          cc = get_sensor_code_by_number(si, mtype, m_number)
          if cc == sensor_code:
              return mtype, m_number
      return None, None
docs: Given a sensor sensor_code, get motion type and sensor number
  
      :param si: dict, sensor index json dictionary
      :param sensor_code: str, a sensor code (e.g. ACCX-UB1-L2C-M)
      :return: