Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

core: Reconsider PROP_MAC_SCAN_STATE behavior #4

@darconeous

Description

@darconeous

Originally, we only had three values for PROP_MAC_SCAN_STATE:

  • SCAN_STATE_IDLE: No scanning is going on
  • SCAN_STATE_BEACON: Scanning for networks
  • SCAN_STATE_ENERGY: Scanning for channel energy

However, the SCAN_STATE_DISCOVER was added in an ill-advised attempt at supporting traditional 802.15.4 beacon scans as well as the new Thread-specific discovery scans. This is confounding to the user. Which one should they use?

I propose we eliminate SCAN_STATE_DISCOVER entirely, and add an entirely new property PROP_MAC_SCAN_ONLY_COMPATIBLE, which would default to true. On a thread device, if this property is true, then doing a beacon scan would actually do a Thread discovery scan. If set to false, it would perform a standard 802.15.4 scan, presumably also returning the results from incompatible networks (to avoid conflicts).

Thoughts?

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions