This is in the serial number range that many 2nd Michigan Cavalry used first model Spencer carbines are found:
17790 - issued 1864 - CO L, 2ND MICH VOL CAV
17796 - issued 1864 - CO A, 2ND MICH VOL CAV
17817 - issued 1864 - CO B, 2ND MICH VOL CAV
17817 - issued 1864 - CO L, 2ND MICH VOL CAV
17823 - issued 1864 - CO A, 2ND MICH VOL CAV
However, there are some just outside this range issued to other units, such as:
17825 - issued 03/01/1864 - CO M, 12TH ILL VOL CAV