STM32-Zombie-0.2.0: control a STM32F103 microcontroller

Copyright(c) Marc Fontaine 2017
LicenseBSD3
MaintainerMarc.Fontaine@gmx.de
Stabilityexperimental
PortabilityGHC-only
Safe HaskellNone
LanguageHaskell2010

App.ADC

Description

This module shows an example for using the analog digital converter. The ADC of the STM32 works best in combination with DMA transfers. This example turns the STM32 into a small digital storage oscilloscope. Thanks to DMA transfers, one can sample with precise timings and sampling rate is not limited by the speed of the Haskell code.

Synopsis

Documentation

sampleBlock :: FilePath -> IO () Source #

Periodically sample a block of data and write it to a file. In combination with a wave-form viewer that can detect file updates, this works as a poor mans' digital storage oscilloscope.