This change adds a build recipe that pastes a header and footer file
to the preprocessed sketch file.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
Those members cause compiler warnings when using recent
compilers. The members are unused and can be safely removed as
they are inaccessible to derived classes.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
Only the virtual device knows about the size of its
EEPROM storage. Including device headers in the virtual
core is not intended (and technical not possible).
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
This file was introduced during an earlier stage of the
work on implementing a general virtual hardware. After
Kaleidoscope's device API redesign it is no more required.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
This makes the build much simpler as the FQBN
can now e.g. be given as keyboardio:virtual:model01
and the build process will automatically find the
virtual arduino core in virtual/cores/arduino
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
This considers improvements that already had been considered for the avr
architecture.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
The virtual hardware is among other purposses meant
to be used for debugging firmware issues.
The flag -Os optimizes out specific information that makes
proper debugging difficult in some situations.
Also, the virtual hardware does not come with restrictions
in terms of PROGMEM. That's why space efficiency is not needed there.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
Some parts were moved over from Kaleidoscope-Hardware-Virtual.
The virtual hardware is now a drop in for the real
pluggable USB interface.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
Consumer code can access the command line via
an additional callback of the virtual hardware.
This makes it possible to access the name of
the executable that is currently executed.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
By this means it is possible to simplify running automatic
simulation based testing with virtual firmare builds.
If a firmware sketch defines a test function it will
be executed.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
Through a command line parameter, the virtual
firmware executable can be instructed to execute
a testing function instead of processing
stdin/stdout I/O.
This can be used to attach an external
testing interface.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
This commit re-enables virtual builds with the Model01 keyboard.
The commit also prepares the infrastructure to generate virtual builds with all other
keyboards currently supported.
Please note that this commit does not enable virtual builds of the stock firmware
right away. This is because currently the stock firmware uses the
Model01-Testmode which is not compatible with virtual builds.
The stock firmware could be made ready for virtual builds by replacing the
Model01-Testmode with the more general HardwareTestMode.
In general for those features/plugins that do not support virtual builds,
this commit adds the generation of compiler error messages
that inform about what parts of the sketch need to be changed to allow virtual
builds.
To allow the stock firmware to build for the virtual core, just remove the
Model01-TestMode, then run the build on a unixoid system as follows.
cd ..../libraries/Model01-Firmware
ARCH=x86 make
With this change, virtual builds are furtheron triggered via setting ARCH=x86.
The board that firmware is meant to be build for is defined through the
BOARD variable, just like with non-virtual builds.
Please note that it is currently not yet possible to run virtual builds for
other keyboards than the Model01. This as because only for the Model01
specification files Model01_Spec.h/cpp have been generated.
To enable virtual builds for all keyboards, specification files need to be
factored out for all keyboards apart from Model01.
After all keyboards will have been made available to virtual builds
through future changes, it will be possible to build the whole examples set
as
cd ..../libraries/Kaleidoscope
ARCH=x86 BOARD_HARDWARE_PATH=$PWD/../../../.. make smoke-examples
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>
The two contained c++ files are almost identical to those
in KeyboardioHID.
The HID library is not used by the build. Checks prove that two
firmware binaries build with and without the library are identical.
Signed-off-by: Florian Fleissner <florian.fleissner@inpartik.de>