I am trying to set up my Intel Nuc as the Onboard Computer for using DJI OSDK on my Matrice 100. I am looking for suggestions to find a way to power the Nuc from the Matrice.
In the beginning, I connected a DC-DC voltage regulator to one of the XT30 ports to get 19V and power the Nuc. It worked okay for a while and I was able to fly the Matrice outside using OSDK. But it has suddenly stopped working now. When the Nuc tries to boot into Ubuntu, it shuts down abruptly.
In short, use separate power source for Onboard PC and sensors.
Typically sensors and PC such as IR or LIDAR or NUC draws power heavily. If the current changes, the sensor value will change (which is bad). The PC will need a safe margin of voltage e.g 16 to 21. A sudden gust wind can cause the drone to output thrust power at a maximum which might lower the voltage for couple secs. In this case, PC might gets shut down or provide wrong calculation output ( e.g false odometry output)
So adding a stand-alone small size 5 cell battery should give you stable performance. Here I cant promote a specific commercial item. For my project, I bought the battery from Hobbyking to do the job for onboard PC and Kinects. You can search there for the battery that suits your need
PS. don't get DC to DC converter, typically it is very low efficiency and prone to power disturbance. I use typically raw battery and BEC(for 5V or 12V Sensor such as IR sensor and Hokuyo LIDAR)
Related
I am attempting to create a kext which will allow me to lower the minimum display brightness. Which drivers would be relevant to this? Would this be an I/O Kit driver?
This pertains to the internal display on my MacBook Pro 14,1 running macOS 10.14.4 using the integrated Intel Iris Plus Graphics 640.
The driver that controls is the "AppleBacklight.kext" kernel extension.
In general: Display backlight is usually (and this is the case on the MacBook Pro) controlled by a PWM (pulse-width modulation) signal from 0% to 100%. A controller - which could be the GPU or a dedicated IC - sends out the PWM signal according to the brightness level chosen by the user. In some cases this factors in an ambient light sensor.
The controller operates by dividing up the usuable PWM range in a number of settings (for example 20 seperate steps). The whole PWM range is usually not available, as backlights have different minimum and maximum allowable PWM ranges. If you go outside that range, you're violating the specs and may cause damage to the display.
On modern Intel computers the PWM range is stored in the SSDT (system service descriptor table) accessible through the ACPI (Advanced Configuration and Power Interface). These tables are usually dumped into .aml/.dsl files. You'll be looking at for example the LMIN and LMAX parameters (LMIN/LMAX = Backlight PWM Min/Max).
You could also consider replacing the default backlight kernel extension with for example this:
https://github.com/RehabMan/OS-X-Intel-Backlight
It is only meant to be used with Hackintoshes, but it controls the same Intel integrated GPU as you have.
Here's a different kernel extension that uses the ACPI method described above to control the backlight:
https://github.com/RehabMan/OS-X-ACPI-Backlight
Again, it is intended for Hackintoshes.
If you want to try dumping and patching your SSDT manually, you can take a look at this guide:
https://www.tonymacx86.com/threads/guide-patching-laptop-dsdt-ssdts.152573/
Again note that it is intended to be used with Hackintoshes.
In general I wouldn't recommend trying to change the minimum display brightness on original Apple hardware. You run the risk of damaging circuits - but most likely you'll just experience a black screen when you lower the brightness below the minimum.
How can I receive a time signal with an unmodified RTL-SDR USB TV Dongle here in Europe?
RTL-SDR Dongles are able to receive the frequency range 52-2200MHz.
Here in Europe, radio-controlled clocks receive DCF-77, a time signal broadcast on 77KHz, but as 77KHz is a bit lower than 52MHz, that's out.
The GPS L2 signal is at 1575.42 MHz, so that's within the dongle's range, but the signal is way too weak to be received with the TV antenna. An active GPS antenna is needed, and for providing the antenna with the power, I'd need to make some modifications to the electronics which I don't really want to do.
In the old age of analog TV broadcasting, we had Teletext / Videotext here in Germany, which contained a time signal, but these times are long gone.
ADS-B reception with a dongle works like a charm, but unfortunately they did not put in time or date bits into the data packets.
So: Does anybody have any idea where in the spectrum that can be received by an unmodified RTL-SDR dongle there is a time signal that could be easily decoded?
I'm well aware that getting time over the network via NTP, or via a GPS modem via NMEA 0183 would be way easier, but I'm curious and just want to play around with that dongle a bit. Precision is not important. +/- 2 seconds is fine. And I'd like to do it the SDR-way, so using the dongle in the originally intended way (as a DVB-T receiver using the original software) defeats the purpose (i.e. learning and DIY)
The GPS L2 signal is at 1575.42 MHz, so that's within the dongle's range, but the signal is way too weak to be received with the TV antenna. An active GPS antenna is needed, and for providing the antenna with the power, I'd need to make some modifications to the electronics which I don't really want to do.
Well, first of all, GPS is really weak, but it still works under the noise floor; that's something important to realize – I've seen it more than one time that people are worried because they can't see GPS on a PSD display. You won't; you'll need signal processing to recover it from all the noise.
The modifications aren't all that complicated; basically, you need a capacitor to let through the AC component to the RTL dongle, and a voltage source to feed the active antenna; the required component is usually called a bias-T.
Nevertheless, an active antenna will be necessary – your RTL dongle probably won't have a Noise Figure low enough to receive GPS signals on its own.
In the old age of analog TV broadcasting, we had Teletext / Videotext here in Germany, which contained a time signal, but these times are long gone.
True; haven't looked at local FM stations, but RDS might be the way to go – it can contain a clock/time signal; the German Wikipedia claims that mainly publicly owned stations transmit that information field.
Have a look at gr-rds; it's a GNU Radio implementation of the Radio Data System. If you don't have a working GNU Radio installation (yet), you might try out the GNU Radio LiveSDR Image, which contains a ready-to-use gr-rds.
I just learned that a red flashing LED indicates voltage below 4.63V on a Raspberry Pi Model B+.
Is there a command to determine the voltage programmatically?
I tried vcgencmd measure_volts. But it yields 1.2000V, independent of the input source and the LED status. And it doesn't seem to be related to the 4.63V mentioned above.
Update
Let me describe the situation in a bit more detail:
I'm powering the Raspberry Pi with a lead-acid battery built into a moving robot. After operating the robot for a while, the voltage seams to drop below a critical minimum, causing potential damage to the file system. Therefore, I'd like to detect low voltage automatically (and trigger the robot to return to the charging station).
I'm asking here in StackOverflow, since I assume the solution not to be robotic-specific, but generally applicable to other machines.
Yes you can, as it is said in this topic Under-voltage warnings you can know the low voltage reading the GPIO 35. For reading GPIO, you can refer to this topic:
Python Script to read one pin
Have a look at the adafruit ina219 sensor https://learn.adafruit.com/downloads/pdf/adafruit-ina219-current-sensor-breakout.pdf .
This sensor can be put between the battery and the raspberry and measures the current and the voltage along this connection (0-26V and max. 3.2A). It communicates via i2c bus. Together with an Arduino you can easyly build an battery watchdog for your raspberry. A sample program and the arduino driver can be found here: https://github.com/adafruit/Adafruit_INA219.
According to https://raspberrypi.stackexchange.com/questions/7414/is-it-possible-to-detect-input-voltage-using-only-software it's not possible to do it on software level without other hardware.
I need to build a platform for logging some sensor data. And possibly later doing some calculations on this logged data.
The Raspberry Pi seem like an interesting (and cheap!) device for this.
I have a gyroscope that can sample at 800 Hz which is equivalent to one sample every 1.25 ms.
The gyroscope has a built-in FIFO that can store 32 samples.
This means that the FIFO has to be emptied at least every 32 * 1.25 = 40 ms, otherwise samples will be dropped.
So my question is: Can I be 100% certain that my kernel driver will be able to extract the data from this FIFO within the specified time?
The gyroscope communicates with the host via i2c, and it can also trigger an interrupt pin on a "almost full"-event if that would make things simpler.
But it would be easiest if I could just have a loop in the driver that retrieves the data at regular intervals.
I can live with storing the data in kernel space, and move it to user space more infrequently (no constraint on time).
I can also live with sampling the gyroscope at lower sample rates (400 or 200 Hz is acceptable).
This is with regards to the stock kernel, and not the special real-time kernel as it seems like this is currently not supported for the Raspberry Pi.
You will need a real-time linux environment for tight timing:
You could try Xenomai on Raspberry Pi:
http://diy.powet.eu/2012/07/25/raspberry-pi-xenomai/
However, following along this blog:
http://linuxcnc.mah.priv.at/rpi/rpi-rtperf.html (dead, and I could not find it in wayback or google cache)
It seems he is getting repeatable +/- 20µS timing out of the stock kernel. As your timing resolution is 1250µS you may be fine with the stock kernel if you willing to lose a sample once in a blue moon YMMV.
I have not tested this yet myself but I have been reading up in an attempt to try to drive a ws2811 LED controller with the Raspberry Pi and this was looking the most promising to me.
There is also the RT linux patch: https://rt.wiki.kernel.org/index.php/Main_Page
Which has at lest one pi version: https://github.com/licaon-kter/raspi-rt
However I have run into a bunch of nay-sayers when looking deeper into this patch.
Your best bet it to read the MS timer and log or light an LED if you miss an interval and then try some of the solutions. Happy Hacking..
I am looking to write an Arduino script that uses whatever audio signal is going to the speakers to create a physical visualization.
The Arduino is connected to the windows machine only through USB, so I need to use USB to find out what is being sent to the speakers. How would I access this information?
As of right now, the Arduino can only communicate with the computer via serial over USB. Things have changed with the new Arduino Uno, but the examples have not yet been released to show how to have the new Arduino act as other USB devices.
You would have to write something for the Windows box that monitor's the system audio and sends the info about it over serial to the Arduino, as long as you want it to only connect via USB.
There isn't a very good way to interface an audio signal to an Arduino without some external hardware.
One way to do it though would be to connect the audio line to a biased pin with a capacitor, then you could use the ADC directly. There will be pretty terrible dynamic range, but it only takes 3 passive parts. Running that through an opamp before going to the ADC pin could significantly improve dynamic range and provide a filtering opportunity (see below). Alternatively, you could switch on an on-chip voltage reference to use (typically 1-1.5 V) instead of the main supply.
It doesn't matter that much for a straight visualization, but the sample rate will not be good enough to capture the full spectral content of the audio (in addition to the poor dynamic range resolution). The default Arduino sample rate is 10 kHz(-ish...possibly asynchronous), so you will only get valid data if your signal is below 5 kHz, otherwise aliasing will muck it up. (If you write your own analog driver for the ATmega32P you could get up to 76 kHz sample rate with 8-bit samples)
Then to actually communicate that data to a computer, you can fairly easily throw all those ADC values onto the UART for the computer to pick up and process as it sees fit. An ATmega will not have the power to compute FFTs on the fly (what you'd do almost always do for a viz anyways).
Or to skip all that, connect the audio signal to your computer's sound card (or USB sound card...they're pretty nice) and use some audio driver.
There is a Java library for processing called ESS that lets you access audio out.