where can I find connectiq.js

hello. where can i find connectiq.js

I'm testing an app on my garmin watch to transmit accelerometer values in semi-real time and would like to use a socket based html/js page for testing.

Thank you

John

  • What exactly are you trying to achieve? What are you referring to with "connectiq.js"? Are you looking to send an HTTP request to that page as an endpoint for testing purposes? If so, you might want to check out Postman—it allows you to create mock servers to simulate the API you're working with, which can be very useful for testing without needing the actual backend.

  • I don't think it's possible. You can make http GET, POST requests, but not sockets.

  • thank you:

    • Could you confirm if there’s a specific JavaScript library or Connect IQ API for handling HTTP requests to external servers? For example, does Garmin provide a JavaScript SDK or sample code for web integration?
    • If I’m off-base with "connectiq.js," is there a recommended way to send Tacx trainer data from a Connect IQ app to a web-based relay app? I’m open to using tools like Postman for testing or exploring Garmin’s Communications API for HTTP requests.
    • Any pointers to documentation or examples for integrating Connect IQ apps with external servers would be super helpful.
  • All that's in CIQ can be found in Communications.  Starting with makeWebRequest,  As far as the server end, I've just used apache in the past,  In geral, it's a bit more complex than it was in the early days as unless the server is on your phone, you need to use https with a valid certificate

  • I think you don't understand how this works. And I'm not even talking about Monkey C or Garmin devices. In general you have systems (i.e a Garmin device) , the internet, and other systems (i.e your website). Each of these systems use their own architecture, operating system, and have some language compilers. They don't need to use the same language. An Android app written in java can usually talk to a http server using the standards, and it doesn't matter if the web server is implemented in java, js or PHP.

    Similarly, you don't need to use the same language on both sides of your app. But you have to take into consideration the abilities of the other side. So you shouldn't even ask for running JavaScript on a Garmin watch, but instead ask if the concrete protocol used by your web server can be implemented on a Garmin device. If the answer is yes then it's going to be implemented in Monkey C (and then it's not even off topic in this forum ;) If I understand correctly what you want to do, then you won't be able to do it.

    To translate it to web terminologies, instead of using sockets and probably something like long polling, you'll need to make it possible for the client to use http requests and maybe do polling.

    I'm not familiar with tacx but I'm pretty sure that you won't be able to see it from Monkey C. 

    Maybe you should tell us more about what you really are trying to do.

  • Thank you. Yes. I am using MonkeyC on the watch. The additional components I am adding  is a nodeJS program receiving the data from the watch (in as real time as possible) via BT. Then I have a TensorFlow program that will be doing some analysis on the data etc.... I

    'm just testing collecting the  XYZ off of the accelerometers , Pulse rate and that all works and  I was looking to run a test via a JavaScript in an HTML page on my local machine (just to test the transmission and data transfer). Thank You.

    John

  • Thanks for your assistance. I have an alternate solution that seems to be working..... Thanks everyone.