0

io.connect() clashes with WiFi client
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

io.connect() clashes with WiFi client

by ShelM on Fri Jul 05, 2019 5:57 am

Hi...

I have a project using a Feather M0 with ATWINC1500. I have successfully used this platform sending data to Adafruit IO feeds and displaying dashboards.

On the same platform, I currently have a project where I query several internet data sources, and I want to pass my derived data to an AIO feed.

As soon as I add my io.connect() line to the project sketch, my wifi connection goes dead. I don't understand the low-level guts of what I'm doing well enough to know how I should integrate the two different protocols.

Any advice, or pointers to reading material, would be much appreciated .

Thanks in advance,
...ShelM

ShelM
 
Posts: 58
Joined: Sun Mar 11, 2018 1:45 am

Re: io.connect() clashes with WiFi client

by brubell on Fri Jul 05, 2019 9:36 am

Hi ShelM,

I'll need a few more pieces of information to assist in debugging your project.

Have you uncommented the #define WINC1500 line in the config.h file?
https://github.com/adafruit/Adafruit_IO ... nfig.h#L27

Could you post the output of the Serial monitor?

Could you post the code for your project between code tags like:
Code: Select all | TOGGLE FULL SIZE
[code]my code here![/code]

brubell
 
Posts: 494
Joined: Fri Jul 17, 2015 10:33 pm

Re: io.connect() clashes with WiFi client

by ShelM on Sat Jul 06, 2019 4:43 am

Hi Brubell...

First, thanks for getting back to me so promptly!

brubell wrote:Have you uncommented the #define WINC1500 line in the config.h file?
https://github.com/adafruit/Adafruit_IO ... nfig.h#L27

Not in the specific .h file to which you pointed me, but I #define WINC1500 true very early in my application's .h file.

I doubt you'd enjoy looking thru my ~6500 lines of code, so will not post them here. 8^) Just to state it here explicitly, my use of AIO has been using the WINC1500, and also my use of GET from numerous different internet platforms is using the same WINC1500.

I had been hoping for some easy-to-try response like merging the names of AdafruitIO_Feed with WiFiSSLClient. Or a statement of how to use GET and PUT or POST to talk directly to AIO - as I currently do when retrieving data via HTTP thru the wifi. Or something, no idea what - I'm pretty clueless about the down and dirty of this type of communication.

If I understand you correctly, you are saying that there is no inherent reason why I should not be able to independently do my AIO feeds while also doing my client GET requests within the same program. If you can confirm that this should be workable, I will back away from my current attempt at mixing the two, and will forge a small-scale demo. If by some chance the demo works, then I'm good-to-go. If it doesn't work, I'll be in a better position to show you trial code.

Thanks again for your response,
Bests,
...Shel

ShelM
 
Posts: 58
Joined: Sun Mar 11, 2018 1:45 am

Re: io.connect() clashes with WiFi client

by brubell on Mon Jul 08, 2019 10:26 am

The Adafruit IO Arduino library does handle network connection/management with the WINC1500, perhaps it's not the correct library to use for this project.


I had been hoping for some easy-to-try response like merging the names of AdafruitIO_Feed with WiFiSSLClient. Or a statement of how to use GET and PUT or POST to talk directly to AIO - as I currently do when retrieving data via HTTP thru the wifi.

Adafruit IO Arduino uses a mix of Adafruit IO's HTTP and MQTT APIs. It seems like your project has a lot going on - maybe it'd be helpful to only implement what you need out of Adafruit IO's API.

If you want to use HTTP network requests with Adafruit IO, I suggest reading through the Adafruit IO API documentation. It includes CuRL code samples for network requests.
https://io.adafruit.com/api/docs/#adafruit-io-http-api

brubell
 
Posts: 494
Joined: Fri Jul 17, 2015 10:33 pm

Re: io.connect() clashes with WiFi client

by deemathur on Thu Jul 11, 2019 2:54 am

Hi

I'm a Student, trying to Add feed through MIT Inventor 2 App develop by me but unable to Add the data ie (0, 1) to my Adafruit Account through my app i want to add through https

https://io.adafruit.com/api/feeds/home/ ... xxx&bulb=1

Please help me to complete my project

Regards
Dee

deemathur
 
Posts: 2
Joined: Thu May 03, 2018 5:39 am

Re: io.connect() clashes with WiFi client

by brubell on Thu Jul 11, 2019 9:33 am

deemathur wrote:Hi

I'm a Student, trying to Add feed through MIT Inventor 2 App develop by me but unable to Add the data ie (0, 1) to my Adafruit Account through my app i want to add through https

https://io.adafruit.com/api/feeds/home/ ... xxx&bulb=1

Please help me to complete my project

Regards
Dee


Please see these two threads regarding app inventor:
viewtopic.php?f=56&t=151387&p=748015&hilit=mit+app#p748015
viewtopic.php?f=56&t=152632&p=753645&hilit=mit+app#p753645

brubell
 
Posts: 494
Joined: Fri Jul 17, 2015 10:33 pm

Please be positive and constructive with your questions and comments.