Hi all,
I'm having a bit of difficulty understanding binary pin references. It's a problem I've had before and it's a problem I'd like to not have anymore, so perhaps someone could help me out a little.
I'm trying to re-work some code to run the gadget gangster 4.3" LCD touchscreen. Currently it works by connecting the VGA pins on the device into pins 16 to 23 on my propeller, and in the code, that is referenced with '%010_111, and it has the following notes attached to it on how to change the pins around:
I want the LCD to be connected to pins 8 to 15 (which is what they've done in the example there) but for some reason, when I change it to have the code VgaPins=%01111 it still won't work... Am I doing something wrong? The original code has an underscore in there, and the new one doesn't...Code:CON 'Here is where you define the pins you use to control the 3.5" LCD BackLightPin=26 ResetPin=12 'reset PixelClockPin=25 DataEnablePin=24 TouchIrqPin=27 'This pin is really optional, but touchscreen sets this whenever screen is touched VgaPins=%010_111 'Pins 16..23 This is the same syntax as used by the VGA driver '' vga_pins '' '' bits 5..3 select pin group: '' %000: pins 7..0 '' %001: pins 15..8 '' %010: pins 23..16 '' %011: pins 31..24 '' %100: pins 39..32 '' %101: pins 47..40 '' %110: pins 55..48 '' %111: pins 63..56 '' '' bits 2..0 select top pin within group '' for example: %01111 (15) will use pins %01000-%01111 (8-15)
I feel a bit silly asking about this, but it's been driving me up the wall...



Reply With Quote
sorry about that. Should have updated that first. Nothing else will be assigned from 8 to 15.




Bookmarks