
* emacstheviking
let payload = pack "\x00\x00\x00\x00" let endPoint = EndpointAddress 0 Out action <- writeInterrupt handle endPoint ^^^^^^^^^^^^^^ ^^^^^^ ^^^^^^^^ ^^^^^^^ writeInterrupt :: DeviceHandle -> EndpointAddress -> WriteAction
WriteAction parameter is missing. GHC tells you about that right here:
usb1.hs:60:13: Couldn't match expected type `IO t0' with actual type `WriteAction' In the return type of a call of `writeInterrupt' Probable cause: `writeInterrupt' is applied to too few arguments ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
In a stmt of a 'do' block: action <- writeInterrupt handle endPoint In the expression: do { putStrLn $ "Inspecting device: \"" ++ (show dev) ++ "\""; let payload = pack "\NUL\NUL\NUL\NUL"; let endPoint = EndpointAddress 0 Out; action <- writeInterrupt handle endPoint; .... } Failed, modules loaded: none.
-- Alexander Polakov | plhk.ru