Giter VIP home page Giter VIP logo

Comments (5)

aribeironovaes avatar aribeironovaes commented on June 17, 2024

Hi @mupparajuvamsi ,

What client are you using to get EventHubClient? Let us know which client you are trying to use on your module and we can try to check if it's possible and how to change port (if possible).

Have you tried to receive the message using our IotHub Client?

Thanks,

Angelo Ribeiro.

from iot-edge-v1.

mupparajuvamsi avatar mupparajuvamsi commented on June 17, 2024

Hi @aribeironovaes
I am using java code to register a device and send a message and receive back the message .First two things are happening fine .But while receiving messages from cloud to device using EventHubClient my Firewall is blocking 5671 port .Moreover i had not seen any documentation regarding receive the message using your IotHub Client in Java API.Could you please be specific about IotHubClient in Java ApI.
If possible can you please send the documentation(link) for Bidirectional communication for IotHub Client
Ex: if i send a message from device to cloud it should receive the message and it should send some response back from cloud to device back .
I saw some where it is mentioned like device endpoints and service endpoints .It is not much clear for java Api(https://azure.microsoft.com/en-in/documentation/articles/iot-hub-devguide-endpoints/)
Send device-to-cloud messages. Receive cloud-to-device messages. Receive device-to-cloud messages. Send cloud-to-device messages and receive delivery acknowledgments. Can i get detailed documentation for all these things with Java Api if possible please guide me where can i get that.

from iot-edge-v1.

aribeironovaes avatar aribeironovaes commented on June 17, 2024

Thanks @mupparajuvamsi ,

Just to confirm, since it's not clear on your message.
Are you using Java Binding on Azure Gateway SDK to get a message from the cloud? (Cloud to Device?).
Either way, if you want to use java i would suggest you to take a look into here:
https://github.com/Azure/azure-iot-sdks
More specifically here:
https://github.com/Azure/azure-iot-sdks/tree/master/java/device

To check more documentation of the specific scenarios you are listing, take a look into our samples on both Azure Gateway SDK (this github) and Azure IoT Hub.

Once you confirm that you are using Gateway Java Binding to receive the message We can guide you more on the D2C and C2D scenarios, as well as selecting the Java SDK to check if you can change the port used....

Thanks,

Angelo Ribeiro.

from iot-edge-v1.

mupparajuvamsi avatar mupparajuvamsi commented on June 17, 2024

Thanks @aribeironovaes
I am not using Java Binding on Azure Gateway SDK
i am using this for sending and receiving message
https://github.com/Azure/azure-iot-sdks/blob/master/java/device/samples/send-receive-sample/src/main/java/samples/com/microsoft/azure/iothub/SendReceive.java
using this i am able to send while doing that i am getting a iothubstatuscode of OK_EMPTY
while receiving in the setMessageCallBack it is checking com.microsoft.azure.iothub.transport.https.HttpsIotHubConnection public Message receiveMessage()
Here it is checking messageStatus == IotHubStatusCode.OK but when i send i am getting status code OK_EMPTY so that i am not able to receive the message whatever i send .This is the main issue..

Secondly provide any reference documentation for D2C and C2D scenarios, (Sending as well as Receiving )

from iot-edge-v1.

aribeironovaes avatar aribeironovaes commented on June 17, 2024

Hi @mupparajuvamsi ,

Ok, from your message I can see that you are using https://github.com/Azure/azure-iot-sdks/ instead of gateway sdk.

Can you post your question on https://github.com/Azure/azure-iot-sdks so you can get proper answer? There you will able to have your questions addressed better.

That said, I went to the Azure-iot-sdk and here is the documentation on how you can do C2D and D2C using Java Client:
https://github.com/Azure/azure-iot-sdks/blob/master/java/device/readme.md

Follow the step by step on how to run the sample and you should see both C2D and D2C working there.

They also have an api documentation here: https://azure.github.io/azure-iot-sdks/java/device/api_reference/index.html

Regarding the Firewall issue you are having, please do post a question on https://github.com/Azure/azure-iot-sdks/ and they may be able to help you. If I have to guess you would be able to change protocols that you connect to IoT Hub (Http, Mqtt or AMQP).

I'm going ahead and close this issue here so you can open a proper issue/question on the respective github repository, but feel free to open anytime if you need help with the azure-iot-gateway-sdk.

Thanks a lot and let us know if this helped,

Angelo Ribeiro.

from iot-edge-v1.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.