Prop Counter Details ??
Hi All;
I'm using a prop counter on one cog in the NCO mode for internal timing purposes by accessing the counter's Phase register, and that works fine. I note however that a Phase register bit31 output appears on pin0 of port A. This is not desirable as that signal is of no value to me, and it consumes a port pin.
So, I thought, I will assign the counter to pin0 of portB which is not pinned out. In doing that, port A pin0 still exhibits the bit31 output from the Phase register.
What is going on here?·I did not think·the port B pins were doubled up on top of the port A pins. What am I missing?
Cheers,
Peter (pjv)
I'm using a prop counter on one cog in the NCO mode for internal timing purposes by accessing the counter's Phase register, and that works fine. I note however that a Phase register bit31 output appears on pin0 of port A. This is not desirable as that signal is of no value to me, and it consumes a port pin.
So, I thought, I will assign the counter to pin0 of portB which is not pinned out. In doing that, port A pin0 still exhibits the bit31 output from the Phase register.
What is going on here?·I did not think·the port B pins were doubled up on top of the port A pins. What am I missing?
Cheers,
Peter (pjv)
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Nyamekye,
But it still begs the question of what I was observing..... seeing a port A output on a port B assignment??
Anyone??
Cheers,
Peter (pjv)
The CTRA / CTRB register’s fields are organized to make use of the assembly instructions MOVS,
MOVD and MOVI. The APIN field may be set using the MOVS instruction, the BPIN field using the
MOVD instruction and the CTRMODE/ PLLDIV fields using the MOVI instruction. The BPIN and
APIN fields are six bits each, the highest bit in each field (bits 5 and 14) are reserved for future use
and are ignored by the P8X32A Propeller. Both counters have their own APIN and BPIN and are
specified uniquely in their CTRA / CTRB register.
This means that you cannot effectively specify pins in port B.
-Phil
From the Manual v1.1 I read
"The APIN field of CTRA selects a primary I/O pin for that counter. May be ignored if not used. %0xxxxx = Port A, %1xxxxx = Port B (reserved for future use). In Propeller Assembly, the APIN field can conveniently be written using the MOVS instruction."
The "reserved for future use" had not implied to me in this case that port A would by default take on the function of an assignment to port B.
After all, port B is not totally dead..... it functions just fine internally as readable latches.
But I believe you are right..... just one of those quirks.
Cheers,
Peter (pjv)