- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is it posible to conect ESP8266 ESP-01 WiFi module and psoc6 CY8CKIT 062S2 43012 by use MQTT ?
Dose it have example code ? I have tried the example code of MQTT client by use Modustool box but it didn’t work .
i am not sure if ESP8266 ESP-01 WiFi module can receive the date from Psoc .
Thanks!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
"Interface is not up/NULL" msg is seen when one of the whd_init(), cybsp_wifi_bus_init(), whd_wifi_on() fail which are called as part of wcm_init(). Most probably sdio bus init might be failing which could happen due to sdio interface hardware issue or for some other reason.
To pin point which API among the three that are listed above is failing, the CE could be run in debugger mode with breakpoints placed at each of those APIs called inside the cybsp_wifi_init_primary_extended() in the cybsp_wifi.c file. If cybsp_wifi_bus_init() is failing, you can run the CE on another CY8CKIT 062S2 43012 board and see if it runs. If that is the case then it could be the board hardware issue.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
You can connect both devices using MQTT. In MQTT, clients have to be connected to MQTT broker which pushes the information to the client according to the subscribed topics. The client on ESP8266 ESP-01 WiFi module must subscribe to same topic that psoc6 board is publishing to receive data. The example code works if parameters mentioned in README are properly set.
Thanks,
Phanindra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The ''MQTT_USERNAME"and"MQTT_PASSWORD" maens that my AWS acount if i use AWS IoT as MQTT broker?
thanks
Jessy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
''MQTT_USERNAME" and "MQTT_PASSWORD" are not AWS account credentials. They are for client authentication and not necessary to set if you are using AWS IOT broker.
AWS MQTT broker uses client certificate and client private key that you get after creating a new thing in AWS for client authentication.
Thanks,
Phanindra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If I can’t find MQTT USERNAME and PASSWORD how can I use the example code? I have already checked the broker address is correct.
Thank
Jessy.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
MQTT USERNAME and PASSWORD are for client authentication and authorization, if required by the MQTT broker. AWS requires secure connection, so It uses certificates, keys for the authentication instead of username, password. You can use example code without setting USERNAME, PASSWORD in case of AWS broker.
Make sure to convert the certificates and keys from PEM format to C string format using HTML utility in README before updating the macros in mqtt_client_config.h file.
Thanks,
Phanindra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
i have download the certificates and keys but i still don't know how to change PEM form to C string after i read the README.
Thanks,
Jessy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the README, at the bottom of the "AWS IoT MQTT" sub section, you can find a link for HTML utility present in the GitHub repository. I have pasted that link below for your reference.
First, you need to clone that repository to your pc and then you can open "PEMfileToCString.html" file, upload the certificates, keys and paste the converted ones in their respective macros of "mqtt_client_config.h" file.
Thanks,
Phanindra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
"Interface is not up/NULL" msg is seen when one of the whd_init(), cybsp_wifi_bus_init(), whd_wifi_on() fail which are called as part of wcm_init(). Most probably sdio bus init might be failing which could happen due to sdio interface hardware issue or for some other reason.
To pin point which API among the three that are listed above is failing, the CE could be run in debugger mode with breakpoints placed at each of those APIs called inside the cybsp_wifi_init_primary_extended() in the cybsp_wifi.c file. If cybsp_wifi_bus_init() is failing, you can run the CE on another CY8CKIT 062S2 43012 board and see if it runs. If that is the case then it could be the board hardware issue.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Seems you did not actually need a broker for ESP8266 but if you do, here is one. https://github.com/martin-ger/uMQTTBroker In my experience AWS is harder to use because you can't just have username password connections, you need the signed certificates. By running your own broker you will not have that problem.