R-Net: Releasing code that lets you control chairs remotely

Power wheelchair board for REAL info!

POWERCHAIR MENU! www.wheelchairdriver.com/powerchair-stuff.htm

R-Net: Releasing code that lets you control chairs remotely

Postby stephenc1 » 04 Jul 2017, 09:18

Hi people,

It is time that I am finally releasing the code that controls chairs wirelessly over WIFI or any TRUSTED network. As there is no encryption of any kind, feel free to add encryption if you're a good programmer. We just don't have the manpower or time to add encryption. :)

We waited over a year to do it for some personal reasons.

As time passed by, it was obvious that people were very interested in controlling their chairs remotely. A lot of you emailed me asking how to do it. I said I had some code that would let you remotely control a chair, but I wasn't ready to share the code yet.

I was testing the code because I wanted to see how it acts under various situations that would make it fail horribly. Test results show that when any network errors happen, the chair will stop as quickly as it can if there was a network error of any kind. The code relies on the fact the network delivered all packets in a timely matter.

We weighted on certain factors and felt that it was time.

So, we made a sweet video on how to use the new code.

https://youtu.be/wW4jzoRx98A

https://github.com/redragonx/can2RNET/tree/master/R-net_over_IP

PLEASE be careful!

If all is working correctly the "remote" machine should now be controlling various aspects of the wheelchair. We've mapped X-Y to the left stick on the USB controller. Additionally, buttons map to MAXSPEED, HORN, and HEADLIGHTS/FLASHERS.

Seriously... both of us were injured and humbled during the creation of this code. We've tried to make it fail-safe. You are a beta-tester. BEWARE. What can go wrong WILL go wrong. So stay clear of cliffs, canals, china-shops, monster-trucks, puppies, or anything else that can injure you or that you might injure due to some kind of bug we did not anticipate.

We've waited over a year to release this code publicly. If you have gotten this far in trying to get this to work then you must be prepared to assume the risk of something going wrong.

So, that was scary. But the good news is we tested this code at defcon24, in the hallways of the con, with many people walking all around us, in a VERY hostile radio environment, and there was not a single incident after many hours of crazed and irresponsible use. Your mileage may vary. Nuff said.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 04 Jul 2017, 09:55

Image
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby Burgerman » 04 Jul 2017, 10:49

Trying to fathom how this is different to just adding RC?

And not needing a laptop, and having a bigger range?

Eg,
http://www.wheelchairdriver.com/gopro/rc.mp4
http://www.wheelchairdriver.com/gopro/rc2.mp4
http://www.wheelchairdriver.com/BM3-con ... RC-BM3.mp4
User avatar
Burgerman
Site Admin
 
Posts: 70463
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: R-Net: Releasing code that lets you control chairs remot

Postby Burgerman » 04 Jul 2017, 10:51

Maybe for remote use over a network?
Or different input methods to automate control around a house?
User avatar
Burgerman
Site Admin
 
Posts: 70463
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: R-Net: Releasing code that lets you control chairs remot

Postby woodygb » 04 Jul 2017, 11:10

Could you do a R/C version and a Android phone Bluetooth version rather than using Wifi ?
An expert is a person who has made all the mistakes that can be made in a very narrow field.
Niels Bohr
User avatar
woodygb
 
Posts: 7128
Joined: 12 Mar 2011, 18:45
Location: Bedford UK

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 04 Jul 2017, 11:28

The main advantage is portability, programmable, and low cost.

One, there is no hardware modifications on any chip so you can just plug and go.
Two, it is network based, so this means 3g/4g, ethernet, and WIFI.
Three, you are in complete control, so you can add sensors,, add Tesorflow (Google AI) or anything you want. Why screw around with RC when you have more better options?
Four, the code can work on any chair with R-Net installed
Five, low cost integration of new code

Six: It is free.

There are many more ideas and options beneficial to chair users with this new code. You don't have to use a laptop, you can use whatever you want if people start experimenting :)

Also, I'm at a point where I'm able to control a chair remotely without any external hardware added. I am able to use existing R-Net hardware like the bluetooth module to control a chair with a smart phone or any device for that matter.

