shaddow501

Members
  • Content Count

    7
  • Joined

  • Last visited

 Content Type 

Forums

Member Map

Store

Crowdfunding

Raffles

Applications

Everything posted by shaddow501

  1. Actually I need to see a working example of the dts file... Because I do not know how to build it correctly.
  2. I have BPI_M64 that basically have the same hardware and with Armbian image I am facing the same issue with the axp20x device. It is strange because if I install image with Kernel from - https://github.com/BPI-SINOVOIP/BPI-M64-bsp-4.4 I do get those parameters root@bpi-iot-ros-ai:~# ls /sys/class/power_supply/ ac battery usb When working with Armbian it doesnt show those values. (ac, battery , usb) We need to figure out what to change in the Armbian based kernel sources in order to get it to work also with Armbian. I have no clue what to look for... Any thoughts? UPDATE: Since with kernel based 4.4.98 of BananaPI image it works does anyone know how to take this driver: https://github.com/BPI-SINOVOIP/BPI-M64-bsp-4.4/tree/master/linux-sunxi/drivers/power/axp and add it to to Armbian build?
  3. Hello Does anyone know how to toggle GPIO output at boot / power up as an overlay or similar? I have seen only examples that show GPIO in function and I didnt find much information how to toggle GPIO out function. Basically I would like to be able to turn LCD back light on when the board is booting and than to be able to control the brightness. (That I can do after the Linux is up and running) but before the Linux is up I still want to be able to control the LCD back light. Can anyone help with that matter?
  4. Hello All After a lot of hours and sleepless nights I was able to get this 5" LCD to work with the BPI-M64 module. 1. Correct resolution setup + environment. A. In /Boot/armbianEnv.txt set the following: Make sure to enter overlays= spi-add-cs1 spi-spidev (this is for the touch panel to work) B. for 180 rotation: extraargs=fbcon=rotate:2 drm_kms_helper.edid_firmware=HDMI-A-1:edid/800x480.bin video=HDMI-A-1:800x480-24@60 No rotation: extraargs= drm_kms_helper.edid_firmware=HDMI-A-1:edid/800x480.bin video=HDMI-A-1:800x480-24@60 C. this info came from: https://askubuntu.com/questions/890231/adding-newmode-with-xrandr-800x480-60-00 by the way if you dont want to see the console messages during boot you can add this to the armbianEnv.txt: console=serial D. Save and close. E. Create a directory where the .desktop file will be contained: sudo mkdir -p /etc/xdg/autostart F. Create the .desktop file and make it executable: Let's call this file custom-screen-resolution.desktop: sudo nano /etc/xdg/autostart/custom-screen-resolution.desktop The content of the file custom-screen-resolution.desktop should look as: [Desktop Entry] Name=Custom Screen Resolution Exec=sh -c 'xrandr --newmode "800x480_60.00" 29.50 800 824 896 992 480 483 493 500 -hsync +vsync; xrandr --addmode HDMI-1 800x480_60.00; xrandr --output HDMI-1 --mode 800x480_60.00' Terminal=false Type=Application Categories=Application G. reboot H. After O/S is loaded go to settings => display and you be able to select the 800x480 resolution. 2. With the Touch Panel I lost some hair on my head since there were many issues to overcome. A. I had to solder the LCD TP_IRQ Pin (22) to unused Pin (13) since Pin 22 on the BPI-M64 didnt support GPIO to IRQ... and diving into the sources took a lot of time to figure out why, so the easiest way is to change the Pin. (please have a look at the attached picture. B. Also there were wrong settings in the sun50i-a64-spi-add-cs1.dtbo overly, it seems that CS1 were going to the wrong Pin ( not as the BPI_M64 page shows, it should have been going to Pin 26 - PC2 but in the overlay it did go to Pin 35- PB6) I really dont know why so I had to change the DTS file to: /dts-v1/; /plugin/; / { compatible = "allwinner,sun50i-a64"; fragment@0 { target = <&pio>; __overlay__ { spi0_cs1: spi0_cs1 { pins = "PD0"; function = "gpio_out"; output-high; }; spi1_cs1: spi1_cs1 { pins = "PC2"; function = "gpio_out"; output-high; }; }; }; fragment@1 { target = <&spi0>; __overlay__ { pinctrl-names = "default", "default"; pinctrl-1 = <&spi0_cs1>; cs-gpios = <0>, <&pio 3 0 0>; /* PD0 */ }; }; fragment@2 { target = <&spi1>; __overlay__ { pinctrl-names = "default", "default"; pinctrl-1 = <&spi1_cs1>; cs-gpios = <0>, <&pio 2 2 0>; /* PC2 */ }; }; }; The sun50i-a64-spi-add-cs1.dts & the sun50i-a64-spi-add-cs1.dtbo are also attached. Just replace the sun50i-a64-spi-add-cs1.dtbo located at /boot/dtb/allwinner/overlay with file that I have attached here. C. The next settings I have found at post here I just copy and paste so you will have all the info in one page: D) Download ads7846? touch driver (compatible with xpt2046) mkdir ds7846 cd ds7846 wget https://sourceforge.net/p/openipmi/linux-ipmi/ci/master/tree/drivers/input/touchscreen/ads7846.c?format=raw mv ads7846.c?format=raw ads7846.c E) Create a makefile (Take note that it is TABS instead of spaces before the $(MAKE)) nano Makefile Insert the below in without the ----- -------------------------------- obj-m := ads7846.o KDIR := /lib/modules/$(shell uname -r)/build PWD := $(shell pwd) all: $(MAKE) -C $(KDIR) M=$(PWD) modules clean: $(MAKE) -C $(KDIR) M=$(PWD) clean install: $(MAKE) -C $(KDIR) M=$(PWD) modules_install -------------------------------- F) Exit nano and run the following cd /usr/src/linux-headers-4.19.38-sunxi64 make scripts make modules_prepare sudo make sudo make install sudo depmod G) Download and compile and install ads7846_device cd .. git clone https://github.com/notro/fbtft_tools/ cd fbtft_tools/ads7846_device make sudo make install sudo depmod H) Load ads7846 and ads7846_device on boot sudo nano /etc/modules-load.d/ads7846.conf ads7846 ads7846_device I) Load ads7846_device options nano /etc/modprobe.d/ads7846_device.conf options ads7846_device model=7846 cs=1 gpio_pendown=234 keep_vref_on=1 swap_xy=0 pressure_max=255 x_plate_ohms=150 x_min=3900 x_max=200 y_min=3900 y_max=200 busnum=1 Note: GPIO_PENDOWN relate to the GPIO of the actual Pin number 13, With my board it is 234, If you are using other module (not BPI_M64) it could be other number, check with your module documents or do "gpio printall" in your board to see the correct Pin number. Since I use the screen in inverted mode those settings fits my needs. if you will use it in normal mode you might have to switch those parameters : swap_xy=0 or 1 x_min=3900 x_max=200 y_min=3900 y_max=200 or x_min=200 x_max=3900y_min=200 y_max=3900 I didnt really need it but you can install sudo apt-get install xinput-calibrator for fine tunning. (follow the instructions) I hope that I didnt forget anything. By the way the kernel I use is: 4.19.38-sunxi64 sun50i-a64-spi-add-cs1.dtbo sun50i-a64-spi-add-cs1.dts
  5. Hello I am having the same issue with the BPI-M64 (same chipset) is there any new information of what we should do? or where should we look for a solution? Any guidance of how to proceed?
  6. Hello In raspberry pi there is an option to add a boot splash screen, looking in this forum I havent found and instructions or if it is even possible. I am not interested with u-boot splash screen but when the Linux start booting. I am using 3.5" SPI LCD and I do see the boot logs when the Linux is loading. So my question is if there is any guide of how to do that boot splash screen in Armbian or there is no way to do that?