Safe Haskell | None |
---|
Some convenience for building applications that want to read Emotiv data.
You can use this if you are writing an EEG application and don't want to do the whole device selection / opening yourself.
- data EmotivArgs = EmotivArgs {
- model :: EmotivModel
- serial :: Maybe SerialNumber
- fromFile :: Maybe FilePath
- emotivArgsParser :: Parser EmotivArgs
- parseModel :: Monad m => String -> m EmotivModel
- parseArgs :: String -> Parser a -> IO a
- getEmotivDeviceFromArgs :: EmotivArgs -> IO (Either String EmotivDevice)
Documentation
data EmotivArgs
Commonly used options for EEG command line applications. Mainly deals with input selection.
EmotivArgs | |
|
Eq EmotivArgs | |
Ord EmotivArgs | |
Show EmotivArgs |
emotivArgsParser :: Parser EmotivArgs
Command line parser for EEG selection. See EmotivArgs
.
parseModel :: Monad m => String -> m EmotivModel
EEG model command line parser.
parseArgs :: String -> Parser a -> IO a
Runs a command line parser. The given program description is used for the --help message.
getEmotivDeviceFromArgs :: EmotivArgs -> IO (Either String EmotivDevice)
Depending on some common EEG-choice-related user input, list devices or try to open the correct device.