MKRFOX1200 Questions

Hello Everybody
I would like to know if the MKRFOX1200 is able to receive a string from the BACKEND that was previously sent via the external API so that the device would activate, for example, some digital output ...
Thank's
Antonio

Hi there,

I think this is the answer you need.

Aurelien said :

aureleq:
For the arduino sketch, you can look at the FirstConfiguration example (https://github.com/arduino-libraries/SigFox/tree/master/examples/FirstConfiguration):

The downlink is triggered by setting the endPacket() method to true, then use SigFox.read() to retrieve received bytes:

int ret = SigFox.endPacket(true);  // send buffer to SIGFOX network and wait for a response

...
if (SigFox.parsePacket()) {
    Serial.println("Response from server:");
    while (SigFox.available()) {
      Serial.print("0x");
      Serial.println(SigFox.read(), HEX);
    }





If you need information on how to configure the downlink on sigfox backend, you can refer to this guide:

https://github.com/nicolsc/sigfox-downlink


Aurelien

Enjoy'

Méric

after following the instructions sigfox-downlink you can test the downlink using a service such as PutsReq which records HTTP requests and allows the creation of a response, e.g.

  1. create a PutsReq
  2. copy the URL into the Sigfox backend CALLBACK URL pattern and save the callback
  3. in the PutsReq Response Builder enter

response.status = 200; // default value
response.headers['Content-Type'] = 'application/json';
response.body = {"XXXXX":{"downlinkData":"70117f61a5ceec67"}}

where XXXXX is your device ID

on the next uplink you should get a downlink to the device, e.g.

MKRFox1200 Sigfox 
SigFox FW version 2.3

Module temperature: 20.00
Type the message to be sent
Sending 6

Getting the response will take up to 50 seconds
The LED will blink while the operation is ongoing
Transmission ok
OK
PA OFF
Response from server:
0x70 0x11 0x7F 0x61 0xA5 0xCE 0xEC 0x67