Merge branch 'dev' of github.com:MilosKozak/AndroidAPS into update-oref

This commit is contained in:
Tim Gunn 2019-09-07 10:46:19 +12:00
commit b231903c2e
69 changed files with 1667 additions and 957 deletions

View file

@ -1,14 +1,10 @@
package info.nightscout.androidaps;
import android.app.Application;
import android.bluetooth.BluetoothAdapter;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.res.Resources;
import android.os.SystemClock;
import android.util.Log;
import androidx.annotation.Nullable;
import androidx.annotation.PluralsRes;
@ -44,7 +40,7 @@ import info.nightscout.androidaps.plugins.constraints.dstHelper.DstHelperPlugin;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.constraints.safety.SafetyPlugin;
import info.nightscout.androidaps.plugins.constraints.storage.StorageConstraintPlugin;
import info.nightscout.androidaps.plugins.general.actions.ActionsFragment;
import info.nightscout.androidaps.plugins.general.actions.ActionsPlugin;
import info.nightscout.androidaps.plugins.general.automation.AutomationPlugin;
import info.nightscout.androidaps.plugins.general.careportal.CareportalPlugin;
import info.nightscout.androidaps.plugins.general.food.FoodPlugin;
@ -70,8 +66,6 @@ import info.nightscout.androidaps.plugins.profile.local.LocalProfilePlugin;
import info.nightscout.androidaps.plugins.profile.ns.NSProfilePlugin;
import info.nightscout.androidaps.plugins.profile.simple.SimpleProfilePlugin;
import info.nightscout.androidaps.plugins.pump.combo.ComboPlugin;
import info.nightscout.androidaps.plugins.pump.common.hw.rileylink.RileyLinkConst;
import info.nightscout.androidaps.plugins.pump.common.hw.rileylink.RileyLinkUtil;
import info.nightscout.androidaps.plugins.pump.danaR.DanaRPlugin;
import info.nightscout.androidaps.plugins.pump.danaRKorean.DanaRKoreanPlugin;
import info.nightscout.androidaps.plugins.pump.danaRS.DanaRSPlugin;
@ -177,7 +171,7 @@ public class MainApp extends Application {
// Register all tabs in app here
pluginsList.add(OverviewPlugin.getPlugin());
pluginsList.add(IobCobCalculatorPlugin.getPlugin());
if (Config.ACTION) pluginsList.add(ActionsFragment.getPlugin());
if (Config.ACTION) pluginsList.add(ActionsPlugin.INSTANCE);
pluginsList.add(InsulinOrefRapidActingPlugin.getPlugin());
pluginsList.add(InsulinOrefUltraRapidActingPlugin.getPlugin());
pluginsList.add(InsulinOrefFreePeakPlugin.getPlugin());
@ -208,7 +202,7 @@ public class MainApp extends Application {
if (Config.SAFETY) pluginsList.add(VersionCheckerPlugin.INSTANCE);
if (Config.SAFETY) pluginsList.add(StorageConstraintPlugin.getPlugin());
if (Config.SAFETY) pluginsList.add(SignatureVerifier.getPlugin());
if (Config.APS) pluginsList.add(ObjectivesPlugin.getPlugin());
if (Config.APS) pluginsList.add(ObjectivesPlugin.INSTANCE);
pluginsList.add(SourceXdripPlugin.getPlugin());
pluginsList.add(SourceNSClientPlugin.getPlugin());
pluginsList.add(SourceMM640gPlugin.getPlugin());

View file

@ -11,6 +11,7 @@ import org.slf4j.LoggerFactory;
import java.text.DecimalFormat;
import java.util.TimeZone;
import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
@ -227,8 +228,10 @@ public class Profile {
for (int index = 0; index < basal_v.size(); index++) {
long secondsFromMidnight = basal_v.keyAt(index);
if (notify && secondsFromMidnight % 3600 != 0) {
Notification notification = new Notification(Notification.BASAL_PROFILE_NOT_ALIGNED_TO_HOURS, String.format(MainApp.gs(R.string.basalprofilenotaligned), from), Notification.NORMAL);
MainApp.bus().post(new EventNewNotification(notification));
if (Config.APS) {
Notification notification = new Notification(Notification.BASAL_PROFILE_NOT_ALIGNED_TO_HOURS, String.format(MainApp.gs(R.string.basalprofilenotaligned), from), Notification.NORMAL);
MainApp.bus().post(new EventNewNotification(notification));
}
}
}
}

View file

@ -12,10 +12,7 @@ import info.nightscout.androidaps.interfaces.Constraint
import info.nightscout.androidaps.plugins.aps.loop.events.EventLoopSetLastRunGui
import info.nightscout.androidaps.plugins.aps.loop.events.EventLoopUpdateGui
import info.nightscout.androidaps.plugins.bus.RxBus
import info.nightscout.androidaps.utils.DateUtil
import info.nightscout.androidaps.utils.FabricPrivacy
import info.nightscout.androidaps.utils.HtmlHelper
import info.nightscout.androidaps.utils.plusAssign
import info.nightscout.androidaps.utils.*
import io.reactivex.android.schedulers.AndroidSchedulers
import io.reactivex.disposables.CompositeDisposable
import kotlinx.android.synthetic.main.loop_fragment.*
@ -61,6 +58,7 @@ class LoopFragment : Fragment() {
})
updateGUI()
SP.putBoolean(R.string.key_objectiveuseloop, true)
}
@Synchronized

View file

@ -51,7 +51,6 @@ import info.nightscout.androidaps.plugins.aps.loop.events.EventNewOpenLoopNotifi
import info.nightscout.androidaps.plugins.bus.RxBus;
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin;
import info.nightscout.androidaps.plugins.configBuilder.ProfileFunctions;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.general.nsclient.NSUpload;
import info.nightscout.androidaps.plugins.general.wear.ActionStringHandler;
import info.nightscout.androidaps.plugins.iob.iobCobCalculator.events.EventAutosensCalculationFinished;
@ -471,11 +470,7 @@ public class LoopPlugin extends PluginBase {
lastRun.lastEnact = new Date();
lastRun.lastOpenModeAccept = new Date();
NSUpload.uploadDeviceStatus();
ObjectivesPlugin objectivesPlugin = MainApp.getSpecificPlugin(ObjectivesPlugin.class);
if (objectivesPlugin != null) {
ObjectivesPlugin.getPlugin().manualEnacts++;
ObjectivesPlugin.getPlugin().saveProgress();
}
SP.incInt(R.string.key_ObjectivesmanualEnacts);
}
MainApp.bus().post(new EventAcceptOpenLoopChange());
}

View file

@ -27,6 +27,7 @@ import info.nightscout.androidaps.plugins.general.overview.dialogs.ErrorHelperAc
import info.nightscout.androidaps.plugins.treatments.TreatmentsPlugin;
import info.nightscout.androidaps.queue.Callback;
import info.nightscout.androidaps.utils.FabricPrivacy;
import info.nightscout.androidaps.utils.SP;
public class ProfileFunctions {
private static Logger log = LoggerFactory.getLogger(L.PROFILE);
@ -159,6 +160,8 @@ public class ProfileFunctions {
public static void doProfileSwitch(final ProfileStore profileStore, final String profileName, final int duration, final int percentage, final int timeshift) {
ProfileSwitch profileSwitch = prepareProfileSwitch(profileStore, profileName, duration, percentage, timeshift, System.currentTimeMillis());
TreatmentsPlugin.getPlugin().addToHistoryProfileSwitch(profileSwitch);
if (percentage == 90 && duration == 10)
SP.putBoolean(R.string.key_objectiveuseprofileswitch, true);
}
public static void doProfileSwitch(final int duration, final int percentage, final int timeshift) {

View file

@ -1,229 +0,0 @@
package info.nightscout.androidaps.plugins.constraints.objectives;
import android.app.Activity;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import androidx.annotation.NonNull;
import androidx.cardview.widget.CardView;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.LinearSmoothScroller;
import androidx.recyclerview.widget.RecyclerView;
import android.text.Html;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.LinearLayout;
import android.widget.TextView;
import java.util.Date;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.plugins.common.SubscriberFragment;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective;
import info.nightscout.androidaps.utils.FabricPrivacy;
public class ObjectivesFragment extends SubscriberFragment {
RecyclerView recyclerView;
CheckBox enableFake;
TextView reset;
ObjectivesAdapter objectivesAdapter = new ObjectivesAdapter();
Handler handler = new Handler(Looper.getMainLooper());
private Runnable objectiveUpdater = new Runnable() {
@Override
public void run() {
handler.postDelayed(this, 60 * 1000);
updateGUI();
}
};
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
try {
View view = inflater.inflate(R.layout.objectives_fragment, container, false);
recyclerView = view.findViewById(R.id.objectives_recyclerview);
recyclerView.setLayoutManager(new LinearLayoutManager(view.getContext()));
recyclerView.setAdapter(objectivesAdapter);
enableFake = view.findViewById(R.id.objectives_fake);
reset = view.findViewById(R.id.objectives_reset);
enableFake.setOnClickListener(v -> updateGUI());
reset.setOnClickListener(v -> {
ObjectivesPlugin.getPlugin().reset();
ObjectivesPlugin.getPlugin().saveProgress();
recyclerView.getAdapter().notifyDataSetChanged();
scrollToCurrentObjective();
});
scrollToCurrentObjective();
startUpdateTimer();
return view;
} catch (Exception e) {
FabricPrivacy.logException(e);
}
return null;
}
@Override
public synchronized void onDestroyView() {
super.onDestroyView();
handler.removeCallbacks(objectiveUpdater);
}
private void startUpdateTimer() {
handler.removeCallbacks(objectiveUpdater);
for (Objective objective : ObjectivesPlugin.getPlugin().getObjectives()) {
if (objective.isStarted() && !objective.isAccomplished()) {
long timeTillNextMinute = (System.currentTimeMillis() - objective.getStartedOn().getTime()) % (60 * 1000);
handler.postDelayed(objectiveUpdater, timeTillNextMinute);
break;
}
}
}
private void scrollToCurrentObjective() {
for (int i = 0; i < ObjectivesPlugin.getPlugin().getObjectives().size(); i++) {
Objective objective = ObjectivesPlugin.getPlugin().getObjectives().get(i);
if (!objective.isStarted() || !objective.isAccomplished()) {
RecyclerView.SmoothScroller smoothScroller = new LinearSmoothScroller(getContext()) {
@Override
protected int getVerticalSnapPreference() {
return LinearSmoothScroller.SNAP_TO_START;
}
@Override
protected int calculateTimeForScrolling(int dx) {
return super.calculateTimeForScrolling(dx) * 4;
}
};
smoothScroller.setTargetPosition(i);
recyclerView.getLayoutManager().startSmoothScroll(smoothScroller);
break;
}
}
}
private class ObjectivesAdapter extends RecyclerView.Adapter<ObjectivesAdapter.ViewHolder> {
@NonNull
@Override
public ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
return new ViewHolder(LayoutInflater.from(parent.getContext()).inflate(R.layout.objectives_item, parent, false));
}
@Override
public void onBindViewHolder(@NonNull ViewHolder holder, int position) {
Objective objective = ObjectivesPlugin.getPlugin().getObjectives().get(position);
holder.title.setText(MainApp.gs(R.string.nth_objective, position + 1));
holder.revert.setVisibility(View.INVISIBLE);
if (objective.getObjective() != 0) {
holder.objective.setVisibility(View.VISIBLE);
holder.objective.setText(MainApp.gs(objective.getObjective()));
} else holder.objective.setVisibility(View.GONE);
if (objective.getGate() != 0) {
holder.gate.setVisibility(View.VISIBLE);
holder.gate.setText(MainApp.gs(objective.getGate()));
} else holder.gate.setVisibility(View.GONE);
if (!objective.isStarted()) {
holder.gate.setTextColor(0xFFFFFFFF);
holder.verify.setVisibility(View.GONE);
holder.progress.setVisibility(View.GONE);
if (position == 0 || ObjectivesPlugin.getPlugin().getObjectives().get(position - 1).isAccomplished())
holder.start.setVisibility(View.VISIBLE);
else holder.start.setVisibility(View.GONE);
} else if (objective.isAccomplished()) {
holder.gate.setTextColor(0xFF4CAF50);
holder.verify.setVisibility(View.GONE);
holder.progress.setVisibility(View.GONE);
holder.start.setVisibility(View.GONE);
} else if (objective.isStarted()) {
holder.gate.setTextColor(0xFFFFFFFF);
holder.verify.setVisibility(View.VISIBLE);
holder.verify.setEnabled(objective.isCompleted() || enableFake.isChecked());
holder.start.setVisibility(View.GONE);
if(objective.isRevertable()) {
holder.revert.setVisibility(View.VISIBLE);
}
holder.progress.setVisibility(View.VISIBLE);
holder.progress.removeAllViews();
for (Objective.Task task : objective.getTasks()) {
if (task.shouldBeIgnored()) continue;
TextView textView = new TextView(holder.progress.getContext());
textView.setTextColor(0xFFFFFFFF);
String basicHTML = "%2$s: <font color=\"%1$s\"><b>%3$s</b></font>";
String formattedHTML = String.format(basicHTML, task.isCompleted() ? "#4CAF50" : "#FF9800", MainApp.gs(task.getTask()), task.getProgress());
textView.setText(Html.fromHtml(formattedHTML));
holder.progress.addView(textView, LinearLayout.LayoutParams.WRAP_CONTENT, LinearLayout.LayoutParams.WRAP_CONTENT);
}
}
holder.verify.setOnClickListener((view) -> {
objective.setAccomplishedOn(new Date());
notifyDataSetChanged();
scrollToCurrentObjective();
startUpdateTimer();
});
holder.start.setOnClickListener((view) -> {
objective.setStartedOn(new Date());
notifyDataSetChanged();
scrollToCurrentObjective();
startUpdateTimer();
});
holder.revert.setOnClickListener((view) -> {
objective.setAccomplishedOn(null);
objective.setStartedOn(null);
if (position > 0) {
Objective prevObj = ObjectivesPlugin.getPlugin().getObjectives().get(position - 1);
prevObj.setAccomplishedOn(null);
}
notifyDataSetChanged();
scrollToCurrentObjective();
});
}
@Override
public int getItemCount() {
return ObjectivesPlugin.getPlugin().getObjectives().size();
}
public class ViewHolder extends RecyclerView.ViewHolder {
public CardView cardView;
public TextView title;
public TextView objective;
public TextView gate;
public LinearLayout progress;
public Button verify;
public Button start;
public Button revert;
public ViewHolder(View itemView) {
super(itemView);
cardView = (CardView) itemView;
title = itemView.findViewById(R.id.objective_title);
objective = itemView.findViewById(R.id.objective_objective);
gate = itemView.findViewById(R.id.objective_gate);
progress = itemView.findViewById(R.id.objective_progress);
verify = itemView.findViewById(R.id.objective_verify);
start = itemView.findViewById(R.id.objective_start);
revert = itemView.findViewById(R.id.objective_back);
}
}
}
@Override
public void updateGUI() {
Activity activity = getActivity();
if (activity != null)
activity.runOnUiThread(() -> {
objectivesAdapter.notifyDataSetChanged();
});
}
}

View file

@ -0,0 +1,268 @@
package info.nightscout.androidaps.plugins.constraints.objectives
import android.graphics.Color
import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.view.Gravity
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.Button
import android.widget.EditText
import android.widget.LinearLayout
import android.widget.TextView
import androidx.fragment.app.Fragment
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.LinearSmoothScroller
import androidx.recyclerview.widget.RecyclerView
import info.nightscout.androidaps.MainApp
import info.nightscout.androidaps.R
import info.nightscout.androidaps.plugins.bus.RxBus
import info.nightscout.androidaps.plugins.constraints.objectives.activities.ObjectivesExamDialog
import info.nightscout.androidaps.plugins.constraints.objectives.events.EventObjectivesUpdateGui
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective.ExamTask
import info.nightscout.androidaps.utils.DateUtil
import info.nightscout.androidaps.utils.FabricPrivacy
import info.nightscout.androidaps.utils.HtmlHelper
import info.nightscout.androidaps.utils.SP
import io.reactivex.android.schedulers.AndroidSchedulers
import io.reactivex.disposables.CompositeDisposable
import kotlinx.android.synthetic.main.objectives_fragment.*
class ObjectivesFragment : Fragment() {
private val objectivesAdapter = ObjectivesAdapter()
private val handler = Handler(Looper.getMainLooper())
private var disposable: CompositeDisposable = CompositeDisposable()
private val objectiveUpdater = object : Runnable {
override fun run() {
handler.postDelayed(this, (60 * 1000).toLong())
updateGUI()
}
}
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?,
savedInstanceState: Bundle?): View? {
return inflater.inflate(R.layout.objectives_fragment, container, false)
}
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
objectives_recyclerview.layoutManager = LinearLayoutManager(view.context)
objectives_recyclerview.adapter = objectivesAdapter
objectives_fake.setOnClickListener { updateGUI() }
objectives_reset.setOnClickListener {
ObjectivesPlugin.reset()
objectives_recyclerview.adapter?.notifyDataSetChanged()
scrollToCurrentObjective()
}
scrollToCurrentObjective()
startUpdateTimer()
}
@Synchronized
override fun onResume() {
super.onResume()
disposable.add(RxBus
.toObservable(EventObjectivesUpdateGui::class.java)
.observeOn(AndroidSchedulers.mainThread())
.subscribe({
objectives_recyclerview.adapter?.notifyDataSetChanged()
}, {
FabricPrivacy.logException(it)
})
)
}
@Synchronized
override fun onPause() {
super.onPause()
disposable.clear()
}
@Synchronized
override fun onDestroyView() {
super.onDestroyView()
handler.removeCallbacks(objectiveUpdater)
}
private fun startUpdateTimer() {
handler.removeCallbacks(objectiveUpdater)
for (objective in ObjectivesPlugin.objectives) {
if (objective.isStarted && !objective.isAccomplished) {
val timeTillNextMinute = (System.currentTimeMillis() - objective.startedOn) % (60 * 1000)
handler.postDelayed(objectiveUpdater, timeTillNextMinute)
break
}
}
}
private fun scrollToCurrentObjective() {
for (i in 0 until ObjectivesPlugin.objectives.size) {
val objective = ObjectivesPlugin.objectives[i]
if (!objective.isStarted || !objective.isAccomplished) {
val smoothScroller = object : LinearSmoothScroller(context!!) {
override fun getVerticalSnapPreference(): Int {
return SNAP_TO_START
}
override fun calculateTimeForScrolling(dx: Int): Int {
return super.calculateTimeForScrolling(dx) * 4
}
}
smoothScroller.targetPosition = i
objectives_recyclerview.layoutManager?.startSmoothScroll(smoothScroller)
break
}
}
}
private inner class ObjectivesAdapter : RecyclerView.Adapter<ObjectivesAdapter.ViewHolder>() {
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ViewHolder {
return ViewHolder(LayoutInflater.from(parent.context).inflate(R.layout.objectives_item, parent, false))
}
override fun onBindViewHolder(holder: ViewHolder, position: Int) {
val objective = ObjectivesPlugin.objectives[position]
holder.title.text = MainApp.gs(R.string.nth_objective, position + 1)
holder.revert.visibility = View.GONE
if (objective.objective != 0) {
holder.objective.visibility = View.VISIBLE
holder.objective.text = MainApp.gs(objective.objective)
} else
holder.objective.visibility = View.GONE
if (objective.gate != 0) {
holder.gate.visibility = View.VISIBLE
holder.gate.text = MainApp.gs(objective.gate)
} else
holder.gate.visibility = View.GONE
if (!objective.isStarted) {
holder.gate.setTextColor(-0x1)
holder.verify.visibility = View.GONE
holder.progress.visibility = View.GONE
holder.accomplished.visibility = View.GONE
if (position == 0 || ObjectivesPlugin.objectives[position - 1].isAccomplished)
holder.start.visibility = View.VISIBLE
else
holder.start.visibility = View.GONE
} else if (objective.isAccomplished) {
holder.gate.setTextColor(-0xb350b0)
holder.verify.visibility = View.GONE
holder.progress.visibility = View.GONE
holder.start.visibility = View.GONE
holder.accomplished.visibility = View.VISIBLE
} else if (objective.isStarted) {
holder.gate.setTextColor(-0x1)
holder.verify.visibility = View.VISIBLE
holder.verify.isEnabled = objective.isCompleted || objectives_fake.isChecked
holder.start.visibility = View.GONE
holder.accomplished.visibility = View.GONE
if (objective.isRevertable) {
holder.revert.visibility = View.VISIBLE
}
holder.progress.visibility = View.VISIBLE
holder.progress.removeAllViews()
for (task in objective.tasks) {
if (task.shouldBeIgnored()) continue
val name = TextView(holder.progress.context)
name.text = MainApp.gs(task.task) + ":"
name.setTextColor(-0x1)
holder.progress.addView(name, LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT)
val state = TextView(holder.progress.context)
state.setTextColor(-0x1)
val basicHTML = "<font color=\"%1\$s\"><b>%2\$s</b></font>"
val formattedHTML = String.format(basicHTML, if (task.isCompleted) "#4CAF50" else "#FF9800", task.progress)
state.text = HtmlHelper.fromHtml(formattedHTML)
state.gravity = Gravity.END
holder.progress.addView(state, LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT)
if (task is ExamTask) {
state.setOnClickListener {
val dialog = ObjectivesExamDialog()
val bundle = Bundle()
val position = objective.tasks.indexOf(task)
bundle.putInt("currentTask", position)
dialog.arguments = bundle
ObjectivesExamDialog.objective = objective
fragmentManager?.let { dialog.show(it, "ObjectivesFragment") }
}
}
val separator = View(holder.progress.context)
separator.setBackgroundColor(Color.DKGRAY)
holder.progress.addView(separator, LinearLayout.LayoutParams.MATCH_PARENT, 2)
}
}
holder.accomplished.text = MainApp.gs(R.string.accomplished, DateUtil.dateAndTimeString(objective.accomplishedOn))
holder.accomplished.setTextColor(-0x3e3e3f)
holder.verify.setOnClickListener {
objective.accomplishedOn = DateUtil.now()
notifyDataSetChanged()
scrollToCurrentObjective()
startUpdateTimer()
}
holder.start.setOnClickListener {
objective.startedOn = DateUtil.now()
notifyDataSetChanged()
scrollToCurrentObjective()
startUpdateTimer()
}
holder.revert.setOnClickListener {
objective.accomplishedOn = 0
objective.startedOn = 0
if (position > 0) {
val prevObj = ObjectivesPlugin.objectives[position - 1]
prevObj.accomplishedOn = 0
}
notifyDataSetChanged()
scrollToCurrentObjective()
}
if (objective.hasSpecialInput && !objective.isAccomplished && objective.isStarted) {
// generate random request code if none exists
val request = SP.getString(R.string.key_objectives_request_code, String.format("%1$05d", (Math.random() * 99999).toInt()))
SP.putString(R.string.key_objectives_request_code, request)
holder.requestCode.text = MainApp.gs(R.string.requestcode, request)
holder.requestCode.visibility = View.VISIBLE
holder.enterButton.visibility = View.VISIBLE
holder.input.visibility = View.VISIBLE
holder.inputHint.visibility = View.VISIBLE
holder.enterButton.setOnClickListener {
val input = holder.input.text.toString()
objective.specialAction(activity, input)
notifyDataSetChanged()
}
} else {
holder.enterButton.visibility = View.GONE
holder.input.visibility = View.GONE
holder.inputHint.visibility = View.GONE
holder.requestCode.visibility = View.GONE
}
}
override fun getItemCount(): Int {
return ObjectivesPlugin.objectives.size
}
inner class ViewHolder internal constructor(itemView: View) : RecyclerView.ViewHolder(itemView) {
val title: TextView = itemView.findViewById(R.id.objective_title)
val objective: TextView = itemView.findViewById(R.id.objective_objective)
val gate: TextView = itemView.findViewById(R.id.objective_gate)
val accomplished: TextView = itemView.findViewById(R.id.objective_accomplished)
val progress: LinearLayout = itemView.findViewById(R.id.objective_progress)
val verify: Button = itemView.findViewById(R.id.objective_verify)
val start: Button = itemView.findViewById(R.id.objective_start)
val revert: Button = itemView.findViewById(R.id.objective_back)
val inputHint: TextView = itemView.findViewById(R.id.objective_inputhint)
val input: EditText = itemView.findViewById(R.id.objective_input)
val enterButton: Button = itemView.findViewById(R.id.objective_enterbutton)
val requestCode: TextView = itemView.findViewById(R.id.objective_requestcode)
}
}
fun updateGUI() {
activity?.runOnUiThread { objectivesAdapter.notifyDataSetChanged() }
}
}

