Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Getting started with Udoo
  • Table Of Contents Toc
  • Feedback & Rating feedback
Getting started with Udoo

Getting started with Udoo

By : Emanuele Palazzetti
4.8 (4)
close
close
Getting started with Udoo

Getting started with Udoo

4.8 (4)
By: Emanuele Palazzetti

Overview of this book

If you are an Android developer who wants to learn how to use UDOO to build Android applications that are capable of interacting with their surrounding environment, then this book is ideal for you. Learning UDOO is the next great step to start building your first real-world prototypes powered by the Android operating system.
Table of Contents (10 chapters)
close
close
9
Index

Improving the boiler with an antifreeze check


Now that the forecast fetching is up and running, we can proceed with implementing the antifreeze feature. To achieve the interaction and the logic previously discussed, we should:

  1. Enhance the Preset class storing the user's antifreeze setpoint. In this class, we should provide two utilities to disable the antifreeze check and to find out whether the feature is enabled or not.

  2. Handle the antifreeze feature in the Overview activity, updating the user interface when a setpoint is selected.

  3. Update the boiler logic in the SensorThread class so it takes into account the antifreeze check when it's enabled.

We begin our work by changing the Preset class with the following steps:

  1. At the top of the class, add the highlighted declarations:

    private static final String CURRENT_LOCATION = "__LOCATION__";
    private static final String CURRENT_ANTIFREEZE = "__ANTIFREEZE__";
    private static final float ANTIFREEZE_DISABLED = -Float.MAX_VALUE
    

    We use the ANTIFREEZE_DISABLED...

Visually different images
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Getting started with Udoo
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon