[INSTRM-1043] Fix usage of ADC bits for old FPGA/ADCs. Created: 29/Jul/20 Updated: 29/Jul/20 Resolved: 29/Jul/20 |
|
| Status: | Done |
| Project: | Instrument control development |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Normal |
| Reporter: | cloomis | Assignee: | cloomis |
| Resolution: | Done | Votes: | 0 |
| Labels: | SM1, SPS | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
The configuration bits which control which 16-bit window to select from the 18-bit ADC outputs are being misused. The FPGA code for the new (sm2+) ADCs drops support for the old 16-bit ADCs, but the C code which controls both old and new ADCs allows setting the configuration to enable 16-bit support in the old ADCs, and swapped the usage of two of the bits. Not a problem for the new ADCs, but bad for the old ones. A two-line fix plus a comment. Needed for SM1 at Subaru until the ADCs get swapped. |
| Comments |
| Comment by cloomis [ 29/Jul/20 ] |
|
"Two-line fix" Yes, well. I ended up changing the way ADC versions and modes are tracked, with humans limited to requesting "lsb", "mid", msb" bits, and the CCD object mapping those to the correct FPGA bits. The mapping depends on the FPGA version, which is something which the CCD object knows about. The ADC version cannot be different from the major FPGA version, so we only need to worry about one, which we can read from hardware. This pretty much takes care of a couple of other issues, which I will set to Won't Fix. ics_xcu_fpga: merged at e293a8a, tagged 82.1.1 Both running at Subaru and JHU. |