Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Cubieboard2 Cannot get SPI to work

Featured Replies

Hello,

 

I have a problem with communicating with SPI device, namely accelerometer ADXL345

 

I quadripple checked connection and it seems to be fine, device shows in /dev/spidev0.0

 

I have also tested shorting miso and mosi and testing with spidev_test, here is the result:

 

spi mode: 0x0
bits per word: 8
max speed: 500000 Hz (500 KHz)
TX | FF FF FF FF FF FF 40 00 00 00 00 95 FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D  | ......@....�..................�.
RX | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  | ................................

 

 

My ArmbianEnv

verbosity=1
bootlogo=false
console=both
disp_mode=1920x1080p60
overlay_prefix=sun7i-a20
rootdev=UUID=88c29f81-18b8-4d41-a900-21ce6eba4664
rootfstype=ext4
overlays=spi0 spi-spidev
param_spidev_spi_bus=0
param_spidev_max_freq=12000000
usbstoragequirks=0x2537:0x1066:u,0x2537:0x1068:u

 

I have also tried param_spidev_spi_bus - 0, 1, 2

But device just did not show up, it always stayed /dev/spidev0.0

 

I have also tried switching to some older kernel but no luck.

 

Is there any image to be known to work? I dont have much requirements so old stuff would be fine. Thanks in advance.

I vaguely remember having trouble with this myself. The 2mm pins were a problem too so I switched to a different board.

 

Are you absolutely sure you have shorted the right two pins?

 

One of those $10 USB logic analysers from eBay can be handy to see if the TX is actually TXing. They work with Pulseview from Sigrok.

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.