ROS: Access to sensor data from Jetson board - connection

I dont know if someone can help me here. I also asked in the ros forum. So here is my problem:
Im working on a project and im a very beginner of ROS. I have a sensor which calculates the distance between two decanodes (range). The name of these two decanodes are AGV and SV. The AGV is the module which calculates the distance. Thats the key difference between AVG and SV. The AGV has to be connected to the PC via UART to USB, in my case its connected to the Jetson board. You have insight to the data of AGV with the docklight software. Its only for windows.
If everything is set up the sensor begins to collect the data (in meters).
My question is: How can I have access to these data. There is no information about that i should install a driver or something like that or a package. So if i connect it to the Jetson and if i look to the rosnode list i cant find anything which leads me to the data. I dont know what i have to do. I asked other people and they didnt know how to access the data if it is via UART to USB.
So it would be really nice if someone could write a helpful answer.

If I understand correctly, I think you will need to find documentation on the data format or protocol that your sensor is sending over its serial connection, or, if the manufacturer of the sensor provides a library or SDK with an API for receiving the data. Then write a new ROS node that receives the data and publishes it to the ROS system.

Related

Vehicle Can Bus Access

not really sure where to put this, so please direct me elsewhere is this is not a good fit for this question.
I am currently exploring car programming via the OBD2 port. I have been scouring the internet for a OBD2 solution that will allow me to read RAW CAN bus messaged from my car. So far I have not been able to find a software that lets me do this with a ELM327 adapter. Does anyone know if there is software available that can read these A.) with this adapter and B.) Actually show me RAW CAN messages?
So far I have only been able to see the OBD2 messages, but I would like to get under this layer. Any guidance here is greatly appreciated!
Thanks!
If your car is recent enough, you won't be able to get the "RAW CAN" traffic. Because behind the OBD port is a gateway that only relay SOME of the CAN messages.
You can still get those messages with your ELM but as this device is not made to be a CAN adaptator it can be tricky. You can find a lot of information here.
To get more information on what you can find on the CAN bus of the OBD port, you can read this article. It's a good way of having a first overview of the CAN bus in cars.
If you want to have access to the CAN traffic, you will have to do some soldering on your car's wires. Here is an article of what it can look like. WARNING : do not perform random stuff on your car, it can be as dangerous as expensive.

Arduino-LoRa module code doesn't work

I am trying to develop an Arduino sketch in order to send Temp-humi data from a dht11 sensor to KPN (Dutch) Network throughout a LoRa module (Dragino).
There are plenty of sketches around internet with similar function, but none of them has the right function I expect, since most of them ONLY send a simple 'Hello world' data throughout the ABP or OTAA Keys that the Network provides. In the other hand, I have also found sketches that ONLY makes the temp/humi functionality, withouth having the chance to write the Activation Keys.
So, I am actually trying to join these two codes with these functionalities (Request the Activation Keys to connect with KPN Network, as well as the sender sensor data), and it seems to compile properly, however, it is not sending any data, so probably the code is wrong.
May I get any link to the right one or any recommendation, please?
Many thanks in advance.
Project Code:
enter link description here
I have also had my problems with the Dragino shield and dht11 but i got it working.
My script: https://github.com/FelixKunz/LoraDraginoDHT
I would recommend you to use the RN2483. I've had rarely any troubles with this chip and it is not as expensive as the dragino shields.
en prettige dag

Is it possible to directly connect the kinect to an iphone?

