@Dana-Myers114 That would be nice, thanks !
Is it not possible to do bit banging using python ? This is what is done on the RPi in the adafruit tutorial link I gave. It doesn't seem a very clean way to do it, but it works pretty well on the RPi.
Posts made by Pierre Rossinès
-
RE: Using a MCP3008 via SPI
-
RE: Using a MCP3008 via SPI
Is it possible to user other GPIO pins to bit bang the SPI protocol ?
-
RE: Using a MCP3008 via SPI
@Richard-Berg said in Using a MCP3008 via SPI:
Read this thread HERE
Oh ok, thanks.
Everytime I try to use my omega 2 for something, I first need to wait for a fimware update.
Guess I'll have to build my own LEDE or something... Too bad, I needed the wifi -
Using a MCP3008 via SPI
Hi,
Last week I connected a MCP3008 ADC to my omega2 via the SPI pins.
I thought I could read data but it was in fact rubbish.Reading a tutorial on adafruit (https://learn.adafruit.com/reading-a-analog-in-and-controlling-audio-volume-with-the-raspberry-pi/script) and the mcp documentation (http://ww1.microchip.com/downloads/en/DeviceDoc/21295d.pdf), it seems the read procedure is simple : I just have to send a 4 bit word (1100) to ask for a reading on channel 0, and the MCP returns 10 bits.
However, using the python lib I have to give a one byte address during the read, which I assume would be the command word 1100 with a 0 padding, so 11000000. The value I read next is quite inconsistent, even with a fixed input voltage.Has anyone any clue of what I am doing wrong ?
Thanks
-
RE: [resolved] Help, My Omega2 plus can't start successfully
@ccs-hello
I have the same issues with two different voltage regulators.
I bought a first one which delivers ~3.1V, which I recon might not be enough.
I made another one using a LMS1117 which delivers a very nice 3.3V from a USB charger. It says it handles 1A, and the USB charger can deliver up to 1.2A.The worst part is that sometimes they work, sometimes they don't.
I did not connect anything else on the charger so the Omega2 should be able to draw whatever it needs. -
RE: SPI Pins for the Omega2
@Brice-Parent I don't need it, I'm using the SPI to communicate with a very simple MCP3008
-
RE: SPI Pins for the Omega2
@Brice-Parent
Indeed, my only mistake was to swap the arguments.
I did not have the spi-tools package installed but I'm not sure it is really necessary.My code seems to work now.
Thank you very much ! -
RE: SPI Pins for the Omega2
@WereCatf It does show up, but when I use it with the python library as described here : https://docs.onion.io/omega2-docs/spi-python-module.html
I get that error.My code is pretty simple :
import onionSpi spi = onionSpi.OnionSpi(32766, 1) spi.sck = 7 spi.mosi = 8 spi.miso = 9 spi.cs = 6 spi.registerDevice() spi.setupDevice()
I got the 32766, 1 part from the /dev/spi32766.1 file name
-
RE: SPI Pins for the Omega2
@Brice-Parent What did you install to make it work on the omega2?
I followed the documentation but I get an error while registering the spi device : "Failed to find spi-gpio-custom. Maybe it is a built in module ?" -
RE: SPI python module OnionSpi doesn't work.
I've had the same issue in the latest firmware
Has anyone managed to make it work ? -
RE: Timer Interrupts on the Omega2
@luz Nice !
Let's hope they read this thread soon. -
RE: Timer Interrupts on the Omega2
@Kit-Bishop
Have you made your code open source ? Maybe someone else is able to make the changes necessary to make it work on the omega2. I am willing to try even if my knowledge in this field is quite limited.
Was it necessary to rebuild the full system to get interrupts on the Omega 1 ? -
RE: Omega2 - LEDE or OpenWrt?
@Chris-Stratton said in Omega2 - LEDE or OpenWrt?:
Ok thanks. I'll buy one of those then.
-
RE: Omega2 - LEDE or OpenWrt?
@luz Thanks. Does LEDE include the firmware flashing tool ? I have no dock nor do I have a serial to USB chip, so I would appreciate to be able to flash the official firmware back if I mess something up while using LEDE.
-
RE: Omega2 - LEDE or OpenWrt?
What does the official LEDE support brings ? If I build an image, will I get the exact same functionality as the original Omega2 ?
Is there a way to obtain the exact same image as the official firmware ?