Picoscope with Raspberry PI

Post general discussions on using our drivers to write your own software here
Post Reply
pebert
Newbie
Posts: 0
Joined: Thu Nov 23, 2023 8:41 am

Picoscope with Raspberry PI

Post by pebert »

Hi

Will start with a small description of my current issue.

I'm working Telematic system for the public transportation sector.

Sometimes we are facing issues witn our vehicle computer (and Sometimes also other equipment we have installed un the vehicle)

Yesterday I was in a fully bus i order to analyze the 24V system. Theese busses (Solaris) are using two ordinary lead-acid batteries that are charged from the main battery pack. In theese busses we installed a couple of TFT-displays for passenger information. These displays contains a computer with an Intel atom CPU.

We have observed threw different issues with some of these units;
  • internal fuse is blown,
    CPU dies
    GPU (Graphics processing unit) is killed.
We have two hypotheses
  • that those failures are related to the power supply from that 24V circuit,. The batteries gets drained causing our equipment to get ro low voltage, resulting in to high current.
  • Short voltage peaks in the power circuit.
Yesterday I was in one of theese busses to analyzed the electrical environment. For this purpose I bought a picoscope 2204a and a current clamp.

Original plas was to install this equipment in the buss, measuring current from the clamp att ch A and measuring the voltage with an ordinary x10 probe on ch B.

Test setup was intended to look like this:
Vehicle -> picoscope -> raspberry pi ->LTE-router

How ever I faced severe issus getting the picoscope or picolog software running on the raspberry PI. Intended I ended up with putting my laptop in the bus, running picolog6, this worked very good.

But, for the next time I intend to run the logging for a couples of days. Hence putting my laptop there is not an option, but putting a raspberry pi there would be a very good solution, if I could only get the software up and running (feels like a quite vital factor) :x

Do anyone of you guys/girls have any experience in a similar activity, and are there anyone out there that successfully manage to run this from a raspberry Pi, in that case, how did you set it up?

Thanks
/Per

Gerry
PICO STAFF
PICO STAFF
Posts: 1144
Joined: Mon Aug 11, 2014 11:14 am

Re: Picoscope with Raspberry PI

Post by Gerry »

Hi pebert,

Unfortunately, PicoScope 7 won't run on arm or Raspberry Pi platforms. however, PicoLog 6 will do, if you restrict the operating system to 32-bit. So, for instance, with the Raspberry Pi 3 or 4, running on 32-bit Raspbian, Picolog 6 will work if you restrict the Raspbian version that you're using to 5.10 (bullseye) and don't upgrade to 6.1
Below is the account of a customers recently successful setup and installation of PicoLog 6, drivers and Python for using the SDK to control data loggers, on Bullseye (thanks to Marcin for the details):

INSTALLATION OF PICOLOG SOFTWARE:
Install PicoLog 6.2.8 manually after downloading file, in terminal:
Download from: https://www.picotech.com/downloads
cd Documents (or other directory where .deb file is located)
sudo apt install ./picolog-6.2.8-armhf.deb
Fix USB permissions, in terminal run:
sudo bash -c 'echo "ATTRS{idVendor}==\"0ce9\", MODE=\"777\"" > /etc/udev/rules.d/95-pico.rules'

INSTALLATION OF DRIVERS FOR DATA LOGGERS:
Download driver ending… _armhf.deb from: https://labs.picotech.com/debian/pool/m ... _armhf.deb
Navigate to folder with downloaded file:
cd Downloads
Install .deb file:
sudo dpkg --force-depends -i ./libpicohrdl_2.0.17-1r1441_armhf.deb

INSTALL LATEST VERSION OF PYTHON:
sudo apt update
sudo apt upgrade
sudo apt install python3-pip

INSTALL THE PICOSDK-PYTHON-WRAPPERS:
Download from github: https://github.com/picotech/picosdk-python-wrappers
Unzip to “Documents” folder
cd to “picosdk-python-wrappers” folder
Install requirements: sudo apt install -r requirements.txt (pip3 install -r requirements.txt) and sudo apt install -r requirements-for-examples.txt (pip3 install -r requirements-for-examples.txt)
Install setup.py file: cd to “picosdk-python-wrappers” folder then use: sudo python setup.py install
Run example in Thonny for picoLog ADC-20 “picohrdlSingleModeExample.py”

Regards,

Gerry
Gerry
Technical Specialist

bennog
Advanced User
Advanced User
Posts: 199
Joined: Mon Nov 26, 2012 9:16 am
Location: Netherlands

Re: Picoscope with Raspberry PI

Post by bennog »

A simple intel NUC is also an option.
I regularly use this smal formfactor PC (115mm x 115mm x 35mm) you have a small i5 windows (10/11) based system that wil work with picoscope.

you can get a decent i5 system for below $100 on ebay

I don't know if the 2205A has level drop out trigger to test for 1V below and 1V above 24V

Benno

bennog
Advanced User
Advanced User
Posts: 199
Joined: Mon Nov 26, 2012 9:16 am
Location: Netherlands

Re: Picoscope with Raspberry PI

Post by bennog »

I was thinking about your problem but the problem using picoscope software is that if you use triggers and alarms to save the .psdata file, you will have a gap of data between the end of the capture and the start of te new capture where the data is saved. Also if the voltage drops for say 1 hour below 15V you will have a disk full of captures.

The only way I can think of is with the SDK stream data for 24/7 at say 100.000 - 500.000 samples / second and on the fly using a moving average. If there are samples that are 1V below or 1V above this average then save the data in a different thread while the main thread keeps capturing and measuring.
This way if you have 2 glitches in short succession you are certain you have them both.
The problem is only you can not save the data in .psdata fromat.

I usually save them in RAW binair format or sigrok .sr files

I had a similar problem as you have and used the last approach to do this with a 3000 series scope.

Benno

Post Reply