iotcreators.com web
    • Login
    • Search
    • forum.iotcreators.com
    • docs.iotcreators.com
    • Tags
    • Popular
    • Recent
    • Register
    1. Home
    2. waltert
    W
    • Profile
    • Following 0
    • Followers 0
    • Topics 3
    • Posts 7
    • Best 0
    • Controversial 0
    • Groups 1

    waltert

    @waltert

    Member

    0
    Reputation
    386
    Profile views
    7
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    waltert Unfollow Follow
    Member

    Latest posts made by waltert

    • RE: Raspberry as node

      using the pi’s standard uart interface, i got this working.
      Only caveat is to connect the pi’s rx to the shield rx, and tx to tx, so DONT cross !

      Afterwards i found : http://forum.sodaq.com/t/sodaq-shield-with-raspberry-pi/1169

      posted in Archive
      W
      waltert
    • RE: How to send a message to my SODAQ device?

      @felixdonkers the device needs to be connected to the gateway to be able to receive data, and the only way to get a connection at the current state of the network is to send data to the gateway. So the postmanscript itself is not enough, if your device does an AT+NMGS after you have submitted the postman request, then you will receive on the device.

      posted in Archive
      W
      waltert
    • RE: How to send a message to my SODAQ device?

      If you send a msg from the node to the gateway eg AT+NMGS it will work.

      I rather use the NNMI than the NMGR, since with NNMI you get all te messages in stead of just one.
      NB either NMGR of NNMI you cannot use both at the same time.

      posted in Archive
      W
      waltert
    • sturen vanuit oceanconnect naar node

      Ik heb dit weekend wat testen gedaan met het sturen van berichten (grootte van 10 tot 30 bytes) naar de node
      Samenvatting: alle berichten komen binnen, en zijn correct qua inhoud, berichten komen niet altijd in volgorde van submitten binnen, soms komen berichten dubbel binnen.
      Als je in een klap een 100 tal berichten aanbiedt, dan duurt het ongeveer een halve minuut voordat alles
      binnen bij de node is.
      Komen deze ervaringen overeen met wat anderen vinden ?

      Je geeft in de message post een ExpiryTime op, maar is er dan een retry scheme ? Als de node pas later opkomt,
      zie ik helemaal geen berichten op de node binnenkomen en centraal zie ik “resultCode” : “FAILED”
      Behalve SUCCESFUL heb ik ook wel eens teruggekregen: “resultCode” : “TIMEOUT” “resultCode” : “PENDING”, wat
      betekenen die precies?

      Als response op de post zie ik {“requestId”:null,“commandId”:“xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx”}, wat betekent het dat
      het requestId niet ingevuld is, soms zie ik wel een ingevuld requestId veld ?

      Wat handig werkt (zeker als je veel stuurt 🙂 is het query-en met een starttijd, bv:

      curl  -k --insecure -X GET https://160.44.201.248:8743/iocm/app/cmd/v1.2.0/queryCmd?deviceId=$DEVICEID\&startTime=20171210T084937Z \
        --cert  outgoing.CertwithKey.pem \
        -H "authorization: Bearer $TOKEN" \
        -H 'cache-control: no-cache' \
        -H 'content-type: application/json' \
        -H "app_key: $APPID"
      
      posted in Archive
      W
      waltert
    • Disconnect na een dikke twee uur

      Firmware 6.57, na succesvol verbinding te hebben gemaakt valt de verbinding reproduceerbaar weg na een dikke twee uur. Is dit een bekend verschijnsel ?
      Hierbij de laatste regels uit mijn logfile met in de eerste kolom de millisecs sinds boot.

      7238812 AT+CSQ<CR><LF>          :Return after:21:(ms):           ..+CSQ: 14,99....OK
      7239148 AT+CGATT?<CR><LF>       :Return after:18:(ms):           ..+CGATT: 1....OK
      7838814 AT+CSQ<CR><LF>          :Return after:20:(ms):           ..+CSQ: 99,99....OK
      7839147 AT+CGATT?<CR><LF>       :Return after:18:(ms):           ..+CGATT: 0....OK
      
      posted in Archive
      W
      waltert
    • RE: script ipv postman

      in de getdevices sequence hebben we al een token, dus hoeft secret niet gestuurd te worden,
      vervang de regel onder de curl GET aanroep dus door:

      -d "appId=$APPID" \ 
      
      posted in Archive
      W
      waltert
    • script ipv postman

      Het kostte wat puzzelwerk, maar uiteindelijk is het me gelukt de backend via scripting vanuit een *nix omgeving te benaderen:

      # ProofofConcept shellscript to interact for nb-iot with OceanConnect
      # v0.1 20171029WalterT
      # NB: minimal errorchecking
      
      #Personal configuration :setup secrets
      APPID=xxxxxxxxxxxxxxxxxxxxxxxxxxxx
      SECRET=yyyyyyyyyyyyyyyyyyyyyyyyyyyy
      PASSPHRASE=zzzzzzzzzz
      
      # Generic configuration
      # onetime creation of pem file by concatenating the two original files
      # file should be located in the directory from which the script is run
      #
      # cat outgoing.CertwithKey.key > outgoing.CertwithKey.pem
      # cat outgoing.CertwithKey.crt >> outgoing.CertwithKey.pem
      
      
      KEY=accessToken
      
      #######################################
      #   login and populate TOKEN variable #
      #######################################
      TOKEN=`/usr/bin/curl -k -X POST https://160.44.201.248:8743/iocm/app/sec/v1.1.0/login \
        -d "appId=$APPID&Secret=$SECRET" \
        --pass $PASSPHRASE \
        --cert  outgoing.CertwithKey.pem \
        --header 'cache-control: no-cache' \
        -H 'content-type: application/x-www-form-urlencoded' 2>/dev/null | /usr/bin/awk -F"[,:{}]" '{for(i=1;i<=NF;i++){if($i~/'$KEY'\042/){print $(i+1)}}}' | tr -d '"'`
      
      if [  -z "$TOKEN" ]; then
         echo "login failed\n\n"
         exit 1
      fi
      
      #################
      #  getdevices   #
      #################
      curl -k -X GET https://160.44.201.248:8743/iocm/app/dm/v1.1.0/devices?pageNo=0 \
        -d "appId=$APPID&Secret=$SECRET" \
        --pass $PASSPHRASE \
        --cert  outgoing.CertwithKey.pem \
        -H "app_key: $APPID" \
        -H "authorization: Bearer $TOKEN" \
        -H 'cache-control: no-cache' \
        -H 'content-type: application/json
      
      posted in Archive
      W
      waltert