Use of particular wireless link with an analog sensor

HI,

  • I work on a system helping to drive a car with only the hands ( acceration function ) for a disabled person.

  • I need to suppress the cable of 1 or 2 meters long between the analog sensor (potentiometer) and the processing unit ( UNO Arduino card) and use instead a wireless link (for instance bluetooth modules such HC 05).

  • The constraint is that the transmitter package (and associated electronics) has to be as small as possible ( I cannot use another UNO card at that level).

Any idea to proceed or similar system references ?

Is this one way comm. or two way comm.?

Maybe try the ever popular 433Mhz RF trans/rec out there?

Or maybe use 2 ESP (wifi) modules...

(an ESP module can be/act like an Arduino all by itself.. FYI.. and can be programmed using the same Arduino IDE)

A pot value (voltage) can be transmitted by a radio remote control (in PCM), or by digitizing the setting and transmitting the binary value over some digital connection. For the latter approach an ESP may be usable, provided that it supports analog inputs.

I have built a wireless system for an 00 Gauge model train from an nRf24L01+ module and an Attiny 1634.

  • would that be small enough?

If you have a little more space you could use an Atmega328 which makes the soldering a little easier.

...R

Hi,

Is this for a road registered motor car?

Tom... :slight_smile:

Hi,

Thanks a lot to all,

  • More about my constraints (!) : dimensions ( image underneath) and power consumption because in that volume I can only integrate a 3,7 V rechargeable « coinPower » Varta : 60 mAh / 12mm diameter 5,5 mm high .

  • About your various proposed solutions

a/ ESP 8266 ( Wifi) : seems Ok with respect to ADC input ( pin 6 TOUT), package dimensions 5 x5 mm (but PCB antenna ?), Arduino compatibility, however power consumption high ( 50 mA min )

b/ Pot value transmitted by a radio remote control (in PCM) looks good but I don't figure out what that means in terms of hardware / power consumption/ dimensions ?

c/ nRf24L01+ module and an Attiny 1634 solution : looks good wrt power consumption ( ~11 mA / 3V , including 0,2 mA Attiny 1634. ) and seems at that stage compatible in terms od dimensions ?

  • Tom : no it's for my wife's car ( and any others if I succeed !) but that could be used may be with other vehicules I suppose but difficult with a motocar : the UNO card, as indicated, drives an assembly sermotor + mechanical parts linked to the gas pedal.

  • I may have missed something ( I am not familiar with this technology ) or if you have any comments, don't hesitate...

main-2.jpg

Image from Reply #5 so we don't have to download it. See this Image Guide

25ba9e966f2e03b86e267df2cf61150989e20ad3.jpg

...R

The device in my picture measures 29mm x 15.5mm and I have another version that is about 22mm x 15.5mm. And I am running it from a 1S LiPo cell - using a diode to drop the voltage so it does not exceed the max for the nRf24L01+

The version that uses an Atmega 328 measures 41mm x 15,5mm

...R

Hi again Robin,

  • Sorry for the image, I will follow « reply 5 » next time ..

  • What you are telling seems very encouraging specially your 22 x 15,5 mm package.
    Do you mean that with these dimensions all functions are « included » : nRf24L01+ PCB antenna + Attiny 1634 + a few components around exept the LIPO battery ?
    In terms of thickness what can I expect ?

TomGeorge:
Hi,

Is this for a road registered motor car?

Tom... :slight_smile:

  • Tom : no it's for my wife's car ( and any others if I succeed !) but that could be used may be with other vehicules I suppose but difficult with a motocar : the UNO card, as indicated, drives an assembly sermotor + mechanical parts linked to the gas pedal

What sort of car is it? (Electric Mobility Vehicle?)
What is its max speed?
Arduino may be okay for proof of concept, but there are many safety considerations.
Tom.... :slight_smile:

Samanu:

  • What you are telling seems very encouraging specially your 22 x 15,5 mm package.
    Do you mean that with these dimensions all functions are « included » : nRf24L01+ PCB antenna + Attiny 1634 + a few components around exept the LIPO battery ?
    In terms of thickness what can I expect ?

I am somewhat surprised because the bigger 29x15.5 easily fits within your 45x25. The picture shows the 29x15.5 version.

To get it down to 22x15.5 I sawed off the PCB antenna and soldered on a short wire for an antenna.

The thickness is determined by the header pins on the nRF24 and its crystal making the total about 13.75mm.

If you are seriously thinking of going down this route I suggest you buy several nRF24s so you can see exactly what is involved. They are only about £2 each. And if you are thinking of cutting off the PCB antenna be sure to buy enough modules so that you always have at least two undamaged modules.

Be sure to get simple communication working using (say) a pair of standard Unos before you start any of the complicated stuff. Wireless can be very difficult to debug - hence start simple and move slowly. Start with the examples in this Simple nRF24L01+ Tutorial

...R

Hi,

Robin :

  • « why 22x15,5 instead of 29x15,5 » I don't yet kow what stuff will have to be around the well identified components ( nRF24L01, Attiny 1364 & battery ) so before starting any breadboarding I try to evaluate the minimum volume necessary for major functions. I tried to define the HW configuratio in the image as shown ( if I succeed ! ) This project has some interest if the module is small / very small : I have found the equivalent system on the market : it covers almost the back of the hand, it is heavy and then, for us, of no interest.
    I prefer to have to recharge the battery often ( every 2 days for instance ) instead of having a larger package.