View file

@ -1,164 +0,0 @@
package info.nightscout.androidaps.plugins.constraints.objectives;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.ArrayList;
import java.util.List;
import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.interfaces.Constraint;
import info.nightscout.androidaps.interfaces.ConstraintsInterface;
import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginDescription;
import info.nightscout.androidaps.interfaces.PluginType;
import info.nightscout.androidaps.interfaces.PumpInterface;
import info.nightscout.androidaps.logging.L;
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin;
import info.nightscout.androidaps.plugins.constraints.objectives.events.EventObjectivesSaved;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective1;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective2;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective3;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective4;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective5;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective6;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective7;
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective8;
import info.nightscout.androidaps.utils.SP;
/**
* Created by mike on 05.08.2016.
*/
public class ObjectivesPlugin extends PluginBase implements ConstraintsInterface {
private static Logger log = LoggerFactory.getLogger(L.CONSTRAINTS);
private static ObjectivesPlugin objectivesPlugin;
public List<Objective> objectives = new ArrayList<>();
public boolean bgIsAvailableInNS = false;
public boolean pumpStatusIsAvailableInNS = false;
public Integer manualEnacts = 0;
public static ObjectivesPlugin getPlugin() {
if (objectivesPlugin == null) {
objectivesPlugin = new ObjectivesPlugin();
}
return objectivesPlugin;
}
private ObjectivesPlugin() {
super(new PluginDescription()
.mainType(PluginType.CONSTRAINTS)
.fragmentClass(ObjectivesFragment.class.getName())
.alwaysEnabled(!Config.NSCLIENT)
.showInList(!Config.NSCLIENT)
.pluginName(R.string.objectives)
.shortName(R.string.objectives_shortname)
.description(R.string.description_objectives)
);
setupObjectives();
loadProgress();
}
@Override
public boolean specialEnableCondition() {
PumpInterface pump = ConfigBuilderPlugin.getPlugin().getActivePump();
return pump == null || pump.getPumpDescription().isTempBasalCapable;
}
private void setupObjectives() {
objectives.add(new Objective1());
objectives.add(new Objective2());
objectives.add(new Objective3());
objectives.add(new Objective4());
objectives.add(new Objective5());
objectives.add(new Objective6());
objectives.add(new Objective7());
objectives.add(new Objective8());
}
public void reset() {
for (Objective objective : objectives) {
objective.setStartedOn(null);
objective.setAccomplishedOn(null);
}
bgIsAvailableInNS = false;
pumpStatusIsAvailableInNS = false;
manualEnacts = 0;
saveProgress();
}
public void saveProgress() {
SP.putBoolean("Objectives" + "bgIsAvailableInNS", bgIsAvailableInNS);
SP.putBoolean("Objectives" + "pumpStatusIsAvailableInNS", pumpStatusIsAvailableInNS);
SP.putString("Objectives" + "manualEnacts", Integer.toString(manualEnacts));
if (L.isEnabled(L.CONSTRAINTS))
log.debug("Objectives stored");
MainApp.bus().post(new EventObjectivesSaved());
}
private void loadProgress() {
bgIsAvailableInNS = SP.getBoolean("Objectives" + "bgIsAvailableInNS", false);
pumpStatusIsAvailableInNS = SP.getBoolean("Objectives" + "pumpStatusIsAvailableInNS", false);
try {
manualEnacts = SP.getInt("Objectives" + "manualEnacts", 0);
} catch (Exception e) {
log.error("Unhandled exception", e);
}
if (L.isEnabled(L.CONSTRAINTS))
log.debug("Objectives loaded");
}
public List<Objective> getObjectives() {
return objectives;
}
/**
* Constraints interface
**/
@Override
public Constraint<Boolean> isLoopInvocationAllowed(Constraint<Boolean> value) {
if (!objectives.get(0).isStarted())
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), 1), this);
return value;
}
@Override
public Constraint<Boolean> isClosedLoopAllowed(Constraint<Boolean> value) {
if (!objectives.get(3).isStarted())
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), 4), this);
return value;
}
@Override
public Constraint<Boolean> isAutosensModeEnabled(Constraint<Boolean> value) {
if (!objectives.get(5).isStarted())
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), 6), this);
return value;
}
@Override
public Constraint<Boolean> isAMAModeEnabled(Constraint<Boolean> value) {
if (!objectives.get(6).isStarted())
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), 7), this);
return value;
}
@Override
public Constraint<Boolean> isSMBModeEnabled(Constraint<Boolean> value) {
if (!objectives.get(7).isStarted())
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), 8), this);
return value;
}
@Override
public Constraint<Double> applyMaxIOBConstraints(Constraint<Double> maxIob) {
if (objectives.get(3).isStarted() && !objectives.get(3).isAccomplished())
maxIob.set(0d, String.format(MainApp.gs(R.string.objectivenotfinished), 4), this);
return maxIob;
}
}

View file

@ -0,0 +1,170 @@
package info.nightscout.androidaps.plugins.constraints.objectives
import android.app.Activity
import com.google.common.base.Charsets
import com.google.common.hash.Hashing
import info.nightscout.androidaps.BuildConfig
import info.nightscout.androidaps.Config
import info.nightscout.androidaps.MainApp
import info.nightscout.androidaps.R
import info.nightscout.androidaps.interfaces.*
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.*
import info.nightscout.androidaps.utils.DateUtil
import info.nightscout.androidaps.utils.OKDialog
import info.nightscout.androidaps.utils.SP
import java.util.*
/**
* Created by mike on 05.08.2016.
*/
object ObjectivesPlugin : PluginBase(PluginDescription()
.mainType(PluginType.CONSTRAINTS)
.fragmentClass(ObjectivesFragment::class.qualifiedName)
.alwaysEnabled(!Config.NSCLIENT)
.showInList(!Config.NSCLIENT)
.pluginName(R.string.objectives)
.shortName(R.string.objectives_shortname)
.description(R.string.description_objectives)), ConstraintsInterface {
var objectives: MutableList<Objective> = ArrayList()
val FIRST_OBJECTIVE = 0
val USAGE_OBJECTIVE = 1
val EXAM_OBJECTIVE = 2
val OPENLOOP_OBJECTIVE = 3
val MAXBASAL_OBJECTIVE = 4
val MAXIOB_ZERO_CL_OBJECTIVE = 5
val MAXIOB_OBJECTIVE = 6
val AUTOSENS_OBJECTIVE = 7
val AMA_OBJECTIVE = 8
val SMB_OBJECTIVE = 9
init {
convertSP()
setupObjectives()
}
override fun specialEnableCondition(): Boolean {
val pump = ConfigBuilderPlugin.getPlugin().activePump
return pump == null || pump.pumpDescription.isTempBasalCapable
}
// convert 2.3 SP version
private fun convertSP() {
doConvertSP(0, "config")
doConvertSP(1, "openloop")
doConvertSP(2, "maxbasal")
doConvertSP(3, "maxiobzero")
doConvertSP(4, "maxiob")
doConvertSP(5, "autosens")
doConvertSP(6, "ama")
doConvertSP(7, "smb")
}
private fun doConvertSP(number: Int, name: String) {
if (!SP.contains("Objectives_" + name + "_started")) {
SP.putLong("Objectives_" + name + "_started", SP.getLong("Objectives" + number + "accomplished", 0L))
SP.putLong("Objectives_" + name + "_accomplished", SP.getLong("Objectives" + number + "accomplished", 0L))
}
// TODO: we can remove Objectives1accomplished sometimes later
}
private fun setupObjectives() {
objectives.clear()
objectives.add(Objective0())
objectives.add(Objective1())
objectives.add(Objective2())
objectives.add(Objective3())
objectives.add(Objective4())
objectives.add(Objective5())
objectives.add(Objective6())
objectives.add(Objective7())
objectives.add(Objective8())
objectives.add(Objective9())
}
fun reset() {
for (objective in objectives) {
objective.startedOn = 0
objective.accomplishedOn = 0
}
SP.putBoolean(R.string.key_ObjectivesbgIsAvailableInNS, false)
SP.putBoolean(R.string.key_ObjectivespumpStatusIsAvailableInNS, false)
SP.putInt(R.string.key_ObjectivesmanualEnacts, 0)
SP.putBoolean(R.string.key_objectiveuseprofileswitch, false)
SP.putBoolean(R.string.key_objectiveusedisconnect, false)
SP.putBoolean(R.string.key_objectiveusereconnect, false)
SP.putBoolean(R.string.key_objectiveusetemptarget, false)
SP.putBoolean(R.string.key_objectiveuseactions, false)
SP.putBoolean(R.string.key_objectiveuseloop, false)
SP.putBoolean(R.string.key_objectiveusescale, false)
}
fun completeObjectives(activity: Activity, request: String) {
val requestCode = SP.getString(R.string.key_objectives_request_code, "")
var url = SP.getString(R.string.key_nsclientinternal_url, "").toLowerCase()
if (!url.endsWith("\"")) url = "$url/"
val hashNS = Hashing.sha1().hashString(url + BuildConfig.APPLICATION_ID + "/" + requestCode, Charsets.UTF_8).toString()
if (request.equals(hashNS.substring(0, 10), ignoreCase = true)) {
SP.putLong("Objectives_" + "openloop" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "openloop" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "maxbasal" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "maxbasal" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "maxiobzero" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "maxiobzero" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "maxiob" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "maxiob" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "autosens" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "autosens" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "ama" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "ama" + "_accomplished", DateUtil.now())
SP.putLong("Objectives_" + "smb" + "_started", DateUtil.now())
SP.putLong("Objectives_" + "smb" + "_accomplished", DateUtil.now())
setupObjectives()
OKDialog.show(activity, "", MainApp.gs(R.string.codeaccepted), null)
} else {
OKDialog.show(activity, "", MainApp.gs(R.string.codeinvalid), null)
}
}
/**
* Constraints interface
*/
override fun isLoopInvocationAllowed(value: Constraint<Boolean>): Constraint<Boolean> {
if (!objectives[FIRST_OBJECTIVE].isStarted)
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), FIRST_OBJECTIVE + 1), this)
return value
}
override fun isClosedLoopAllowed(value: Constraint<Boolean>): Constraint<Boolean> {
if (!objectives[MAXIOB_ZERO_CL_OBJECTIVE].isStarted)
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), MAXIOB_ZERO_CL_OBJECTIVE + 1), this)
return value
}
override fun isAutosensModeEnabled(value: Constraint<Boolean>): Constraint<Boolean> {
if (!objectives[AUTOSENS_OBJECTIVE].isStarted)
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), AUTOSENS_OBJECTIVE + 1), this)
return value
}
override fun isAMAModeEnabled(value: Constraint<Boolean>): Constraint<Boolean> {
if (!objectives[AMA_OBJECTIVE].isStarted)
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), AMA_OBJECTIVE + 1), this)
return value
}
override fun isSMBModeEnabled(value: Constraint<Boolean>): Constraint<Boolean> {
if (!objectives[SMB_OBJECTIVE].isStarted)
value.set(false, String.format(MainApp.gs(R.string.objectivenotstarted), SMB_OBJECTIVE + 1), this)
return value
}
override fun applyMaxIOBConstraints(maxIob: Constraint<Double>): Constraint<Double> {
if (objectives[MAXIOB_ZERO_CL_OBJECTIVE].isStarted && !objectives[MAXIOB_ZERO_CL_OBJECTIVE].isAccomplished)
maxIob.set(0.0, String.format(MainApp.gs(R.string.objectivenotfinished), MAXIOB_ZERO_CL_OBJECTIVE + 1), this)
return maxIob
}
}

View file

@ -0,0 +1,132 @@
package info.nightscout.androidaps.plugins.constraints.objectives.activities
import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.fragment.app.DialogFragment
import info.nightscout.androidaps.MainApp
import info.nightscout.androidaps.R
import info.nightscout.androidaps.plugins.bus.RxBus
import info.nightscout.androidaps.plugins.constraints.objectives.events.EventObjectivesUpdateGui
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective
import info.nightscout.androidaps.plugins.constraints.objectives.objectives.Objective.*
import info.nightscout.androidaps.utils.DateUtil
import info.nightscout.androidaps.utils.OKDialog
import info.nightscout.androidaps.utils.T
import info.nightscout.androidaps.utils.ToastUtils
import kotlinx.android.synthetic.main.objectives_exam_fragment.*
class ObjectivesExamDialog : DialogFragment() {
companion object {
var objective: Objective? = null
}
var currentTask = 0
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?,
savedInstanceState: Bundle?): View? {
// load data from bundle
(savedInstanceState ?: arguments)?.let { bundle ->
currentTask = bundle.getInt("currentTask", 0)
}
return inflater.inflate(R.layout.objectives_exam_fragment, container, false)
}
override fun onStart() {
super.onStart()
dialog.setCanceledOnTouchOutside(false)
dialog.window?.setLayout(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
}
override fun onResume() {
super.onResume()
updateGui()
}
override fun onSaveInstanceState(bundle: Bundle) {
super.onSaveInstanceState(bundle)
bundle.putInt("currentTask", currentTask)
}
fun updateGui() {
objective?.let { objective ->
val task: ExamTask = objective.tasks[currentTask] as ExamTask
objectives_exam_name.setText(task.task)
objectives_exam_question.setText(task.question)
// Options
objectives_exam_options.removeAllViews()
for (o in task.options) {
val option: Option = o as Option;
val cb = option.generate(context)
if (task.answered) {
cb.isEnabled = false
if (option.isCorrect)
cb.isChecked = true
}
objectives_exam_options.addView(cb)
}
// Hints
objectives_exam_hints.removeAllViews()
for (h in task.hints) {
val hint: Hint = h as Hint;
objectives_exam_hints.addView(hint.generate(context))
}
// Disabled to
objectives_exam_disabledto.text = MainApp.gs(R.string.answerdisabledto, DateUtil.timeString(task.disabledTo))
objectives_exam_disabledto.visibility = if (task.isEnabledAnswer) View.GONE else View.VISIBLE
// Buttons
objectives_exam_verify.isEnabled = !task.answered && task.isEnabledAnswer
objectives_exam_verify.setOnClickListener {
var result = true
for (o in task.options) {
val option: Option = o as Option;
result = result && option.evaluate()
}
task.setAnswered(result);
if (!result) {
task.disabledTo = DateUtil.now() + T.hours(1).msecs()
ToastUtils.showToastInUiThread(context, R.string.wronganswer)
} else task.disabledTo = 0
updateGui()
RxBus.send(EventObjectivesUpdateGui())
}
close.setOnClickListener { dismiss() }
objectives_exam_reset.setOnClickListener {
task.answered = false
//task.disabledTo = 0
updateGui()
RxBus.send(EventObjectivesUpdateGui())
}
objectives_back_button.isEnabled = currentTask != 0
objectives_back_button.setOnClickListener {
currentTask--
updateGui()
}
objectives_next_button.isEnabled = currentTask != objective.tasks.size - 1
objectives_next_button.setOnClickListener {
currentTask++
updateGui()
}
objectives_next_unanswered_button.isEnabled = !objective.isCompleted
objectives_next_unanswered_button.setOnClickListener {
for (i in (currentTask + 1)..(objective.tasks.size - 1)) {
if (!objective.tasks[i].isCompleted) {
currentTask = i
updateGui()
return@setOnClickListener
}
}
for (i in 0..currentTask) {
if (!objective.tasks[i].isCompleted) {
currentTask = i
updateGui()
return@setOnClickListener
}
}
}
}
}
}

View file

@ -1,6 +0,0 @@
package info.nightscout.androidaps.plugins.constraints.objectives.events;
import info.nightscout.androidaps.events.Event;
public class EventObjectivesSaved extends Event {
}

View file

@ -0,0 +1,5 @@
package info.nightscout.androidaps.plugins.constraints.objectives.events
import info.nightscout.androidaps.events.EventUpdateGui
class EventObjectivesUpdateGui : EventUpdateGui()

View file

