Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
micropython
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
card10
micropython
Commits
44bb616b
Commit
44bb616b
authored
10 years ago
by
danicampora
Browse files
Options
Downloads
Patches
Plain Diff
cc3200: Add simplelink non-os task calls.
parent
4bfc4917
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cc3200/mods/modwlan.c
+14
-2
14 additions, 2 deletions
cc3200/mods/modwlan.c
with
14 additions
and
2 deletions
cc3200/mods/modwlan.c
+
14
−
2
View file @
44bb616b
...
...
@@ -371,6 +371,9 @@ modwlan_Status_t wlan_sl_enable (SlWlanMode_t mode, const char *ssid, uint8_t ss
// if the device is in AP mode, we need to wait for this event
// before doing anything
while
(
!
IS_IP_ACQUIRED
(
wlan_obj
.
status
))
{
#ifndef SL_PLATFORM_MULTI_THREADED
_SlTaskEntry
();
#endif
HAL_Delay
(
5
);
}
}
...
...
@@ -386,6 +389,9 @@ modwlan_Status_t wlan_sl_enable (SlWlanMode_t mode, const char *ssid, uint8_t ss
// other return-codes
if
(
0
==
sl_WlanDisconnect
())
{
while
(
IS_CONNECTED
(
wlan_obj
.
status
))
{
#ifndef SL_PLATFORM_MULTI_THREADED
_SlTaskEntry
();
#endif
HAL_Delay
(
5
);
}
}
...
...
@@ -516,7 +522,7 @@ void wlan_set_pm_policy (uint8_t policy) {
void
wlan_servers_stop
(
void
)
{
servers_disable
();
do
{
HAL_Delay
(
2
);
HAL_Delay
(
5
);
}
while
(
servers_are_enabled
());
}
...
...
@@ -553,9 +559,12 @@ STATIC modwlan_Status_t wlan_do_connect (const char* ssid, uint32_t ssid_len, co
if
(
0
==
sl_WlanConnect
((
_i8
*
)
ssid
,
ssid_len
,
(
_u8
*
)
bssid
,
&
secParams
,
NULL
))
{
// Wait for WLAN Event
// Wait for
the
WLAN Event
uint32_t
waitForConnectionMs
=
0
;
while
(
!
IS_CONNECTED
(
wlan_obj
.
status
))
{
#ifndef SL_PLATFORM_MULTI_THREADED
_SlTaskEntry
();
#endif
HAL_Delay
(
5
);
if
(
++
waitForConnectionMs
>=
MODWLAN_TIMEOUT_MS
)
{
return
MODWLAN_ERROR_TIMEOUT
;
...
...
@@ -777,6 +786,9 @@ STATIC mp_obj_t wlan_connect(mp_uint_t n_args, const mp_obj_t *pos_args, mp_map_
if
(
GET_STATUS_BIT
(
wlan_obj
.
status
,
STATUS_BIT_CONNECTION
))
{
if
(
0
==
sl_WlanDisconnect
())
{
while
(
IS_CONNECTED
(
wlan_obj
.
status
))
{
#ifndef SL_PLATFORM_MULTI_THREADED
_SlTaskEntry
();
#endif
HAL_Delay
(
5
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment