14M output question

orko007

New Member
I am working on a project with an xbox controller making button functions happen with a picaxe chip. the 08M did not have enough in/outputs so i want to use a 14M. my only problem is on the that i need to pull a button to 0V to activate it but when the output is set to HIGH the button on the controller no longer works. because +5v is going to it. On the 08M i can change the output to an input to get around this but on the 14M i cannot. is there anything i can do within the chip on the 14M to make this work or will i need an external switch to make this happen the way I want?
 

eclectic

Moderator
Orko

You CAN change some of the 14M pins.

Please read
http://www.rev-ed.co.uk/docs/picaxe_manual1.pdf

Page 20

Then pages 70 –71.

e.
 

BeanieBots

Moderator
If you need to pull a line low but then let it float rather than push up to 5v, simply add a diode between the PICAXE output and the line you wish to control. (pointy end towards PICAXE).
It will give the same effect as an open collector output and/or a PICAXE switching between low and tri-state.
 

orko007

New Member
Ah ha, i guess i did not read enough. i was only looking at page 20 which does not mention being able to change them.

this has brought up a few more quesitons then. When using the like "let dirsc = %00111111" to switch all ports to outputs are they by default HIGH or LOW? Also if a pin is already an output and you use the command above will it affect the HIGH/LOW status of that pin?

Then if I use "high portc 4" to change a input to an output can if be reffered to as just c4 thereafter so then "low c4"?

sorry for the newb questions but have not found much on ports in the manuals. if someone could direct me that would be great.
 

hippy

Technical Support
Staff member
<i>When using the like &quot;let dirsc = %00111111&quot; to switch all ports to outputs are they by default HIGH or LOW? </i>

They will probably go to whatever state they were before they became inputs. I say probably, because I haven't tried it but it would be consistent with the behaviour of other PICAXE's.

<i>Also if a pin is already an output and you use the command above will it affect the HIGH/LOW status of that pin? </i>

No it should not.

<i>Then if I use &quot;high portc 4&quot; to change a input to an output can if be reffered to as just c4 thereafter so then &quot;low c4&quot;? </i>

No, you have to always use &quot;High PortC 4&quot; or &quot;Low PortC 4&quot;.
 
Top