Failed starting software [solved]


#1

Just finished my Zynthian build:

The LCD is a Waveshare3.2. I added the proper overlay and changed the right line in the config.txt file.

When I start the Pi I get an error, which has something to do with the GPIO…

SSH to the pi and stopped zynthian.

When I run the zyncodertest I get

pi@zynthian ~ $ sudo zynthian/zyncoder/build/zyncoder_test
INITIALIZING ZYNCODER LIBRARY!
Zynswitches poll thread created successfully
SETTING UP ZYNSWITCHES!
gpio: Unable to open GPIO direction interface for pin 27: No such file or directory
wiringPiISR: unable to open /sys/class/gpio/gpio27/value: No such file or directory

Any clue?

Cheers,
Kees


#2

Ok, because I use a different lcd screen (waveshare 3.2"), the wiring is also different. I had to rewire pins 2, 3 and 4 of controller 2 to another location. I used 18, 22 and 28 of the PI and created my own HW-version :slight_smile:
All seems to work now! Time for some sleep and see if I can get some sound tomorrow!

Cheers,
Kees


#3

This starting to become a monologue, but my zynthian works! Sound and vision :sunglasses: and I love it!
Great thanks to the developers. The code is great to understand and can be easily altered.

The only problem I have is that when there is an update of the software, al my settings are reset. Perhaps a good plan to make some configurationfile? Where you can put the pin-layout, used DAC and LCD-screen?

Again, kuddos to the developers! :+1:
Cheers,
Kees


#4

Hi Kees!
Congratulations for your success in building a Zynthian! Please, send your pin-layout and i will add it to the list as “PROTOTYPE-KEES” :wink: By now is the better solution. I will improve the configuration file in next revisions …


#5

That would be great!~
Pinmapping:

elif hw_version=="PROTOTYPE-KEES":
        zyncoder_pin_a=[27,21,4,5]
        zyncoder_pin_b=[25,26,31,7]
        zynswitch_pin=[23,107,6,106]
        select_ctrl=3


#6

Hi Kees! Your pin-layout is in the repository, available for everybody. Enjoy! :wink:


#7

Hi Kees,

I have a similar lcd, but slightly different. How did you manage to get it working? It must be something with different wiring. How did you do it?

Regards, Pim.


#8

Hi Pim,

Which screen do you use?

The procedure I used was:
First get the screen to work (insert the right overlay in the /boot/config.txt file)
If this works, create your own pinmap.
Then create your own hw-section in zynthian/zynthian-ui/zynthian_gui.py and
declare that hw-version in zynthian/zynthian_ui/zynthian_gui_config.py

–edit–
Looking at your other topic, I think it can be done. Rewire everything that has something to do with the screen itself. Make a pinmap as I sayd here.

Hope this helps…

Cheers,
Kees


#9

Hi Kees,

I use a Banggood 3,5 inch LCD.
How do i get in the hdmi mode again, because my hdmi screen is all black?

Reg. Pim.


#10

I don’t use HDMI mode, but connect the zynthian to my network and SSH into it, much more easy.


#11

I am new in Raspberry Pi so this is abacadabra for me. How do i ssh into it?


#12

Can you connect the PI to a network? If so, check: https://www.raspberrypi.org/documentation/remote-access/ssh/windows.md


#13

Thanks, Kees. I will try it. Hope i’ll get it working.


#14

I have managed to get the ssh connection started. I am not able to change the config.txt file. Nano doesn’t work and i don’t know commands to edit a file.


#15

Hmm, is nano installed?

Are you logged in as root? Then no need to use sudo.

Type

  1. apt-get update
  2. apt-get install nano

should do the trick.
If not logged in as root, add sudo before the commands.


#16

Hi Kees,

I have got it all working with the waveshare files for waveshare tft 3.2. Did you plug it in the raspberry or did you change the pinout? what changes did you make, so i can try that.

Regards, Pim.


#17

I changed the pinout according to the sheet I posted somewhere here above…

Ok, because I use a different lcd screen (waveshare 3.2"), the wiring is also different. I had to rewire pins 2, 3 and 4 of controller 2 to another location. I used 18, 22 and 28 of the PI and created my own HW-version :slight_smile:
All seems to work now! Time for some sleep and see if I can get some sound tomorrow!


#18

Thanks for your quick response. I have not connected any controller. Just an LCD at the RPi. So it should give some pictures, but it stays all white. What did you change in the config.txt?


#19

My config.txt

#NO_ZYNTHIAN_UPDATE
# For more options and information see
# http://www.raspberrypi.org/documentation/configuration/config-txt.md
# Some settings may impact device functionality. See link above for details

# Tell bootloader to use initram image
#initramfs initrd.img-4.1.13-v7+

# Load RT Kernel for RBPI2
#kernel=kernel7-rt.img

# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1

# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

# uncomment if hdmi display is not detected and composite is being output
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
#hdmi_group=1
#hdmi_mode=1

# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

# Disable Splash Screen
disable_splash=1

# Disables dynamic frequency clocking
force_turbo=1

# Uncomment to overclock the arm. 700 MHz is the default.
[pi2]
arm_freq=900
core_freq=250
sdram_freq=450
over_voltage=2
[all]

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on
dtparam=i2s=on
dtparam=spi=on

# Uncomment this to enable the lirc-rpi module
#dtoverlay=lirc-rpi

# Additional overlays and parameters are documented /boot/overlays/README

# Disable Blutooth Support for HifiBerry compatibility with RBPi 3
# Swap back the ttyAMA0 to GPIO
[pi3]
dtoverlay=pi3-disable-bt 
dtoverlay=pi3-miniuart-bt
[all]

# Enable MMAP support (Jackd, etc.)
dtoverlay=i2s-mmap

# Audio Device Driver:
#dtoverlay=hifiberry-amp
#dtoverlay=hifiberry-dac
dtoverlay=hifiberry-dacplus
#dtoverlay=hifiberry-digi
#dtoverlay=iqaudio-dac
#dtoverlay=iqaudio-dacplus
#dtoverlay=audioinjector-wm8731-audio
#AUDIO_DEVICE_DTOVERLAY

# PiTFT Config
#dtoverlay=pitft28-capacitive,rotate=90,speed=32000000,fps=20
#dtoverlay=pitft28-resistive,rotate=90,speed=32000000,fps=20
dtoverlay=waveshare32b:rotate=90,swapxy=1

# Adjust Serial Port Clock to allow MIDI baudrate 31250
[pi2]
init_uart_clock=2441000
init_uart_baud=38400
dtparam=uart0_clkrate=3000000
[pi3]
init_uart_clock=39062500
init_uart_baud=38400
dtparam=uart0_clkrate=48000000
[all]

You already in via SSH. What does dmesg says?

root@zynthian:~# dmesg | grep fb

should give something like

[    0.000000] Kernel command line: 8250.nr_uarts=1 dma.dmachans=0x7f35 bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416 bcm2709.boardrev=0xa02082 bcm2709.serial=0x2a652e52 smsc95xx.macaddr=B8:27:EB:65:2E:52 bcm2708_fb.fbswap=1 bcm2709.uart_clock=39062500 vc_mem.mem_base=0x3dc00000 vc_mem.mem_size=0x3f000000  dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
[    5.245721] fbtft: module is from the staging directory, the quality is unknown, you have been warned.
[    5.264049] fb_ili9340: module is from the staging directory, the quality is unknown, you have been warned.
[    5.271127] fbtft_of_value: buswidth = 8
[    5.274204] fbtft_of_value: debug = 0
[    5.277228] fbtft_of_value: rotate = 90
[    5.280288] fbtft_of_value: fps = 25
[    5.663062] graphics fb1: fb_ili9340 frame buffer, 320x240, 150 KiB video memory, 4 KiB DMA buffer memory, fps=25, spi0.0 at 16 MHz

Succes :wink:


#20

Hi Kees,

The dmesg gave:

root@zynthian:~# dmesg | grep fb
[ 0.000000] Kernel command line: dma.dmachans=0x7f35 bcm2708_fb.fbwidth=640 bcm2708_fb.fbheight=480 bcm2709.boardrev=0x2a01041 bcm2709.serial=0x82450165 smsc95xx.macaddr=B8:27:EB:45:01:65 bcm2708_fb.fbswap=1 bcm2709.uart_clock=48000000 bcm2709.disk_led_gpio=47 bcm2709.disk_led_active_low=0 vc_mem.mem_base=0x3dc00000 vc_mem.mem_size=0x3f000000 dwc_otg.lpm_enable=0 console=tty1 console=ttyAMA0,115200 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo

Still no display. Do i have to rebuild it. If yes,how?

Regards, Pim.