But that will need more research and time before I can show and discuss that in detail

I'm making an Android app that will let you control a chair.

http://i.imgur.com/j4xkFr4.png

The point is that I want to see people tinkering, just because you're in a chair you're stuck with limited options. This is why I even bothered to share my knowledge.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 04 Jul 2017, 11:29

woodygb wrote:Could you do a R/C version and a Android phone Bluetooth version rather than using Wifi ?


See my above post. :)
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 04 Jul 2017, 11:35

With this code I released, you can control a chair anywhere in the world with whatever you want, you decide. Use your imagination. Seriously.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby woodygb » 04 Jul 2017, 11:40

Might I suggest this App that I use.

Joystick with 6 buttons, 3 datafields....

https://play.google.com/store/apps/deta ... k&hl=en_GB

There is also this option available from Kas with video via Wifi.

Image.
An expert is a person who has made all the mistakes that can be made in a very narrow field.
Niels Bohr
User avatar
woodygb
 
Posts: 7128
Joined: 12 Mar 2011, 18:45
Location: Bedford UK

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 04 Jul 2017, 20:12

I want to turn one of my chair bases into a rover I can drive from my PC with a USB joystick. But much to learn.
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 04 Jul 2017, 20:24

Also put a camera on it with a live video feed.

And at some point add telemetry info and GPS.
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby woodygb » 04 Jul 2017, 22:28

I've already tried the camera with a live feed via Wifi using the Commander App on my test chair with an Android tablet.

P.I.T.A to get it working and the range wasn't great.
An expert is a person who has made all the mistakes that can be made in a very narrow field.
Niels Bohr
User avatar
woodygb
 
Posts: 7128
Joined: 12 Mar 2011, 18:45
Location: Bedford UK

Re: R-Net: Releasing code that lets you control chairs remot

Postby Burgerman » 04 Jul 2017, 23:43

I drive my chairs remotely from a 4 watt boosted RC transmitter, up to about 5 or 6 miles airborne range, but chairs don't fly! With decent RX and 3 extra diversity ones, you can still drive very securely half a mile away or more, through cars and streets.

As for video range, Thar's easy! Just set up a laptop with a mobile phone card, a sim, for mobile internet. (or a phone untried?) Then drive from your desktop PC screen as a monitor. That doesn't ever run out of range.
User avatar
Burgerman
Site Admin
 
Posts: 70463
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 05 Jul 2017, 18:28

woodygb wrote:I've already tried the camera with a live feed via Wifi using the Commander App on my test chair with an Android tablet.

P.I.T.A to get it working and the range wasn't great.


I don't need a ton of range, but it would be nice. And I'll be (hopefully) controlling from a Windows PC with a standard USB joystick.

So what shown in the bottom of this page would work with R-net plug and play?

I have a couple bases with DX electronics. I don't really have the skills to do fine soldering to a PCB of some sort, so for me to pull this off I need a plug and play solution if possible. Converting my spare bases to R-net isn't too big an issue. I'd just need to change the motor plugs to fit the R-net power module. Which should be doable.
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 05 Jul 2017, 18:31

Burgerman wrote:I drive my chairs remotely from a 4 watt boosted RC transmitter, up to about 5 or 6 miles airborne range, but chairs don't fly! With decent RX and 3 extra diversity ones, you can still drive very securely half a mile away or more, through cars and streets.

As for video range, Thar's easy! Just set up a laptop with a mobile phone card, a sim, for mobile internet. (or a phone untried?) Then drive from your desktop PC screen as a monitor. That doesn't ever run out of range.


What hardware/software would be needed to use my PC as a control base station for RC? (besides the camera and video feed)
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby woodygb » 05 Jul 2017, 18:35

An OMNI is the easiest to interface with and I can supply a R/C interface for it.

B.M. seems to have the video camera / PC solution cracked ...so I'd follow his advice on that.
An expert is a person who has made all the mistakes that can be made in a very narrow field.
Niels Bohr
User avatar
woodygb
 
Posts: 7128
Joined: 12 Mar 2011, 18:45
Location: Bedford UK

