Need a little help/advice on PanelDUE on coding it
-
Hi Guys, mainly @dc42 David, I want to work out custom UI for your screens and possibly upgrade the touch panel to capacitive etc. mostly for the fun and a challenge. I have some guys in my team who can do that. And if we end up with something usable, I will surely share it under OS license.
With that said, is there any documentation of how your PanelDUE is actually programmed and where is the code to mess with that. And what kind of interface it uses with a board etc etc.
Basically all that is needed for the following tasks:
-
upgrading/changing lcd panel into capacitive version
-
reworking the UI
Thanks in advance.
Vlad
-
-
You can find the code at https://github.com/dc42/PanelDueFirmware. The UI items are defined in file src/UserInterface.cpp. I've never coded for capacitive touch screens so I can't help you with that.
-
@dc42 I don't need coding help. This info is more than enough for me and a good start! Will run it with my guys and see if we can come up with something cool Thanks a lot! I purchased a 6in screen to mess with it, only found IPS, but still hoping to find OLED on a market.
-
Hi @dc42 , do you know how to actually debug your paneldue while running it? Is there a way at all? I am messing with UI a bit, trial and error, debugging would make the process much faster actually, if there is a way. Thanks in advance!
-
@vlad Hi, you could put a hardware debugger/analyzer between Paneldue and Duet following the procedure of https://github.com/technik-gegg/SMuFF-Ifc
-
@vlad chapter 12 may help http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6500-32-bit-Cortex-M3-Microcontroller-SAM3S4-SAM3S2-SAM3S1_Datasheet.pdf (although, at a glance there doesnt appear to be a dedicated debug header onboard)
-
@bearer JTAG seems to be not completely exposed on the Duet: https://forum.duet3d.com/topic/6023/using-jtag-with-the-duet-wifi so it may be impossible to use it. But I did not try yet.
-
@bearer and @JoergS5 i'm also looking for a way to debug the firmware while running it on the LCD. I'm having a hard time to find any schematics for PanelDue 5i.
Any pointers to where i could find those?With a schematic i can figure out how to connect a debugger to the screen.
-
Yeah, at a glance it seemed like neither jtag or serial debug wire was brought out to a header, but i didn't crossrefrence all the pins against the schematic, left as an excercie for the reader sort to speak.
-
@dtpteunissen said in Need a little help/advice on PanelDUE on coding it:
I'm having a hard time to find any schematics for PanelDue 5i.
Havent seen, but I can't image they're very different to the v3 board https://raw.githubusercontent.com/dc42/PanelDue/master/PCB/V3.0/PaneDue-3.0-schematic.png
Between the code and the board should be doable to work out any major differences if any.
-
@bearer said in Need a little help/advice on PanelDUE on coding it:
@dtpteunissen said in Need a little help/advice on PanelDUE on coding it:
I'm having a hard time to find any schematics for PanelDue 5i.
Havent seen, but I can't image they're very different to the v3 board https://raw.githubusercontent.com/dc42/PanelDue/master/PCB/V3.0/PaneDue-3.0-schematic.png
Between the code and the board should be doable to work out any major differences if any.
The schematic for the SAM4S part of the PanelDue 5i and 7i is identical to the non-integrated version.
-
@dc42 said in Need a little help/advice on PanelDUE on coding it:
@bearer said in Need a little help/advice on PanelDUE on coding it:
@dtpteunissen said in Need a little help/advice on PanelDUE on coding it:
I'm having a hard time to find any schematics for PanelDue 5i.
Havent seen, but I can't image they're very different to the v3 board https://raw.githubusercontent.com/dc42/PanelDue/master/PCB/V3.0/PaneDue-3.0-schematic.png
Between the code and the board should be doable to work out any major differences if any.
The schematic for the SAM4S part of the PanelDue 5i and 7i is identical to the non-integrated version.
Thank you for the info. I checked the schematic, and its not possible to connect a JTAG or SWD debugger to the microcontroller since the needed pins are also connected to the LCD.
-
Actually it's not impossible. PB6/SWDIO goes to X4 the expansion connector, so it's free. PB7/SWCLK goes to RST on the LCD connector, so you could cut that trace and connect to it. The LCD may not need the reset signal, but if it does you could add a push button. You would need to modify the startup code not to program the bus matrix to use those pins as GPIO.
But I've never had to resort to a debugger when developing PanelDue code.
-
@dc42 @bearer thank you guys. Quite a bit to digest now!
-
@dc42 said in Need a little help/advice on PanelDUE on coding it:
Actually it's not impossible. PB6/SWDIO goes to X4 the expansion connector, so it's free. PB7/SWCLK goes to RST on the LCD connector, so you could cut that trace and connect to it. The LCD may not need the reset signal, but if it does you could add a push button. You would need to modify the startup code not to program the bus matrix to use those pins as GPIO.
But I've never had to resort to a debugger when developing PanelDue code.
I was considering that as well, but i'm a bit hesitant about modifying the PCB by cutting traces.
But this helped! Thanks