Changeset 1533
- Timestamp:
- 03/30/09 15:48:16 (15 years ago)
- Files:
-
- trunk/libffado/doc/rme_notes/rme_config_register_map.txt (modified) (2 diffs)
- trunk/libffado/src/rme/fireface_def.h (added)
- trunk/libffado/src/rme/rme_avdevice.cpp (modified) (4 diffs)
- trunk/libffado/src/rme/rme_avdevice.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/libffado/doc/rme_notes/rme_config_register_map.txt
r1532 r1533 191 191 192 192 For the FF400, the buffer is written in 32-quadlet (128-byte) sub-blocks via 193 a bounce buffer. If the final sub-block is not 32-quadlets the write is only194 as big as the sub-block (that is, no padding takes place). The sub-block 195 data to be written is sent to register 0x80100290. The 2-quadlet register 196 at 0x80100288 is set with the flash address to write the block to and the197 size (in bytes) of the data block. Finally, a 0x1 is written to CBA+(8*4) 198 to initiate the write. Polling for "device not busy" should commence after 199 a wait of 2 ms.193 a bounce buffer. If the final sub-block is not 32-quadlets the write is 194 only as big as the sub-block (that is, no padding takes place). The 195 sub-block data to be written is sent to the block starting at 0x80100290. 196 The 2-quadlet register at 0x80100288 is set with the flash address to write 197 the block to and the size (in bytes) of the data block. Finally, a 0x1 is 198 written to CBA+(8*4) to initiate the write. Polling for "device not busy" 199 should commence after a wait of 2 ms. 200 200 201 201 … … 207 207 208 208 On the FF400, erasure is controlled by writing a special magic number to 209 the the flash erasecontrol register (CBA+8*4):209 the the flash control register (CBA+8*4): 210 210 Erase volume: write 0xe 211 211 Erase settings: write 0xd trunk/libffado/src/rme/rme_avdevice.cpp
r1532 r1533 1 1 /* 2 * Copyright (C) 2005-200 8by Jonathan Woithe2 * Copyright (C) 2005-2009 by Jonathan Woithe 3 3 * Copyright (C) 2005-2008 by Pieter Palmers 4 4 * … … 26 26 27 27 #include "rme/rme_avdevice.h" 28 #include "rme/fireface_def.h" 28 29 29 30 #include "libieee1394/configrom.h" … … 43 44 44 45 namespace Rme { 46 47 // Template for a RmeDevice object method which intelligently returns a 48 // register or value applicable to the connected model and warns if something 49 // isn't quite right. 50 #define MODEL_SELECTOR(_name,_ff400_arg,_ff800_arg) \ 51 unsigned long long int \ 52 RmeDevice::_name() { \ 53 switch (m_rme_model) { \ 54 case RME_MODEL_FIREFACE400: return _ff400_arg; \ 55 case RME_MODEL_FIREFACE800: return _ff800_arg; \ 56 default: \ 57 debugOutput( DEBUG_LEVEL_WARNING, "Bad RME model %d\n", m_rme_model ); \ 58 } \ 59 return 0xffffffffffffffffLL; \ 60 } 45 61 46 62 // to define the supported devices … … 67 83 68 84 } 85 86 MODEL_SELECTOR(cmd_buffer_addr, RME_FF400_CMD_BUFFER, RME_FF800_CMD_BUFFER) 87 MODEL_SELECTOR(stream_start_reg, RME_FF400_STREAM_START_REG, RME_FF800_STREAM_START_REG) 88 MODEL_SELECTOR(stream_end_reg, RME_FF400_STREAM_END_REG, RME_FF800_STREAM_END_REG) 89 MODEL_SELECTOR(flash_settings_addr, RME_FF400_FLASH_SETTINGS_ADDR, RME_FF800_FLASH_SETTINGS_ADDR) 90 MODEL_SELECTOR(flash_mixer_vol_addr, RME_FF400_FLASH_MIXER_VOLUME_ADDR, RME_FF800_FLASH_MIXER_VOLUME_ADDR) 91 MODEL_SELECTOR(flash_mixer_pan_addr, RME_FF400_FLASH_MIXER_PAN_ADDR, RME_FF800_FLASH_MIXER_PAN_ADDR) 92 MODEL_SELECTOR(flash_mixer_hw_addr, RME_FF400_FLASH_MIXER_HW_ADDR, RME_FF800_FLASH_MIXER_HW_ADDR) 69 93 70 94 bool trunk/libffado/src/rme/rme_avdevice.h
r1532 r1533 100 100 101 101 signed int m_ddsFreq; 102 103 private: 104 unsigned long long int cmd_buffer_addr(); 105 unsigned long long int stream_start_reg(); 106 unsigned long long int stream_end_reg(); 107 unsigned long long int flash_settings_addr(); 108 unsigned long long int flash_mixer_vol_addr(); 109 unsigned long long int flash_mixer_pan_addr(); 110 unsigned long long int flash_mixer_hw_addr(); 102 111 }; 103 112