CaptainTuna
Member
Hi guys!
I recently bought an ISD4002 (IC used for recording and playing audio) and it works with SPI. Now, I have a picaxe 28x1 and was trying to interface it with the ISD chip. In the ISD's manual it says:
It is necessary therefore to shift in HEX address 20, <0010 0000>....
The input byte, <0010 0000>, is to be clocked in, right to left.
And then it shows this example to understand how the right-to-left shifting works:
MCU ---> ISD
<0010 0000> ---> <0000 0000>
<0001 0000> ---> <0000 0000>
<0000 1000> ---> <0000 0000>
<0000 0100> ---> <0000 0000>
<0000 0010> ---> <0000 0000>
<0000 0001> ---> <0000 0000>
<0000 0000> ---> <1000 0000>
<0000 0000> ---> <0100 0000>
<0000 0000> ---> <0010 0000>
and then it says:
Note that some microcontrollers with hardware SPI ports only have the ability to do a left to right shift. Consult the μP data sheet for details. If this is so, then the bit placement of the data shifted in would have to be inverted.
My question is: is there a way to know how the SPI works for the picaxe? Do i just have to use hspiout the normal way (regarding the above example, i'll just input the data <0010 0000>) ?
Thank you
I recently bought an ISD4002 (IC used for recording and playing audio) and it works with SPI. Now, I have a picaxe 28x1 and was trying to interface it with the ISD chip. In the ISD's manual it says:
It is necessary therefore to shift in HEX address 20, <0010 0000>....
The input byte, <0010 0000>, is to be clocked in, right to left.
And then it shows this example to understand how the right-to-left shifting works:
MCU ---> ISD
<0010 0000> ---> <0000 0000>
<0001 0000> ---> <0000 0000>
<0000 1000> ---> <0000 0000>
<0000 0100> ---> <0000 0000>
<0000 0010> ---> <0000 0000>
<0000 0001> ---> <0000 0000>
<0000 0000> ---> <1000 0000>
<0000 0000> ---> <0100 0000>
<0000 0000> ---> <0010 0000>
and then it says:
Note that some microcontrollers with hardware SPI ports only have the ability to do a left to right shift. Consult the μP data sheet for details. If this is so, then the bit placement of the data shifted in would have to be inverted.
My question is: is there a way to know how the SPI works for the picaxe? Do i just have to use hspiout the normal way (regarding the above example, i'll just input the data <0010 0000>) ?
Thank you