@ -1,35 +1,41 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import android.app.Activity;
import android.content.Context;
import android.graphics.Color;
import android.text.util.Linkify;
import android.widget.CheckBox;
import android.widget.TextView;
import androidx.annotation.StringRes;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.utils.DateUtil;
import info.nightscout.androidaps.utils.SP;
import info.nightscout.androidaps.utils.T;
public abstract class Objective {
private int number;
private String spName;
@StringRes
private int objective;
@StringRes
private int gate;
private Date startedOn;
private Date accomplishedOn;
private long startedOn;
private long accomplishedOn;
private List<Task> tasks = new ArrayList<>();
public boolean hasSpecialInput = false;
public Objective(int number, @StringRes int objective, @StringRes int gate) {
this.number = number;
public Objective(String spName, @StringRes int objective, @StringRes int gate) {
this.spName = spName;
this.objective = objective;
this.gate = gate;
startedOn = new Date(SP.getLong("Objectives" + number + "started", 0L));
if (startedOn.getTime() == 0L) startedOn = null;
accomplishedOn = new Date(SP.getLong("Objectives" + number + "accomplished", 0L));
if (accomplishedOn.getTime() == 0L) accomplishedOn = null;
startedOn = SP.getLong("Objectives_" + spName + "_started", 0L);
accomplishedOn = SP.getLong("Objectives_" + spName + "_accomplished", 0L);
setupTasks(tasks);
for (Task task : tasks) task.objective = this;
}
@ -47,14 +53,14 @@ public abstract class Objective {
}
public boolean isAccomplished() {
return accomplishedOn != null;
return accomplishedOn != 0;
}
public boolean isStarted() {
return startedOn != null;
return startedOn != 0;
}
public Date getStartedOn() {
public long getStartedOn() {
return startedOn;
}
@ -66,14 +72,18 @@ public abstract class Objective {
return gate;
}
public void setStartedOn(Date startedOn) {
public void setStartedOn(long startedOn) {
this.startedOn = startedOn;
SP.putLong("Objectives" + number + "started", startedOn == null ? 0 : startedOn.getTime());
SP.putLong("Objectives_" + spName + "_started", startedOn);
}
public void setAccomplishedOn(Date accomplishedOn) {
public void setAccomplishedOn(long accomplishedOn) {
this.accomplishedOn = accomplishedOn;
SP.putLong("Objectives" + number + "accomplished", accomplishedOn == null ? 0 : accomplishedOn.getTime());
SP.putLong("Objectives_" + spName + "_accomplished", accomplishedOn);
}
public long getAccomplishedOn() {
return accomplishedOn;
}
protected void setupTasks(List<Task> tasks) {
@ -84,6 +94,8 @@ public abstract class Objective {
return tasks;
}
public void specialAction(Activity activity, String input) {}
public abstract class Task {
@StringRes
private int task;
@ -93,7 +105,7 @@ public abstract class Objective {
this.task = task;
}
public int getTask() {
public @StringRes int getTask() {
return task;
}
@ -116,19 +128,19 @@ public abstract class Objective {
private long minimumDuration;
public MinimumDurationTask(long minimumDuration) {
MinimumDurationTask(long minimumDuration) {
super(R.string.time_elapsed);
this.minimumDuration = minimumDuration;
}
@Override
public boolean isCompleted() {
return getObjective().isStarted() && System.currentTimeMillis() - getObjective().getStartedOn().getTime() >= minimumDuration;
return getObjective().isStarted() && System.currentTimeMillis() - getObjective().getStartedOn() >= minimumDuration;
}
@Override
public String getProgress() {
return getDurationText(System.currentTimeMillis() - getObjective().getStartedOn().getTime())
return getDurationText(System.currentTimeMillis() - getObjective().getStartedOn())
+ " / " + getDurationText(minimumDuration);
}
@ -142,4 +154,117 @@ public abstract class Objective {
}
}
public class ExamTask extends Task {
@StringRes
int question;
List hints = new ArrayList<>();
List options = new ArrayList<>();
private String spIdentifier;
private boolean answered;
private long disabledTo;
ExamTask(@StringRes int task, @StringRes int question, String spIdentifier) {
super(task);
this.question = question;
this.spIdentifier = spIdentifier;
answered = SP.getBoolean("ExamTask_" + spIdentifier, false);
disabledTo = SP.getLong("DisabledTo_" + spIdentifier, 0L);
}
public void setDisabledTo(long newState) {
disabledTo = newState;
SP.putLong("DisabledTo_" + spIdentifier, disabledTo);
}
public long getDisabledTo() {
return disabledTo;
}
public boolean isEnabledAnswer() {
return disabledTo < DateUtil.now();
}
public void setAnswered(boolean newState) {
answered = newState;
SP.putBoolean("ExamTask_" + spIdentifier, answered);
}
public boolean getAnswered() {
return answered;
}
ExamTask option(Option option) {
options.add(option);
return this;
}
ExamTask hint(Hint hint) {
hints.add(hint);
return this;
}
public @StringRes int getQuestion() {
return question;
}
public List getOptions() {
return options;
}
public List getHints() {
return hints;
}
@Override
public boolean isCompleted() {
return answered;
}
}
public class Option {
@StringRes int option;
boolean isCorrect;
CheckBox cb; // TODO: change it, this will block releasing memeory
Option(@StringRes int option, boolean isCorrect) {
this.option = option;
this.isCorrect = isCorrect;
}
public boolean isCorrect() {
return isCorrect;
}
public CheckBox generate(Context context) {
cb = new CheckBox(context);
cb.setText(option);
return cb;
}
public boolean evaluate() {
boolean selection = cb.isChecked();
if (selection && isCorrect) return true;
if (!selection && !isCorrect) return true;
return false;
}
}
public class Hint {
@StringRes int hint;
Hint(@StringRes int hint) {
this.hint = hint;
}
public TextView generate(Context context) {
TextView textView = new TextView(context);
textView.setText(hint);
textView.setAutoLinkMask(Linkify.WEB_URLS);
textView.setLinksClickable(true);
textView.setLinkTextColor(Color.YELLOW);
Linkify.addLinks(textView, Linkify.WEB_URLS);
return textView;
}
}
}

View file

@ -0,0 +1,84 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.db.DatabaseHelper;
import info.nightscout.androidaps.interfaces.APSInterface;
import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginType;
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.aps.loop.LoopPlugin;
import info.nightscout.androidaps.plugins.general.nsclient.NSClientPlugin;
import info.nightscout.androidaps.plugins.pump.virtual.VirtualPumpPlugin;
import info.nightscout.androidaps.plugins.treatments.TreatmentsPlugin;
import info.nightscout.androidaps.utils.DateUtil;
import info.nightscout.androidaps.utils.SP;
public class Objective0 extends Objective {
public Objective0() {
super("config", R.string.objectives_0_objective, R.string.objectives_0_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new Task(R.string.objectives_bgavailableinns) {
@Override
public boolean isCompleted() {
return SP.getBoolean(R.string.key_ObjectivesbgIsAvailableInNS, false);
}
});
tasks.add(new Task(R.string.nsclienthaswritepermission) {
@Override
public boolean isCompleted() {
return NSClientPlugin.getPlugin().hasWritePermission();
}
});
tasks.add(new Task(R.string.virtualpump_uploadstatus_title) {
@Override
public boolean isCompleted() {
return SP.getBoolean("virtualpump_uploadstatus", false);
}
@Override
public boolean shouldBeIgnored() {
return !VirtualPumpPlugin.getPlugin().isEnabled(PluginType.PUMP);
}
});
tasks.add(new Task(R.string.objectives_pumpstatusavailableinns) {
@Override
public boolean isCompleted() {
return SP.getBoolean(R.string.key_ObjectivespumpStatusIsAvailableInNS, false);
}
});
tasks.add(new Task(R.string.hasbgdata) {
@Override
public boolean isCompleted() {
return DatabaseHelper.lastBg() != null;
}
});
tasks.add(new Task(R.string.loopenabled) {
@Override
public boolean isCompleted() {
return LoopPlugin.getPlugin().isEnabled(PluginType.LOOP);
}
});
tasks.add(new Task(R.string.apsselected) {
@Override
public boolean isCompleted() {
APSInterface usedAPS = ConfigBuilderPlugin.getPlugin().getActiveAPS();
if (usedAPS != null && ((PluginBase) usedAPS).isEnabled(PluginType.APS))
return true;
return false;
}
});
tasks.add(new Task(R.string.activate_profile) {
@Override
public boolean isCompleted() {
return TreatmentsPlugin.getPlugin().getProfileSwitchFromHistory(DateUtil.now()) != null;
}
});
}
}

View file

@ -3,81 +3,60 @@ package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.db.DatabaseHelper;
import info.nightscout.androidaps.interfaces.APSInterface;
import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginType;
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.aps.loop.LoopPlugin;
import info.nightscout.androidaps.plugins.general.nsclient.NSClientPlugin;
import info.nightscout.androidaps.plugins.pump.virtual.VirtualPumpPlugin;
import info.nightscout.androidaps.plugins.treatments.TreatmentsPlugin;
import info.nightscout.androidaps.utils.DateUtil;
import info.nightscout.androidaps.plugins.general.actions.ActionsPlugin;
import info.nightscout.androidaps.utils.SP;
public class Objective1 extends Objective {
public Objective1() {
super(0, R.string.objectives_0_objective, R.string.objectives_0_gate);
super("usage", R.string.objectives_usage_objective, R.string.objectives_usage_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new Task(R.string.objectives_bgavailableinns) {
tasks.add(new Task(R.string.objectives_useprofileswitch) {
@Override
public boolean isCompleted() {
return ObjectivesPlugin.getPlugin().bgIsAvailableInNS;
return SP.getBoolean(R.string.key_objectiveuseprofileswitch, false);
}
});
tasks.add(new Task(R.string.nsclienthaswritepermission) {
tasks.add(new Task(R.string.objectives_usedisconnectpump) {
@Override
public boolean isCompleted() {
return NSClientPlugin.getPlugin().hasWritePermission();
return SP.getBoolean(R.string.key_objectiveusedisconnect, false);
}
});
tasks.add(new Task(R.string.virtualpump_uploadstatus_title) {
tasks.add(new Task(R.string.objectives_usereconnectpump) {
@Override
public boolean isCompleted() {
return SP.getBoolean("virtualpump_uploadstatus", false);
}
@Override
public boolean shouldBeIgnored() {
return !VirtualPumpPlugin.getPlugin().isEnabled(PluginType.PUMP);
return SP.getBoolean(R.string.key_objectiveusereconnect, false);
}
});
tasks.add(new Task(R.string.objectives_pumpstatusavailableinns) {
tasks.add(new Task(R.string.objectives_usetemptarget) {
@Override
public boolean isCompleted() {
return ObjectivesPlugin.getPlugin().pumpStatusIsAvailableInNS;
return SP.getBoolean(R.string.key_objectiveusetemptarget, false);
}
});
tasks.add(new Task(R.string.hasbgdata) {
tasks.add(new Task(R.string.objectives_useactions) {
@Override
public boolean isCompleted() {
return DatabaseHelper.lastBg() != null;
return SP.getBoolean(R.string.key_objectiveuseactions, false) && ActionsPlugin.INSTANCE.isEnabled(PluginType.GENERAL) && ActionsPlugin.INSTANCE.isFragmentVisible();
}
});
tasks.add(new Task(R.string.loopenabled) {
tasks.add(new Task(R.string.objectives_useloop) {
@Override
public boolean isCompleted() {
return LoopPlugin.getPlugin().isEnabled(PluginType.LOOP);
return SP.getBoolean(R.string.key_objectiveuseloop, false);
}
});
tasks.add(new Task(R.string.apsselected) {
tasks.add(new Task(R.string.objectives_usescale) {
@Override
public boolean isCompleted() {
APSInterface usedAPS = ConfigBuilderPlugin.getPlugin().getActiveAPS();
if (usedAPS != null && ((PluginBase) usedAPS).isEnabled(PluginType.APS))
return true;
return false;
}
});
tasks.add(new Task(R.string.activate_profile) {
@Override
public boolean isCompleted() {
return TreatmentsPlugin.getPlugin().getProfileSwitchFromHistory(DateUtil.now()) != null;
return SP.getBoolean(R.string.key_objectiveusescale, false);
}
});
}

View file

@ -1,36 +1,70 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.Collections;
import java.util.List;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.utils.T;
public class Objective2 extends Objective {
public final int MANUAL_ENACTS_NEEDED = 20;
public Objective2() {
super(1, R.string.objectives_1_objective, R.string.objectives_1_gate);
super("exam", R.string.objectives_exam_objective, R.string.objectives_exam_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(7).msecs()));
tasks.add(new Task(R.string.objectives_manualenacts) {
@Override
public boolean isCompleted() {
return ObjectivesPlugin.getPlugin().manualEnacts >= MANUAL_ENACTS_NEEDED;
}
tasks.add(new ExamTask(R.string.dia_meaningofdia, R.string.dia_whatmeansdia,"dia")
.option(new Option(R.string.dia_minimumis3h, false))
.option(new Option(R.string.dia_minimumis5h, true))
.option(new Option(R.string.dia_meaningisequaltodiapump, false))
.option(new Option(R.string.dia_valuemustbedetermined, true))
.hint(new Hint(R.string.dia_hint1))
);
tasks.add(new ExamTask(R.string.hypott, R.string.hypott_whenhypott,"hypott")
.option(new Option(R.string.hypott_goinglow, true))
.option(new Option(R.string.hypott_havinglow, true))
.option(new Option(R.string.hypott_notlowanymorebutrising, false))
.option(new Option(R.string.hypott_havehadalowbg, false))
.hint(new Hint(R.string.hypott_hint1))
);
tasks.add(new ExamTask(R.string.offlineprofile, R.string.offlineprofile_whatprofile,"offlineprofile")
.option(new Option(R.string.localprofile, true))
.option(new Option(R.string.nsprofile, false))
.option(new Option(R.string.offlineprofile_nsprofile, true))
.hint(new Hint(R.string.offlineprofile_hint1))
);
tasks.add(new ExamTask(R.string.pumpdisconnect, R.string.pumpdisconnect_whattodo,"pumpdisconnect")
.option(new Option(R.string.pumpdisconnect_letknow, true))
.option(new Option(R.string.pumpdisconnect_dontchnage, false))
.hint(new Hint(R.string.pumpdisconnect_hint1))
);
tasks.add(new ExamTask(R.string.objectives, R.string.objectives_howtosave,"objectives")
.option(new Option(R.string.objectives_writetopaper, false))
.option(new Option(R.string.objectives_exportsettings, true))
.option(new Option(R.string.objectives_storeelsewhere, true))
.option(new Option(R.string.objectives_doexportonstart, false))
.option(new Option(R.string.objectives_doexportafterchange, true))
.option(new Option(R.string.objectives_doexportafterfirtssettings, true))
.hint(new Hint(R.string.objectives_hint1))
);
tasks.add(new ExamTask(R.string.noisycgm, R.string.noisycgm_whattodo,"noisycgm")
.option(new Option(R.string.nothing, false))
.option(new Option(R.string.disconnectpumpfor1h, false))
.option(new Option(R.string.noisycgm_pause, true))
.option(new Option(R.string.noisycgm_replacesensor, true))
.option(new Option(R.string.noisycgm_turnoffcgmreceiver, false))
.option(new Option(R.string.noisycgm_checksmoothing, true))
.hint(new Hint(R.string.noisycgm_hint1))
);
@Override
public String getProgress() {
if (ObjectivesPlugin.getPlugin().manualEnacts >= MANUAL_ENACTS_NEEDED)
return MainApp.gs(R.string.completed_well_done);
else
return ObjectivesPlugin.getPlugin().manualEnacts + " / " + MANUAL_ENACTS_NEEDED;
}
});
for (Task task : tasks)
Collections.shuffle(((ExamTask)task).options);
}
@Override
public boolean isRevertable() {
return true;
}
}

View file

@ -1,10 +1,45 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import android.app.Activity;
import java.util.List;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.utils.SP;
import info.nightscout.androidaps.utils.T;
public class Objective3 extends Objective {
public final int MANUAL_ENACTS_NEEDED = 20;
public Objective3() {
super(2, R.string.objectives_2_objective, R.string.objectives_2_gate);
super("openloop", R.string.objectives_openloop_objective, R.string.objectives_openloop_gate);
hasSpecialInput = true;
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(7).msecs()));
tasks.add(new Task(R.string.objectives_manualenacts) {
@Override
public boolean isCompleted() {
return SP.getInt(R.string.key_ObjectivesmanualEnacts, 0) >= MANUAL_ENACTS_NEEDED;
}
@Override
public String getProgress() {
if (SP.getInt(R.string.key_ObjectivesmanualEnacts, 0) >= MANUAL_ENACTS_NEEDED)
return MainApp.gs(R.string.completed_well_done);
else
return SP.getInt(R.string.key_ObjectivesmanualEnacts, 0) + " / " + MANUAL_ENACTS_NEEDED;
}
});
}
@Override
public void specialAction(Activity activity, String input) {
ObjectivesPlugin.INSTANCE.completeObjectives(activity, input);
}
}

View file

@ -1,33 +1,10 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.interfaces.Constraint;
import info.nightscout.androidaps.plugins.constraints.safety.SafetyPlugin;
import info.nightscout.androidaps.utils.T;
public class Objective4 extends Objective {
public Objective4() {
super(3, R.string.objectives_3_objective, R.string.objectives_3_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(5).msecs()));
tasks.add(new Task(R.string.closedmodeenabled) {
@Override
public boolean isCompleted() {
Constraint<Boolean> closedLoopEnabled = new Constraint<>(true);
SafetyPlugin.getPlugin().isClosedLoopAllowed(closedLoopEnabled);
return closedLoopEnabled.value();
}
});
}
@Override
public boolean isRevertable() {
return true;
super("maxbasal", R.string.objectives_maxbasal_objective, R.string.objectives_maxbasal_gate);
}
}

View file

@ -2,25 +2,32 @@ package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.interfaces.Constraint;
import info.nightscout.androidaps.plugins.constraints.safety.SafetyPlugin;
import info.nightscout.androidaps.utils.T;
public class Objective5 extends Objective {
public Objective5() {
super(4, R.string.objectives_4_objective, R.string.objectives_4_gate);
super("maxiobzero", R.string.objectives_maxiobzero_objective, R.string.objectives_maxiobzero_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(1).msecs()));
tasks.add(new Task(R.string.maxiobset) {
tasks.add(new MinimumDurationTask(T.days(5).msecs()));
tasks.add(new Task(R.string.closedmodeenabled) {
@Override
public boolean isCompleted() {
double maxIOB = MainApp.getConstraintChecker().getMaxIOBAllowed().value();
return maxIOB > 0;
Constraint<Boolean> closedLoopEnabled = new Constraint<>(true);
SafetyPlugin.getPlugin().isClosedLoopAllowed(closedLoopEnabled);
return closedLoopEnabled.value();
}
});
}
@Override
public boolean isRevertable() {
return true;
}
}

View file

@ -2,17 +2,25 @@ package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.utils.T;
public class Objective6 extends Objective {
public Objective6() {
super(5, R.string.objectives_5_objective, R.string.objectives_5_gate);
super("maxiob", R.string.objectives_maxiob_objective, R.string.objectives_maxiob_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(7).msecs()));
tasks.add(new MinimumDurationTask(T.days(1).msecs()));
tasks.add(new Task(R.string.maxiobset) {
@Override
public boolean isCompleted() {
double maxIOB = MainApp.getConstraintChecker().getMaxIOBAllowed().value();
return maxIOB > 0;
}
});
}
}

View file

@ -3,16 +3,17 @@ package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.utils.T;
public class Objective7 extends Objective {
public Objective7() {
super(6, R.string.objectives_6_objective, 0);
super("autosens", R.string.objectives_autosens_objective, R.string.objectives_autosens_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(28).msecs()));
tasks.add(new MinimumDurationTask(T.days(7).msecs()));
}
}

View file

@ -3,12 +3,13 @@ package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.utils.T;
public class Objective8 extends Objective {
public Objective8() {
super(7, R.string.objectives_7_objective, R.string.objectives_7_gate);
super("ama", R.string.objectives_ama_objective, 0);
}
@Override

View file

@ -0,0 +1,18 @@
package info.nightscout.androidaps.plugins.constraints.objectives.objectives;
import java.util.List;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.utils.T;
public class Objective9 extends Objective {
public Objective9() {
super("smb", R.string.objectives_smb_objective, R.string.objectives_smb_gate);
}
@Override
protected void setupTasks(List<Task> tasks) {
tasks.add(new MinimumDurationTask(T.days(28).msecs()));
}
}

View file

@ -5,13 +5,13 @@ import android.app.Activity;
import android.content.Intent;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import androidx.fragment.app.FragmentManager;
import com.squareup.otto.Subscribe;
import java.util.ArrayList;
@ -43,31 +43,21 @@ import info.nightscout.androidaps.plugins.general.careportal.CareportalFragment;
import info.nightscout.androidaps.plugins.general.careportal.Dialogs.NewNSTreatmentDialog;
import info.nightscout.androidaps.plugins.general.careportal.OptionsToShow;
import info.nightscout.androidaps.plugins.treatments.TreatmentsPlugin;
import info.nightscout.androidaps.utils.FabricPrivacy;
import info.nightscout.androidaps.utils.SP;
import info.nightscout.androidaps.utils.SingleClickButton;
/**
* A simple {@link Fragment} subclass.
*/
public class ActionsFragment extends SubscriberFragment implements View.OnClickListener {
static ActionsPlugin actionsPlugin = new ActionsPlugin();
static public ActionsPlugin getPlugin() {
return actionsPlugin;
}
View actionsFragmentView;
SingleClickButton profileSwitch;
SingleClickButton tempTarget;
SingleClickButton extendedBolus;
SingleClickButton extendedBolusCancel;
SingleClickButton tempBasal;
SingleClickButton tempBasalCancel;
SingleClickButton fill;
SingleClickButton tddStats;
SingleClickButton history;
private View actionsFragmentView;
private SingleClickButton profileSwitch;
private SingleClickButton tempTarget;
private SingleClickButton extendedBolus;
private SingleClickButton extendedBolusCancel;
private SingleClickButton tempBasal;
private SingleClickButton tempBasalCancel;
private SingleClickButton fill;
private SingleClickButton tddStats;
private SingleClickButton history;
private Map<String, CustomAction> pumpCustomActions = new HashMap<>();
private List<SingleClickButton> pumpCustomButtons = new ArrayList<>();
@ -80,38 +70,33 @@ public class ActionsFragment extends SubscriberFragment implements View.OnClickL
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
try {
View view = inflater.inflate(R.layout.actions_fragment, container, false);
View view = inflater.inflate(R.layout.actions_fragment, container, false);
profileSwitch = (SingleClickButton) view.findViewById(R.id.actions_profileswitch);
tempTarget = (SingleClickButton) view.findViewById(R.id.actions_temptarget);
extendedBolus = (SingleClickButton) view.findViewById(R.id.actions_extendedbolus);
extendedBolusCancel = (SingleClickButton) view.findViewById(R.id.actions_extendedbolus_cancel);
tempBasal = (SingleClickButton) view.findViewById(R.id.actions_settempbasal);
tempBasalCancel = (SingleClickButton) view.findViewById(R.id.actions_canceltempbasal);
fill = (SingleClickButton) view.findViewById(R.id.actions_fill);
tddStats = view.findViewById(R.id.actions_tddstats);
history = view.findViewById(R.id.actions_historybrowser);
profileSwitch = view.findViewById(R.id.actions_profileswitch);
tempTarget = view.findViewById(R.id.actions_temptarget);
extendedBolus = view.findViewById(R.id.actions_extendedbolus);
extendedBolusCancel = view.findViewById(R.id.actions_extendedbolus_cancel);
tempBasal = view.findViewById(R.id.actions_settempbasal);
tempBasalCancel = view.findViewById(R.id.actions_canceltempbasal);
fill = view.findViewById(R.id.actions_fill);
tddStats = view.findViewById(R.id.actions_tddstats);
history = view.findViewById(R.id.actions_historybrowser);
profileSwitch.setOnClickListener(this);
tempTarget.setOnClickListener(this);
extendedBolus.setOnClickListener(this);
extendedBolusCancel.setOnClickListener(this);
tempBasal.setOnClickListener(this);
tempBasalCancel.setOnClickListener(this);
fill.setOnClickListener(this);
history.setOnClickListener(this);
tddStats.setOnClickListener(this);
profileSwitch.setOnClickListener(this);
tempTarget.setOnClickListener(this);
extendedBolus.setOnClickListener(this);
extendedBolusCancel.setOnClickListener(this);
tempBasal.setOnClickListener(this);
tempBasalCancel.setOnClickListener(this);
fill.setOnClickListener(this);
history.setOnClickListener(this);
tddStats.setOnClickListener(this);
actionsFragmentView = view;
actionsFragmentView = view;
updateGUI();
return view;
} catch (Exception e) {
FabricPrivacy.logException(e);
}
return null;
updateGUI();
SP.putBoolean(R.string.key_objectiveuseactions, true);
return view;
}
@Subscribe

View file

@ -1,23 +0,0 @@
package info.nightscout.androidaps.plugins.general.actions;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginDescription;
import info.nightscout.androidaps.interfaces.PluginType;
/**
* Created by mike on 05.11.2016.
*/
public class ActionsPlugin extends PluginBase {
public ActionsPlugin() {
super(new PluginDescription()
.mainType(PluginType.GENERAL)
.fragmentClass(ActionsFragment.class.getName())
.pluginName(R.string.actions)
.shortName(R.string.actions_shortname)
.description(R.string.description_actions)
);
}
}

View file

@ -0,0 +1,13 @@
package info.nightscout.androidaps.plugins.general.actions
import info.nightscout.androidaps.R
import info.nightscout.androidaps.interfaces.PluginBase
import info.nightscout.androidaps.interfaces.PluginDescription
import info.nightscout.androidaps.interfaces.PluginType
object ActionsPlugin : PluginBase(PluginDescription()
.mainType(PluginType.GENERAL)
.fragmentClass(ActionsFragment::class.java.name)
.pluginName(R.string.actions)
.shortName(R.string.actions_shortname)
.description(R.string.description_actions))

View file

@ -84,14 +84,13 @@ class EventListAdapter extends RecyclerView.Adapter<EventListAdapter.ViewHolder>
// enabled event
holder.enabled.setOnCheckedChangeListener((buttonView, isChecked) -> {
event.setEnabled(isChecked);
notifyDataSetChanged();
RxBus.INSTANCE.send(new EventAutomationDataChanged());
});
// remove event
holder.iconTrash.setOnClickListener(v -> {
mEventList.remove(event);
notifyDataSetChanged();
RxBus.INSTANCE.send(new EventAutomationDataChanged());
});
// edit event

View file

@ -71,7 +71,7 @@ public class ActionStartTempTarget extends Action {
int unitResId = value.getUnits().equals(Constants.MGDL) ? R.string.mgdl : R.string.mmol;
new LayoutBuilder()
.add(new LabelWithElement(MainApp.gs(R.string.careportal_temporarytarget), MainApp.gs(unitResId), value))
.add(new LabelWithElement(MainApp.gs(R.string.careportal_temporarytarget) + " [" + MainApp.gs(unitResId) + "]", "", value))
.add(new LabelWithElement(MainApp.gs(R.string.careportal_newnstreatment_duration_min_label), "", duration))
.build(root);
}

View file

@ -25,8 +25,8 @@ public class InputDouble extends Element {
};
private double value;
double minValue;
double maxValue;
private double minValue;
private double maxValue;
private double step;
private DecimalFormat decimalFormat;

View file

@ -20,6 +20,11 @@ public class InputDuration extends Element {
this.value = value;
}
public InputDuration(InputDuration another) {
unit = another.unit;
value = another.value;
}
@Override
public void addToLayout(LinearLayout root) {
NumberPicker numberPicker = new NumberPicker(root.getContext(), null);

View file

@ -1,5 +1,7 @@
package info.nightscout.androidaps.plugins.general.automation.elements;
import android.text.Editable;
import android.text.TextWatcher;
import android.widget.LinearLayout;
import java.text.DecimalFormat;
@ -17,6 +19,22 @@ public class InputTempTarget extends Element {
private double step;
private DecimalFormat decimalFormat;
private final TextWatcher textWatcher = new TextWatcher() {
@Override
public void afterTextChanged(Editable s) {
value = Math.max(minValue, value);
value = Math.min(maxValue, value);
}
@Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
}
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
}
};
public InputTempTarget() {
super();
setUnits(ProfileFunctions.getInstance().getProfileUnits());
@ -36,7 +54,7 @@ public class InputTempTarget extends Element {
@Override
public void addToLayout(LinearLayout root) {
NumberPicker numberPicker = new NumberPicker(root.getContext(), null);
numberPicker.setParams(value, minValue, maxValue, step, decimalFormat, true, null, null);
numberPicker.setParams(value, minValue, maxValue, step, decimalFormat, true, null, textWatcher);
numberPicker.setOnValueChangedListener(value -> this.value = value);
root.addView(numberPicker);
}

View file

@ -3,6 +3,7 @@ package info.nightscout.androidaps.plugins.general.automation.elements;
import android.graphics.Typeface;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import android.widget.TableLayout;
import android.widget.TextView;
import info.nightscout.androidaps.MainApp;
@ -37,6 +38,10 @@ public class LabelWithElement extends Element {
textViewPre.setTypeface(textViewPre.getTypeface(), Typeface.BOLD);
layout.addView(textViewPre);
TextView spacer = new TextView(root.getContext());
spacer.setLayoutParams(new TableLayout.LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT, 1f));
layout.addView(spacer);
// add element to layout
element.addToLayout(layout);

View file

@ -11,8 +11,6 @@ import org.json.JSONObject;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.text.DecimalFormat;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.logging.L;
@ -28,9 +26,7 @@ import info.nightscout.androidaps.utils.T;
public class TriggerBolusAgo extends Trigger {
private static Logger log = LoggerFactory.getLogger(L.AUTOMATION);
private final double step = 1;
private DecimalFormat decimalFormat = new DecimalFormat("1");
public InputDuration minutesAgo = new InputDuration(0, InputDuration.TimeUnit.MINUTES);
private InputDuration minutesAgo = new InputDuration(0, InputDuration.TimeUnit.MINUTES);
private Comparator comparator = new Comparator();
public TriggerBolusAgo() {
@ -39,7 +35,7 @@ public class TriggerBolusAgo extends Trigger {
private TriggerBolusAgo(TriggerBolusAgo triggerBolusAgo) {
super();
minutesAgo = new InputDuration(triggerBolusAgo.minutesAgo.getMinutes(), InputDuration.TimeUnit.MINUTES);
minutesAgo = new InputDuration(triggerBolusAgo.minutesAgo);
lastRun = triggerBolusAgo.lastRun;
comparator = new Comparator(triggerBolusAgo.comparator);
}

View file

@ -32,10 +32,8 @@ import info.nightscout.androidaps.utils.T;
public class TriggerCOB extends Trigger {
private static Logger log = LoggerFactory.getLogger(L.AUTOMATION);
private final int minValue = 0;
private final int maxValue = (int) (SP.getInt(R.string.key_treatmentssafety_maxcarbs, 48));
private final double step = 1;
private DecimalFormat decimalFormat = new DecimalFormat("1");
private InputDouble value = new InputDouble(0, (double) minValue, (double) maxValue, step, decimalFormat);
private final int maxValue = SP.getInt(R.string.key_treatmentssafety_maxcarbs, 48);
private InputDouble value = new InputDouble(0, (double) minValue, (double) maxValue, 1, new DecimalFormat("1"));
private Comparator comparator = new Comparator();
public TriggerCOB() {

View file

@ -51,10 +51,11 @@ public class TriggerDelta extends Trigger {
private TriggerDelta(TriggerDelta triggerDelta) {
super();
this.units = ProfileFunctions.getInstance().getProfileUnits();
initializer();
value = triggerDelta.value;
lastRun = triggerDelta.lastRun;
this.units = triggerDelta.units;
deltaType = triggerDelta.deltaType;
value = new InputDelta(triggerDelta.value);
comparator = new Comparator(triggerDelta.comparator);
}
public double getValue() {
@ -68,7 +69,7 @@ public class TriggerDelta extends Trigger {
if (units.equals(Constants.MMOL))
value = new InputDelta(0, -MMOL_MAX, MMOL_MAX, 0.1d, new DecimalFormat("0.1"), DeltaType.DELTA);
else
value = new InputDelta(0, -MGDL_MAX, MGDL_MAX, 0.1d, new DecimalFormat("1"), DeltaType.DELTA);
value = new InputDelta(0, -MGDL_MAX, MGDL_MAX, 1d, new DecimalFormat("1"), DeltaType.DELTA);
}

View file

@ -51,10 +51,11 @@ public class TriggerLocation extends Trigger {
private TriggerLocation(TriggerLocation triggerLocation) {
super();
latitude = new InputDouble(triggerLocation.latitude.getValue(), -90d, +90d, 0.00001d, new DecimalFormat("0.00000"));
longitude = new InputDouble(triggerLocation.longitude.getValue(), -180d, +180d, 0.00001d, new DecimalFormat("0.00000"));
distance = new InputDouble(200d, 0, 100000, 10d, new DecimalFormat("0"));
latitude = new InputDouble(triggerLocation.latitude);
longitude = new InputDouble(triggerLocation.longitude);
distance = new InputDouble(triggerLocation.distance);
lastRun = triggerLocation.lastRun;
name = triggerLocation.name;
}
@Override

View file

@ -741,6 +741,8 @@ public class NewNSTreatmentDialog extends DialogFragment implements View.OnClick
}
TreatmentsPlugin.getPlugin().addToHistoryTempTarget(tempTarget);
}
if (duration == 10)
SP.putBoolean(R.string.key_objectiveusetemptarget, true);
} else {
if (JsonHelper.safeGetString(data, "eventType").equals(CareportalEvent.PROFILESWITCH)) {
ProfileSwitch profileSwitch = ProfileFunctions.prepareProfileSwitch(

View file

@ -17,10 +17,9 @@ import java.util.Map;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R;
import info.nightscout.androidaps.logging.L;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.aps.loop.APSResult;
import info.nightscout.androidaps.logging.BundleLogger;
import info.nightscout.androidaps.logging.L;
import info.nightscout.androidaps.plugins.aps.loop.APSResult;
import info.nightscout.androidaps.utils.DateUtil;
import info.nightscout.androidaps.utils.Round;
import info.nightscout.androidaps.utils.SP;
@ -108,8 +107,7 @@ public class NSDeviceStatus {
setData(devicestatusJson);
if (devicestatusJson.has("pump")) {
// Objectives 0
ObjectivesPlugin.getPlugin().pumpStatusIsAvailableInNS = true;
ObjectivesPlugin.getPlugin().saveProgress();
SP.putBoolean(R.string.key_ObjectivespumpStatusIsAvailableInNS, true);
}
}
if (bundle.containsKey("devicestatuses")) {
@ -120,8 +118,7 @@ public class NSDeviceStatus {
setData(devicestatusJson);
if (devicestatusJson.has("pump")) {
// Objectives 0
ObjectivesPlugin.getPlugin().pumpStatusIsAvailableInNS = true;
ObjectivesPlugin.getPlugin().saveProgress();
SP.putBoolean(R.string.key_ObjectivespumpStatusIsAvailableInNS, true);
}
}
}

View file

@ -334,6 +334,7 @@ public class OverviewFragment extends Fragment implements View.OnClickListener,
rangeToDisplay = rangeToDisplay > 24 ? 6 : rangeToDisplay;
SP.putInt(R.string.key_rangetodisplay, rangeToDisplay);
updateGUI("rangeChange");
SP.putBoolean(R.string.key_objectiveusescale, true);
return false;
});
@ -592,6 +593,7 @@ public class OverviewFragment extends Fragment implements View.OnClickListener,
}
}
});
SP.putBoolean(R.string.key_objectiveusereconnect, true);
NSUpload.uploadOpenAPSOffline(0);
return true;
} else if (item.getTitle().equals(MainApp.gs(R.string.suspendloopfor1h))) {
@ -620,6 +622,7 @@ public class OverviewFragment extends Fragment implements View.OnClickListener,
return true;
} else if (item.getTitle().equals(MainApp.gs(R.string.disconnectpumpfor1h))) {
LoopPlugin.getPlugin().disconnectPump(60, profile);
SP.putBoolean(R.string.key_objectiveusedisconnect, true);
updateGUI("suspendmenu");
return true;
} else if (item.getTitle().equals(MainApp.gs(R.string.disconnectpumpfor2h))) {

View file

@ -16,7 +16,6 @@ import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginDescription;
import info.nightscout.androidaps.interfaces.PluginType;
import info.nightscout.androidaps.logging.L;
import info.nightscout.androidaps.plugins.constraints.objectives.ObjectivesPlugin;
import info.nightscout.androidaps.plugins.general.nsclient.data.NSSgv;
import info.nightscout.androidaps.utils.JsonHelper;
import info.nightscout.androidaps.utils.SP;
@ -85,8 +84,7 @@ public class SourceNSClientPlugin extends PluginBase implements BgSourceInterfac
}
// Objectives 0
ObjectivesPlugin.getPlugin().bgIsAvailableInNS = true;
ObjectivesPlugin.getPlugin().saveProgress();
SP.putBoolean(R.string.key_ObjectivesbgIsAvailableInNS, true);
}
private void storeSgv(JSONObject sgvJson) {

View file

@ -425,8 +425,8 @@ public class SWDefinition {
.add(new SWBreak())
.add(new SWFragment(this)
.add(new ObjectivesFragment()))
.validator(() -> ObjectivesPlugin.getPlugin().objectives.get(0).isStarted())
.visibility(() -> !ObjectivesPlugin.getPlugin().objectives.get(0).isStarted() && Config.APS);
.validator(() -> ObjectivesPlugin.INSTANCE.getObjectives().get(ObjectivesPlugin.INSTANCE.getFIRST_OBJECTIVE()).isStarted())
.visibility(() -> !ObjectivesPlugin.INSTANCE.getObjectives().get(ObjectivesPlugin.INSTANCE.getFIRST_OBJECTIVE()).isStarted() && Config.APS);
private void SWDefinitionFull() {
// List all the screens here

View file

@ -26,7 +26,6 @@ import info.nightscout.androidaps.activities.NoSplashAppCompatActivity;
import info.nightscout.androidaps.events.EventProfileNeedsUpdate;
import info.nightscout.androidaps.events.EventProfileStoreChanged;
import info.nightscout.androidaps.events.EventPumpStatusChanged;
import info.nightscout.androidaps.plugins.constraints.objectives.events.EventObjectivesSaved;
import info.nightscout.androidaps.plugins.general.nsclient.events.EventNSClientStatus;
import info.nightscout.androidaps.setupwizard.elements.SWItem;
import info.nightscout.androidaps.setupwizard.events.EventSWUpdate;
@ -121,11 +120,6 @@ public class SetupWizardActivity extends NoSplashAppCompatActivity {
updateButtons();
}
@Subscribe
public void onEventObjectivesSaved(EventObjectivesSaved ignored) {
updateButtons();
}
private void generateLayout() {
SWScreen currentScreen = screens.get(currentWizardPage);
LinearLayout layout = SWItem.generateLayout(this.findViewById(R.id.sw_content_fields));

View file

@ -126,6 +126,13 @@ public class SP {
editor.apply();
}
static public void incInt(int resourceID) {
SharedPreferences.Editor editor = sharedPreferences.edit();
int value = SP.getInt(resourceID, 0) + 1;
editor.putInt(MainApp.gs(resourceID), value);
editor.apply();
}
static public void putString(int resourceID, String value) {
SharedPreferences.Editor editor = sharedPreferences.edit();
editor.putString(MainApp.gs(resourceID), value);

View file

@ -0,0 +1,148 @@
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".plugins.constraints.objectives.activities.ObjectivesExamDialog">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp">
<LinearLayout
android:id="@+id/objectives_exam_options"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:orientation="vertical"
app:layout_constraintTop_toBottomOf="@+id/objectives_exam_question"
tools:layout_editor_absoluteX="3dp">
</LinearLayout>
<LinearLayout
android:id="@+id/objectives_exam_hints"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:layout_marginBottom="10dp"
android:orientation="vertical"
app:layout_constraintTop_toBottomOf="@+id/objectives_exam_options"
tools:layout_editor_absoluteX="3dp" />
<LinearLayout
android:id="@+id/objectives_buttons"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:background="#3C3C3C"
android:orientation="horizontal"
android:padding="4dp"
app:layout_constraintTop_toBottomOf="@+id/objectives_exam_disabledto">
<Button
android:id="@+id/objectives_exam_reset"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/reset" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="" />
<Button
android:id="@+id/close"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/close" />
<Button
android:id="@+id/objectives_exam_verify"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/objectives_button_verify" />
</LinearLayout>
<TextView
android:id="@+id/objectives_exam_question"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Question"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/objectives_exam_name" />
<TextView
android:id="@+id/objectives_exam_name"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Name"
android:textAppearance="@style/TextAppearance.AppCompat.Large"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/objectives_exam_disabledto"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:text="Disabled to:"
android:textColor="#FF5722"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/objectives_exam_hints" />
<LinearLayout
android:id="@+id/objectives_navigation"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="2dp"
android:background="#3C3C3C"
android:orientation="horizontal"
android:padding="4dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/objectives_buttons">
<Button
android:id="@+id/objectives_back_button"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/previous_button" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="" />
<Button
android:id="@+id/objectives_next_button"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/next_button" />
<Button
android:id="@+id/objectives_next_unanswered_button"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/unfinshed_button" />
</LinearLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>

View file

@ -49,7 +49,9 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:orientation="vertical" />
android:orientation="vertical" >
</LinearLayout>
<Button
android:id="@+id/objective_verify"
@ -71,6 +73,50 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/objectives_button_back" />
<TextView
android:id="@+id/objective_inputhint"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/enter_code_obtained_from_developers_to_bypass_the_rest_of_objectives" />
<TextView
android:id="@+id/objective_requestcode"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Request code: XXXXX" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" >
<EditText
android:id="@+id/objective_input"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:ems="10"
android:hint="XXXXXXXXXX"
android:inputType="text" />
<Button
android:id="@+id/objective_enterbutton"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/objectives_button_enter" />
</LinearLayout>
<TextView
android:id="@+id/objective_accomplished"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:textColor="#FFFFFF"
tools:text="Accomplished" />
</LinearLayout>
</androidx.cardview.widget.CardView>

View file

@ -317,19 +317,19 @@
<string name="overview_bolusprogress_goingtodeliver">Gaan %1$.2fU lewer</string>
<string name="objectives_0_objective">Opstel van visualisering en monitering, en ontleed basale en verhoudings</string>
<string name="objectives_0_gate">Verifieer dat BG beskikbaar is in Nightscout, en dat pomp insulien data opgelaai word</string>
<string name="objectives_1_objective">Begin op \'n oop lus</string>
<string name="objectives_1_gate">Loop in oop lus modus vir \'n paar dae en boots met hand met baie tydelike basale. Stel tydelike gebruik en verstek tydelike teikens (bv. vir aktiwiteit of hipo behandeling koolhidrate)</string>
<string name="objectives_2_objective">Verstaan jou oop lus, insluitend sy tydelike basale aanbevelings</string>
<string name="objectives_2_gate">Gebaseer op daardie ervaring, besluit watter maks basale moet gebruik word, en stel dit op die pomp en voorkeure</string>
<string name="objectives_3_objective">Begin toe die lus met lae glukose opgeskort</string>
<string name="objectives_3_gate">Loop in geslote lus met max IAB = 0 vir \'n paar dae sonder te veel LGS gebeure</string>
<string name="objectives_4_objective">Verstel die geslote lus, verhoog maks IAB bo 0 en geleidelik verlaag BG doelwitte</string>
<string name="objectives_4_gate">Lus vir \'n paar dae, en ten minste een nag met geen lae BG alarms, voor BG val</string>
<string name="objectives_5_objective">Pas basale en verhoudings aan as nodig, en dan aktiveer auto-sens</string>
<string name="objectives_5_gate">1 week suksesvolle dagtyd lus met gereelde karb toevoegings</string>
<string name="objectives_6_objective">Skakel bykomende nutsfunskies aan vir bedagse gebruik, soos bv advanced meal assist</string>
<string name="objectives_7_objective">Skakel bykomende nutsfunskies aan vir bedags gebruik, soos bv. SMB</string>
<string name="objectives_7_gate">Jy moet asb die wiki lees en verhoog maksIAB om SMBs te laat werk! \'n Goeie begin is maksIAB = gemiddelde ete bolus + 3 x maks daaglikse basale</string>
<string name="objectives_openloop_objective">Begin op \'n oop lus</string>
<string name="objectives_openloop_gate">Loop in oop lus modus vir \'n paar dae en boots met hand met baie tydelike basale. Stel tydelike gebruik en verstek tydelike teikens (bv. vir aktiwiteit of hipo behandeling koolhidrate)</string>
<string name="objectives_maxbasal_objective">Verstaan jou oop lus, insluitend sy tydelike basale aanbevelings</string>
<string name="objectives_maxbasal_gate">Gebaseer op daardie ervaring, besluit watter maks basale moet gebruik word, en stel dit op die pomp en voorkeure</string>
<string name="objectives_maxiobzero_objective">Begin toe die lus met lae glukose opgeskort</string>
<string name="objectives_maxiobzero_gate">Loop in geslote lus met max IAB = 0 vir \'n paar dae sonder te veel LGS gebeure</string>
<string name="objectives_maxiob_objective">Verstel die geslote lus, verhoog maks IAB bo 0 en geleidelik verlaag BG doelwitte</string>
<string name="objectives_maxiob_gate">Lus vir \'n paar dae, en ten minste een nag met geen lae BG alarms, voor BG val</string>
<string name="objectives_autosens_objective">Pas basale en verhoudings aan as nodig, en dan aktiveer auto-sens</string>
<string name="objectives_autosens_gate">1 week suksesvolle dagtyd lus met gereelde karb toevoegings</string>
<string name="objectives_ama_objective">Skakel bykomende nutsfunskies aan vir bedagse gebruik, soos bv advanced meal assist</string>
<string name="objectives_smb_objective">Skakel bykomende nutsfunskies aan vir bedags gebruik, soos bv. SMB</string>
<string name="objectives_smb_gate">Jy moet asb die wiki lees en verhoog maksIAB om SMBs te laat werk! \'n Goeie begin is maksIAB = gemiddelde ete bolus + 3 x maks daaglikse basale</string>
<string name="youareonallowedlimit">Die toegelate limiet is bereik</string>
<string name="noprofileselected">Geen profiel gekies</string>
<string name="smscommunicator_loophasbeendisabled">Loop is gedeaktiveer</string>

View file

@ -318,19 +318,19 @@
<string name="overview_bolusprogress_goingtodeliver">Ще стартира %1$.2fЕ болус</string>
<string name="objectives_0_objective">Настройка на визуализацията и наблюдението, а също и анализиране на базалните нужди и коефициенти</string>
<string name="objectives_0_gate">Потвърждаване, че КЗ е достъпна в Найтскаут и данните за помпата се качват там</string>
<string name="objectives_1_objective">Стартиране в режим Отворен кръг (Open loop)</string>
<string name="objectives_1_gate">Работа в режим \"Отворен кръг\" за няколко дни и ръчно въвеждане на много временни базали. Настройте и използвайте временни и стандартни временни цели (напр. за активни или хипо-третирани въглехидрати)</string>
<string name="objectives_2_objective">Опитайте се да разбирате по-добре вашият APS в режим \"Отворен кръг\", включително препоръчваните временни базали</string>
<string name="objectives_2_gate">Определяне на макс. лимит на базалния инсулин и настройване в помпата и програмата</string>
<string name="objectives_3_objective">Стартиране на \"Затворен кръг\" с изключване на базал при ниска КЗ</string>
<string name="objectives_3_gate">Стартиране на \"Затворен кръг\" с макс. IOB=0 без твърде много събития тип ниска КЗ</string>
<string name="objectives_4_objective">Настройване на \"Затворен кръг\" чрез повишаване на максималният IOB над 0 и понижаване на целевите нива на КЗ</string>
<string name="objectives_4_gate">Прекарайте няколко дни по този начин, като поне една нощ нямате аларма за ниска КЗ.</string>
<string name="objectives_5_objective">Настройване на базалния инсулин и коефициенти ако е необходимо и активиране на auto-sens</string>
<string name="objectives_5_gate">Една седмица успешно дневно използване с редовно въвеждане на въглехидрати</string>
<string name="objectives_6_objective">Активиране на допълнителни функции за дневно използване, включително и advanced meal assist (АМА)</string>
<string name="objectives_7_objective">Добавяне на допълнителни функции за използване през деня, като SMB</string>
<string name="objectives_7_gate">Вие трябва да прочетете wiki и увеличите maxIOB за да може SMB да работи добре! Добро начало е maxIOB = средния болус за хранене + 3 x най-големия базал от профила</string>
<string name="objectives_openloop_objective">Стартиране в режим Отворен кръг (Open loop)</string>
<string name="objectives_openloop_gate">Работа в режим \"Отворен кръг\" за няколко дни и ръчно въвеждане на много временни базали. Настройте и използвайте временни и стандартни временни цели (напр. за активни или хипо-третирани въглехидрати)</string>
<string name="objectives_maxbasal_objective">Опитайте се да разбирате по-добре вашият APS в режим \"Отворен кръг\", включително препоръчваните временни базали</string>
<string name="objectives_maxbasal_gate">Определяне на макс. лимит на базалния инсулин и настройване в помпата и програмата</string>
<string name="objectives_maxiobzero_objective">Стартиране на \"Затворен кръг\" с изключване на базал при ниска КЗ</string>
<string name="objectives_maxiobzero_gate">Стартиране на \"Затворен кръг\" с макс. IOB=0 без твърде много събития тип ниска КЗ</string>
<string name="objectives_maxiob_objective">Настройване на \"Затворен кръг\" чрез повишаване на максималният IOB над 0 и понижаване на целевите нива на КЗ</string>
<string name="objectives_maxiob_gate">Прекарайте няколко дни по този начин, като поне една нощ нямате аларма за ниска КЗ.</string>
<string name="objectives_autosens_objective">Настройване на базалния инсулин и коефициенти ако е необходимо и активиране на auto-sens</string>
<string name="objectives_autosens_gate">Една седмица успешно дневно използване с редовно въвеждане на въглехидрати</string>
<string name="objectives_ama_objective">Активиране на допълнителни функции за дневно използване, включително и advanced meal assist (АМА)</string>
<string name="objectives_smb_objective">Добавяне на допълнителни функции за използване през деня, като SMB</string>
<string name="objectives_smb_gate">Вие трябва да прочетете wiki и увеличите maxIOB за да може SMB да работи добре! Добро начало е maxIOB = средния болус за хранене + 3 x най-големия базал от профила</string>
<string name="youareonallowedlimit">Достигнахте лимита</string>
<string name="noprofileselected">Няма избран профил</string>
<string name="smscommunicator_loophasbeendisabled">APS е деактивиран</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Podávání %1$.2fU inzulínu</string>
<string name="objectives_0_objective">Nastavit vizualizaci a monitoring, analyzovat bazály a koeficienty</string>
<string name="objectives_0_gate">Zkontrolovat, zda jsou glykémie a údaje z pumpy viditelné v Nightscoutu</string>
<string name="objectives_1_objective">Začít s otevřenou smyčkou</string>
<string name="objectives_1_gate">Provozovat několik dní otevřenou smyčku a ručně potvrzovat doporučené dočasné bazály. Nastavovat a používat dočasné cíle (např. pro sport nebo hypo)</string>
<string name="objectives_2_objective">Porozumět otevřené smyčce a doporučeným dočasným bazálům</string>
<string name="objectives_2_gate">Na základě předchozích zkušeností rozhodnout, jaký je třeba maximální bazál a nastavit ho v pumpě a v aplikaci</string>
<string name="objectives_3_objective">Začít uzavřenou smyčku pouze s hlídáním nízké glykémie</string>
<string name="objectives_3_gate">Spustit uzavřenou smyčku s max IOB = 0 na několik dní s minimem nutných korekcí na nízkou glykémii</string>
<string name="objectives_4_objective">Zapnout uzavřenou smyčku, zvyšovat max IOB nad 0 a snižovat cílovou glykémii</string>
<string name="objectives_4_gate">Provozovat smyčku několik dní s alespoň jednou nocí bez alarmů na nízkou glykémii</string>
<string name="objectives_5_objective">Upravit bazály a koeficienty, když bude potřeba a povolit automatickou detekci citlivosti na inzulín</string>
<string name="objectives_5_gate">Jeden týden úspěšného používání s běžným příjmem sacharidů</string>
<string name="objectives_6_objective">Povolit další funkce pro běžné používání jako AMA</string>
<string name="objectives_7_objective">Povolit další funkce pro běžné používání jako SMB</string>
<string name="objectives_7_gate">Přečíst si dokumentaci a zvýšit maximání IOB, aby mohlo SMB fungovat. Pro začátek se dá použít velikost běžného bolusu + 3x maximální denní bazál</string>
<string name="objectives_openloop_objective">Začít s otevřenou smyčkou</string>
<string name="objectives_openloop_gate">Provozovat několik dní otevřenou smyčku a ručně potvrzovat doporučené dočasné bazály. Nastavovat a používat dočasné cíle (např. pro sport nebo hypo)</string>
<string name="objectives_maxbasal_objective">Porozumět otevřené smyčce a doporučeným dočasným bazálům</string>
<string name="objectives_maxbasal_gate">Na základě předchozích zkušeností rozhodnout, jaký je třeba maximální bazál a nastavit ho v pumpě a v aplikaci</string>
<string name="objectives_maxiobzero_objective">Začít uzavřenou smyčku pouze s hlídáním nízké glykémie</string>
<string name="objectives_maxiobzero_gate">Spustit uzavřenou smyčku s max IOB = 0 na několik dní s minimem nutných korekcí na nízkou glykémii</string>
<string name="objectives_maxiob_objective">Zapnout uzavřenou smyčku, zvyšovat max IOB nad 0 a snižovat cílovou glykémii</string>
<string name="objectives_maxiob_gate">Provozovat smyčku několik dní s alespoň jednou nocí bez alarmů na nízkou glykémii</string>
<string name="objectives_autosens_objective">Upravit bazály a koeficienty, když bude potřeba a povolit automatickou detekci citlivosti na inzulín</string>
<string name="objectives_autosens_gate">Jeden týden úspěšného používání s běžným příjmem sacharidů</string>
<string name="objectives_ama_objective">Povolit další funkce pro běžné používání jako AMA</string>
<string name="objectives_smb_objective">Povolit další funkce pro běžné používání jako SMB</string>
<string name="objectives_smb_gate">Přečíst si dokumentaci a zvýšit maximání IOB, aby mohlo SMB fungovat. Pro začátek se dá použít velikost běžného bolusu + 3x maximální denní bazál</string>
<string name="youareonallowedlimit">Dosaženo limitu</string>
<string name="noprofileselected">Není vybrán žádný profil</string>
<string name="smscommunicator_loophasbeendisabled">Smyčka byla zakázána</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Werde %1$.2fU abgeben</string>
<string name="objectives_0_objective">Konfiguriere die Anzeige und das Monitoring (Nightscout) und analysiere Basal-Raten und Faktoren</string>
<string name="objectives_0_gate">Verifiziere, dass BZ- und Pumpen-Insulin-Daten erfolgreich zu Nightscout hochgeladen werden.</string>
<string name="objectives_1_objective">Starte den Open Loop Modus</string>
<string name="objectives_1_gate">Erprobe den Open Loop Modus für ein paar Tage und setze manuell temporäre Basal-Raten. Richte temporäre Ziele ein und nutze sie (z.B. für Bewegung, unterstützend zur Hypobehandlung).</string>
<string name="objectives_2_objective">Verstehe den Open Loop und die TBR-Empfehlungen</string>
<string name="objectives_2_gate">Entscheide anhand von dieser Erfahrung, wie hoch max Basal sein sollte, und übernehme den Wert in die Pumpen- und AAPS-Einstellungen.</string>
<string name="objectives_3_objective">Starte den Closed Loop Modus mit Abschaltung bei niedrigen Werten</string>
<string name="objectives_3_gate">Erprobe den Closed Loop Modus mit max IOB = 0 für ein paar Tage, ohne zu viele Unterzuckerungen zu haben.</string>
<string name="objectives_4_objective">Stelle den Closed Loop fein ein, erhöhe max IOB über 0 und setze den Zielbereich langsam herunter.</string>
<string name="objectives_4_gate">Verwende es ein paar Tage und zumindest eine Nacht ohne Niedrig-Alarme (UZ), bevor du den BZ-Zielbereich senkst.</string>
<string name="objectives_5_objective">Passe, falls notwendig, Basal und Faktoren an und aktiviere dann die Autosens-Funktion.</string>
<string name="objectives_5_gate">Loope eine Woche erfolgreich am Tag mit regelmäßiger Kohlenhydrat-Eingabe.</string>
<string name="objectives_6_objective">Aktiviere zusätzliche Funktionen wie z. B. den Mahlzeitenassistenten</string>
<string name="objectives_7_objective">Aktiviere zusätzliche Funktionen wie z. B. SMB</string>
<string name="objectives_7_gate">Lies das Wiki und hebe maxIOB an, damit SMB funktioniert. Ein guter Startwert ist
<string name="objectives_openloop_objective">Starte den Open Loop Modus</string>
<string name="objectives_openloop_gate">Erprobe den Open Loop Modus für ein paar Tage und setze manuell temporäre Basal-Raten. Richte temporäre Ziele ein und nutze sie (z.B. für Bewegung, unterstützend zur Hypobehandlung).</string>
<string name="objectives_maxbasal_objective">Verstehe den Open Loop und die TBR-Empfehlungen</string>
<string name="objectives_maxbasal_gate">Entscheide anhand von dieser Erfahrung, wie hoch max Basal sein sollte, und übernehme den Wert in die Pumpen- und AAPS-Einstellungen.</string>
<string name="objectives_maxiobzero_objective">Starte den Closed Loop Modus mit Abschaltung bei niedrigen Werten</string>
<string name="objectives_maxiobzero_gate">Erprobe den Closed Loop Modus mit max IOB = 0 für ein paar Tage, ohne zu viele Unterzuckerungen zu haben.</string>
<string name="objectives_maxiob_objective">Stelle den Closed Loop fein ein, erhöhe max IOB über 0 und setze den Zielbereich langsam herunter.</string>
<string name="objectives_maxiob_gate">Verwende es ein paar Tage und zumindest eine Nacht ohne Niedrig-Alarme (UZ), bevor du den BZ-Zielbereich senkst.</string>
<string name="objectives_autosens_objective">Passe, falls notwendig, Basal und Faktoren an und aktiviere dann die Autosens-Funktion.</string>
<string name="objectives_autosens_gate">Loope eine Woche erfolgreich am Tag mit regelmäßiger Kohlenhydrat-Eingabe.</string>
<string name="objectives_ama_objective">Aktiviere zusätzliche Funktionen wie z. B. den Mahlzeitenassistenten</string>
<string name="objectives_smb_objective">Aktiviere zusätzliche Funktionen wie z. B. SMB</string>
<string name="objectives_smb_gate">Lies das Wiki und hebe maxIOB an, damit SMB funktioniert. Ein guter Startwert ist
maxIOB = durchschnittlicher Essensbolus + 3 x maximale Basalrate</string>
<string name="youareonallowedlimit">Limit erreicht</string>
<string name="noprofileselected">Kein Profil ausgewählt</string>

View file

@ -317,19 +317,19 @@
<string name="overview_bolusprogress_goingtodeliver">Προς έγχυση %1$.2fU</string>
<string name="objectives_0_objective">Δημιουργία παρακολούθησης και ανάλυση βασικού ρυθμού και αναλογιών</string>
<string name="objectives_0_gate">Επιβεβαιώστε ότι η BG φαίνεται στο Nightscout και τα δεδομένα της αντλίας φορτώθηκαν</string>
<string name="objectives_1_objective">Ξεκινήστε σε ανοιχτό κύκλωμα</string>
<string name="objectives_1_gate">Εκτελέστε σε ανοιχτό κύκλωμα για μερικές ημέρες και χειροκίνητα κάντε πολλές παρεμβάσεις με προσωρινό ρυθμό. Ρυθμίστε και χρησιμοποιήστε προσωρινούς στόχους (π.χ. για αθλήματα ή υπογλυκαιμία)</string>
<string name="objectives_2_objective">Κατανοήστε το ανοιχτό κύκλωμα, περιλαμβάνοντας τις προτάσεις για Προσωρινό ρυθμό</string>
<string name="objectives_2_gate">Βάση της εμπειρίας σας, αποφασίστε ποιο είναι το μέγιστο βασικής δόσης και αποθηκεύστε το στην αντλία και στις Επιλογές</string>
<string name="objectives_3_objective">Ξεκινήστε να κλείσετε το κύκλωμα με Σταμάτημα Χαμηλής Γλυκόζης (Low Glucose Suspend) </string>
<string name="objectives_3_gate">Εκτελέστε σε κλειστό κύκλωμα με μέγιστο IOB = 0 για μερικές ημέρες χωρίς πολλά LGS - υπογλυκαιμίες</string>
<string name="objectives_4_objective">Ρυθμίζοντας το κλειστό κύκλωμα, αυξήστε το μέγιστο IOB πάνω από 0 και σταδιακά μειώστε τους στόχους BG</string>
<string name="objectives_4_gate">Τρέξτε το για λίγες ημέρες, και τουλάχιστον μία νύχτα χωρίς χαμηλό συναγερμό BG, πριν χαμηλώσετε τα όρια</string>
<string name="objectives_5_objective">Ρυθμίστε τον βασικό ρυθμό και τις αναλογίες αν χρειάζεται, και μετά ενεργοποιήστε το auto-sens</string>
<string name="objectives_5_gate">1 επιτυχής εβδομάδα ημερήσιου κυκλώματος με κανονική εισαγωγή υδατανθράκων</string>
<string name="objectives_6_objective">Ενεργοποιώντας επιπρόσθετα χαρακτηριστικά για χρήση κατά την ημέρα, όπως τον Προχωρημένο Βοηθό Γεύματος</string>
<string name="objectives_7_objective">Ενεργοποιήστε άλλες λειτουργίες για χρήση κατά την ημέρα, όπως SMB</string>
<string name="objectives_7_gate">Πρέπει να διαβάσετε τον οδηγό wiki και να αυξήσετε το ανώτατο όριο του IOB για να μπορέσει να λειτουργήσει σωστά η SMB! Μια καλή αρχή είναι μέγιστο IOB= μέσο bolus γεύματος + 3 x το μέγιστο ημερήσιο βασικού ρυθμού</string>
<string name="objectives_openloop_objective">Ξεκινήστε σε ανοιχτό κύκλωμα</string>
<string name="objectives_openloop_gate">Εκτελέστε σε ανοιχτό κύκλωμα για μερικές ημέρες και χειροκίνητα κάντε πολλές παρεμβάσεις με προσωρινό ρυθμό. Ρυθμίστε και χρησιμοποιήστε προσωρινούς στόχους (π.χ. για αθλήματα ή υπογλυκαιμία)</string>
<string name="objectives_maxbasal_objective">Κατανοήστε το ανοιχτό κύκλωμα, περιλαμβάνοντας τις προτάσεις για Προσωρινό ρυθμό</string>
<string name="objectives_maxbasal_gate">Βάση της εμπειρίας σας, αποφασίστε ποιο είναι το μέγιστο βασικής δόσης και αποθηκεύστε το στην αντλία και στις Επιλογές</string>
<string name="objectives_maxiobzero_objective">Ξεκινήστε να κλείσετε το κύκλωμα με Σταμάτημα Χαμηλής Γλυκόζης (Low Glucose Suspend) </string>
<string name="objectives_maxiobzero_gate">Εκτελέστε σε κλειστό κύκλωμα με μέγιστο IOB = 0 για μερικές ημέρες χωρίς πολλά LGS - υπογλυκαιμίες</string>
<string name="objectives_maxiob_objective">Ρυθμίζοντας το κλειστό κύκλωμα, αυξήστε το μέγιστο IOB πάνω από 0 και σταδιακά μειώστε τους στόχους BG</string>
<string name="objectives_maxiob_gate">Τρέξτε το για λίγες ημέρες, και τουλάχιστον μία νύχτα χωρίς χαμηλό συναγερμό BG, πριν χαμηλώσετε τα όρια</string>
<string name="objectives_autosens_objective">Ρυθμίστε τον βασικό ρυθμό και τις αναλογίες αν χρειάζεται, και μετά ενεργοποιήστε το auto-sens</string>
<string name="objectives_autosens_gate">1 επιτυχής εβδομάδα ημερήσιου κυκλώματος με κανονική εισαγωγή υδατανθράκων</string>
<string name="objectives_ama_objective">Ενεργοποιώντας επιπρόσθετα χαρακτηριστικά για χρήση κατά την ημέρα, όπως τον Προχωρημένο Βοηθό Γεύματος</string>
<string name="objectives_smb_objective">Ενεργοποιήστε άλλες λειτουργίες για χρήση κατά την ημέρα, όπως SMB</string>
<string name="objectives_smb_gate">Πρέπει να διαβάσετε τον οδηγό wiki και να αυξήσετε το ανώτατο όριο του IOB για να μπορέσει να λειτουργήσει σωστά η SMB! Μια καλή αρχή είναι μέγιστο IOB= μέσο bolus γεύματος + 3 x το μέγιστο ημερήσιο βασικού ρυθμού</string>
<string name="youareonallowedlimit">Φτάσατε το επιτρεπτό όριο</string>
<string name="noprofileselected">Δεν επηλέχθηκε προφίλ</string>
<string name="smscommunicator_loophasbeendisabled">Το κύκλωμα απενεργοποιήθηκε</string>

View file

@ -317,19 +317,19 @@
<string name="overview_bolusprogress_goingtodeliver">Se van a infundir %1$.2fU</string>
<string name="objectives_0_objective">Configuración de visualización y monitorización, y análisis de basales y ratios</string>
<string name="objectives_0_gate">Comprobar que los datos de BG están disponibles en Nightscout, y que los datos de la bomba de insulina se están subiendo</string>
<string name="objectives_1_objective">Empezar con lazo abierto</string>
<string name="objectives_1_gate">Ejecutar en modo de lazo abierto durante unos días, y aceptar manualmente las basales temporales. Configure y use objetivos temporales y predeterminados (por ejemplo, para actividad o carbohidratos para hipoglucemia)</string>
<string name="objectives_2_objective">Entender el lazo abierto, incluidas las recomendaciones de basales temporales</string>
<string name="objectives_2_gate">Sobre la base de esa experiencia, decidir valores de máximo basal, y ajustar la bomba y preferencias</string>
<string name="objectives_3_objective">Iniciando el lazo cerrado con suspensión con baja glucosa</string>
<string name="objectives_3_gate">Ejecutar en lazo cerrado con max IOB=0 durante unos días sin demasiados valores bajos de glucosa</string>
<string name="objectives_4_objective">Ajuste del lazo cerrado, aumentando máximo IOB por encima de 0 y bajando gradualmente objetivos BG</string>
<string name="objectives_4_gate">Funcionando unos cuantos días, y al menos una noche sin alarmas de glucosa baja, antes de bajar valor de glucosa</string>
<string name="objectives_5_objective">Ajustar los basales y ratios, si es necesario, y luego activar auto-sens</string>
<string name="objectives_5_gate">Una semana con éxito en lazo cerrado durante el día con entrada regular de carbohidratos</string>
<string name="objectives_6_objective">Habilitar funciones adicionales para su uso durante el día, como asistente de comida avanzado</string>
<string name="objectives_7_objective">Habilitar funciones adicionales para uso durante el día como SMB</string>
<string name="objectives_7_gate">¡Debes leer el wiki y subir maxIOB para que SMB funcione bien! Para comenzar un buen valor sería maxIOB = bolo de comida medio + 3 x máximo basal diario</string>
<string name="objectives_openloop_objective">Empezar con lazo abierto</string>
<string name="objectives_openloop_gate">Ejecutar en modo de lazo abierto durante unos días, y aceptar manualmente las basales temporales. Configure y use objetivos temporales y predeterminados (por ejemplo, para actividad o carbohidratos para hipoglucemia)</string>
<string name="objectives_maxbasal_objective">Entender el lazo abierto, incluidas las recomendaciones de basales temporales</string>
<string name="objectives_maxbasal_gate">Sobre la base de esa experiencia, decidir valores de máximo basal, y ajustar la bomba y preferencias</string>
<string name="objectives_maxiobzero_objective">Iniciando el lazo cerrado con suspensión con baja glucosa</string>
<string name="objectives_maxiobzero_gate">Ejecutar en lazo cerrado con max IOB=0 durante unos días sin demasiados valores bajos de glucosa</string>
<string name="objectives_maxiob_objective">Ajuste del lazo cerrado, aumentando máximo IOB por encima de 0 y bajando gradualmente objetivos BG</string>
<string name="objectives_maxiob_gate">Funcionando unos cuantos días, y al menos una noche sin alarmas de glucosa baja, antes de bajar valor de glucosa</string>
<string name="objectives_autosens_objective">Ajustar los basales y ratios, si es necesario, y luego activar auto-sens</string>
<string name="objectives_autosens_gate">Una semana con éxito en lazo cerrado durante el día con entrada regular de carbohidratos</string>
<string name="objectives_ama_objective">Habilitar funciones adicionales para su uso durante el día, como asistente de comida avanzado</string>
<string name="objectives_smb_objective">Habilitar funciones adicionales para uso durante el día como SMB</string>
<string name="objectives_smb_gate">¡Debes leer el wiki y subir maxIOB para que SMB funcione bien! Para comenzar un buen valor sería maxIOB = bolo de comida medio + 3 x máximo basal diario</string>
<string name="youareonallowedlimit">Alcanzado el límite permitido</string>
<string name="noprofileselected">Sin perfil seleccionado</string>
<string name="smscommunicator_loophasbeendisabled">Lazo se ha desactivado</string>

View file

@ -320,19 +320,19 @@ L\'ENSEMBLE DES RISQUES LIÉS À LA QUALITÉ ET À LA PERFORMANCE DU PROGRAMME S
<string name="overview_bolusprogress_goingtodeliver">%1$.2fU vont être injectées</string>
<string name="objectives_0_objective">Paramétrer la visualisation et la surveillance des données, analyser les débits de basal et les ratios</string>
<string name="objectives_0_gate">Vérifiez que la Glycémie est disponible sur Nightscout et que les données dinsuline ont été téléchargées de la pompe</string>
<string name="objectives_1_objective">Commencez par la configuration Boucle Ouverte</string>
<string name="objectives_1_gate">Utiliser le système Boucle Ouverte pour quelques jours, et activer manuellement de nombreux débits de basal temporaires. Définir et utiliser des objectifs temporaires (ex : activités ou utilisation de glucides pour traiter des hypos)</string>
<string name="objectives_2_objective">Comprendre votre système Boucle Ouverte, y compris ses recommandations de débit de Basal temporaire</string>
<string name="objectives_2_gate">Partant de ce constat, décidez quel est le débit de base maximum à choisir, et entrez le dans la pompe et les préférences </string>
<string name="objectives_3_objective">Commencez par utiliser la Boucle Fermée avec le système Arrêt Glycémie Basse</string>
<string name="objectives_3_gate">Utiliser la Boucle Fermée avec max IA = 0 pour quelques jours sans avoir trop dévénements AGB Arrêt Glycémie Basse (LGS Low Glucose Suspend)</string>
<string name="objectives_4_objective">Ajustez votre système Boucle Fermée, augmentez la fonction « max IOB » au delà de 0 et diminuez progressivement vos cibles glycémiques</string>
<string name="objectives_4_gate">Utiliser pendant quelques jours, et au moins une nuit sans les alarmes dhypoglycémie, avant la baisse de G</string>
<string name="objectives_5_objective">Ajustez si besoin les débits de base et les ratios, activez ensuite « Autosens »</string>
<string name="objectives_5_gate">Une semaine réussie avec des journées en Boucle Fermée, avec des entrées normales des glucides</string>
<string name="objectives_6_objective">Activer dautres fonctionnalités pour lutilisation dans la journée, tel que Assistance Repas Avancée (AMA Advanced Meal Assist)</string>
<string name="objectives_7_objective">Activer des fonctionnalités supplémentaires pour l\'utilisation dans la journée, telles que la fonction SMB</string>
<string name="objectives_7_gate">Vous devez lire le wiki et augmenter les max IA pour faire fonctionner SMB ! Un bon début est max IA = moyenne bolus repas + 3 fois max daily basal</string>
<string name="objectives_openloop_objective">Commencez par la configuration Boucle Ouverte</string>
<string name="objectives_openloop_gate">Utiliser le système Boucle Ouverte pour quelques jours, et activer manuellement de nombreux débits de basal temporaires. Définir et utiliser des objectifs temporaires (ex : activités ou utilisation de glucides pour traiter des hypos)</string>
<string name="objectives_maxbasal_objective">Comprendre votre système Boucle Ouverte, y compris ses recommandations de débit de Basal temporaire</string>
<string name="objectives_maxbasal_gate">Partant de ce constat, décidez quel est le débit de base maximum à choisir, et entrez le dans la pompe et les préférences </string>
<string name="objectives_maxiobzero_objective">Commencez par utiliser la Boucle Fermée avec le système Arrêt Glycémie Basse</string>
<string name="objectives_maxiobzero_gate">Utiliser la Boucle Fermée avec max IA = 0 pour quelques jours sans avoir trop dévénements AGB Arrêt Glycémie Basse (LGS Low Glucose Suspend)</string>
<string name="objectives_maxiob_objective">Ajustez votre système Boucle Fermée, augmentez la fonction « max IOB » au delà de 0 et diminuez progressivement vos cibles glycémiques</string>
<string name="objectives_maxiob_gate">Utiliser pendant quelques jours, et au moins une nuit sans les alarmes dhypoglycémie, avant la baisse de G</string>
<string name="objectives_autosens_objective">Ajustez si besoin les débits de base et les ratios, activez ensuite « Autosens »</string>
<string name="objectives_autosens_gate">Une semaine réussie avec des journées en Boucle Fermée, avec des entrées normales des glucides</string>
<string name="objectives_ama_objective">Activer dautres fonctionnalités pour lutilisation dans la journée, tel que Assistance Repas Avancée (AMA Advanced Meal Assist)</string>
<string name="objectives_smb_objective">Activer des fonctionnalités supplémentaires pour l\'utilisation dans la journée, telles que la fonction SMB</string>
<string name="objectives_smb_gate">Vous devez lire le wiki et augmenter les max IA pour faire fonctionner SMB ! Un bon début est max IA = moyenne bolus repas + 3 fois max daily basal</string>
<string name="youareonallowedlimit">Vous avez atteint la limite maximale</string>
<string name="noprofileselected">Aucun profil séléctionné</string>
<string name="smscommunicator_loophasbeendisabled">La Boucle été désactivée</string>

View file

@ -34,6 +34,7 @@
<string name="description_smb">Algoritmo più recente per gli utenti avanzati</string>
<string name="description_overview">Visualizza lo stato corrente del tuo loop e i pulsanti per le azioni più comuni</string>
<string name="description_persistent_notification">Mostra una notifica con una breve panoramica di ciò che sta facendo il tuo loop</string>
<string name="description_profile_local">Definisci un profilo disponibile offline.</string>
<string name="description_profile_nightscout">Fornisce il profilo definito in Nightscout</string>
<string name="description_profile_simple">Imposta un profilo con un solo intervallo temporale.</string>
<string name="description_pump_combo">Integrazione del microinfusore Accu-Chek Combo, è necessario avere Ruffy installato</string>
@ -318,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Sto per erogare %1$.2fU</string>
<string name="objectives_0_objective">Configurazione della visualizzazione e del monitoraggio, analisi basali e rapporti</string>
<string name="objectives_0_gate">Verificare che la Glicemia sia disponibile su Nightscout e che i dati sull\'insulina del micro siano in fase di caricamento</string>
<string name="objectives_1_objective">Partenza con Loop Aperto</string>
<string name="objectives_1_gate">Esegui l\'applicazione in modalità Loop Aperto per alcuni giorni e accetta manualmente le basali temporanee. Imposta e utilizza i target temporanei, anche quelli predefiniti (ad esempio, per l\'attività fisica o il trattamento dell\'ipoglicemia con carboidrati)</string>
<string name="objectives_2_objective">Comprendi il tuo Loop Aperto, incluse le relative raccomandazioni sulle basali temporanee</string>
<string name="objectives_2_gate">Sulla base di tale esperienza, decidi quale deve essere il valore max della basale e impostalo sul microinfusore e nelle preferenze</string>
<string name="objectives_3_objective">Iniziare a chiudere il Loop con Low Glucose Suspend</string>
<string name="objectives_3_gate">Esegui l\'applicazione in Loop Chiuso con max IOB = 0 per pochi giorni senza troppi eventi LGS</string>
<string name="objectives_4_objective">Regola il Loop Chiuso, aumentando max IOB al di sopra di 0 e abbassando gradualmente i target glicemici</string>
<string name="objectives_4_gate">Esegui l\'applicazione per alcuni giorni e almeno una notte senza allarmi glicemia, prima di abbassare il target glicemico</string>
<string name="objectives_5_objective">Regola le basali e i rapporti se necessario, quindi attiva auto-sens</string>
<string name="objectives_5_gate">1 settimana di looping diurno con dichiarazione regolare dei carboidrati, eseguito con successo</string>
<string name="objectives_6_objective">Abilita funzioni aggiuntive per l\'uso diurno, ad esempio AMA (advanced meal assist - assistenza avanzata del pasto)</string>
<string name="objectives_7_objective">Abilita funzioni aggiuntive per l\'uso diurno, come SMB</string>
<string name="objectives_7_gate">È necessario leggere il wiki e aumentare maxIOB affinché le azioni di SMB funzionino adeguatamente! Un buon inizio è maxIOB = media bolo posto + 3 x max basale giornaliera</string>
<string name="objectives_openloop_objective">Partenza con Loop Aperto</string>
<string name="objectives_openloop_gate">Esegui l\'applicazione in modalità Loop Aperto per alcuni giorni e accetta manualmente le basali temporanee. Imposta e utilizza i target temporanei, anche quelli predefiniti (ad esempio, per l\'attività fisica o il trattamento dell\'ipoglicemia con carboidrati)</string>
<string name="objectives_maxbasal_objective">Comprendi il tuo Loop Aperto, incluse le relative raccomandazioni sulle basali temporanee</string>
<string name="objectives_maxbasal_gate">Sulla base di tale esperienza, decidi quale deve essere il valore max della basale e impostalo sul microinfusore e nelle preferenze</string>
<string name="objectives_maxiobzero_objective">Iniziare a chiudere il Loop con Low Glucose Suspend</string>
<string name="objectives_maxiobzero_gate">Esegui l\'applicazione in Loop Chiuso con max IOB = 0 per pochi giorni senza troppi eventi LGS</string>
<string name="objectives_maxiob_objective">Regola il Loop Chiuso, aumentando max IOB al di sopra di 0 e abbassando gradualmente i target glicemici</string>
<string name="objectives_maxiob_gate">Esegui l\'applicazione per alcuni giorni e almeno una notte senza allarmi glicemia, prima di abbassare il target glicemico</string>
<string name="objectives_autosens_objective">Regola le basali e i rapporti se necessario, quindi attiva auto-sens</string>
<string name="objectives_autosens_gate">1 settimana di looping diurno con dichiarazione regolare dei carboidrati, eseguito con successo</string>
<string name="objectives_ama_objective">Abilita funzioni aggiuntive per l\'uso diurno, ad esempio AMA (advanced meal assist - assistenza avanzata del pasto)</string>
<string name="objectives_smb_objective">Abilita funzioni aggiuntive per l\'uso diurno, come SMB</string>
<string name="objectives_smb_gate">È necessario leggere il wiki e aumentare maxIOB affinché le azioni di SMB funzionino adeguatamente! Un buon inizio è maxIOB = media bolo posto + 3 x max basale giornaliera</string>
<string name="youareonallowedlimit">Hai raggiunto il limite consentito</string>
<string name="noprofileselected">Nessun profilo selezionato</string>
<string name="smscommunicator_loophasbeendisabled">Disattivazione Loop corretta</string>
@ -950,6 +951,7 @@
<string name="sensitivitysetup">Configura il plugin di Sensibilità</string>
<string name="setupwizard_sensitivity_description">Il plugin di Sensibilità è utilizzato per il rilevamento della sensibilità all\'insulina e il calcolo di COB. Per ulteriori informazioni visita:</string>
<string name="setupwizard_sensitivity_url">https://github.com/MilosKozak/AndroidAPS/wiki/Sensitivity-detection-and-COB</string>
<string name="nsclientinfotext">NSClient gestisce la connessione a Nightscout. Puoi saltare questa parte ora, ma non sarai in grado di superare gli obiettivi fino a quando non ne porterai a termine la configurazione.</string>
<string name="diawarning">Ricorda: i nuovi profili di insulina richiedono una DIA di almeno 5h. DIA di 5 - 6h sui nuovi profili sono uguali a DIA di 3h sui vecchi profili di insulina.</string>
<string name="bgsourcesetup">Configura sorgente Glicemie</string>
<string name="setupwizard_profile_description">Seleziona il tipo di profilo. Se il paziente è un bambino è necessario utilizzare il profilo di NS. Se non c\'è nessuno a seguirti su Nightscout probabilmente preferirai il profilo locale. Ricorda che stai solo selezionando la sorgente del profilo. Per utilizzarlo devi attivarlo tramite l\'esecuzione del comando \"Cambio Profilo\"</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">%1$.2fU을 주입합니다</string>
<string name="objectives_0_objective">표시설정과 모니터설정을 완료하고, Basal과 비율을 분석한다.</string>
<string name="objectives_0_gate">나이트스카우트에서 혈당 데이터가 잘 들어오는지, 펌프데이터가 업로드 되는지 확인한다.</string>
<string name="objectives_1_objective">Open Loop를 시작한다.</string>
<string name="objectives_1_gate">Open Loop 모드에서 몇일간 사용하여보고, 임시Basal을 여러번 수동으로 주입해 본다. 임시목표와 기본임시목표(\'식사직전\', \'활동\',\'저혈당\' 임시목표)를 설정하고 사용해 본다.</string>
<string name="objectives_2_objective">임시Basal 추천기능을 포함해서, Open Loop에 대해 이해한다.</string>
<string name="objectives_2_gate">이 경험을 토대로, 최대 Basal을 결정하고 이를 펌프와 설정에 입력한다.</string>
<string name="objectives_3_objective">Closed Loop를 시작하고 저혈당인슐린 중지 기능을 사용해본다.</string>
<string name="objectives_3_gate">최대 IOB = 0 인 상태로 Closed Loop를 몇일동안 실행시켜 본다. 저혈당 인슐린일시중지가 많이 발생하지 않도록 한다.</string>
<string name="objectives_4_objective">Closed Loop를 조정하여 최대 IOB를 0 이상으로 올려서 서서히 혈당 목표치를 낮춘다.</string>
<string name="objectives_4_gate">혈당을 낮추기 전에 몇일간 사용해보되 최소한 하루는 저혈당 혈당 알람이 발생하지 않도록 해본다.</string>
<string name="objectives_5_objective">필요하면 Basal과 비율을 조절하고, auto-sens를 활성화한다.</string>
<string name="objectives_5_gate">평소의 탄수화물을 입력하면서 1주일동안 낮시간대에 loop를 성공적으로 사용해본다.</string>
<string name="objectives_6_objective">AMA(Advanced Meal Assist)같은 낮시간대를 위한 추가적인 기능들을 실행하여 본다.</string>
<string name="objectives_7_objective">낮시간대에 SMB(Super Micro Bolus)같은 추가기능을 활성화해 사용해본다.</string>
<string name="objectives_7_gate">SMB가 잘 작동하게 하기위해서 wiki를 반드시 읽은다음 maxIOB를 올려주세요. maxIOB=평균 식사 Bolus + 3 x 최대하루 Basal이면 괜찮은 시작값입니다.</string>
<string name="objectives_openloop_objective">Open Loop를 시작한다.</string>
<string name="objectives_openloop_gate">Open Loop 모드에서 몇일간 사용하여보고, 임시Basal을 여러번 수동으로 주입해 본다. 임시목표와 기본임시목표(\'식사직전\', \'활동\',\'저혈당\' 임시목표)를 설정하고 사용해 본다.</string>
<string name="objectives_maxbasal_objective">임시Basal 추천기능을 포함해서, Open Loop에 대해 이해한다.</string>
<string name="objectives_maxbasal_gate">이 경험을 토대로, 최대 Basal을 결정하고 이를 펌프와 설정에 입력한다.</string>
<string name="objectives_maxiobzero_objective">Closed Loop를 시작하고 저혈당인슐린 중지 기능을 사용해본다.</string>
<string name="objectives_maxiobzero_gate">최대 IOB = 0 인 상태로 Closed Loop를 몇일동안 실행시켜 본다. 저혈당 인슐린일시중지가 많이 발생하지 않도록 한다.</string>
<string name="objectives_maxiob_objective">Closed Loop를 조정하여 최대 IOB를 0 이상으로 올려서 서서히 혈당 목표치를 낮춘다.</string>
<string name="objectives_maxiob_gate">혈당을 낮추기 전에 몇일간 사용해보되 최소한 하루는 저혈당 혈당 알람이 발생하지 않도록 해본다.</string>
<string name="objectives_autosens_objective">필요하면 Basal과 비율을 조절하고, auto-sens를 활성화한다.</string>
<string name="objectives_autosens_gate">평소의 탄수화물을 입력하면서 1주일동안 낮시간대에 loop를 성공적으로 사용해본다.</string>
<string name="objectives_ama_objective">AMA(Advanced Meal Assist)같은 낮시간대를 위한 추가적인 기능들을 실행하여 본다.</string>
<string name="objectives_smb_objective">낮시간대에 SMB(Super Micro Bolus)같은 추가기능을 활성화해 사용해본다.</string>
<string name="objectives_smb_gate">SMB가 잘 작동하게 하기위해서 wiki를 반드시 읽은다음 maxIOB를 올려주세요. maxIOB=평균 식사 Bolus + 3 x 최대하루 Basal이면 괜찮은 시작값입니다.</string>
<string name="youareonallowedlimit">허용된 제한값에 도달하였습니다</string>
<string name="noprofileselected">프로파일이 선택되지 않았습니다</string>
<string name="smscommunicator_loophasbeendisabled">Loop가 중지되었습니다.</string>

View file

@ -317,19 +317,19 @@
<string name="overview_bolusprogress_goingtodeliver">Bus suleista %1$.2fvv</string>
<string name="objectives_0_objective">Nustatymai vizualizacijai, monitoringui ir bazės verčių bei koeficientų analizei</string>
<string name="objectives_0_gate">Įsitikinkite, kad gliukozės duomenys rodomi Nightscout, o pompos insulino duomenys yra įkelti</string>
<string name="objectives_1_objective">Aktyvuojamas atviras ciklas</string>
<string name="objectives_1_gate">Keletą dienų praleiskite atvirojo ciklo (Open Loop) režime, rankiniu būdu tvirtindami kuo daugiau siūlomų bazės pakeitimų. Nustatykite ir naudokite laikinus bei numatytuosiuos tikslus (pvz.: fiziniam aktyvumui ir hipo korekcijai angliavandeniais)</string>
<string name="objectives_2_objective">Perpraskite atvirojo ciklo veikimą bei laikinos bazės rekomendacijas</string>
<string name="objectives_2_gate">Remdamiesi šia patirtimi, nuspręskite, koks turėtų būti maksimalus bazės dydis bei įveskite jį pompoje ir programos Nustatymuose</string>
<string name="objectives_3_objective">Pradėkite uždaro ciklo (Closed Loop) režimą su pompos stabdymu esant žemai gliukozei</string>
<string name="objectives_3_gate">Keletą dienų praleiskite uždaro ciklo režime su kuo mažiau hipoglikemijų, kai IK = 0</string>
<string name="objectives_4_objective">Koreguokite savo uždarąjį ciklą po truputį didindami maks IK ir mažindami tikslinę gliukozės vertę</string>
<string name="objectives_4_gate">Praleiskite keletą dienų ir bent vieną naktį be hipoglikemijos aliarmų</string>
<string name="objectives_5_objective">Jei reikia, paderinkite valandines bazės vertes bei pagrindinius parametrus ir įgalinkite Autosens funkciją.</string>
<string name="objectives_5_gate">1 savaitę praleiskite sėkmingai naudodami uždarąjį ciklą dienos metu ir įvesdami visus valgomus angliavandenius.</string>
<string name="objectives_6_objective">Dienos metu aktyvuokite papildomas funkcijas, tokias kaip pažangioji maisto skaičiuoklė (AMA Advanced Meal Assist)</string>
<string name="objectives_7_objective">Dienos metu aktyvuokite papildomas funkcijas, tokias kaip SMB (Super Mikro Bolusas).</string>
<string name="objectives_7_gate">Norėdami, kad SMB veiktų gerai, turite perskaityti dokumentaciją ir padidinti max IK! Pradžiai patartina skaičiuoti taip: maxIK=(didžiausia valandinė bazė x 3) + vidutinis bolusas.</string>
<string name="objectives_openloop_objective">Aktyvuojamas atviras ciklas</string>
<string name="objectives_openloop_gate">Keletą dienų praleiskite atvirojo ciklo (Open Loop) režime, rankiniu būdu tvirtindami kuo daugiau siūlomų bazės pakeitimų. Nustatykite ir naudokite laikinus bei numatytuosiuos tikslus (pvz.: fiziniam aktyvumui ir hipo korekcijai angliavandeniais)</string>
<string name="objectives_maxbasal_objective">Perpraskite atvirojo ciklo veikimą bei laikinos bazės rekomendacijas</string>
<string name="objectives_maxbasal_gate">Remdamiesi šia patirtimi, nuspręskite, koks turėtų būti maksimalus bazės dydis bei įveskite jį pompoje ir programos Nustatymuose</string>
<string name="objectives_maxiobzero_objective">Pradėkite uždaro ciklo (Closed Loop) režimą su pompos stabdymu esant žemai gliukozei</string>
<string name="objectives_maxiobzero_gate">Keletą dienų praleiskite uždaro ciklo režime su kuo mažiau hipoglikemijų, kai IK = 0</string>
<string name="objectives_maxiob_objective">Koreguokite savo uždarąjį ciklą po truputį didindami maks IK ir mažindami tikslinę gliukozės vertę</string>
<string name="objectives_maxiob_gate">Praleiskite keletą dienų ir bent vieną naktį be hipoglikemijos aliarmų</string>
<string name="objectives_autosens_objective">Jei reikia, paderinkite valandines bazės vertes bei pagrindinius parametrus ir įgalinkite Autosens funkciją.</string>
<string name="objectives_autosens_gate">1 savaitę praleiskite sėkmingai naudodami uždarąjį ciklą dienos metu ir įvesdami visus valgomus angliavandenius.</string>
<string name="objectives_ama_objective">Dienos metu aktyvuokite papildomas funkcijas, tokias kaip pažangioji maisto skaičiuoklė (AMA Advanced Meal Assist)</string>
<string name="objectives_smb_objective">Dienos metu aktyvuokite papildomas funkcijas, tokias kaip SMB (Super Mikro Bolusas).</string>
<string name="objectives_smb_gate">Norėdami, kad SMB veiktų gerai, turite perskaityti dokumentaciją ir padidinti max IK! Pradžiai patartina skaičiuoti taip: maxIK=(didžiausia valandinė bazė x 3) + vidutinis bolusas.</string>
<string name="youareonallowedlimit">Pasiekėte leistiną ribą</string>
<string name="noprofileselected">Nepasirinktas profilis</string>
<string name="smscommunicator_loophasbeendisabled">Ciklas buvo išjungtas</string>

View file

@ -319,20 +319,20 @@
<string name="overview_bolusprogress_goingtodeliver">Er worden %1$.2fE toegediend</string>
<string name="objectives_0_objective">Opzetten van visualisatie en monitoring en analyzeren van basaal en ratio\'s</string>
<string name="objectives_0_gate">Controleren van beschikbaarheid BG en insuline pomp data op Nightscout</string>
<string name="objectives_1_objective">Starten met de Open Loop modus</string>
<string name="objectives_1_gate">In Open Loop modus werken voor enkele dagen en handmatig meermaals tijdelijke basaal instellen.
<string name="objectives_openloop_objective">Starten met de Open Loop modus</string>
<string name="objectives_openloop_gate">In Open Loop modus werken voor enkele dagen en handmatig meermaals tijdelijke basaal instellen.
Stel in en gebruik tijdelijk en standaard tijdelijke streefdoelen (bv. bij sporten of koolhydraten inname bij hypo)</string>
<string name="objectives_2_objective">De Open Loop begrijpen, inclusief de voorgestelde tijdelijke basaalstanden</string>
<string name="objectives_2_gate">Gebaseerd op deze ervaringen beslissen wat het maximale basaal mag zijn en dit in de pomp instellen</string>
<string name="objectives_3_objective">Starten met closed Loop met bescherming tegen lage BG</string>
<string name="objectives_3_gate">In closed Loop werken met een max. IOB = 0 gedurende enkele dagen met een beperkt aantal lage BG</string>
<string name="objectives_4_objective">Inregelen van de closed loop, verhoog de max IOB boven 0 en laat gelijdelijk het streef BG dalen</string>
<string name="objectives_4_gate">Verhoog max. IOB en test enkele dagen als ook minstens 1 nacht zonder een laag BG alarm voordat je jouw streef BG verlaagt</string>
<string name="objectives_5_objective">Pas het basaal en de ratios aan indien nodig, activeer hierna de auto-sens optie</string>
<string name="objectives_5_gate">Gedurende 1 week succesvol closed loop met invoer van koolhydraten</string>
<string name="objectives_6_objective">Activeren van extra functies overdag zoals AMA</string>
<string name="objectives_7_objective">Activeren van extra functies overdag zoals SMB</string>
<string name="objectives_7_gate">Lees de wiki en verhoog maxIOB om SMB goed werkend te krijgen. Een goed begin is maxIOB=gemiddelde maaltijdbolus + 3 x max dagelijkse basaal</string>
<string name="objectives_maxbasal_objective">De Open Loop begrijpen, inclusief de voorgestelde tijdelijke basaalstanden</string>
<string name="objectives_maxbasal_gate">Gebaseerd op deze ervaringen beslissen wat het maximale basaal mag zijn en dit in de pomp instellen</string>
<string name="objectives_maxiobzero_objective">Starten met closed Loop met bescherming tegen lage BG</string>
<string name="objectives_maxiobzero_gate">In closed Loop werken met een max. IOB = 0 gedurende enkele dagen met een beperkt aantal lage BG</string>
<string name="objectives_maxiob_objective">Inregelen van de closed loop, verhoog de max IOB boven 0 en laat gelijdelijk het streef BG dalen</string>
<string name="objectives_maxiob_gate">Verhoog max. IOB en test enkele dagen als ook minstens 1 nacht zonder een laag BG alarm voordat je jouw streef BG verlaagt</string>
<string name="objectives_autosens_objective">Pas het basaal en de ratios aan indien nodig, activeer hierna de auto-sens optie</string>
<string name="objectives_autosens_gate">Gedurende 1 week succesvol closed loop met invoer van koolhydraten</string>
<string name="objectives_ama_objective">Activeren van extra functies overdag zoals AMA</string>
<string name="objectives_smb_objective">Activeren van extra functies overdag zoals SMB</string>
<string name="objectives_smb_gate">Lees de wiki en verhoog maxIOB om SMB goed werkend te krijgen. Een goed begin is maxIOB=gemiddelde maaltijdbolus + 3 x max dagelijkse basaal</string>
<string name="youareonallowedlimit">Limiet bereikt</string>
<string name="noprofileselected">Geen profiel geselecteerd</string>
<string name="smscommunicator_loophasbeendisabled">Loop was uitgeschakeld</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Zamierzam dostarczyć %1$.2fU</string>
<string name="objectives_0_objective">Konfiguracja wizualizacji i monitorowania, analiza dawek i wartości bazowych</string>
<string name="objectives_0_gate">Sprawdź czy BG (pomiary cukru) są dostępne w Nightscout, i dane pompy insulinowej są ładowane</string>
<string name="objectives_1_objective">Uruchamiam otwartą pętle (OpenLoop)</string>
<string name="objectives_1_gate">Używaj Otwartą pętle (OpenLoop) przez kilka dni, i ręcznie wykonaj wiele dawek bazowych tymczasowych (np. podczas aktywności fizycznej lub leczenia hipoglikemii węglowodanami)</string>
<string name="objectives_2_objective">Zrozumienie działania otwartej pętli, wraz z jej rekomendacjami dawek tymczasowych</string>
<string name="objectives_2_gate">Na podstawie tych doświadczeń zdecyduj jaka maksymalna baza powinna być ustawiona, i wprowadź ją w pompie i w ustawieniach AAPS</string>
<string name="objectives_3_objective">Rozpoczęcie zamknięcia pętli z zawieszeniem podawania bazy przy niskim poziomie cukru</string>
<string name="objectives_3_gate">Używaj zamkniętej pętli (Closed Loop) z max IOB (maksymalną dawką aktywnej insuliny) = 0 bez zbyt wielu incydentów niedocukrzeń</string>
<string name="objectives_4_objective">Dostrajanie zamkniętej pętli, podniesienie wartości max IOB powyżej 0 i stopniowe obniżanie docelowego poziomu cukru (BG target)</string>
<string name="objectives_4_gate">Używaj pętli przez kilka dni i przynajmniej jedną noc bez żadnego alarmu niskiego poziomu, przed obniżeniem docelowego poziomu cukru (BG target)</string>
<string name="objectives_5_objective">Dostosuj bazę i wartości parametrów, i wtedy uruchom funkcję autosens</string>
<string name="objectives_5_gate">1 tydzień sukcesu w działaniu pętli w ciągu dnia z regularnym wprowadzaniem spożywanych węglowodanów (węglow.)</string>
<string name="objectives_6_objective">Uruchomienie do użytku dziennego dodatkowych funkcji, jak AMA (zaawansowany asystent posiłku)</string>
<string name="objectives_7_objective">Uruchomienie do użytku dziennego dodatkowych funkcji, jak SMB (Super Mikro Bolusy)</string>
<string name="objectives_7_gate">Musisz przeczytać wiki i zwiększyć maxIOB, aby SMB działało dobrze! Dobrym początkiem jest max10 = średni bolus + 3 x maks. dzienna dawka bazowa</string>
<string name="objectives_openloop_objective">Uruchamiam otwartą pętle (OpenLoop)</string>
<string name="objectives_openloop_gate">Używaj Otwartą pętle (OpenLoop) przez kilka dni, i ręcznie wykonaj wiele dawek bazowych tymczasowych (np. podczas aktywności fizycznej lub leczenia hipoglikemii węglowodanami)</string>
<string name="objectives_maxbasal_objective">Zrozumienie działania otwartej pętli, wraz z jej rekomendacjami dawek tymczasowych</string>
<string name="objectives_maxbasal_gate">Na podstawie tych doświadczeń zdecyduj jaka maksymalna baza powinna być ustawiona, i wprowadź ją w pompie i w ustawieniach AAPS</string>
<string name="objectives_maxiobzero_objective">Rozpoczęcie zamknięcia pętli z zawieszeniem podawania bazy przy niskim poziomie cukru</string>
<string name="objectives_maxiobzero_gate">Używaj zamkniętej pętli (Closed Loop) z max IOB (maksymalną dawką aktywnej insuliny) = 0 bez zbyt wielu incydentów niedocukrzeń</string>
<string name="objectives_maxiob_objective">Dostrajanie zamkniętej pętli, podniesienie wartości max IOB powyżej 0 i stopniowe obniżanie docelowego poziomu cukru (BG target)</string>
<string name="objectives_maxiob_gate">Używaj pętli przez kilka dni i przynajmniej jedną noc bez żadnego alarmu niskiego poziomu, przed obniżeniem docelowego poziomu cukru (BG target)</string>
<string name="objectives_autosens_objective">Dostosuj bazę i wartości parametrów, i wtedy uruchom funkcję autosens</string>
<string name="objectives_autosens_gate">1 tydzień sukcesu w działaniu pętli w ciągu dnia z regularnym wprowadzaniem spożywanych węglowodanów (węglow.)</string>
<string name="objectives_ama_objective">Uruchomienie do użytku dziennego dodatkowych funkcji, jak AMA (zaawansowany asystent posiłku)</string>
<string name="objectives_smb_objective">Uruchomienie do użytku dziennego dodatkowych funkcji, jak SMB (Super Mikro Bolusy)</string>
<string name="objectives_smb_gate">Musisz przeczytać wiki i zwiększyć maxIOB, aby SMB działało dobrze! Dobrym początkiem jest max10 = średni bolus + 3 x maks. dzienna dawka bazowa</string>
<string name="youareonallowedlimit">Osiągnąłeś dozwolony limit</string>
<string name="noprofileselected">Nie wybrano profilu</string>
<string name="smscommunicator_loophasbeendisabled">Pętla (Loop) została wyłączona</string>

View file

@ -318,19 +318,19 @@
<string name="overview_bolusprogress_goingtodeliver">Vão ser administradas %1$.2fU</string>
<string name="objectives_0_objective">Configuração da visualização e monitoramento, e análise de rácios e basals</string>
<string name="objectives_0_gate">Verificar se a BG está disponível no Nightscout, e se os dados de insulina da bomba estão a ser carregados</string>
<string name="objectives_1_objective">A iniciar um open loop</string>
<string name="objectives_1_gate">Execute no Modo de Loop aberto por alguns dias e execute manualmente muitos basais de temp. Configure e use alvos temporários e padrão (por exemplo, para atividades ou tratamento hipos com carboidratos)</string>
<string name="objectives_2_objective">Compreender o seu open loop, incluindo as suas recomendações de basais temporárias</string>
<string name="objectives_2_gate">Com base nessa experiência, decidir qual deve ser a basal máxima e configurá-la na bomba e nas preferências</string>
<string name="objectives_3_objective">Começar o close loop com Suspensão por Glicose Baixa.</string>
<string name="objectives_3_gate">Utilizar em close loop com IOB máx = 0 por alguns dias sem muitas situações de Suspensão por Baixa Glicose</string>
<string name="objectives_4_objective">Ajustar o close loop, levantar a IOB máxima acima de 0 e reduzir gradualmente os alvos de valor glicémico</string>
<string name="objectives_4_gate">Utilizar por alguns dias e pelo menos uma noite sem alarmes de valores glicémicos baixos, antes de baixar os valores</string>
<string name="objectives_5_objective">Ajustar as basals e os rácios se necessário e em seguida habilitar o auto-sens</string>
<string name="objectives_5_gate">1 semana de looping durante o dia com sucesso com entrada de hidratos de carbono regular</string>
<string name="objectives_6_objective">Ativando recursos adicionais para uso durante o dia, como assistente avançado de refeição</string>
<string name="objectives_7_objective">Ativando recursos adicionais para uso durante o dia, como SMB</string>
<string name="objectives_7_gate">Deverá ler a wiki e aumentar a IOB máx para que os SMBs funcionem devidamente! Inicialmente poderá considerar maxIOB= média dos bolus + 3 x a basal máxima</string>
<string name="objectives_openloop_objective">A iniciar um open loop</string>
<string name="objectives_openloop_gate">Execute no Modo de Loop aberto por alguns dias e execute manualmente muitos basais de temp. Configure e use alvos temporários e padrão (por exemplo, para atividades ou tratamento hipos com carboidratos)</string>
<string name="objectives_maxbasal_objective">Compreender o seu open loop, incluindo as suas recomendações de basais temporárias</string>
<string name="objectives_maxbasal_gate">Com base nessa experiência, decidir qual deve ser a basal máxima e configurá-la na bomba e nas preferências</string>
<string name="objectives_maxiobzero_objective">Começar o close loop com Suspensão por Glicose Baixa.</string>
<string name="objectives_maxiobzero_gate">Utilizar em close loop com IOB máx = 0 por alguns dias sem muitas situações de Suspensão por Baixa Glicose</string>
<string name="objectives_maxiob_objective">Ajustar o close loop, levantar a IOB máxima acima de 0 e reduzir gradualmente os alvos de valor glicémico</string>
<string name="objectives_maxiob_gate">Utilizar por alguns dias e pelo menos uma noite sem alarmes de valores glicémicos baixos, antes de baixar os valores</string>
<string name="objectives_autosens_objective">Ajustar as basals e os rácios se necessário e em seguida habilitar o auto-sens</string>
<string name="objectives_autosens_gate">1 semana de looping durante o dia com sucesso com entrada de hidratos de carbono regular</string>
<string name="objectives_ama_objective">Ativando recursos adicionais para uso durante o dia, como assistente avançado de refeição</string>
<string name="objectives_smb_objective">Ativando recursos adicionais para uso durante o dia, como SMB</string>
<string name="objectives_smb_gate">Deverá ler a wiki e aumentar a IOB máx para que os SMBs funcionem devidamente! Inicialmente poderá considerar maxIOB= média dos bolus + 3 x a basal máxima</string>
<string name="youareonallowedlimit">Atingiu o limite autorizado</string>
<string name="noprofileselected">Nenhum perfil selecionado</string>
<string name="smscommunicator_loophasbeendisabled">Loop foi desativado</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Vão ser administradas %1$.2fU</string>
<string name="objectives_0_objective">Configuração da visualização e monitoramento, e análise de rácios e basals</string>
<string name="objectives_0_gate">Verificar se a BG está disponível no Nightscout, e se os dados de insulina da bomba estão a ser carregados</string>
<string name="objectives_1_objective">A iniciar um open loop</string>
<string name="objectives_1_gate">Utilizar em modo de open loop por alguns dias e dar manualmente muitas basais temporárias. Configurar e usar alvos temporários e alvos padrão temporários (por exemplo, para atividade ou tratamentos de hipo com Hcs)</string>
<string name="objectives_2_objective">Compreender o seu open loop, incluindo as suas recomendações de basais temporárias</string>
<string name="objectives_2_gate">Com base nessa experiência, decidir qual deve ser a basal máxima e configurá-la na bomba e nas preferências</string>
<string name="objectives_3_objective">Começar o close loop com Suspensão por Glicose Baixa.</string>
<string name="objectives_3_gate">Utilizar em close loop com IOB máx = 0 por alguns dias sem muitas situações de Suspensão por Baixa Glicose</string>
<string name="objectives_4_objective">Ajustar o close loop, levantar a IOB máxima acima de 0 e reduzir gradualmente os alvos de valor glicémico</string>
<string name="objectives_4_gate">Utilizar por alguns dias e pelo menos uma noite sem alarmes de valores glicémicos baixos, antes de baixar os valores</string>
<string name="objectives_5_objective">Ajustar as basals e os rácios se necessário e em seguida habilitar o auto-sens</string>
<string name="objectives_5_gate">1 semana de looping durante o dia com sucesso com entrada de hidratos de carbono regular</string>
<string name="objectives_6_objective">Ativando recursos adicionais para uso durante o dia, como assistente avançado de refeição</string>
<string name="objectives_7_objective">Ativando recursos adicionais para uso durante o dia, como SMB</string>
<string name="objectives_7_gate">Deverá ler a wiki e aumentar a IOB máx para que os SMBs funcionem devidamente! Inicialmente poderá considerar maxIOB= média dos bolus + 3 x a basal máxima</string>
<string name="objectives_openloop_objective">A iniciar um open loop</string>
<string name="objectives_openloop_gate">Utilizar em modo de open loop por alguns dias e dar manualmente muitas basais temporárias. Configurar e usar alvos temporários e alvos padrão temporários (por exemplo, para atividade ou tratamentos de hipo com Hcs)</string>
<string name="objectives_maxbasal_objective">Compreender o seu open loop, incluindo as suas recomendações de basais temporárias</string>
<string name="objectives_maxbasal_gate">Com base nessa experiência, decidir qual deve ser a basal máxima e configurá-la na bomba e nas preferências</string>
<string name="objectives_maxiobzero_objective">Começar o close loop com Suspensão por Glicose Baixa.</string>
<string name="objectives_maxiobzero_gate">Utilizar em close loop com IOB máx = 0 por alguns dias sem muitas situações de Suspensão por Baixa Glicose</string>
<string name="objectives_maxiob_objective">Ajustar o close loop, levantar a IOB máxima acima de 0 e reduzir gradualmente os alvos de valor glicémico</string>
<string name="objectives_maxiob_gate">Utilizar por alguns dias e pelo menos uma noite sem alarmes de valores glicémicos baixos, antes de baixar os valores</string>
<string name="objectives_autosens_objective">Ajustar as basals e os rácios se necessário e em seguida habilitar o auto-sens</string>
<string name="objectives_autosens_gate">1 semana de looping durante o dia com sucesso com entrada de hidratos de carbono regular</string>
<string name="objectives_ama_objective">Ativando recursos adicionais para uso durante o dia, como assistente avançado de refeição</string>
<string name="objectives_smb_objective">Ativando recursos adicionais para uso durante o dia, como SMB</string>
<string name="objectives_smb_gate">Deverá ler a wiki e aumentar a IOB máx para que os SMBs funcionem devidamente! Inicialmente poderá considerar maxIOB= média dos bolus + 3 x a basal máxima</string>
<string name="youareonallowedlimit">Atingiu o limite autorizado</string>
<string name="noprofileselected">Nenhum perfil seleccionado</string>
<string name="smscommunicator_loophasbeendisabled">Loop foi desactivado</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Se va livra un bolus de %1$.2fU</string>
<string name="objectives_0_objective">Se stabilesc vizualizările și monitorizarea și se analizează bazalele și valorile ratelor</string>
<string name="objectives_0_gate">Verificați că vedeți glicemia în Nightscout și că datele despre insulină date de pompă sunt înregistrate în site</string>
<string name="objectives_1_objective">Pornire în mod buclă deschisă</string>
<string name="objectives_1_gate">Rulați în modul Buclă Deschisă pentru câteva zile și faceți manual bazalele temporare sugerate. Setează și folosește ținte temporare implicite (ex.: pentru activități sau carbohidrați de tratare a hipo)</string>
<string name="objectives_2_objective">Trebuie să fie înțeleasă modalitatea de funcționare a buclei deschise, inclusiv recomandările de bazală temporară</string>
<string name="objectives_2_gate">Pe baza acestei experiențe, decideți care va fi bazala maximă și setați această valoare în pompă și în preferințe</string>
<string name="objectives_3_objective">Se începe etapa de buclă închisă cu Suspendarea Insulinei la Valori Glicemie Mici (Low Glucose Suspend = LGS)</string>
<string name="objectives_3_gate">Folosiți sistemul în mod buclă închisă cu IOB maxim = 0 pentru câteva zile fără prea multe evenimente LGS</string>
<string name="objectives_4_objective">Acordați fin performanța buclei închise, prin mărirea valorii max IOB peste 0 și micșorarea graduală a țintelor glicemice</string>
<string name="objectives_4_gate">Folosiți pentru câteva zile și cel puțin o noapte fără a avea alarme de hipoglicemie, înainte de scăderea glicemiei</string>
<string name="objectives_5_objective">Ajustați bazalele și ratele dacă este cazul și apoi activați autosens</string>
<string name="objectives_5_gate">O săptămână de folosire cu succes a sistemului cu buclă închisă cu introducerea normală de carbohidrați</string>
<string name="objectives_6_objective">Folosirea instrumentelor adiționale pentru timpul zilei, cum ar fi asistența avansată pentru mese</string>
<string name="objectives_7_objective">Se activează opțiuni pentru uzul în timpul zilei, cum ar fi SMB</string>
<string name="objectives_7_gate">Trebuie sa citiți wiki și măriți maxIOB pentru a obține SMB corect! Un start bun este maxIOB=media bolusurilor + 3x maxima bazalei din zi</string>
<string name="objectives_openloop_objective">Pornire în mod buclă deschisă</string>
<string name="objectives_openloop_gate">Rulați în modul Buclă Deschisă pentru câteva zile și faceți manual bazalele temporare sugerate. Setează și folosește ținte temporare implicite (ex.: pentru activități sau carbohidrați de tratare a hipo)</string>
<string name="objectives_maxbasal_objective">Trebuie să fie înțeleasă modalitatea de funcționare a buclei deschise, inclusiv recomandările de bazală temporară</string>
<string name="objectives_maxbasal_gate">Pe baza acestei experiențe, decideți care va fi bazala maximă și setați această valoare în pompă și în preferințe</string>
<string name="objectives_maxiobzero_objective">Se începe etapa de buclă închisă cu Suspendarea Insulinei la Valori Glicemie Mici (Low Glucose Suspend = LGS)</string>
<string name="objectives_maxiobzero_gate">Folosiți sistemul în mod buclă închisă cu IOB maxim = 0 pentru câteva zile fără prea multe evenimente LGS</string>
<string name="objectives_maxiob_objective">Acordați fin performanța buclei închise, prin mărirea valorii max IOB peste 0 și micșorarea graduală a țintelor glicemice</string>
<string name="objectives_maxiob_gate">Folosiți pentru câteva zile și cel puțin o noapte fără a avea alarme de hipoglicemie, înainte de scăderea glicemiei</string>
<string name="objectives_autosens_objective">Ajustați bazalele și ratele dacă este cazul și apoi activați autosens</string>
<string name="objectives_autosens_gate">O săptămână de folosire cu succes a sistemului cu buclă închisă cu introducerea normală de carbohidrați</string>
<string name="objectives_ama_objective">Folosirea instrumentelor adiționale pentru timpul zilei, cum ar fi asistența avansată pentru mese</string>
<string name="objectives_smb_objective">Se activează opțiuni pentru uzul în timpul zilei, cum ar fi SMB</string>
<string name="objectives_smb_gate">Trebuie sa citiți wiki și măriți maxIOB pentru a obține SMB corect! Un start bun este maxIOB=media bolusurilor + 3x maxima bazalei din zi</string>
<string name="youareonallowedlimit">Ați atins limita permisă</string>
<string name="noprofileselected">Niciun profil selectat</string>
<string name="smscommunicator_loophasbeendisabled">Bucla a fost dezactivată</string>

View file

@ -319,19 +319,19 @@
<string name="overview_bolusprogress_goingtodeliver">Начинается подача болюса %1$.2fед.</string>
<string name="objectives_0_objective">настройка визуализации и мониторинга, анализ базала и коэффициентов</string>
<string name="objectives_0_gate">убедитесь что СК и данные помпы передаются в NS</string>
<string name="objectives_1_objective">старт незамкнутого цикла</string>
<string name="objectives_1_gate">Работа в режиме незамкнутого цикла и ручной подстройки величины временного базала. Установите и применяйте временные цели и временные цели по умолчанию (напр. углеводы при нагрузке или купировании гипо)</string>
<string name="objectives_2_objective">анализ вашего незамкнутого цикла включая рекомендации по врем базалу</string>
<string name="objectives_2_gate">на основе полученного опыта определите макс величину базала и введите ее в помпу и настройки</string>
<string name="objectives_3_objective">закольцовывание цикла с Low Glucose Suspend (приостановка на низких СК)</string>
<string name="objectives_3_gate">работа в замкнутом цикле с макс IOB = 0 несколько дней избегая событий типа Low Suspend</string>
<string name="objectives_4_objective">настройка замкнутого цикла с поднятием макс величины IOB выше 0 и постепенным понижением целевых СК</string>
<string name="objectives_4_gate">работа несколько дней и по кр мере одну ночь без срабатывания оповещений о низком СК</string>
<string name="objectives_5_objective">при необходимости настройка базала и коэффициентов с последующей активацией auto-sens</string>
<string name="objectives_5_gate">1 неделя успешной дневной работы с регулярным введением углеводов</string>
<string name="objectives_6_objective">активация таких доп функций для дневного времени как калькулятор advanced meal assist</string>
<string name="objectives_7_objective">Активация таких доп функций для дневного времени как супер микро болюс SMB</string>
<string name="objectives_7_gate">Прочтите wiki и увеличьте maxIOB чтобы супер микро болюс SMB заработал как надо! Хорошее начало maxIOB = средний болюс на еду + троекратный максимальный базал суток</string>
<string name="objectives_openloop_objective">старт незамкнутого цикла</string>
<string name="objectives_openloop_gate">Работа в режиме незамкнутого цикла и ручной подстройки величины временного базала. Установите и применяйте временные цели и временные цели по умолчанию (напр. углеводы при нагрузке или купировании гипо)</string>
<string name="objectives_maxbasal_objective">анализ вашего незамкнутого цикла включая рекомендации по врем базалу</string>
<string name="objectives_maxbasal_gate">на основе полученного опыта определите макс величину базала и введите ее в помпу и настройки</string>
<string name="objectives_maxiobzero_objective">закольцовывание цикла с Low Glucose Suspend (приостановка на низких СК)</string>
<string name="objectives_maxiobzero_gate">работа в замкнутом цикле с макс IOB = 0 несколько дней избегая событий типа Low Suspend</string>
<string name="objectives_maxiob_objective">настройка замкнутого цикла с поднятием макс величины IOB выше 0 и постепенным понижением целевых СК</string>
<string name="objectives_maxiob_gate">работа несколько дней и по кр мере одну ночь без срабатывания оповещений о низком СК</string>
<string name="objectives_autosens_objective">при необходимости настройка базала и коэффициентов с последующей активацией auto-sens</string>
<string name="objectives_autosens_gate">1 неделя успешной дневной работы с регулярным введением углеводов</string>
<string name="objectives_ama_objective">активация таких доп функций для дневного времени как калькулятор advanced meal assist</string>
<string name="objectives_smb_objective">Активация таких доп функций для дневного времени как супер микро болюс SMB</string>
<string name="objectives_smb_gate">Прочтите wiki и увеличьте maxIOB чтобы супер микро болюс SMB заработал как надо! Хорошее начало maxIOB = средний болюс на еду + троекратный максимальный базал суток</string>
<string name="youareonallowedlimit">разрешенный предел достигнут</string>
<string name="noprofileselected">профиль не выбран</string>
<string name="smscommunicator_loophasbeendisabled">зцикл был деактивирован</string>

View file

@ -318,19 +318,19 @@
<string name="overview_bolusprogress_goingtodeliver">Podávanie %1$.2fJ inzulínu</string>
<string name="objectives_0_objective">Nastavenie vizualizácie a monitoringu (Nightscout), analyzovať bazály a prevody</string>
<string name="objectives_0_gate">Skontrolovať, či sú glykémie a údaje z pumpy viditeľné v Nightscoute</string>
<string name="objectives_1_objective">Začať s otvoreným okruhom</string>
<string name="objectives_1_gate">Niekoľko dní prevádzkovať otvorený okruh a ručne potvrdzovať doporučené dočasné bazály. Nastavovať a používať dočasné ciele (napr. pre šport, alebo hypo)</string>
<string name="objectives_2_objective">Porozumieť otvorenému okruhu a doporučeným dočasným bazálom</string>
<string name="objectives_2_gate">Na základe predchádzajúcich skúseností rozhodnúť, aký vysoký má byť maximálny bazál a nastaviť ho v pumpe a v aplikácii</string>
<string name="objectives_3_objective">Začať s uzavretým okruhom iba s vypínaním pri nízkej glykémii</string>
<string name="objectives_3_gate">Spustiť uzavretý okruh s max IOB = 0 na niekoľko dní s minimom nutných korekcií na nízku glykémiu</string>
<string name="objectives_4_objective">Ladenie uzavretého okruhu, zvyšovať max IOB nad 0 a postupne znižovať cieľovú glykémiu</string>
<string name="objectives_4_gate">Používať niekoľko dní s aspoň jednou nocou bez alarmov na nízku glykémiu, predtým ako znížiš cieľovú glykémiu</string>
<string name="objectives_5_objective">Ak je to potrebné, prispôsob bazály a prevody a potom aktivuj automatickú detekciu citlivosti</string>
<string name="objectives_5_gate">Jeden týždeň úspešne používaj uzavretý okruh so zadávaním bežného príjmu sacharidov cez deň</string>
<string name="objectives_6_objective">Aktivuj ďalšie prídavné funkcie pre bežné používanie, ako napr. AMA (pokročilý asistent jedál)</string>
<string name="objectives_7_objective">Aktivuj ďalšie prídavné funkcie pre bežné používanie, ako napr. SMB (Super Micro Bolusy)</string>
<string name="objectives_7_gate">Prečítať si dokumentáciu a zvýšiť maximálne IOB, aby mohlo správne fungovať SMB! Pre začiatok sa dá použiť veľkosť bežného bolusu + 3x maximálny denný bazál</string>
<string name="objectives_openloop_objective">Začať s otvoreným okruhom</string>
<string name="objectives_openloop_gate">Niekoľko dní prevádzkovať otvorený okruh a ručne potvrdzovať doporučené dočasné bazály. Nastavovať a používať dočasné ciele (napr. pre šport, alebo hypo)</string>
<string name="objectives_maxbasal_objective">Porozumieť otvorenému okruhu a doporučeným dočasným bazálom</string>
<string name="objectives_maxbasal_gate">Na základe predchádzajúcich skúseností rozhodnúť, aký vysoký má byť maximálny bazál a nastaviť ho v pumpe a v aplikácii</string>
<string name="objectives_maxiobzero_objective">Začať s uzavretým okruhom iba s vypínaním pri nízkej glykémii</string>
<string name="objectives_maxiobzero_gate">Spustiť uzavretý okruh s max IOB = 0 na niekoľko dní s minimom nutných korekcií na nízku glykémiu</string>
<string name="objectives_maxiob_objective">Ladenie uzavretého okruhu, zvyšovať max IOB nad 0 a postupne znižovať cieľovú glykémiu</string>
<string name="objectives_maxiob_gate">Používať niekoľko dní s aspoň jednou nocou bez alarmov na nízku glykémiu, predtým ako znížiš cieľovú glykémiu</string>
<string name="objectives_autosens_objective">Ak je to potrebné, prispôsob bazály a prevody a potom aktivuj automatickú detekciu citlivosti</string>
<string name="objectives_autosens_gate">Jeden týždeň úspešne používaj uzavretý okruh so zadávaním bežného príjmu sacharidov cez deň</string>
<string name="objectives_ama_objective">Aktivuj ďalšie prídavné funkcie pre bežné používanie, ako napr. AMA (pokročilý asistent jedál)</string>
<string name="objectives_smb_objective">Aktivuj ďalšie prídavné funkcie pre bežné používanie, ako napr. SMB (Super Micro Bolusy)</string>
<string name="objectives_smb_gate">Prečítať si dokumentáciu a zvýšiť maximálne IOB, aby mohlo správne fungovať SMB! Pre začiatok sa dá použiť veľkosť bežného bolusu + 3x maximálny denný bazál</string>
<string name="youareonallowedlimit">Dosiahnutý limit</string>
<string name="noprofileselected">Nebol vybraný žiadny profil</string>
<string name="smscommunicator_loophasbeendisabled">Uzavretý okruh bol deaktivovaný</string>

View file

@ -319,19 +319,19 @@ Eversense-appen.</string>
<string name="overview_bolusprogress_goingtodeliver">Kommer att leverera %1$.2f enheter</string>
<string name="objectives_0_objective">Ställer in utseende och övervakning för att sedan kunna analysera basaler och kvoter</string>
<string name="objectives_0_gate">Kontrollera att BG syns i Nightscout och att insulindata från pumpen laddas upp</string>
<string name="objectives_1_objective">Starta med open loop</string>
<string name="objectives_1_gate">Starta med open loop och använd det några dagar. Försök att ge många föreslagna temp basaler. Sätt upp och använd standardmålvärden (Träning, Äta snart och Hypo)</string>
<string name="objectives_2_objective">Förstå din open loop och hur den föreslår temp basaler</string>
<string name="objectives_2_gate">Utifrån vad du nu lärt dig, besluta vilken max basal du vill ha. Ställ in det både i inställningarna i APS och i din pump</string>
<string name="objectives_3_objective">Börja använda closed loop med aktiverad funktion att stänga av vid lågt BG</string>
<string name="objectives_3_gate">Aktivera closed loop med max IOB=0 i några dagar till dess systemet inte stänger av pga lågt BG för många gånger</string>
<string name="objectives_4_objective">Finjustering av closed loop, gradvis ökande IOB och minskande målvärde för BG</string>
<string name="objectives_4_gate">Kör några dagar och åtminstone en natt utan larm för lågt BG innan du sänker målvärdet för BG.</string>
<string name="objectives_5_objective">Justera basaler och kvoter om det behövs. Aktivera sedan autosens</string>
<string name="objectives_5_gate">1 veckas lyckad looping dagtid, där alla måltider lagts in</string>
<string name="objectives_6_objective">Aktiverar extra funktioner som kan användas dagtid, såsom avancerad måltidsassistans, AMA</string>
<string name="objectives_7_objective">Aktiverar ytterligare funktioner för användning dagtid, t ex SMB</string>
<string name="objectives_7_gate">Du måste läsa på wikin och öka max IOB för att få SMB att fungera bra. En bra start är att sätta max IOB till din genomsnittliga måltidsbolus plus 3 gånger den högsta basalen du har under ett dygn</string>
<string name="objectives_openloop_objective">Starta med open loop</string>
<string name="objectives_openloop_gate">Starta med open loop och använd det några dagar. Försök att ge många föreslagna temp basaler. Sätt upp och använd standardmålvärden (Träning, Äta snart och Hypo)</string>
<string name="objectives_maxbasal_objective">Förstå din open loop och hur den föreslår temp basaler</string>
<string name="objectives_maxbasal_gate">Utifrån vad du nu lärt dig, besluta vilken max basal du vill ha. Ställ in det både i inställningarna i APS och i din pump</string>
<string name="objectives_maxiobzero_objective">Börja använda closed loop med aktiverad funktion att stänga av vid lågt BG</string>
<string name="objectives_maxiobzero_gate">Aktivera closed loop med max IOB=0 i några dagar till dess systemet inte stänger av pga lågt BG för många gånger</string>
<string name="objectives_maxiob_objective">Finjustering av closed loop, gradvis ökande IOB och minskande målvärde för BG</string>
<string name="objectives_maxiob_gate">Kör några dagar och åtminstone en natt utan larm för lågt BG innan du sänker målvärdet för BG.</string>
<string name="objectives_autosens_objective">Justera basaler och kvoter om det behövs. Aktivera sedan autosens</string>
<string name="objectives_autosens_gate">1 veckas lyckad looping dagtid, där alla måltider lagts in</string>
<string name="objectives_ama_objective">Aktiverar extra funktioner som kan användas dagtid, såsom avancerad måltidsassistans, AMA</string>
<string name="objectives_smb_objective">Aktiverar ytterligare funktioner för användning dagtid, t ex SMB</string>
<string name="objectives_smb_gate">Du måste läsa på wikin och öka max IOB för att få SMB att fungera bra. En bra start är att sätta max IOB till din genomsnittliga måltidsbolus plus 3 gånger den högsta basalen du har under ett dygn</string>
<string name="youareonallowedlimit">Du har nått din tillåtna gräns</string>
<string name="noprofileselected">Ingen profil vald</string>
<string name="smscommunicator_loophasbeendisabled">Loop stängdes av</string>

View file

@ -306,19 +306,19 @@
<string name="waitingforpump">Pompa bekleniyor</string>
<string name="objectives_0_objective">Nightscout üzerinden izlemeyi ve görselleştirmeyi yapılandırın ve bazal oranlarını ve faktörleri düzenleyin</string>
<string name="objectives_0_gate">Nightscout\'ta KŞ\'nin bulunduğunu ve insülin verilerinin yüklenmekte olduğunu doğrulayın</string>
<string name="objectives_1_objective">ık Döngü modu başlatılıyor</string>
<string name="objectives_1_gate">Birkaç gün boyunca Açık Döngü modunda çalıştırın ve birçok geçici bazalı el yordamı ile girin. Geçici ve varsayılan geçici hedefleri düzenleyin ve kullanın (örn. egzersiz ve hipo-tedaviyi desteklemek için)</string>
<string name="objectives_2_objective">Geçici bazal tavsiyeleri de dahil olmak üzere Açık Döngü anlamak</string>
<string name="objectives_2_gate">Bu deneyime dayanarak, max bazalın ne olması gerektiğine karar vermeli ve bunu pompa ve tercihlere koymalısınız</string>
<string name="objectives_3_objective">Kapalı Döngü, (LGS) Düşük Kan Şekerinde Duraklatma modunda başlatılıyor</string>
<string name="objectives_3_gate">Çok sayıda LGS (düşük KŞ) olmadan birkaç gün boyunca maksimum IOB = 0 (Aktif insülin) Kapalı Döngü\'de deneyin</string>
<string name="objectives_4_objective">Kapalı Döngü\'de ince ayarlar, maksimum (IOB) Aktif İnsülinin 0\'ın üzerine yükseltme ve yavaş yavaş KŞ hedeflerini aşağıya çekme</string>
<string name="objectives_4_gate">KŞ hedefini azaltmadan önce birkaç gün ve en az bir gece düşük KŞ (Hipo) alarmı olmadan deneyin</string>
<string name="objectives_5_objective">Gerekirse, bazal ve oranları ayarlayın ve sonra auto-sens\'i etkinleştirin</string>
<string name="objectives_5_gate">Bir hafta boyunca düzenli Karbonhidrad girdileri yaparak gün boyunca Kapalı Döngüyü çalıştırın</string>
<string name="objectives_6_objective">Gelişmiş yemek asistanı gibi gündüz kullanımı için ek özelliklerin etkinleştirilmesi</string>
<string name="objectives_7_objective">SMB (Super Micro Bolus) gibi gündüz kullanımı için ek özelliklerin etkinleştirilmesi</string>
<string name="objectives_7_gate">(Super Micro Bolus) SMB\'lerın iyi çalışabilmesi için wiki\'yi okumalısınız ve maxIOB\'u yükseltmelisiniz! İyi bir başlangıç için maxIOB = ortalama yemek bolusu + 3 x max günlük bazaldır</string>
<string name="objectives_openloop_objective">ık Döngü modu başlatılıyor</string>
<string name="objectives_openloop_gate">Birkaç gün boyunca Açık Döngü modunda çalıştırın ve birçok geçici bazalı el yordamı ile girin. Geçici ve varsayılan geçici hedefleri düzenleyin ve kullanın (örn. egzersiz ve hipo-tedaviyi desteklemek için)</string>
<string name="objectives_maxbasal_objective">Geçici bazal tavsiyeleri de dahil olmak üzere Açık Döngü anlamak</string>
<string name="objectives_maxbasal_gate">Bu deneyime dayanarak, max bazalın ne olması gerektiğine karar vermeli ve bunu pompa ve tercihlere koymalısınız</string>
<string name="objectives_maxiobzero_objective">Kapalı Döngü, (LGS) Düşük Kan Şekerinde Duraklatma modunda başlatılıyor</string>
<string name="objectives_maxiobzero_gate">Çok sayıda LGS (düşük KŞ) olmadan birkaç gün boyunca maksimum IOB = 0 (Aktif insülin) Kapalı Döngü\'de deneyin</string>
<string name="objectives_maxiob_objective">Kapalı Döngü\'de ince ayarlar, maksimum (IOB) Aktif İnsülinin 0\'ın üzerine yükseltme ve yavaş yavaş KŞ hedeflerini aşağıya çekme</string>
<string name="objectives_maxiob_gate">KŞ hedefini azaltmadan önce birkaç gün ve en az bir gece düşük KŞ (Hipo) alarmı olmadan deneyin</string>
<string name="objectives_autosens_objective">Gerekirse, bazal ve oranları ayarlayın ve sonra auto-sens\'i etkinleştirin</string>
<string name="objectives_autosens_gate">Bir hafta boyunca düzenli Karbonhidrad girdileri yaparak gün boyunca Kapalı Döngüyü çalıştırın</string>
<string name="objectives_ama_objective">Gelişmiş yemek asistanı gibi gündüz kullanımı için ek özelliklerin etkinleştirilmesi</string>
<string name="objectives_smb_objective">SMB (Super Micro Bolus) gibi gündüz kullanımı için ek özelliklerin etkinleştirilmesi</string>
<string name="objectives_smb_gate">(Super Micro Bolus) SMB\'lerın iyi çalışabilmesi için wiki\'yi okumalısınız ve maxIOB\'u yükseltmelisiniz! İyi bir başlangıç için maxIOB = ortalama yemek bolusu + 3 x max günlük bazaldır</string>
<string name="youareonallowedlimit">İzin verilen sınıra ulaştınız</string>
<string name="noprofileselected">Profil seçilmedi</string>
<string name="smscommunicator_loophasbeendisabled">Döngü devre dışı bırakıldı</string>

View file

@ -317,19 +317,19 @@
<string name="overview_bolusprogress_goingtodeliver">将要输注 %1$.2fU</string>
<string name="objectives_0_objective">设置可视化和监视, 并分析基础率和比率</string>
<string name="objectives_0_gate">验证 Nightscout 中的血糖是否可用, 并且正在上传泵的胰岛素数据</string>
<string name="objectives_1_objective">开始开环</string>
<string name="objectives_1_gate">在开环模式下运行几天,并在手机上手动制定很多次临时基础率。设置和使用临时目标和默认的临时目标 (例如, 用于活动或处理碳水化合物)</string>
<string name="objectives_2_objective">了解你的开环,包括它的临时基础率建议</string>
<string name="objectives_2_gate">基于以上的经验,决定适合自己的最大基础率,在泵和本软件的参数选项上设置</string>
<string name="objectives_3_objective">开始闭环模式,低血糖自动暂停</string>
<string name="objectives_3_gate">在闭环模式下运行设置最大IOB = 0 运行几天确保没有太多的低血糖事件</string>
<string name="objectives_4_objective">优化闭环逐渐增加最大IOB并逐渐降低目标血糖值</string>
<string name="objectives_4_gate">运行几天,至少一个晚上没有低血糖报警,然后才可以继续调低目标血糖</string>
<string name="objectives_5_objective">如果需要的话调整基础率和比值然后再启用auto-sense</string>
<string name="objectives_5_gate">一个星期成功的白天闭环,常规的碳水化合物摄入</string>
<string name="objectives_6_objective">启用额外的功能以供白天使用,例如用餐助手(meal assist)</string>
<string name="objectives_7_objective">启用额外的功能以供白天使用, 例如微型大剂量 SMB</string>
<string name="objectives_7_gate">为了让微型大剂量工作的更好你必须读指南提高最大IOB的值。 建议是最大IOB值=餐时大剂量的平均值+3倍 的每日基础率中的最大值</string>
<string name="objectives_openloop_objective">开始开环</string>
<string name="objectives_openloop_gate">在开环模式下运行几天,并在手机上手动制定很多次临时基础率。设置和使用临时目标和默认的临时目标 (例如, 用于活动或处理碳水化合物)</string>
<string name="objectives_maxbasal_objective">了解你的开环,包括它的临时基础率建议</string>
<string name="objectives_maxbasal_gate">基于以上的经验,决定适合自己的最大基础率,在泵和本软件的参数选项上设置</string>
<string name="objectives_maxiobzero_objective">开始闭环模式,低血糖自动暂停</string>
<string name="objectives_maxiobzero_gate">在闭环模式下运行设置最大IOB = 0 运行几天确保没有太多的低血糖事件</string>
<string name="objectives_maxiob_objective">优化闭环逐渐增加最大IOB并逐渐降低目标血糖值</string>
<string name="objectives_maxiob_gate">运行几天,至少一个晚上没有低血糖报警,然后才可以继续调低目标血糖</string>
<string name="objectives_autosens_objective">如果需要的话调整基础率和比值然后再启用auto-sense</string>
<string name="objectives_autosens_gate">一个星期成功的白天闭环,常规的碳水化合物摄入</string>
<string name="objectives_ama_objective">启用额外的功能以供白天使用,例如用餐助手(meal assist)</string>
<string name="objectives_smb_objective">启用额外的功能以供白天使用, 例如微型大剂量 SMB</string>
<string name="objectives_smb_gate">为了让微型大剂量工作的更好你必须读指南提高最大IOB的值。 建议是最大IOB值=餐时大剂量的平均值+3倍 的每日基础率中的最大值</string>
<string name="youareonallowedlimit">你达到了允许的极限</string>
<string name="noprofileselected">没有选定配置文件</string>
<string name="smscommunicator_loophasbeendisabled">闭环已经被禁用</string>

View file

@ -0,0 +1,44 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="dia_whatmeansdia">What is true about DIA?</string>
<string name="dia_meaningofdia">Meaning of DIA</string>
<string name="dia_minimumis3h">minimum is 3 hours</string>
<string name="dia_minimumis5h">minimum is 5 hours</string>
<string name="dia_hint1">https://androidaps.readthedocs.io/en/latest/EN/Configuration/Config-Builder.html?#insulin</string>
<string name="dia_meaningisequaltodiapump">meaning is equal to DIA parameter used in pumps</string>
<string name="dia_valuemustbedetermined">correct value must be determined</string>
<string name="hypott">Hypo temp target</string>
<string name="hypott_whenhypott">When should you do a hypo TT?</string>
<string name="hypott_goinglow">you are going low</string>
<string name="hypott_havinglow">your already have a low bg</string>
<string name="hypott_notlowanymorebutrising">your not low anymore, but your BG is rising because of the (right!) amount of hypo treatments</string>
<string name="hypott_bgisrising">your bg is rising, has just reached the target BG but there is still too much IOB left</string>
<string name="hypott_havehadalowbg">you have had a low bg a while ago, but it got you in a hyper</string>
<string name="hypott_hint1">https://androidaps.readthedocs.io/en/latest/EN/Usage/temptarget.html</string>
<string name="offlineprofile_whatprofile">Which profile can be used and configured offline</string>
<string name="offlineprofile">Offline profile</string>
<string name="offlineprofile_nsprofile">NS Profile can be used but not configured</string>
<string name="offlineprofile_hint1">https://androidaps.readthedocs.io/en/latest/EN/Configuration/Config-Builder.html#profile</string>
<string name="pumpdisconnect">Taking off pump</string>
<string name="pumpdisconnect_whattodo">What to do when taking the pump off</string>
<string name="pumpdisconnect_letknow">Let loop know that there is no insulin running to your body by clicking disconnect pump</string>
<string name="pumpdisconnect_dontchnage">don\'t change anything</string>
<string name="pumpdisconnect_hint1">https://androidaps.readthedocs.io/en/latest/EN/Getting-Started/FAQ.html#other-settings</string>
<string name="objectives_howtosave">What is recommended?</string>
<string name="objectives_writetopaper">write every setting you did to paper and make a copy of it</string>
<string name="objectives_exportsettings">export settings from Maintenance</string>
<string name="objectives_storeelsewhere">store exported file to another place like email, Dropbox, Google drive …</string>
<string name="objectives_doexportonstart">do export right after you install AAPS</string>
<string name="objectives_doexportafterchange">do export after every change</string>
<string name="objectives_doexportafterfirtssettings">do export when you finish initial setting</string>
<string name="objectives_hint1">https://androidaps.readthedocs.io/en/latest/EN/Usage/ExportImportSettings.html</string>
<string name="noisycgm">Noisy CGM</string>
<string name="noisycgm_whattodo">What to do when you see CGM signal being too noisy</string>
<string name="nothing">nothing</string>
<string name="noisycgm_pause">pause closed loop mode</string>
<string name="noisycgm_replacesensor">replace sensor</string>
<string name="noisycgm_turnoffcgmreceiver">turn off CGM receiver</string>
<string name="noisycgm_hint1">https://androidaps.readthedocs.io/en/latest/EN/Usage/Smoothing-Blood-Glucose-Data-in-xDrip.html#smoothing-blood-glucose-data</string>
<string name="noisycgm_checksmoothing">check if input data is smoothed</string>
</resources>

View file

@ -350,19 +350,19 @@
<string name="overview_bolusprogress_goingtodeliver">Going to deliver %1$.2fU</string>
<string name="objectives_0_objective">Setting up visualization and monitoring, and analyzing basals and ratios</string>
<string name="objectives_0_gate">Verify that BG is available in Nightscout, and pump insulin data is being uploaded</string>
<string name="objectives_1_objective">Starting on an open loop</string>
<string name="objectives_1_gate">Run in Open Loop mode for a few days and manually enact lots of temp basals. Set up and use temporary and default temporary targets (e.g. for activity or hypo treatment carbs)</string>
<string name="objectives_2_objective">Understanding your open loop, including its temp basal recommendations</string>
<string name="objectives_2_gate">Based on that experience, decide what max basal should be, and set it on the pump and preferences</string>
<string name="objectives_3_objective">Starting to close the loop with Low Glucose Suspend</string>
<string name="objectives_3_gate">Run in closed loop with max IOB = 0 for a few days without too many LGS events</string>
<string name="objectives_4_objective">Tuning the closed loop, raising max IOB above 0 and gradually lowering BG targets</string>
<string name="objectives_4_gate">Run for a few days, and at least one night with no low BG alarms, before dropping BG</string>
<string name="objectives_5_objective">Adjust basals and ratios if needed, and then enable auto-sens</string>
<string name="objectives_5_gate">1 week successful daytime looping with regular carb entry</string>
<string name="objectives_6_objective">Enabling additional features for daytime use, such as advanced meal assist</string>
<string name="objectives_7_objective">Enabling additional features for daytime use, such as SMB</string>
<string name="objectives_7_gate">You must read the wiki and rise maxIOB to get SMBs working fine! A good start is maxIOB=average mealbolus + 3 x max daily basal</string>
<string name="objectives_openloop_objective">Starting on an open loop</string>
<string name="objectives_openloop_gate">Run in Open Loop mode for a few days and manually enact lots of temp basals. Set up and use temporary and default temporary targets (e.g. for activity or hypo treatment carbs)</string>
<string name="objectives_maxbasal_objective">Understanding your open loop, including its temp basal recommendations</string>
<string name="objectives_maxbasal_gate">Based on that experience, decide what max basal should be, and set it on the pump and preferences</string>
<string name="objectives_maxiobzero_objective">Starting to close the loop with Low Glucose Suspend</string>
<string name="objectives_maxiobzero_gate">Run in closed loop with max IOB = 0 for a few days without too many LGS events</string>
<string name="objectives_maxiob_objective">Tuning the closed loop, raising max IOB above 0 and gradually lowering BG targets</string>
<string name="objectives_maxiob_gate">Run for a few days, and at least one night with no low BG alarms, before dropping BG</string>
<string name="objectives_autosens_objective">Adjust basals and ratios if needed, and then enable auto-sens</string>
<string name="objectives_autosens_gate">1 week successful daytime looping with regular carb entry</string>
<string name="objectives_ama_objective">Enabling additional features for daytime use, such as advanced meal assist</string>
<string name="objectives_smb_objective">Enabling additional features for daytime use, such as SMB</string>
<string name="objectives_smb_gate">You must read the wiki and rise maxIOB to get SMBs working fine! A good start is maxIOB=average mealbolus + 3 x max daily basal</string>
<string name="youareonallowedlimit">You reached allowed limit</string>
<string name="noprofileselected">No profile selected</string>
<string name="smscommunicator_loophasbeendisabled">Loop has been disabled</string>
@ -1611,6 +1611,38 @@
<string name="deliverpartofboluswizard">Bolus wizard performs calculation but only this part of calculated insulin is delivered. Useful with SMB algorithm.</string>
<string name="loading">Loading ...</string>
<string name="snooze">Snooze</string>
<string name="accomplished">Accomplished: %1$s</string>
<string name="objectives_usage_objective">Learn how to control AndroidAPS</string>
<string name="objectives_usage_gate">Perform different actions in AndroidAPS</string>
<string name="objectives_useprofileswitch">Set profile 90% for 10 min (Long-press profile name on Overview)</string>
<string name="key_objectiveuseprofileswitch" translatable="false">ObjectivesProfileSwitchUsed</string>
<string name="key_objectiveusedisconnect" translatable="false">ObjectivesDisconnectUsed</string>
<string name="key_objectiveusereconnect" translatable="false">ObjectivesReconnectUsed</string>
<string name="key_objectiveusetemptarget" translatable="false">ObjectivesTempTargetUsed</string>
<string name="key_objectiveuseactions" translatable="false">ObjectivesActionsUsed</string>
<string name="key_objectiveuseloop" translatable="false">ObjectivesLoopUsed</string>
<string name="key_objectiveusescale" translatable="false">ObjectivesScaleUsed</string>
<string name="objectives_usedisconnectpump">Simulate shower. Disconnect pump for 1h (Long-press on Open Loop)</string>
<string name="objectives_usereconnectpump">... and reconnect back the same way</string>
<string name="objectives_usetemptarget">Create custom temporary target with 10 min duration (Long-press on your current target)</string>
<string name="objectives_useactions">In Config Builder enable Actions plugin, make it visible and display its content from top menu</string>
<string name="objectives_useloop">Display content of Loop plugin</string>
<string name="objectives_usescale">Use scale function by long-pressing BG chart</string>
<string name="objectives_button_enter">Enter</string>
<string name="enter_code_obtained_from_developers_to_bypass_the_rest_of_objectives">Enter code obtained from developers to bypass the rest of objectives</string>
<string name="codeaccepted">Code accepted</string>
<string name="codeinvalid">Code invalid</string>
<string name="key_ObjectivesbgIsAvailableInNS" translatable="false">ObjectivesbgIsAvailableInNS</string>
<string name="key_ObjectivespumpStatusIsAvailableInNS" translatable="false">ObjectivespumpStatusIsAvailableInNS</string>
<string name="key_ObjectivesmanualEnacts" translatable="false">ObjectivesmanualEnacts</string>
<string name="objectives_exam_objective">Prove your knowledge</string>
<string name="objectives_exam_gate">Study and answer questions correctly</string>
<string name="answerdisabledto">Answering disabled to: %1$s</string>
<string name="wronganswer">Wrong answer!</string>
<string name="unfinshed_button">Next unfinished</string>
<string name="close">Close</string>
<string name="key_objectives_request_code" translatable="false">objectives_request_code</string>
<string name="requestcode">Request code: %1$s</string>
<plurals name="objective_days">
<item quantity="one">%1$d day</item>

View file

@ -58,11 +58,11 @@ public class ConstraintsCheckerTest {
boolean notificationSent = false;
public ConstraintsCheckerTest() throws JSONException {
public ConstraintsCheckerTest() {
}
@Test
public void isLoopInvokationAllowedTest() throws Exception {
public void isLoopInvokationAllowedTest() {
comboPlugin.setPluginEnabled(PluginType.PUMP, true);
comboPlugin.setValidBasalRateProfileSelectedOnPump(false);
@ -73,9 +73,9 @@ public class ConstraintsCheckerTest {
}
@Test
public void isClosedLoopAllowedTest() throws Exception {
public void isClosedLoopAllowedTest() {
when(SP.getString(R.string.key_aps_mode, "open")).thenReturn("closed");
objectivesPlugin.objectives.get(3).setStartedOn(null);
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getMAXIOB_ZERO_CL_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = constraintChecker.isClosedLoopAllowed();
Assert.assertEquals(true, c.getReasonList().size() == 2); // Safety & Objectives
@ -90,8 +90,8 @@ public class ConstraintsCheckerTest {
}
@Test
public void isAutosensModeEnabledTest() throws Exception {
objectivesPlugin.objectives.get(5).setStartedOn(null);
public void isAutosensModeEnabledTest() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getAUTOSENS_OBJECTIVE()).setStartedOn(0);
when(SP.getBoolean(R.string.key_openapsama_useautosens, false)).thenReturn(false);
Constraint<Boolean> c = constraintChecker.isAutosensModeEnabled();
@ -101,8 +101,8 @@ public class ConstraintsCheckerTest {
}
@Test
public void isAMAModeEnabledTest() throws Exception {
objectivesPlugin.objectives.get(6).setStartedOn(null);
public void isAMAModeEnabledTest() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getAMA_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = constraintChecker.isAMAModeEnabled();
Assert.assertEquals(true, c.getReasonList().size() == 1); // Objectives
@ -111,7 +111,7 @@ public class ConstraintsCheckerTest {
}
@Test
public void isAdvancedFilteringEnabledTest() throws Exception {
public void isAdvancedFilteringEnabledTest() {
when(ConfigBuilderPlugin.getPlugin().getActiveBgSource()).thenReturn(SourceGlimpPlugin.getPlugin());
Constraint<Boolean> c = constraintChecker.isAdvancedFilteringEnabled();
@ -130,7 +130,7 @@ public class ConstraintsCheckerTest {
@Test
public void isSMBModeEnabledTest() throws Exception {
objectivesPlugin.objectives.get(7).setStartedOn(null);
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getSMB_OBJECTIVE()).setStartedOn(0);
when(SP.getBoolean(R.string.key_use_smb, false)).thenReturn(false);
when(MainApp.getConstraintChecker().isClosedLoopAllowed()).thenReturn(new Constraint<>(true));
@ -294,7 +294,7 @@ public class ConstraintsCheckerTest {
constraintChecker = new ConstraintChecker();
safetyPlugin = SafetyPlugin.getPlugin();
objectivesPlugin = ObjectivesPlugin.getPlugin();
objectivesPlugin = ObjectivesPlugin.INSTANCE;
comboPlugin = ComboPlugin.getPlugin();
danaRPlugin = DanaRPlugin.getPlugin();
danaRSPlugin = DanaRSPlugin.getPlugin();

View file

@ -14,6 +14,7 @@ import info.AAPSMocker;
import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.interfaces.Constraint;
import info.nightscout.androidaps.plugins.configBuilder.ConfigBuilderPlugin;
import info.nightscout.androidaps.utils.DateUtil;
import info.nightscout.androidaps.utils.SP;
/**
@ -27,53 +28,53 @@ public class ObjectivesPluginTest {
ObjectivesPlugin objectivesPlugin;
@Test
public void notStartedObjectivesShouldLimitLoopInvocation() throws Exception {
objectivesPlugin.objectives.get(0).setStartedOn(null);
public void notStartedObjectivesShouldLimitLoopInvocation() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getFIRST_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isLoopInvocationAllowed(c);
Assert.assertEquals("Objectives: Objective 1 not started", c.getReasons());
Assert.assertEquals(Boolean.FALSE, c.value());
objectivesPlugin.objectives.get(0).setStartedOn(new Date());
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getFIRST_OBJECTIVE()).setStartedOn(DateUtil.now());
}
@Test
public void notStartedObjective4ShouldLimitClosedLoop() throws Exception {
objectivesPlugin.objectives.get(3).setStartedOn(null);
public void notStartedObjective6ShouldLimitClosedLoop() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getMAXIOB_ZERO_CL_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isClosedLoopAllowed(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 4 not started"));
Assert.assertEquals(Boolean.FALSE, c.value());
}
@Test
public void notStartedObjective6ShouldLimitAutosensMode() throws Exception {
objectivesPlugin.objectives.get(5).setStartedOn(null);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isAutosensModeEnabled(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 6 not started"));
Assert.assertEquals(Boolean.FALSE, c.value());
}
@Test
public void notStartedObjective7ShouldLimitAMAMode() throws Exception {
objectivesPlugin.objectives.get(6).setStartedOn(null);
public void notStartedObjective8ShouldLimitAutosensMode() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getAUTOSENS_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isAMAModeEnabled(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 7 not started"));
c = objectivesPlugin.isAutosensModeEnabled(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 8 not started"));
Assert.assertEquals(Boolean.FALSE, c.value());
}
@Test
public void notStartedObjective8ShouldLimitSMBMode() throws Exception {
objectivesPlugin.objectives.get(7).setStartedOn(null);
public void notStartedObjective9ShouldLimitAMAMode() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getAMA_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isAMAModeEnabled(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 9 not started"));
Assert.assertEquals(Boolean.FALSE, c.value());
}
@Test
public void notStartedObjective10ShouldLimitSMBMode() {
objectivesPlugin.getObjectives().get(ObjectivesPlugin.INSTANCE.getSMB_OBJECTIVE()).setStartedOn(0);
Constraint<Boolean> c = new Constraint<>(true);
c = objectivesPlugin.isSMBModeEnabled(c);
Assert.assertEquals(true, c.getReasons().contains("Objective 8 not started"));
Assert.assertEquals(true, c.getReasons().contains("Objective 10 not started"));
Assert.assertEquals(Boolean.FALSE, c.value());
}
@ -85,6 +86,6 @@ public class ObjectivesPluginTest {
AAPSMocker.mockSP();
AAPSMocker.mockStrings();
objectivesPlugin = ObjectivesPlugin.getPlugin();
objectivesPlugin = ObjectivesPlugin.INSTANCE;
}
}