Uploading a sealed sensor via wireless or utilizing 4 wires in pigtail

I'm looking for a better way to upload code to a 4 pin (5v, Ground, Position 1 output and Position 2 Output) automotive shaft position sensor that is completely sealed with resin. Both outputs are 0.25-4.75 analog signals.

Components: Nano, Magnetic Position Sensor with external magnet mounted on end of shaft, 2 Channel DAC. The first 50 sensors can't be updated if it malfunctions because I don't want extra wires or USB hanging out. Now I've added some hardware and can do an upload using a FT232 sending it directly up the pigtail. The power and ground didn't change but I use the other two output wires for RX and TX pins D0 and D1. Because of that there is a momentary button hiding in the pigtail if you know where to push to engage reset for the upload. The hidden button is not a good solution. I have many ESP board variations and tried all I could to get the ESP 01S uploading the NANO but no luck.

Wireless is nice but won't be a common task so I'm fine with a physical connection. Just can't have the buttons or extra wires. Any info on how I can accomplish this is appreciated!

gooodsystems:
I'm looking for a better way to upload code to a 4 pin (5v, Ground, Position 1 output and Position 2 Output) automotive shaft position sensor that is completely sealed with resin. Both outputs are 0.25-4.75 analog signals.

Components: Nano, Magnetic Position Sensor with external magnet mounted on end of shaft, 2 Channel DAC. The first 50 sensors can't be updated if it malfunctions because I don't want extra wires or USB hanging out. Now I've added some hardware and can do an upload using a FT232 sending it directly up the pigtail. The power and ground didn't change but I use the other two output wires for RX and TX pins D0 and D1. Because of that there is a momentary button hiding in the pigtail if you know where to push to engage reset for the upload. The hidden button is not a good solution. I have many ESP board variations and tried all I could to get the ESP 01S uploading the NANO but no luck.

Sorry, but I can't make sense of that.

In the first place, why is it necessary to upload code to a sensor? Most sensors just output data and from the first line of your Post the sensor just seems to have two output pins.

Can you post a link to the datasheet for the sensor?

...R

What the hack is a "4 pin (5v, Ground, Position 1 output and Position 2 Output) automotive shaft position sensor"? LINKS!
Filter the language into understandable common engineering language.

Never mind the details of the sensor, it was simply meant to be relate to NANO uploading options for future updates or upgrades. I fill the sensor housing with potting resin to keep it sealed. I’ll rephrase: Is there a way to upload the NANO wirelessly? If so I can redesign the circuitry and hardware to accommodate whatever is required to do wireless uploads.
If not then I can provide those uploads by disconnecting the sensor from the vehicle, wire the FT232 or TTL converter so RX and TX goes up into the sensor using both output wires and adding 2 buttons…one that controls two transistors creating a unique pathway to D0 and D1 and another button for manual reset so it accepts the upload. However I want to avoid having buttons as that creates a potential moisture entry point. Since we’re not using USB is there a way to do the upload without manual reset?

Robin2:
Sorry, but I can’t make sense of that.

In the first place, why is it necessary to upload code to a sensor? Most sensors just output data and from the first line of your Post the sensor just seems to have two output pins.

Can you post a link to the datasheet for the sensor?

The uploads are necessary for customizing beyond what GMC did with it on factory models. I haven’t created a data sheet and didn’t intend to but I do need to get the schematic done so I’ll brew some coffee an draw that up. It’s a simple sensor so I think the schematic will provide any open questions there.

Railroader:
What the hack is a “4 pin (5v, Ground, Position 1 output and Position 2 Output) automotive shaft position sensor”? LINKS!

The factory GMC rear wheel steering sensor used Delphi 150 Series 4-way connector. Pin A is 5 volt supply, pin C is ground and pins B and D are linear analog output voltages to controller to convert to actual wheel angle to the left and right.

I’ll get that schematic up soon, THANKS!

QSv2_20201210_0001.pdf (529 KB)

gooodsystems:
Pin A is 5 volt supply, pin C is ground and pins B and D are linear analog output voltages to controller to convert to actual wheel angle to the left and right.

I'm still stuck with a very basic question.

If you have a device with Power, GND and two Data outputs how is it possible to upload code to it?

...R

