Hello,
I am using the AN00109 as a reference to write my custom loader. The code is no problem but I am trying to detect the status of an input and the xmos internal pull downs are activated.There does not seem to be a way to disable them while the loader is running.(until the actual firmware image runs)
I have tried setting the port to bidirectional, calling the set_port_drive_low function that should enable the internal pull up instead of the pull down before reading but the outcome is the same.
The problem is that the resistor I am using as an external pull up for the button is weak so that when the internal pull downs are active the port voltage level cannot reach the high threshold.
I can replace the external pull up with a lower value and it fixes the problem but ideally I would like a software solution so that I do not have to rework all my boards.
Is there a way with code to disable the pull downs while the loader is running?
The device is XEF232.
Thank you in advance!
pin pull downs disable in Loader Topic is solved
-
- Member++
- Posts: 22
- Joined: Fri Aug 12, 2016 6:13 pm
-
- Respected Member
- Posts: 347
- Joined: Wed Jan 27, 2016 5:21 pm
Hi plex,
Does set_port_pull_none(port) do the trick?
Cheers,
Henk
Does set_port_pull_none(port) do the trick?
Cheers,
Henk
-
- Member++
- Posts: 22
- Joined: Fri Aug 12, 2016 6:13 pm
Unfortunately no.
Regards,
Regards,
-
- Respected Member
- Posts: 347
- Joined: Wed Jan 27, 2016 5:21 pm
Which port are you looking at?
I would expect the pull downs to be off when you enable a port for input; the only exception being where the pull-downs are explicitly enabled such as on 4B where the pull downs are enabled to get them to a default state.
I would expect the pull downs to be off when you enable a port for input; the only exception being where the pull-downs are explicitly enabled such as on 4B where the pull downs are enabled to get them to a default state.
-
- Member++
- Posts: 22
- Joined: Fri Aug 12, 2016 6:13 pm
tile[0] XS1_PORT1A
But now that you mentioned that I did another test and think that I found what the actual issue is. The same button with pull up is connected to a port on tile[3] which is only initialised after the loader ends and the actual firmware image runs. So it makes sense for its pull down to be active while the loader is running.
Thanks!
But now that you mentioned that I did another test and think that I found what the actual issue is. The same button with pull up is connected to a port on tile[3] which is only initialised after the loader ends and the actual firmware image runs. So it makes sense for its pull down to be active while the loader is running.
Thanks!