Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to Get into API Mode programmatically? #45

Closed
PaulHeitkemper opened this issue Feb 26, 2018 · 11 comments
Closed

How to Get into API Mode programmatically? #45

PaulHeitkemper opened this issue Feb 26, 2018 · 11 comments
Assignees

Comments

@PaulHeitkemper
Copy link

Seems like a bootstrapping problem. Is there a way to talk to a local XBee device via serial port to do what XCTU does to set API Mode?

@jefffhaynes
Copy link
Owner

jefffhaynes commented Feb 26, 2018 via email

@PaulHeitkemper
Copy link
Author

Is this the right answer? I won't be looking into it for several days.

https://www.digi.com/support/forum/66685/digimesh-how-to-enter-api-mode?show=66685#q66685

@jefffhaynes
Copy link
Owner

jefffhaynes commented Feb 27, 2018 via email

@PaulHeitkemper
Copy link
Author

Can you just read the AP value to see if it is 0, or are you talking about something else? In the serial console in XCTU, I get the following:

+++OK

ATAP
1

@jefffhaynes
Copy link
Owner

jefffhaynes commented Feb 27, 2018 via email

@PaulHeitkemper
Copy link
Author

I was able to issue the following commands from the serial console inside XCTU.

+++OK
ATAP
0
ATAP1
OK
ATWR
OK
ATAP
1
ATAP0
OK
ATWR
OK

@jefffhaynes
Copy link
Owner

jefffhaynes commented Feb 27, 2018 via email

@jefffhaynes
Copy link
Owner

Are you ok if I just set API mode on controller open? It's probably the easiest since after that the handlers take over and I can't easily inject textual AT commands

@jefffhaynes jefffhaynes self-assigned this Feb 28, 2018
@PaulHeitkemper
Copy link
Author

PaulHeitkemper commented Mar 1, 2018

seems fine. I plan to use them all in API Mode anyway.

Or you could have a different device type to talk to module not in serial mode. Once it's in API mode, one could dispose that object and begin using the API as always.

@jefffhaynes
Copy link
Owner

Done. Core 1.6 will automatically switch controllers into API mode when opened. However, note that it will not persist the settings. Once in API mode you can use the normal Set/GetApiModeAsync methods to manage it along with WriteAsync().

@PaulHeitkemper
Copy link
Author

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants