Browse Source

added 'in' and 'out' as synonyms for 'read' and 'write'...but undocumented, so as to not confuse the 'mode' arguments

Pat Beirne 2 years ago
parent
commit
8684eca46f
1 changed files with 2 additions and 1 deletions
  1. 2 1
      opio

+ 2 - 1
opio

@@ -1,5 +1,4 @@
 #!/usr/bin/python3
-# TODO: add 'out' and 'in' as almost-synonyms for 'write' and 'read'
 """
   This is a clone of the 'gpio/WiringPi' project, written specifically for the
   OrangePi i96.
@@ -600,6 +599,8 @@ if __name__ == "__main__":
          "mode":do_mode,
          "read":do_read,
          "write":do_write,
+         "in":do_read,
+         "out":do_write,
          "exports":do_exports}
   f = switcher.get(args.cmd)
   if not f: