Output the audio signal with filtering by graphic equalizer in the *.wav file on the SD card using onboard CODEC. SD カードの *.wav ファイルのオーディオ信号をグラフィック・イコライザを通して,ボードに搭載されているCODEC で出力する.

Dependencies:   F746_GUI F746_SAI_IO SD_PlayerSkeleton FrequencyResponseDrawer

Committer:
MikamiUitOpen
Date:
Sun Oct 02 06:33:59 2016 +0000
Revision:
16:cbb726ac20d8
17

Who changed what in which revision?

UserRevisionLine numberNew contents of line
MikamiUitOpen 16:cbb726ac20d8 1 /* mbed Microcontroller Library
MikamiUitOpen 16:cbb726ac20d8 2 * Copyright (c) 2006-2013 ARM Limited
MikamiUitOpen 16:cbb726ac20d8 3 *
MikamiUitOpen 16:cbb726ac20d8 4 * Licensed under the Apache License, Version 2.0 (the "License");
MikamiUitOpen 16:cbb726ac20d8 5 * you may not use this file except in compliance with the License.
MikamiUitOpen 16:cbb726ac20d8 6 * You may obtain a copy of the License at
MikamiUitOpen 16:cbb726ac20d8 7 *
MikamiUitOpen 16:cbb726ac20d8 8 * http://www.apache.org/licenses/LICENSE-2.0
MikamiUitOpen 16:cbb726ac20d8 9 *
MikamiUitOpen 16:cbb726ac20d8 10 * Unless required by applicable law or agreed to in writing, software
MikamiUitOpen 16:cbb726ac20d8 11 * distributed under the License is distributed on an "AS IS" BASIS,
MikamiUitOpen 16:cbb726ac20d8 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
MikamiUitOpen 16:cbb726ac20d8 13 * See the License for the specific language governing permissions and
MikamiUitOpen 16:cbb726ac20d8 14 * limitations under the License.
MikamiUitOpen 16:cbb726ac20d8 15 */
MikamiUitOpen 16:cbb726ac20d8 16 #ifndef MBED_BUSIN_H
MikamiUitOpen 16:cbb726ac20d8 17 #define MBED_BUSIN_H
MikamiUitOpen 16:cbb726ac20d8 18
MikamiUitOpen 16:cbb726ac20d8 19 #include "platform.h"
MikamiUitOpen 16:cbb726ac20d8 20 #include "DigitalIn.h"
MikamiUitOpen 16:cbb726ac20d8 21
MikamiUitOpen 16:cbb726ac20d8 22 namespace mbed {
MikamiUitOpen 16:cbb726ac20d8 23
MikamiUitOpen 16:cbb726ac20d8 24 /** A digital input bus, used for reading the state of a collection of pins
MikamiUitOpen 16:cbb726ac20d8 25 */
MikamiUitOpen 16:cbb726ac20d8 26 class BusIn {
MikamiUitOpen 16:cbb726ac20d8 27
MikamiUitOpen 16:cbb726ac20d8 28 public:
MikamiUitOpen 16:cbb726ac20d8 29 /* Group: Configuration Methods */
MikamiUitOpen 16:cbb726ac20d8 30
MikamiUitOpen 16:cbb726ac20d8 31 /** Create an BusIn, connected to the specified pins
MikamiUitOpen 16:cbb726ac20d8 32 *
MikamiUitOpen 16:cbb726ac20d8 33 * @param <n> DigitalIn pin to connect to bus bit <n> (p5-p30, NC)
MikamiUitOpen 16:cbb726ac20d8 34 *
MikamiUitOpen 16:cbb726ac20d8 35 * @note
MikamiUitOpen 16:cbb726ac20d8 36 * It is only required to specify as many pin variables as is required
MikamiUitOpen 16:cbb726ac20d8 37 * for the bus; the rest will default to NC (not connected)
MikamiUitOpen 16:cbb726ac20d8 38 */
MikamiUitOpen 16:cbb726ac20d8 39 BusIn(PinName p0, PinName p1 = NC, PinName p2 = NC, PinName p3 = NC,
MikamiUitOpen 16:cbb726ac20d8 40 PinName p4 = NC, PinName p5 = NC, PinName p6 = NC, PinName p7 = NC,
MikamiUitOpen 16:cbb726ac20d8 41 PinName p8 = NC, PinName p9 = NC, PinName p10 = NC, PinName p11 = NC,
MikamiUitOpen 16:cbb726ac20d8 42 PinName p12 = NC, PinName p13 = NC, PinName p14 = NC, PinName p15 = NC);
MikamiUitOpen 16:cbb726ac20d8 43
MikamiUitOpen 16:cbb726ac20d8 44 BusIn(PinName pins[16]);
MikamiUitOpen 16:cbb726ac20d8 45
MikamiUitOpen 16:cbb726ac20d8 46 virtual ~BusIn();
MikamiUitOpen 16:cbb726ac20d8 47
MikamiUitOpen 16:cbb726ac20d8 48 /** Read the value of the input bus
MikamiUitOpen 16:cbb726ac20d8 49 *
MikamiUitOpen 16:cbb726ac20d8 50 * @returns
MikamiUitOpen 16:cbb726ac20d8 51 * An integer with each bit corresponding to the value read from the associated DigitalIn pin
MikamiUitOpen 16:cbb726ac20d8 52 */
MikamiUitOpen 16:cbb726ac20d8 53 int read();
MikamiUitOpen 16:cbb726ac20d8 54
MikamiUitOpen 16:cbb726ac20d8 55 /** Set the input pin mode
MikamiUitOpen 16:cbb726ac20d8 56 *
MikamiUitOpen 16:cbb726ac20d8 57 * @param mode PullUp, PullDown, PullNone
MikamiUitOpen 16:cbb726ac20d8 58 */
MikamiUitOpen 16:cbb726ac20d8 59 void mode(PinMode pull);
MikamiUitOpen 16:cbb726ac20d8 60
MikamiUitOpen 16:cbb726ac20d8 61 /** Binary mask of bus pins connected to actual pins (not NC pins)
MikamiUitOpen 16:cbb726ac20d8 62 * If bus pin is in NC state make corresponding bit will be cleared (set to 0), else bit will be set to 1
MikamiUitOpen 16:cbb726ac20d8 63 *
MikamiUitOpen 16:cbb726ac20d8 64 * @returns
MikamiUitOpen 16:cbb726ac20d8 65 * Binary mask of connected pins
MikamiUitOpen 16:cbb726ac20d8 66 */
MikamiUitOpen 16:cbb726ac20d8 67 int mask() {
MikamiUitOpen 16:cbb726ac20d8 68 return _nc_mask;
MikamiUitOpen 16:cbb726ac20d8 69 }
MikamiUitOpen 16:cbb726ac20d8 70
MikamiUitOpen 16:cbb726ac20d8 71 #ifdef MBED_OPERATORS
MikamiUitOpen 16:cbb726ac20d8 72 /** A shorthand for read()
MikamiUitOpen 16:cbb726ac20d8 73 */
MikamiUitOpen 16:cbb726ac20d8 74 operator int();
MikamiUitOpen 16:cbb726ac20d8 75
MikamiUitOpen 16:cbb726ac20d8 76 /** Access to particular bit in random-iterator fashion
MikamiUitOpen 16:cbb726ac20d8 77 */
MikamiUitOpen 16:cbb726ac20d8 78 DigitalIn & operator[] (int index);
MikamiUitOpen 16:cbb726ac20d8 79 #endif
MikamiUitOpen 16:cbb726ac20d8 80
MikamiUitOpen 16:cbb726ac20d8 81 protected:
MikamiUitOpen 16:cbb726ac20d8 82 DigitalIn* _pin[16];
MikamiUitOpen 16:cbb726ac20d8 83
MikamiUitOpen 16:cbb726ac20d8 84 /** Mask of bus's NC pins
MikamiUitOpen 16:cbb726ac20d8 85 * If bit[n] is set to 1 - pin is connected
MikamiUitOpen 16:cbb726ac20d8 86 * if bit[n] is cleared - pin is not connected (NC)
MikamiUitOpen 16:cbb726ac20d8 87 */
MikamiUitOpen 16:cbb726ac20d8 88 int _nc_mask;
MikamiUitOpen 16:cbb726ac20d8 89
MikamiUitOpen 16:cbb726ac20d8 90 /* disallow copy constructor and assignment operators */
MikamiUitOpen 16:cbb726ac20d8 91 private:
MikamiUitOpen 16:cbb726ac20d8 92 BusIn(const BusIn&);
MikamiUitOpen 16:cbb726ac20d8 93 BusIn & operator = (const BusIn&);
MikamiUitOpen 16:cbb726ac20d8 94 };
MikamiUitOpen 16:cbb726ac20d8 95
MikamiUitOpen 16:cbb726ac20d8 96 } // namespace mbed
MikamiUitOpen 16:cbb726ac20d8 97
MikamiUitOpen 16:cbb726ac20d8 98 #endif