Re: R-Net: Releasing code that lets you control chairs remot

Postby Burgerman » 05 Jul 2017, 20:30

Albeit with 2 problems.

I theres some latency. So you see whats happening about 1 second after you ran into it. You get used to that. And 2. The typical webcam on a laptop isnt wideangle enough. So its like looking through a small window!
User avatar
Burgerman
Site Admin
 
Posts: 70463
Joined: 27 May 2008, 21:24
Location: United Kingdom

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 05 Jul 2017, 22:57

woodygb wrote:An OMNI is the easiest to interface with and I can supply a R/C interface for it.


So an R-net power module would be ok with your interface, correct? I suppose I'll need an R-net joystick as well to change speeds etc?

I'll email you about the interface, thank you.
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby Gnomatic » 05 Jul 2017, 23:03

Burgerman wrote:Albeit with 2 problems.

I theres some latency. So you see whats happening about 1 second after you ran into it. You get used to that. And 2. The typical webcam on a laptop isnt wideangle enough. So its like looking through a small window!


Not really concerned about a bit of latency for this application.

I can get a better camera, loke a GoPro knockoff, which could plug into a mini PC like the Intel NUC or similar, powered by a small inverter wired to the chair base batteries.

Do you have any suggestions on transmitters that allow PC interface and control, along with corresponding software?
Gnomatic
 
Posts: 2123
Joined: 24 Aug 2012, 17:18
Location: Ohio USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby woodygb » 05 Jul 2017, 23:31

Gnomatic wrote:
woodygb wrote:An OMNI is the easiest to interface with and I can supply a R/C interface for it.


So an R-net power module would be ok with your interface, correct? I suppose I'll need an R-net joystick as well to change speeds etc?

I'll email you about the interface, thank you.


My interface is not a plug and play item and needs to be fitted into / inside the joystick pod ( Made by PGDT ) ...UNLESS the control system has an OMNI then I can supply an interface that is more or less plug and play.
An expert is a person who has made all the mistakes that can be made in a very narrow field.
Niels Bohr
User avatar
woodygb
 
Posts: 7128
Joined: 12 Mar 2011, 18:45
Location: Bedford UK

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 06 Jul 2017, 01:41

After seeing these posts, you guys are missing the point of what my work is and what the Raspberry Pi is doing, running the R-Net protocol itself.


My interface is not a plug and play item and needs to be fitted into / inside the joystick pod ( Made by PGDT ) ...UNLESS the control system has an OMNI then I can supply an interface that is more or less plug and play.


That's the entire point of my solution. It's an R-Net module, a complete standalone computer with custom addons. That alone what made me reverse engineered the R-Net protocol. I wanted a solution that just worked on any chair with R-Net

If you want RC instead. Get a RF module for the PI itself. Modify my code to accept the RC controller, instead of the USB game controller. There you go, no OMNI needed or opening the R-Net hardware.

And you get additional benefits like speed control, seat control, or access to any other R-Net device. Stop beating yourself with additional headaches like soldering and all that :D
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 06 Jul 2017, 01:53

woodygb wrote:Might I suggest this App that I use.

Joystick with 6 buttons, 3 datafields....

https://play.google.com/store/apps/deta ... k&hl=en_GB

There is also this option available from Kas with video via Wifi.

Image.


Also, this might work as with minor code changes and additional RF hardware to the PI.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 06 Jul 2017, 02:16

Since there is RC apps already, I will see what needs to be done to support general RC apps so that you can use any RC app you wish.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby ex-Gooserider » 11 Jul 2017, 03:06

This is very cool Stephen, but I think the other BIG thing that many of us are hoping for is to figure out the programming so that a user can adjust all the stuff that can be changed using the factory OEM level programming software, without needing the expensive and nearly unobtainable dongle...

Any ideas on how to either 'de-dongle' the factory software, or to replicate it's function without needing the dongle?

ex-Gooserider
T-5, ASIA-B
Jazzy 1100
Jazzy Select 6
Quickie Q-7
Invacare Mariner
Want to make / get a better chair, ideally one that stands.
User avatar
ex-Gooserider
 