Is that possible or do you need to connect the kinect to a computer and stream the images in (almost) real time to an iPhone? Is it even possible to get ~30fps via stream on the iphone?
The Kinect uses a USB connection and even if you could make up some sort of cable to connect a Kinect to the Lightning or 30 pin connector, iOS would not recognise the Kinect as it does not have a driver, so the short answer is no, you cannot connect a Kinect directly to the iPhone.
For a simple solution/alternative, you might want to check out Occipital/Structure.io, who are selling a depth sensor for (some) iDevices for ca. 380USD.
Apparently they are using Primesense Carmine sensors ("which is essentially an equivalent of ASUS Xtion Live under different brand name" according to [iPiSoft's sensor comparison] (http://wiki.ipisoft.com/Depth_Sensors_Comparison)).
You can review the differences to the Kinect at the previous link, but basically it boils down to the Kinect being bigger and heavier, having a motorized tilt and requiring external power.
To get back to your question:
if you look around you'll find working examples of how to get OpenNI running on BeagleBone dev-boards under Linux, and thus it is more than conceivable that you'll be able to compile and run it for/on iOS as well (possibly requiring a jailbreak).
You could also have a look at libfreenect, another open implementation of drivers for the Primesense family of sensors (as well as the Kinect 2).

Software for sensor manipulation

I am searching for open source software for wireless sensors’ management in a wireless sensor network environment. More specifically, I have some 802.11-based temperature sensors which are connected with a pc using a 802.11 router. I need to put configurable open source software into the pc to manipulate the information that comes from the sensors. Any idea?
I've been using Zenoss Core Community edition to accomplish the task you mentioned. It allows you to monitor several temperature sensors, storing the information in circular databases. Once deployed, you don't need to perform too much housekeeping.
If your sensors implements SNMP (Simple Network Managment Protocol) all you need is to enable the protocol according to manufacturer specs and let zenoss to discover your devices.
You can create customized reports and trigger events based on your custom configuration (eg, send an email when temperature is over certain level).
Finally, if the monitoring info is retrieved using a different method other than SNMP, you can code custom scripts with Python, so that you help to zenoss to retrieve the info needed. Dig into the forums. Chances are the script is already available for your sensor.

Emulate GPS or a serial device

Is it possible to get location data out of Google Gears, Google Gelocation API or any other web location API (such as Fire Eagle) in such a format that it appears to other software as a GPS device?
It occured to me reading these answers to my question regarding WiFi location finding, on Super User, that if I could emulate a GPS unit, many of these web services could act as a 'poor-mans' GPS to otherwise less useful software that requires it.
Is GPSD an option?
Preferably OSX & Python, but I would be interested in any implementation.
There is a very similar thread on a Python mailinglist that mentions Windows virtual COM ports and discusses Unix's pseudo-tty capabilities. If the app(s) you want to use let you type in a specific tty device file, this may be the easiest route. (Short of asking the authors to provide a plugin API for what you're trying to do, or buying yourself a $20 bluetooth GPS mouse.)
Are you using OS X?
There is a project macosxvirtualserialport on Google code that provides a graphical wrapper around some of the features of a utility called socat. I'd recommend taking a look at socat if you see potential in the pseudo-tty route. I believe you could use socat to link a pipe from a Python program to a pseudo-tty.
Most native Mac apps will be querying IOServiceMatching for a device with kIOSerialBSDRS232Type, and I doubt that a pseudo-tty will show up as an IOKit service.
In this case, unless you can find a project that has already implemented such a thing, you will need to implement a driver as described in this How to create virtual COM port thread. If you're going to the trouble of create a device driver, you would want to base it on IOKit because of that likely IOServiceMatching query. You can find the Apple16X50Serial project mentioned in that post at the top of Apple's open source code list (go to the main page and pick an older OS release if you want to target something pre-10.6).
If your app is most useful with realtime data (e.g. the RouteBuddy app mentioned in the Python mailinglist thread can log current positions) then you will want to fetch updates from your web sources (hopefully they support long-polling) and convert them to basic NMEA RMC sentences. You do not want to do this from inside your driver code. Instead, divide your work up into kernel-land and user-land pieces that can communicate, and put as little of the code as possible into the kernel part.
If you want to let apps both read and write to these web services, your best bet would probably be to simulate a Garmin device. Garmin has more-or-less documented their protocol in the IntfSpec.pdf file included with their Device Interface SDK. Again, you'd want to split as much as you could into user-space code.
I was unable to find a project or utility that implements the kernel side of an IOKit-based virtual serial interface, but I'd be surprised if there wasn't one hiding somewhere out there. Unfortunately, most of the answers I found to that question were like this, with the developer being told to get busy writing a kext.
I'm not exactly sure how to accomplish what you're asking, but I may be able to lend some insight as to how you might begin to get it done. So here goes:
A GPS device shows up to most systems as nothing more than a serial device -- a.k.a. a COM port if you're dealing with Windows, /dev/ttySx if you're in *nix. By definition, a serial port's specific duty is to stream data across a bus, one block at a time. So, it would then follow logically that if you want to emulate the presence of a GPS device, you should gather the data you're consuming and put it into a stream that somehow acts like an active serial port.
There are, however, some complications you might want to consider:
Most GPS devices don't just send out location data; there's also information on satellite locations, fix quality, bearing, and so on. Then again, nobody's made any rules saying you have to make all that data available. There's probably more to this, but I'll admit that I need to do more research in this area myself.
I'm not sure how fast you can receive data when dealing with Google Latitude, etc., but any delays in receiving would definitely result in visible pauses in your "serial port"'s data stream. Again, this may not be as big a complication as it seems, because GPS devices are known to "burst" data across the bus anyway, but I'd definitely keep an eye on that. You want to make sure there's always a surplus of data coming across, not a shortage.
Along the way you'll also have to transform the coordinates you receive into valid GPS sentences, as well. You can find specifications for those, but I would definitely make friends with the NMEA standard -- even though it is a flawed standard, it's the one everyone seems to agree on anyway.
Hope this helped you, at least a little bit. Are there anymore details specific to your problem that you think could be useful in answering this question?
Take a look to Franson GPS Gate which allows you to connect to Google Earth among other things (like simulating GPS and so on). Is windows only though but I think you could get some useful ideas from it.
I haven't looked into it very much, but have you considered using Skyhook's SDK? It might provide you with some of what you are looking for. It's available for every major desktop and mobile OS.

Resources