- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am using a CY8C29466-24PXI want to change P0[6] from an INPUT with PULL-UP (DRIVE) to an OUTPUT with STRONG (DRIVE) is assembler. What is the code to accomplish this?
Solved! Go to Solution.
- Labels:
-
PSoC 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The code in "C" would be
DM0 =1, DM1 = 0, DM2 = 0 for strong drive.
PRT0DM0 != 0x40;
PRT0DM1 &= ~0x40;
PRT0DM2 &= ~0x40;
This would translate in assembler to be:
OR F, 0x10 ; Set register bank 1
OR REG[0x00], 0x40 ; PRT0DM0
AND REG[0x01], 0xBF; PRT0DM1
AND F, 0xCF ; Set register bank 0
AND REG[0x03], 0xBF; PRT0DM2
Best regards,
Sampath Selvaraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The code in "C" would be
DM0 =1, DM1 = 0, DM2 = 0 for strong drive.
PRT0DM0 != 0x40;
PRT0DM1 &= ~0x40;
PRT0DM2 &= ~0x40;
This would translate in assembler to be:
OR F, 0x10 ; Set register bank 1
OR REG[0x00], 0x40 ; PRT0DM0
AND REG[0x01], 0xBF; PRT0DM1
AND F, 0xCF ; Set register bank 0
AND REG[0x03], 0xBF; PRT0DM2
Best regards,
Sampath Selvaraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank youSent via the Samsung Galaxy S8+, an AT&T 5G Evolution smartphone