Releases: Flash3388/FlashLib
Releases · Flash3388/FlashLib
Release 3.2.6
General improvements to PidController
- improved documentation around different functions, especially
applyAsDouble
andisInTolerance
- displaying the error velocity (i.e. change of error in time) via OBSR
- modifying
isInTolerance
to not use clock to check tolerance stability any longer, but rather use the error velocity to determine that.- this removed the need for
Clock
and thus it was removed from use - see documentation in class for further info
- this removed the need for
Release 3.2.4
- Fixed a bug with starting and stopping
Action
from inside anotherAction
. - Modified
DeviceInterface
to use a better defined id for devices.
Release 3.2.3
- Added
Watchdog
. Useful for tracking execution of looping code flows.Watchdog
s can be created fromFlashLibControl.newWatchdog
and will be tracked by a separate threadLoopingRobotBase
updated to use aWatchdog
Release 3.2.2
- Added 'Mathf.shortestAngularDistanceMotionDirection`
- Improved Counter device API and usage
- Fix to
PidController
D component to take period into account
Release 3.2.1
- Updated
InstanceId
for null pointer checks - Updated
InstanceIdGenerator
to support better generation of machine id- added for windows: acquiring the bios serial number from wmic as id
- better fallback look for the first accessible mac address
Release 3.2.0
- Added
Actions.waitUntil
- Logging is now based on traditional slf4j design: acquiring logger with
LoggerFactory
. Property files define logger functionality depending on implementation. - Support for FlashLib Application - i.e. non robot program which uses FlashLib.
- A running FlashLib application is called a FlashLib instance, identified by a unique id
- An application's unique identifier is divided into machine identifier and process identifier.
- Robot applications are a kind of FlashLib application
- Networking protocols for communication between FlashLib programs:
- Removed the deprecated
SynchronousScheduler
. - Added new control components:
ServiceRegistry
: registers and tracks castle'scom.castle.concurrent.service.Service
. Useful for creating services (mostly multithreaded) to be used by the robot code.NetworkInterface
: access to networking protocols via the robot. Namely HFCS and OBSR.FlashLibMainThread
: tracks the main application thread. Allows queuing tasks to run on this thread from other threads. Methods annotated withMainThreadOnly
must be called from that thread.DeviceInterface
: a provider of device interface implementation. Extendible using java's SPI
- Added
ActionStartSelector
, a specialized selector, allowing selection of andAction
based on pre-made conditions. PidController
now hasisInTolerance
as indication that the error is acceptable and the system is in the wanted setpoint. Uses both checks on error and a timeout to ensure stability.Action
interface modified with the addition ofActionControl
toexecute
andinitialize
, allowing further control of theAction
.- Removed
isFinished
. Instead use,ActionControl.finish
inexecute
orinitialize
end
now receivesFinishReason
instead ofwasInterrupted
to describe the finish reason more specifically.
- Removed
Action
interface methods (e.g.initialize
) no longer have default implementations and must be implemented.- A new set of system implementation which provide actions. See the new component
flashlib.robot.systems
- Using OBSR to report on execution of actions in scheduler
- Added detection and tracking of object in
flashlib.vision.core
andflashlib.vision.cv
- Integration with hal for
flashlib.core.io
implementation. Under new componentflashlib.io.hal
. - Reworked the internal mechanisms of
Trigger
andManualTrigger
- Introduced
DeviceInterface
for creating and working with devices abstractly.
Release 3.1.0
- Added the ability to create manually activated
Trigger
s withTriggers.manual()
. - Added HID interface representing the Dualshock 4 controller (
DualshockController
). Can be created withHidInterface.newDualshockController
, - Condition-based
Trigger
s are now created fromScheduler.newTrigger
. ActionConfiguration
now contains a set ofActionFlags
which influence different behaviors.ActionFlag.RUN_ON_DISABLED
: when set,Action
is allowed to run disabled modes (SchedulerMode.isDisabled
returnstrue
). When not set, theAction
will be cancelled.ActionFlag.PREFERRED_FOR_REQUIREMENTS
: when set, theAction
will not be interrupted due to requirements conflict. Attempting to start a newAction
which conflicts with suchAction
will either cause an exception or put the new action in a wait queue for execution (depends onScheduler
implementation).
Analysis
objects modified to reflect a strong API for identified targets.Analysis.getDetectedTargets
returns a list ofTarget
objects.
IterativeRobot
now contains implementable exit methods for control modes, called when leaving the current mode and entering a different control mode.SynchronousSchedluer
is deprecated now. A new implementation,SingleThreadedScheduler
should be used instead.- Added new component
flashlib.hid.sdl2
which uses SDL2 to interface with HID. The interface can be used withSdl2Hid
. Natives for using SDL2 should be installed before hand and JNI should be added from thecom.github.tomtzook:jsdl2-jni
artifact. - Added
whenInterrupted
callback forActionGroup
. Called when the group is interrupted. ActionGroup
s implementations are no longer exposed directly. UseScheduler.newActionGroup
to create one instead.- Implementation for
ActionGroup
revamped.
- Implementation for
Release 3.0.0
Major update to project structure and most core components.
- Reorganized the project structure into several submodule (or components), with dependencies between each other.
- Removed Flashcomm component.
- FlashCv plugin now part of this repository.
- Changed artifact structure. Each component corresponds to a a separate artifact, with dependencies between them, instead of one massive artifact.
- Introducing the new flashlib.core.hid API:
- Completely abstract.
- Previous API served an inspiration for the
generic
implementation for the API.
- Introducing the new flashlib.core.scheduling API.
Scheduler
,Action
andTrigger
are now interfaces.SingleThreadScheduler
provides the basic implementation forScheduler
. Organized as a way to support multi-threading in the future.- Requirements are no longer tied directly to
Subsystem
, but rather toRequirement
interface.Subsystem
being a specific type. - New action group
ParallelRaceActionGroup
. - New sugar syntax for building action groups with
Action.andThen
,Action.alongWith
andAction.raceWith
.
- Added
IoInterface
for creating Io ports with the robot generically. - Added pnuematics interfaces under flashlib.core.io.
- Reworked robot bases:
- Separated
RobotControl
from robot bases. - Using interfaces and delegations to avoid massive inheritance trees.
robotInit
is no longer preferred when creating the robot. Instead, the use of a constructor is.
- Separated
- Vision pipelines reworked:
- Supporting a more functional and flexible API, actually mimicking a pipe flow.
- No longer working with only an
Image
type, now any type can be used.
See examples and Wiki for more information.
Release 2.2.0
- Renamed flashlibj -> flashcore.
- Scheduler conflicts fix.
Release 2.1.0
Update to the robot mode system, and robot bases.