However you can write simple script that converts exported CSV file into XML format.
No, we can't... The problem is that the Pins tool does not export enough information! There is no way to export in any format that will give us all the information we need (as we had in the IOmux xml).
An example:
Open the pins tool, select the i.MX6 Quad, click on peripherals, select ECPI1 -> miso, route to DISP0_DAT22.
Now, the info we need to be able to generate code to setup this pin is:
- Pad name
- Alt mode
- SION (2 and 3 together is SW_MUX_CTL_PAD_XXX)
- HYS, PUS, PUE, PKE, etc (all together SW_PAD_CTL_PAD_XXX)
- Daisy chain register
- Daisy chain value
- PAD to GPIO connection (what GPIO is this pad if we configure it for ALT5)
The IOmux xml had all this info included (apart from item 7, but that was easy to get by selecting all GPIOs and saving that xml).
If we export to csv using the pins tool we get:
V24;DISP0_DAT22;;;;GPIO5_IO16(GPIO5,gpio,16);;IPU1_DISP0_DATA22(IPU1,disp0_dat,22)/IPU2_DISP0_DATA22(IPU2,disp0_dat,22);;ECSPI1_MISO(ECSPI1,miso);;;;AUD4_TXFS(AUDMUX,aud4_txfs);;;;;;;;;;;;;;;;;;;;;;;ECSPI1_MISO
So, we can extract the info listed in item 1 and item 7, but we are missing the info from item 2, 3, 4, 5 and 6.
The pins tool is in that respect a step backwards...
Would it be possible for NXP to add the missing information to the csv export? Also; it is really not necessary to export all pins. Why not just export the selected pins?
Or even better; why not implement plugin support so we can write our own export plugins?