Commit Graph

18 Commits

Author SHA1 Message Date
Dave
66df34a972 Added arch API for msec delay. 2021-12-04 23:06:39 -06:00
Dave
562b859540 Add apple 2 caps, printing, bug fixes
- Added the apple 2 CAPS map

- auto-generate a function to check validity of a keymap index

- Added buffered message printing. This is different from keycode
buffering, since an extra delay is added for each message character to
allow polling hosts to keep up. Keycodes are generated at human speeds
and need no further slowdown.

- Added a message character delay to the arch-* modules

- enlarged the buffer pool, and created a buffer for messages

- bumped version number
2021-11-29 16:26:08 -06:00
Dave
7801a17f56 Add DIP switch select for strobe polarity and autorepeat
- arch-* files: replace private arch_strobe_init() function with public
arch_set_neg_strobe() and arch_set_pos_strobe() functions

- asdf.c,h: add ACTION hooks to set strobe polarity and enable/disable
autorepeat

- break out DIP switch definitions into a separate header file, included by each
keymap.  This ensures consistent DIP switch behavior across keymaps.
2020-05-15 14:42:06 -05:00
Dave
3c1d050abb Move F_CPU to header file and clean up 2560 read_row() code 2020-05-12 17:09:49 -05:00
Dave
de346a1e59 Merge branch 'hooks' 2020-05-05 15:10:40 -05:00
Dave
5baf20a16b Get hook functionality running and DIP switch cleanup 2020-05-05 15:05:54 -05:00
Dave
c7b8641d0d Define dipswitch row in arch-dependent module.
Because the DIP switch row is hardwired on the controller board.
2020-05-03 12:05:27 -05:00
Dave
4d8bc2a9be (Development branch) Added in code to implement fuction hooks 2020-05-01 16:39:21 -05:00
David Fenyes
dae4b8d322 Replaced the Virtual out pulse function with long and short pulse
- Replace V_PULSE with V_PULSE_LONG and V_PULSE_SHORT functions.

- replace the asdf_arch_pulse_delay() with asdf_arch_pulse_delay_short() and
asdf_arch_pulse_delay_long() functions.

- modify keymaps to use long and short pulses.

- long pulse is 50 ms.  Short pulse is 10 us.

- Added localizing prefix to keymap definitions to avoid conflicts.
2020-03-17 01:42:51 -05:00
David Fenyes
93349ed6e9 Add support for "hi-z when low" outputs
The apple 1 CLEAR input requires a high-impedance inactive state to avoid
conflict with the pin output of the 7404 at D12 (via CR4). So, to cover this
condition most generally, this patch changes the adds a Hi-Z when low physical
device for each output line, to complement the Hi-Z-when-high open collector
emulation. The nomenclature is changed from OUT*_OC (emulated open collector) to
OUT*_OPEN_HI and OUT*_OPEN_LO to indicate which condition gets the Hi-Z state.

- added the set() functions to the asdf_arch_atmega328p.[ch] files and applied
the above nomenclature.

- Added the set() functions to the asdf_physical.[ch] files and applied the
above nomenclature

- Modified the SCREEN_CLEAR device to PHYSICAL_OUT1_OPEN_LO in the apple2 and
ascii keymaps.

- Changed the RESET from PHYSICAL_OUT1_OC to PHYSICAL_OUT1_OPEN_HI in the apple2
and ascii keymaps.
2020-03-16 12:56:21 -05:00
David Fenyes
1b388bc591 Add virtual output device module (compiles without warning)
* Created test fixture for virtual outputs

* Added virtual output configuration to keymap definitions removed special
actions_send_reset() and actions_send_screenclear() functions, and replaced with
virtual output definitions.

* asdf_actions.c is removed from build.

* asdf_arch_atmega328p.c: added functions to set/clear each real output

* asdf_arch_atmega328p.c: added pulse_delay() function

* asdf_arch_test.c: added mock machinery to emulate outputs, test output
settings, and detect properly and improperly-formed pulses on the outputs.

* asdf_keymaps.c: allocate initialzer array. asdf_keymaps_select_keymap() calls
asdf_virtual_init() with initializer list for the keymap to set up the LEDS and
outputs every time a new keymap is selected.
2020-03-08 14:45:40 -05:00
David Fenyes
cff7f6052a Changes for virtual LED and output mapping.
Rough first cut, have not yet tried to compile or test.
2020-03-06 13:24:03 -06:00
David Fenyes
a598eaaee1 Add support for LEDs
- asdf_modifier.c: refactor CAPS LOCK setting and add LED setting
- asdf_arch_atmega328p.[ch]: add in LED definitions and functions
- add dummy asdf_arch_caps_led() function to arch files so test can compile.
2020-02-20 16:48:17 -06:00
David Fenyes
6e462589cc Arch file support for 4-bit row address. 2020-02-19 23:32:14 -06:00
Dave
3c34734a46 I/O cleanup and SYS_RESET fix
- Break out initialization of SYS_RESET, CLEAR, STROBE, and CAPS LED into
  separate functions.

- Emulate open collector output for SYS_RESET: OFF=input with weak pullup.
  ON=output low.

- Add function to cap CAPS LED.
2019-12-28 10:22:00 -06:00
Dave
a03473769f Added screen clear and reset functions
- added asdf_actions.c, asdf_actions.h to place misc. key actions
- asdf.c: asdf_activate_action(): added actions for screen clear and reset
- asdf_config.h, Arch/asdf_arch_atmega328p.c: added defs to specify polarity of data,
  strobe, SCREEN_CLEAR and reset outputs.
- Arch/asdf_arch_atmega328p.h: fixed pin definitions for RESET and SCREEN_CLEAR
2019-12-15 02:38:04 -06:00
Dave
6b78fe9111 Change "Universal" to more accurate "Unified" 2019-12-15 02:09:15 -06:00
Dave
784805adc7 first commit 2019-12-12 14:46:29 -06:00