Schlagwort: CLI

  • Arduino CLI 1.0 is out!

    Arduino CLI 1.0 is out!

    Reading Time: 2 minutes

    We are excited to share some incredible news with you all! We recently released the Arduino CLI version 1.0.0, marking a significant milestone for our software. This release is a big deal because it signifies the stabilization of the software API, bringing greater reliability and predictability to our users and developers leveraging it in their projects.

    The Arduino CLI offers multiple ways to integrate and utilize its capabilities:

    • Command line interface: The most straightforward way to use Arduino CLI is through its command line interface. This allows you to manage boards, libraries, compile sketches, and upload code to your Arduino boards with ease.
    • gRPC interface: For more advanced use cases, the Arduino CLI provides a gRPC interface. This enables developers to interact with the CLI using their preferred programming language, allowing for the creation of custom applications and services that leverage the full functionality of the Arduino ecosystem. The gRPC interface is particularly useful for building complex workflows and creating custom IDEs or plug-ins.
    • Go module: You can also use Arduino CLI’s packages within your own applications written in the Go programming language. By importing the source code, you can embed the functionality of the Arduino CLI directly into your projects. This approach is beneficial for developers who want to integrate the tool seamlessly into their own software.

    You can find more information about the different ways the Arduino CLI can be integrated in your software in the official documentation.

    It’s been almost two months since the release of version 1.0.0, and we are now at version 1.0.4. In this short time, we have been working hard to address issues, fix bugs, and enhance the software. We are committed to delivering the best possible experience for our users, and each new version brings us closer to that goal.

    For a comprehensive overview of the features included in Arduino CLI version 1.0.0, please refer to the official release notes. This list details all the enhancements, improvements, and new functionalities that make this release a significant step forward for our community.

    To minimize the impact on our users, we accumulated almost all of the breaking changes for the 1.0.0 release, allowing us to clean up early design errors and other issues in one major event. From now on, our backward compatibility policy is designed to ensure stability and predictability for our community, specifically for the Arduino CLI. For more details about this policy, you can refer to the relevant documentation.

    As we continue to build upon this foundation, we are looking forward to delivering even more improvements and new features in future releases. Thank you to our amazing community for your support and feedback – we couldn’t have reached this milestone without you. Stay tuned for future updates, and thank you for being part of this journey! 

    The post Arduino CLI 1.0 is out! appeared first on Arduino Blog.

    Website: LINK

  • Mass scale with the new Arduino Cloud CLI

    Mass scale with the new Arduino Cloud CLI

    Reading Time: 4 minutes

    The Arduino IoT Cloud enables makers, IoT enthusiasts and professionals to build easily connected projects based on a wide range of Arduino, ESP32, and ESP8266 boards.

    Following Arduino’s vision, it has been carefully designed to provide the most user-friendly and intuitive experience, abstracting the complex tasks that create barriers for users who are not familiar with coding. Some of the features include:

    • Easy onboarding that will automatically generate a sketch layout when setting up a new device so you can edit it right away and quickly go from unboxing to building your project.
    • Building rich and customizable dashboards to visualize your device’s status and data, accessible remotely via a native mobile App and your web space
    • Keeping your devices up-to-date with secure remote OTA updates
    • Storing historical data
    • Automagically” syncing variables between multiple devices
    • Integration with 3rd party platforms like Alexa or IFTTT

    The intuitive and user-friendly web interface is a major factor of Arduino IoT Cloud’s popularity. It simply makes it easy to get started for a great variety of users, from the ones with no prior coding experience to those who are expert Arduino users.

    Introducing a new alternative IoT Cloud experience

    Alternatively, it is possible to interact with the Cloud via the API. This method is mainly used for integration with other platforms, applications or web pages.

    The interaction with the cloud is now complemented with a new Cloud CLI that provides a tool to execute scripted operations on Arduino Cloud, and satisfy use cases like massive device provisioning. As it empowers users to access the major features of Arduino IoT Cloud from a terminal, it is also a long-time demanded feature for skilled users.

    With the new Cloud CLI, the Arduino IoT Cloud has a full suite of tools available for every kind of user.

    All your favorite IoT Cloud actions available on your terminal

    With the new Cloud CLI tool it is possible to perform most of the tasks that can be done using the web interface.

    The Cloud CLI needs a credentials file containing an Arduino IoT Cloud client ID and its corresponding secret. Credentials can also include an optional organisation ID that specifies the organisation to use. These credentials can be retrieved from the cloud by creating a new API key.

    Devices and things can be created, deleted and listed. Things can be bound to devices. In a very similar way it is possible to manage the dashboards.

    OTA firmware updates can also be performed with the ability to defer the update up to one week. It is also possible to perform a mass OTA upload through a specific command.

    One of the key features is the ability to download in different text formats (JSON, YAML, …) the templates of the dashboards, devices and things, so that you can keep them for future use. It is very useful to modify them to create copies of the entities with some properties changed and upload the new templates to the Cloud.

    Mass scale provisioning journey

    The Cloud CLI is a tool that can be integrated easily in scripts and so, it is well-suited for scenarios where mass scale and automated actions are needed.

    The typical journey would consist of the following phases.

    Phase 1: Prototyping

    The user journey starts creating a first prototype of a Thing and a Sketch code that resolves the use case. This activity can be done using IoT Cloud web application, or even editing the Sketch in online Editor or offline Arduino IDE.:

    Phase 2: Factory provisioning

    At this point, the user can replicate the entire configuration of the “prototype” thing on many other devices, going through provisioning and connecting all of those to the cloud. In this phase, using Cloud CLI it’s possible to streamline the provisioning process and even to hook it to automation scripts. 

    Phase 3: Production update

    During the normal life of a thing on the field, it is very typical to need to update the firmware remotely. With Cloud CLI, it is possible to update devices individually, but also many devices with a single  command. Updates can be deferred if needed.

    Phase 4: Dashboards (optional)

    Dashboard creation would be the last optional step. The goal is to create custom dashboards that help us manage and monitor the deployed devices. Once the first dashboard is created in phase 1, it’s easy to replicate it for multiple devices with Cloud CLI.

    Try it now

    Download and get started with the Cloud CLI and associated documentation.

    Website: LINK

  • Arduino CLI 0.23 makes your projects future-proof with Build Profiles

    Arduino CLI 0.23 makes your projects future-proof with Build Profiles

    Reading Time: 4 minutes
    Arduino CLI build profiles

    This new release of Arduino CLI delivers more than the usual bug fixes and performance enhancements. Today we’re delighted to bring you Build Profiles. These have been long in the works and we kept it a bit hush-hush despite releasing a public RFC a bit shy of a year ago.

    Build Profiles

    Sometimes Arduino users end up not being able to build and upload a Sketch after the project is completed, and this might be due to libraries changing an API, or cores having deprecated some parts in favor of a more modern approach.

    Legacy is the enemy of progress, and sometimes developers need to rip the band-aid off and break things. We see this all the time.

    Build Profiles aim at fixing this, and allow users of Arduino CLI to define a configuration file which contains the exact version of platforms and libraries to use, ensuring the project can be built at any time in the future.

    This relies on the libraries being part of the Arduino Library Registry and the platforms to be source-able by the Arduino CLI. All platforms developed by Arduino are available by default, but users can add additional URLs to their configuration and make sure the required platform can always be found and installed.

    For detailed documentation, take a look at the official Arduino CLI docs on GitHub. But let’s take a closer look at how it works so you can get started making your Arduino project future-proof.

    Arduino CLI 0.23

    How does this work?

    Let’s assume you have an Arduino IoT Cloud project running on an Arduino Nano RP2040 Connect that is based on the following:

    • Platform: Arduino Mbed OS Nano Boards 3.1.1
    • Libraries:
      • ArduinoIoTCloud 1.6.0
      • Arduino_ConnectionHandler 0.6.6
      • WiFiNINA 1.8.13
      • Arduino_DebugUtils 1.1.0
      • ArduinoECCX08 1.3.6
      • ArduinoMqttClient 0.1.5

    Your project will compile successfully, but what about five years from now?

    Libraries get updated. That’s the beauty of the open source philosophy that has made Arduino so popular and the same happens with platforms.

    Any dependency might discontinue an API or introduce other kinds of breaking changes, and your sketch may no longer compile. At that point, you won’t be able to upload it to a board.

    We can finally address this shortcoming by creating a Build Profile for the future.

    Let’s learn how to generate one and use it when the day comes.

    To create a Build Profile we need to know which libraries and platforms are used during compilation,, and such dependencies can be made available to the user when compiling using `arduino-cli` and adding `–dump-profile` to the `compile` command as follows.

    `arduino-cli compile -b arduino:mbed_nano:nanorp2040connect --dump-profile`

    Core platforms and libraries used during the build will be listed in the report at the end of the operation, and can be copied and saved into your Build Profile, but in the future you will be able to directly create a Profile entry from a `compile` directive so the leg work will not be required.

    Note that multiple profile configurations can be entered into the Build Profile and used at a later time.

    The output will look something like this.

    ```
    arduino-cli compile -b arduino:mbed_nano:nanorp2040connect --dump-profile Sketch uses 387234 bytes (2%) of program storage space. Maximum is 16777216 bytes.
    Global variables use 68868 bytes (25%) of dynamic memory, leaving 201468 bytes for local variables. Maximum is 270336 bytes. profile: nanorp2040connect: fqbn: arduino:mbed_nano:nanorp2040connect platforms: - platform: arduino:mbed_nano (3.0.1) libraries: - ArduinoIoTCloud (1.6.0) - Arduino_ConnectionHandler (0.6.6) - WiFiNINA (1.8.13) - Arduino_DebugUtils (1.1.0) - ArduinoECCX08 (1.3.6) - ArduinoMqttClient (0.1.5) ```

    Followed by a full report of dependencies and their paths on your system, which we will ignore in this guide.

    Creating a Build Profile

    Using the information above we can create a file named `sketch.yaml` and add the following content to it.

    ```
    profile: nanorp2040connect: fqbn: arduino:mbed_nano:nanorp2040connect platforms: - platform: arduino:mbed_nano (3.0.1) libraries: - ArduinoIoTCloud (1.6.0) - Arduino_ConnectionHandler (0.6.6) - WiFiNINA (1.8.13) - Arduino_DebugUtils (1.1.0) - ArduinoECCX08 (1.3.6) - ArduinoMqttClient (0.1.5) ```

    We can now rely on this file to compile our project even if we don’t have any of the libraries or the Mbed core installed by doing as follows:

    `arduino-cli compile --profile nanorp2040connect`

    This command will install the appropriate platforms and libraries and proceed to build your sketch into a working firmware for your board.

    You can add multiple profiles in the Project file and build with different versions of a platform or any library.

    When you store or distribute your sketch make sure your `sketch.yaml` file is also part of the archive, and you can have the sketch compiled cleanly at any time in the future. 

    No, we can’t do anything about the past, but you can spend some time upgrading your old projects and creating their own `sketch.yaml` file, which will make your work future-proof.

    Sit back, relax and watch out for Terminators coming back to hunt you down.

    Website: LINK

  • Top 10 Arduino blog posts of 2021

    Top 10 Arduino blog posts of 2021

    Reading Time: 4 minutes

    Arduino TeamDecember 31st, 2021

    To say it’s been another challenging year would be an understatement, but it’s reassuring to see that the top 10 Arduino blog posts of 2021 show us that makers have persevered, undaunted.

    As we sprint headlong into 2022 with hope for a return to normality (whatever that might actually look like!) we wanted to cast an eye back over the Arduino blog. These are the top posts from 2021, which prove that you can’t keep good maker down.

    The Arduino community has been creating some of the best projects we’ve ever seen. It’s also exciting to note that it’s been another year when newcomers have taken up the electronics hobby. The presence of Arduino software posts in our top 10 Arduino blog posts of ‘21 suggests lots of people have been getting into the Arduino scene.

    Learn how to build your own massive 3D-printed CNC router

    If you want an affordable option, this guide shows you how to build Ivan Miranda’s 3D-printed CNC machine design.

    Announcing the Arduino IDE 2.0 (beta)

    It was a great day when the famous Arduino IDE reached version 2.0 in March of 2021.

    Hacking a USB battery bank to gather telemetry

    Keenan Johnson needed more info for a new project and so he hacked a USB battery bank to gather telemetry.

    The new Arduino CLI 0.19.0 is out and better than ever!

    This release delivered tons of great enhancements, exciting new features and heaps of bug fixes.

    Arduino MKR IoT Carrier: Control what you want, how you want to!

    By popular demand, we were pleased to announce in early 2021 that it’s possible to buy the Arduino MKR IoT Carrier.

    Cascading LED stair lights prevent late night tumbles

    Stephen Gidge and his roommate could have installed a new hall light, but they were both experienced with Arduino and so they created these cascading LED star lights instead.

    One board to rule them all: History of the Arduino UNO

    With the UNO Mini Limited Edition flying off the shelves, we took a heartfelt look at the history of its inspiration, the ubiquitous UNO.

    The Arduino Nano RP2040 Connect is here

    The first Arduino board to include Raspberry Pi silicon arrived in 2021, to much fanfare.

    Arduino Cloud now supports ESP32 devices

    Support for ESP32 devices (on top of existing support for ESP8266) became available on the Arduino IoT Cloud in May, 2021. A huge step forward in bringing IoT devices of all kinds together.

    Introducing the Arduino UNO Mini Limited Edition: Pre-orders now open

    Even though it only launched a couple of weeks ago, the Arduino UNO Mini Limited Edition announcement is one of the most viewed pages this year.

    Happy New Year from all of us at Arduino!

    Website: LINK

  • The new Arduino CLI 0.19.0 is out and better than ever!

    The new Arduino CLI 0.19.0 is out and better than ever!

    Reading Time: 2 minutes

    Arduino TeamSeptember 2nd, 2021

    There’s a truckload of news from the Arduino Tooling Team today: Arduino CLI 0.19.0 is now available! This release has tons of great enhancements, exciting new features and heaps of bug fixes. Some things required quite a bit of breaking changes but they’re worth the hassle.

    The highlights of this release are certainly the addition of pluggable discovery and the internal restructuring of the startup steps of the Arduino CLI. These affected the JSON output of some commands and the gRPC interface functions, which is documented in the upgrading guide.

    We’re really excited about the release of the pluggable discovery. This new feature will give platform developers the possibility to support more and more boards (such as the Teensy), and also new ways of uploading to boards, like via WiFi, Bluetooth, SSH, CAN bus and anything that comes to mind! If you’re a platform developer and want to know how to start supporting pluggable discovery take a look at the updated platform specification documentation.

    The internal restructuring is also no small thing, it makes the Arduino CLI much more resilient to errors. For example, if the user added an invalid or unreachable package index URL, Arduino CLI would previously be completely unusable. After this change, a warning is shown to notify the user of that failure and other functionality of Arduino CLI is unaffected. And last but not least this change greatly improves other tools as well, in some tests we managed to slice in half the startup time of the Arduino IDE 2.0!

    There are some breaking changes that only affect those that use the Arduino CLI code as a Go library. These were the result of improvements to the internal structures that store information about Sketches, and to the support for different languages. 

    As always, all breaking changes are documented in the upgrading guide. You will find the complete changelog here!

    Website: LINK

  • New workflow for Arduino library submissions

    New workflow for Arduino library submissions

    Reading Time: 2 minutes

    Arduino TeamJune 7th, 2021

    Arduino Libraries Submissions process update

    Arduino library submissions have a new, easier and more transparent workflow.

    Libraries are one of the pillars of the Arduino ecosystem. At time of writing, more than 3,780 open source libraries are available to perform any kind of task. This includes communication with external components and using algorithms for data processing. Such a variety of shared building blocks helps achieve things quickly without the need to write low-level code.

    Beyond the official libraries maintained by the Arduino team, most are contributed by the community. Anyone can submit a new library for inclusion, provided it meets the specification and passes the Arduino Lint checks.

    Note: Did you know you can run the tool locally to check the compliance status of your current libraries?

    A new Arduino library submissions process

    We’re happy to announce that the submission process for community libraries has been refactored. The goal is making it leaner, more automated and more transparent. Previously you would open an issue on the Arduino IDE repository for the Arduino team to handle the request manually. Instead, we’ve now established an official GitHub repository containing the library registry.

    Submitting a new library is now as simple as opening a pull request to that repository. Then you add the URL of the library’s repository to the list. A bot performs automated checks and, when passed, the request will be merged immediately. Within one day, the new library will be listed in the Arduino library directory. It’ll also be made available within the IDE, the Arduino CLI command line tool and the Web Editor. The Arduino team will still be monitoring the process in order to fight abuses and to provide assistance.

    After a library is indexed, new versions are automatically detected and published (if compliant). So nothing changes for existing libraries and no action is required. See the repository documentation for more details about the new process and join the discussion in the forum to provide your feedback.

    Subscribe to the Arduino newsletter so you don’t miss any other exciting developments!

    Website: LINK

  • Arduino CLI 0.16.0 is ready for you all!

    Arduino CLI 0.16.0 is ready for you all!

    Reading Time: < 1 minute

    Arduino CLI 0.16.0 is ready for you all!

    Arduino TeamFebruary 15th, 2021

    This article was written by Silvano Cerza from the Arduino Tooling Team.

    Big news from the Arduino Tooling team: The new Arduino CLI version 0.16.0 has been released!

    You can now use arduino-cli core list –all to return all installed and installable platforms, including those installed manually in the Sketchbook hardware folder.

    We also have a breaking change to mention:

    7e1ff323 [breaking] Fix export binaries binding not working in gRPC interface (#1171)

    It’s in the CLI gRPC interface, so command line users should not be affected! You will find all the details in our handy upgrading guide.

    You can see the complete changelog here.

    Website: LINK

  • Hands-on with the Arduino CLI!

    Hands-on with the Arduino CLI!

    Reading Time: < 1 minute

    Hands-on with the Arduino CLI!

    Arduino TeamApril 23rd, 2020

    In our last post, we told you that the Arduino CLI’s primary goal is to provide a flexible yet simple command line tool with all the features and ease of use that made Arduino a successful platform, and enable users to find new ways of improving their workflows. 

    The Arduino CLI is not just a command line tool, but contains all you need to build applications around the Arduino ecosystem.

    For example, you can:

    • Parse the JSON output of the CLI and easily integrate it into your custom application.
    • Run the CLI as an always-on service that accepts commands via a gRPC interface using your language of choice.
    • Use the CLI in your Go application as a library.

    In the video below, we’ll focus on how to start using the Arduino CLI in a terminal session. The tutorial will walk you through setting up all the required tools on your machine to the fastest way to compile and upload a sketch on your target board to allow quick iterations in developing your project with Arduinos.

    [youtube https://www.youtube.com/watch?v=J-qGn1eEidA?feature=oembed&w=500&h=281]

    Website: LINK