If I see a real possibility to meet this goal, I fully agree with you to start with a breadboard which doen't take into account this dimensions aspect and buy severall items …
I am a bit anxious to succeed to develop the necessary SW : first at the level of the Attiny and the one dealing with the 2 RF modules. I have read rapidly your examples and hope that your detailed explanations will be sufficient in my case ! I am more confortable for the moment with 3D modelling and printing than with micros.

Note : Finally, I am surprised by the amount of efforts, to arrive to communicate a single 8 or 10 bits word every 20 ms, one meter away ! It is because I never had the opportunity to think to it I suppose...

  • Tom : I know what you mean but the laws do not cover all handicap cases and having discussed severall times with « specialists » the project goes in the right direction. The system including the UNO card is already installed by a well known company specialised in that business . Car = Twingo 3 automatic.

With the usual ratiometric ADC the pot and ADC should be powered by the same source (voltage).

Hi,

OK Dr, I hope then that the Attiny will deliver the suitable voltage. I added a few basic functions and hope too that it will help to tell when the system is no more operational ( discharge...)

Samanu:
I hope then that the Attiny will deliver the suitable voltage.

This is back-to-front thinking. Your battery will supply the voltage for everything. An Attiny or Atmega 328 will run at 8MHz happily from a LiPo cell but the nRF24 has a max voltage of 3.6v on its power (Vcc) pin. It can take up to 5.25v on the other pins.

For simplicity and space reasons for my model train I just drop the battery voltage with a diode and feed it both to the nRf24 and the Attiny. In theory if the LiPo is charged to 4.2v the diode voltage drop (0.8v - measured) will bring it down to 3.4v. The downside is that when the battery is nearly discharged it will bring the 3.6v down to 2.8v which may be too low for the Attiny to work at 8MHz - but that might be a good thing if it prevents the battery from being discharged too much.

You could, of course, feed the full battery voltage to the Attiny and just use the diode to drop the power to the nRF24. In my case I did not do that as it would have made the wiring a bit more complicated.

I don't think it is practical to think of a regulator operating in the small voltage gap between a 1S LiPo and (say) a 3v device.

For the device you are thinking of it may actually be simpler to use a pair of AAA alkaline cells - just replace them when they are exhausted.

For maximum battery life have a look at Nick Gammon's power saving tutorial

...R

Hi Robin,

  • Battery : based on your arguments, I will have to perform later a trade off : LiPo, Li button cells etc. depending on usual parameters and room left around major components. The regulator is not a good idea for such low voltage I agree...

  • My today inexperience in micros pushes me to ask for some clarifications concerning the very much interesting article you mentionned.
    In the methods suggested by Nick I see « run the processor to a lower frequency » is that applicable to my case, for instance 2 MHz instead of 8 MHz ?

I was wrong saying, some posts ago, that the total current would be ~11 mA , meaning that the micro power consumption was negligeable. I found an apparently low power one ( PIC16F684). With your experience, could it be used in my application ? ( starting from scratch I suppose that the difficulty to use one or the other micro will be same ! )

The PIC family of microprocessors is not compatible with the Atmel microprocessors used in Arduino boards. AFAIK both families have much the same capabilities.

You need to study the relevant Atmel datasheets to get the details.

One of the graphs in the Attiny1634 datasheet says it consumes 2.5mA running on the 8MHz internal oscillator at 3.5v. And there are also graphs for other frequencies.

...R

Hi,

  • OK PIC and Atmel are not compatible and Atmel is used on Arduino. I have looked the detailed performaneces ( power consumtion/ frequency) and at 8MHz the 2,5 mA, as you said, represent less than 20% of the total budget which is acceptable....
    I don't know the impacts of using a lower frequency, may be an external oscillator, in that case a diminution of 1 or 2 mA is not interesting, consequence : baseline with an ATtiny1634 / 8MHz seems the right approach.

  • For curiosity's sake, how is it possible to have an incompatibility ( PIC/UNO ) with the present configuration : the micro interfaces with the first RF module and the second RF module with the UNO card ? Or is there already an incompatibility between the micro and the RF module ?

Thanks anyway Robin for your explanations

Samanu:

  • For curiosity's sake, how is it possible to have an incompatibility ( PIC/UNO ) with the present configuration : the micro interfaces with the first RF module and the second RF module with the UNO card ? Or is there already an incompatibility between the micro and the RF module ?

I don't understand

...R

Hi again,

I try to clarify : you said that PIC and Atmel are in some way not compatible and that Arduino uses Atmel., OK.

In my configuration, logically, if the 8 or 10 bits word ( position parameter) is generated by a PIC, communicated to the nRF24 transmeter interfacing with the nRF24 receiver and finally communicated to the UNO ( base on Atmel) , I don't understand why it should or may not work.
For me, even if the two families are not compatible they don't interface directly and then the incompatibility should not apply to that case.

As I mentionned previously, exept if the PIC is not compatible with the nRF24, of course !