That is what the buttons and transistors are for. Holding down button #1 changes the path of Pins B and D to TX and RX instead of the DAC output, acting as switches. Then when it is time button #2 resets the board for it to accept the upload. When upload is complete I release button #1 and transistors go back to normal to DAC has their outputs back.

gooodsystems:
That is what the buttons and transistors are for. Holding down button #1 changes the path of Pins B and D to TX and RX instead of the DAC output, acting as switches. Then when it is time button #2 resets the board for it to accept the upload. When upload is complete I release button #1 and transistors go back to normal to DAC has their outputs back.

It would have forestalled a lot of questions if that had been in your Original Post.

...R

Just as it would if I didn’t mention it at all. I’m simply looking for help/advice on other upload options, preferably wireless if possible. My first post only had to say that alone but I’d get ripped on for not having enough data so I added extra details. It takes a brave soul to reach out in this forum. Can you possibly just belittle me, get your fix so we can get creative, have fun, and build something cool?

ESP8266 and ESP32 have OTA (over the air as in wireless) code upload options.

Thanks Idaho! I can't use a 3.3v for a controller because the DAC needs 0-5v output. I also need 2 analog inputs for the sine and cosine magnet position, some of those only have 1 I think. I tried using the ESP 01S as an uploader to the NANO but couldn't get that to work. I have lots of ESP stuff handy if you have another idea?

gooodsystems:
Can you possibly just belittle me,

I have not being trying to belittle you. I have been trying to understand your problem so I could figure out if I could help.

...R

gooodsystems:
Thanks Idaho! I can't use a 3.3v for a controller because the DAC needs 0-5v output. I also need 2 analog inputs for the sine and cosine magnet position, some of those only have 1 I think. I tried using the ESP 01S as an uploader to the NANO but couldn't get that to work. I have lots of ESP stuff handy if you have another idea?

The ESP does not talk Nano.

I misunderstood, sorry Robin. I've read some awesome stuff of yours in the past I should know better, just overwhelmed

Am I correct to think that you want to be able to connect something to the 4 wires of the pigtail (5v, GND, Position1 / TX and Position2 / RX) and have that something upload code or settings to the sensor.

And, along with that am I correct to assume you will have access to the buttons #1 and #2 so that you can change the mode?

Also what's the relevance of the "first 50"? Do you mean that whatever you plan to do will only apply from items 51 onwards?

...R

There are about 50 out there now and there is no way to upload the code in those. It could get expensive if they all start having warranty issues.

The one in the picture has the 2 buttons under the heat shrink placed right where they are. It works good but I'd really like to upload it without having buttons at all. The all black one above it is the same but has the wire protection on it. I can see things go wrong with the buttons. Uploading wireless would be cool but even if we could get away with using the 4 pigtail wires would be awesome!

Called "post production engineering"!

Paul

gooodsystems:
The one in the picture has the 2 buttons under the heat shrink placed right where they are. It works good but I’d really like to upload it without having buttons at all. The all black one above it is the same but has the wire protection on it. I can see things go wrong with the buttons. Uploading wireless would be cool but even if we could get away with using the 4 pigtail wires would be awesome!

I can’t see any buttons in the image in your Original Post, and both units are black.

You said earlier that the buttons are used to change the mode - how would you propose to change the mode without using the buttons?

…R

Hi,
Ops diagram, please post images as jpg rather than pdf, they are easier to view on some platforms.


Thanks.. Tom... :slight_smile:

(deleted)

Robin2:
I can't see any buttons in the image in your Original Post, and both units are black.

You said earlier that the buttons are used to change the mode - how would you propose to change the mode without using the buttons?

It didn't attach last time, sorry. I added the picture to the original post. The buttons are hiding under the heat shrink so the 2 buttons on the table are just referring to their location.
I must have used the wrong terminology with 'mode' as the buttons are just for the upload process. The customer doesn't need to know the buttons are there, they are only for me doing updates.

ArduinoKoen:
Why not get a 5th cable out. That could somehow be used to trigger the RrTx to be ready for upload...

For the end user anything more then the pigtail that plugs into the vehicle will add confusion. It's plug-n-play for them. It is also located under the vehicle susceptible to water and road salt. When the resin is poured it will protect the buttons as the heat shrink goes deep inside.