element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Azure Sphere Starter Kit
  • Products
  • Dev Tools
  • Avnet Boards Community
  • Azure Sphere Starter Kit
  • More
  • Cancel
Azure Sphere Starter Kit
Forum Can I use SCP to move a file into Azure Sphere?
  • Blog
  • Forum
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Azure Sphere Starter Kit to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Verified Answer
  • Replies 15 replies
  • Answers 6 answers
  • Subscribers 48 subscribers
  • Views 1581 views
  • Users 0 members are here
  • azure sphere
Related

Can I use SCP to move a file into Azure Sphere?

clem57
clem57 over 6 years ago

I am wishing to move a configuration file for Azure Sphere. Naturally SCP over SSH would work nicely. Can anyone direct me to a solution? I will have to modify the file sometimes depending on the layout of the equipment in use.

 

Thanks.

  • Sign in to reply
  • Cancel

Top Replies

  • bwilless
    bwilless over 6 years ago +3 suggested
    There are a few ways to move configuration data to a Sphere device . . . If you only need to operate on one or two devices you could use a Direct Method call to send down a JSON object with your configuration…
  • wizio
    wizio over 6 years ago in reply to bwilless +3
    4. simple curl download
  • wizio
    wizio over 6 years ago in reply to clem57 +2 suggested
    File System is real but is controled ( firewall ) from Pluton subsytem ... I dont know ( for now ) how to write file ... Pluton is as "dongle" ... hardware "sudo" There is MutableStorage for user ( not…
Parents
  • wizio
    0 wizio over 6 years ago

    Just hint: app_manifest.json can be used as read-only setting file

    see: my ... var_1 ....

    {
        "Name": "", 
        "Capabilities": {
            "Uart": ["$AVNET_AESMS_ISU0_UART"], 
            "AllowedConnections": []
        }, 
        "CmdArgs": [], 
        "EntryPoint": "", 
        "SchemaVersion": 1, 
        "ComponentId": "9FAFA94E-3CFA-4B1D-8A13-50B82539A9B7",
        "my" : {
          "var_1" : "1",
          "var_2" : "2",
          "var_3" : "3"
        }
    }

    as example

    #include <applibs/storage.h>

     


    void foo(){

      int fd = Storage_OpenFileInImagePackage("app_manifest.json");

      char json_buffer[1024];

      read(fd, json_buffer, sizeof(json_buffer));

      //PARSE JSON VARIABLES

      close(fd);

    }

     

    the real file name is: /mnt/apps/GUID_FROM_APP_MANIFEST/app_manifest.json

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • clem57
    0 clem57 over 6 years ago in reply to wizio

    I wish to detach the settings from the code because the code is generic and the data is specific to the device. But I can see usefulness in this sample.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • wizio
    0 wizio over 6 years ago in reply to clem57

    app_manifest.json is specific for "this" application only

     

    app container is:

    /mnt ...../GUID/app_manifest.json

    /mnt ...../GUID/packed_files...

    /mnt ...../GUID/bin/application

    Storage_GetAbsolutePathInImagePackage() return path from this container ( print result )

     

    other GUID is other container ( app )

     

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • bwilless
    0 bwilless over 5 years ago in reply to wizio

    I'm not sure I see any advantage to using the app_manifest.json file to define application settings.  You can do this, but the only way to change them in the field is to upload a new application to AS3 and push the changes down with an OTA update.  This would be similar to using constants in your application. 

     

    If you use device twins, or Direct Methods for configuration data you have a flexible implementation that does not require a new application build and you can push different values down for each device. 

     

    My 2 cents . . .

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Reply
  • bwilless
    0 bwilless over 5 years ago in reply to wizio

    I'm not sure I see any advantage to using the app_manifest.json file to define application settings.  You can do this, but the only way to change them in the field is to upload a new application to AS3 and push the changes down with an OTA update.  This would be similar to using constants in your application. 

     

    If you use device twins, or Direct Methods for configuration data you have a flexible implementation that does not require a new application build and you can push different values down for each device. 

     

    My 2 cents . . .

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Children
  • wizio
    0 wizio over 5 years ago in reply to bwilless

    yep ... it is app constants

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube