Landfall

Changeset

170:d7a233d7a908
22 months ago Paul Boddie raw files shortlog changelog graph Fixed tests for defined fields. cpm-library-improvements
pkg/devices/lib/cpm/src/x1600.cc (file)
     1.1 --- a/pkg/devices/lib/cpm/src/x1600.cc	Sat Sep 16 00:49:41 2023 +0200
     1.2 +++ b/pkg/devices/lib/cpm/src/x1600.cc	Sat Sep 16 01:12:18 2023 +0200
     1.3 @@ -824,7 +824,7 @@
     1.4  void
     1.5  Clock_base::set_source(Cpm_regs &regs, uint8_t source)
     1.6  {
     1.7 -  if (_source.is_defined())
     1.8 +  if (!_source.is_defined())
     1.9      return;
    1.10  
    1.11    _source.set_field(regs, source);
    1.12 @@ -1054,7 +1054,7 @@
    1.13  void
    1.14  Clock::set_divider(Cpm_regs &regs, uint32_t division)
    1.15  {
    1.16 -  if (_divider.is_defined())
    1.17 +  if (!_divider.is_defined())
    1.18      return;
    1.19  
    1.20    change_enable(regs);