Posts: 6232
Joined: 15 Feb 2011, 06:17
Location: Billerica, MA. USA

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 13 Jul 2017, 00:31

ex-Gooserider wrote:This is very cool Stephen, but I think the other BIG thing that many of us are hoping for is to figure out the programming so that a user can adjust all the stuff that can be changed using the factory OEM level programming software, without needing the expensive and nearly unobtainable dongle...

Any ideas on how to either 'de-dongle' the factory software, or to replicate it's function without needing the dongle?

ex-Gooserider



My friend and I have been working on this issue as much we can. We only have time after life duties. We have been reverse engineering the actual firmware, which has thousands lines of code. We could use help with the rnet file format.

The first step is to pull apart the rnet file format.

Any volunteers?

Once rnet files are decoded any platform can be used to change settings. I would like a list of people who will be willing to work with a HEX editor and be working on this with us. We want more people to join us.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 13 Jul 2017, 01:25

Image

This is what a rnet file looks in a hex editor. As you might be able to see I've been editing my own parameters.

I know it looks complex and scary, but you guys can learn to read this. The rnet file stores blobs of the EEROM that get mapped to the chair's memory.

I'm focusing on making apps work with the R-Net protocol. And my friend is reversing the code that is the R-Net protocol itself.

There are over 200 estimated parameters a person can change within the R-Net settings. Far more than what you may believe.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 13 Jul 2017, 02:00

My goals are:

1. Answer: How do u upload an rnet file to a chair without the dongle? I have partly answered that with the PI hardware. But we need more hands on making the program that sends this file.

I have a programmer and I will share the programmer canbus messages that allows programming with a rnet file. The hard part is emulating the order of these messages sent by the programmer. We can use the can2rnet library to do the sending.

People can help here.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby c500user » 13 Jul 2017, 16:33

http://www.permobil.com/fr/France/Assis ... ametrages/

Not sure what file you are trying to decode. Above a link to Permobil r-net factory default configuration files.

Perhaps useful to know that the Permobil r-net dealer sw can be downloaded from http://www.permobil.com/fr/France/Assis ... rogrammer/
Permobil C500 main
Permobil C500 spare
Otto Bock C2000 long distance outdoor
Magic Mobility Extreme X8 off road
c500user
 
Posts: 269
Joined: 10 Mar 2016, 01:47
Location: Brisbane, Australia

Re: R-Net: Releasing code that lets you control chairs remot

Postby stephenc1 » 14 Jul 2017, 05:37

c500user wrote:http://www.permobil.com/fr/France/Assistance/Informations-techniques/Fichiers-de-Parametrages/

Not sure what file you are trying to decode. Above a link to Permobil r-net factory default configuration files.

Perhaps useful to know that the Permobil r-net dealer sw can be downloaded from http://www.permobil.com/fr/France/Assis ... rogrammer/


This helps a lot. The files I'm decoding are *.rnet and *.rnss because that's what the chair's parameters are stored in.

It is less guesswork for us to make a program that uses the same format.

Once the files are decoded, then one can see their speed settings, jsm settings and more. And it gives us a way to store them back in a chair.
stephenc1
 
Posts: 33
Joined: 17 Dec 2016, 01:47

Re: R-Net: Releasing code that lets you control chairs remot

Postby gcebiker » 20 Jul 2017, 08:25

This is great Stephen, thank you for your hard work.

I dont have a Pi...or an Rnet chair but i do have the OEM software (not cutting up the cable...).
I also have Leonardo Can Bus Arduino boards , available in the UK.

Once i finish tinkering with the Arduino i am doing the same for the Dynamic Shark, i think i will have a go at this.

Cheers
Tony
http://greenmobility.com.au/rc-wheelchair-controller/
My YouTube Ch -- https://www.youtube.com/user/gcebiker
User avatar
gcebiker
 
Posts: 879
Joined: 11 Jul 2015, 14:20
Location: Gold Coast, Queensland, Australia.


Return to Everything Powerchair

Who is online

Users browsing this forum: JMGarage, LROBBINS, sergey0, Superchunk and 96 guests

cron

 

  eXTReMe Tracker