Some ideas for a domestic antitheft system... and probably more.

Hi Marco,

Thanks nice.

in Souliss the support for RS485 will be based on custom drivers and not the Arduino ones. This let me have a stable software that is not addressed during the IDE releases and at same time I can modify the same as per my requirements.

For example, the W5100 drivers are based on the Sockets/W5100 libraries but not on the Ethernet from the IDE.

If you would like to share the problem that you found, it will let me easy do the job. I hope to end as soon the uIP integration for ENC28J60, so I will move on the RS485 side.

Regards,
Dario.

Hi Marco,

I know that there isn't space available, but maybe during the re-design for 12/24V operation, you may found space for the holes of a UEXT connector.

You can provide just the holes and let people solder it themself if required.

This may embeed in your board nice features like IrDa or 2.4Ghz wireless.

Regards,
Dario.

Hi Dario.

It's a very good idea.
I'll do the best to have as least the holes for the connector.
Probably to be soldered on the back side would be an option.

Thank you for the feedback!

Regards,
Marco.

Hi.

A little update about the project status...
I've built a prototype of a new switching power supply as suggested by Dario. Below is a picture. I was able to test it at 400mAmps and a Vin Max of 31Volt DC.
The output voltage is 5V. I've measured about 200mV of ripple in these conditions.
I think it's good and I'll integrate as soon as possible in the target board.

Thanks!

Marco.

Hi Marco,

nice news. Does you have the oscilloscope graphs for the input and output voltage/current with the 400mA load?

It would be nice find out the switching efficiency.

Thanks for sharing.

Regards,
Dario.

Hello Dario.
Sorry for the delay... but my spare time is very limited...

Unfortunately I've not a current probe for the scope so I've modified a little bit the schematics inserting a 1ohm resistor series to the inductor. I've then used two scope channels to measure the voltage across the resistor terminals. I've also placed a multimeter measuring current flowing either on the input side, either on the output side.
In the attached picture you can see the results.

Channel1, the yellow line, is the output side voltage (more or less 5V). Channel 2, the cyan line, is the input voltage (an average of 31.4V).
Channel3 is the "hot" resistor terminal (the one attached to the inductor), Channel4, the green line, is the resistor on the capacitor side (i.e. it's attached to the same position of CH1 but the sensitivity on this channel is 1V). The red line is the difference between Ch3 and Ch4.
With a 1ohm resistor I can imagine to read Amps instead of Volts. Effectively we can see a sawtooth with an averaged value supposed to be a bit less than a half of Ampere.

The Frequency measurement on Ch3 reports that the switching is running at 24.3kHz. It's probably something I can modify changing the capacitor value connected to the switching IC... Probably increasing the frequency will rise up the efficiency... but I've to investigate about.

On the multimeter snapshots, below the scope picture, are the DC and AC current measurements at the input side (on the left) and at the output side (on the right).

With this collected data I can calculate:

Pin = Vin x Iin = 31.40.10 = 3.14W
Pout = Vout x Iout = 5.4
0.43 = 2.32W

having an efficiency of E = Pout/Pin *100 = 73.8%

I think is an interesting value, do you? We have to consider that there are some power losses introduced by the 1ohm resistor...

Thanks!

Marco Signorini.

Hi Marco,

the result is pretty nice and close to the maximum efficiency that you can have. Using a linear regulator with 31V input (if it doesn't burn before) has (5V/31V) 16% of efficiency because the input and output current are the same.

The frequency value is related to the power loss, bigger is the frequency lower is the efficiency. This because this type of devices has losses during the switching phase, rather during the ON or OFF phase the power that is lost is pretty low. On the other side, bigger frequencies gives you a lower ripple.

You may try to increase the efficiency with a lower frequency and a bigger output capacity, but I think that your result are good and also the output voltage is stable.

Thanks for sharing.

Regards,
Dario.

Thank you Dario.
You're absolutely right about efficiency variation vs switching frequency.

In the meantime I would like to update this thread with the new schematics and the board layout.
In this new revision is the switching power supply and the UEXT connector. This will not be populated but it will be available for users that like this type of expansion connector.
The two I2C pull-up resistors will be soldered on but left unconnected from the 3v3 through the SJ2 placed on the back side. I'm thinking that probably the best solution would be to have a SJ for each resistor instead of a single SJ2 in series with the 3.3V. This will prevents a series resitor connections between SCL and SDA lines when UEXT is not used. I'll do it.
The PD5 line is used as slave select in the SPI related part of UEXT connector. This connector receives, as required by the UEXT documentation, the 3.3V generated by IC6.

Lastly, the three relays and related LEDs are directly connected to the Vin.

I'm planning to have a new set of prototypes in next three weeks.

Thank you.
Marco Signorini.

Domoduino12b.png

Hi Marco,

I think that your board will be very interesting and I hope to have the RS485 drivers running on Souliss as soon. It will be a nice work, because I shall build a P2P over RS485 and so means have a collision management done at software side.

In Souliss, we are planning the new release by the end of the June or earlier July. The new release shall contain the support for ENC28J60, a new scheduler, anti-theft logics and some general improvement and bugfix. After, we will start for the new features that will include: RS485 drivers, Ethernet-MAC support (to skip IP configuration) and a binary protocol for the external interfaces.

In the while, we are working with the Freedomotic team for the integration between Souliss and Freedomotic, using a plugin on the freeedomotic side (JSON), and I hope to be able to release also a new web-based user interface.

Thanks for sharing your work.

Regards,
Dario.

Hi Dario.
I'll send you in a short time a prototype. Unfortunately actually I have only one unit in my hands (I built two units but one is actually out of the office and will be back in a few days (I hope))... but I think you're more interested in the new version with UEXT connector... so we have to wait for the PCB production and assembly.

In the meantime I'm thinking to a new other object that I think could help Freedomotic and Souliss to have a more impact on domotic systems. Let's imagine to have a board could be easily connected to pushbuttons and/or switches like the one provided by Living Series or similar. A board with ATMEGA328, power supply and the RS485 bus logic onboard, with LEDs (RGB?) placed in the proper position in order to be fitted in the Living pushbuttons hole for status indication... Something like a piggy back for three standard switches...

May I've to open a new thread? :slight_smile:

Thank you!
Marco Signorini.

Great idea Marco. I'm following your thread since the beginning. Unfortunately I have no such experience in this field in order to be able to contribute.

Hi Marco,

I've the hardware to start the development of the RS485 drivers, so don't worry for the time required to get the PCBs. Now for me is just a matter of time, because I've some pending activities before the release of the next Souliss and only after I may start the development of RS485 and other features.
If you will open a new topic, I will be in the chat :slight_smile:

Regarding the new proposal for others boards, let me say that compete with the Big of the automation is too hard, if you want to win or at least stay alive, the easy way is propose something different. This is why Souliss has a different approach that is not found in the commercial automation systems. On my side, I think that the actual commercial products are not strong enough on the small installation, where you have to spent an huge amount of money compared to the home size. In a big home the ration looks different.

On my side I think that the hardwired pushbutton, in a modern automated home, shall be less as possible. Maybe, you have it all in one remote location, used only when required. Sensors like PIRs and mobile devices may act for this.

To lower the price of the automation system, I think that the option shall be use less board with high density of I/O, rather than boards in each junction box. It require more cabling, but in a small home shall not be a problem.

I’ve an idea to propose, dimming is something “cool” but use old fashing lights has no meaning, play with high power LEDs is more interesting. I think that on the market there aren’t LEDs power supply that can be easily included in an home automation system, I was working to a power supply that may interact with Souliss (RS485, Wireless 2.4 GHz or Ethernet).

I’ve tried to find out a commercial power supply that was easy to interface with a board (the best was dimmed via analog output), but I’ve found nothing as now.

Is this something that look interesting to you?

Thanks again for your sharing.

Regards,
Dario.

This was just my point of view, if you will move to a input board like you have described, it will happy to support it in the framework.

Regards,
Dario.

Hi!

@Flx: Thank you for sharing your opinion. It's not important if you don't have so much experience in developing boards and/or schematics. Here we are for share ideas... and all contributes are really appreciated. The success of a product is not strictly related to technical solutions but more on ideas! So you're welcome!

@Dario: I don't want (can't) compete with big players. I would like to develop objects targeted to DIY fans. I can tell you an example... my house. The electric plan was built following the conventional style. No domotics, no other goodies. Being a DIY-man I would like to add some domotics functions... but this requires to change all switches and much more. So I was thinking about re-use the electrical hardware (that not only costs a lot... but is also beautiful and I like it!). I can then re-use the electric junction boxes disseminated through the home to install actuators... all could be connected through a 485 bus and probably integrated with the ethernet equipment through a gateway for controlling/supervising. I'll be able to program it because each "agent" in the system contains open software. I think that there are a lot of people that love this approach in the Community and could be interested in this type of products that, sure, will not demote the Souliss approach but can help integration through a "classic" human interface.

For what's related to High Power LEDs: it's something I started to follow some years ago (there is a Circuit Cellar's article I wrote, where I used a dsPIC to drive three 1Watt LEDs in a three channel psychedelic lights project http://www.scribd.com/doc/50577471/CC-248-2011). I'm interested on this type of project and it's something I would like to propose. We can start a new thread to understand what are the requirements.
Have you checked the High Power LED Shield proposed on the www.EtherMania.com website? It's a four channel 350mA constant current driver for High Power LEDs. LEDs could be dimmered through the Arduino PWM channels. 4 Channels High Power LED driver shield : EtherMania, The store for network enthusiasts It could be a good starting point... but I think we are OT on this thread (sorry for the link-spamming).

Thank you for sharing your opinions!
Marco Signorini

Hi Marco,

nice shield, I've missed it when I was looking into your store. I will spent some time to read the documentation and the links that you have provided.

I agree that we can move the discussion into another topic.

Thanks.

Regards,
Dario.

Hi Marco,

I would like to evaluate the board consumption, in order to understand which are the constrains in terms of number of board vs bus lenght.

Does you have the model number for 12 and 24V relays that you are planning to use?

Thanks.

Dario.

Hi Dario.

I'm planning to use the T7SS5E6-24. I've already used the 5V version without problem in these years and I like it.
They have a 360mW coil consumption so I can calculate a 15mA for the 24V version... (quite like a normal LED). Having three of that + LEDs I suspect we are in the range of a 100mA at full load.
I think we can also reduce the coil dimension used in the last PCB because I suspect that nobody needs a 0.4Amps on the 5V... and probably reduce the switching output capacitor.

But... speaking about DC and power related... I'm thinking to something that could help to have an easy deploy of these items in the house. I'm thinking to merge the data and power on the same line.
What do you think to have a carrier modulated injected over the DC line?
I'm thinking to something like DTMF tones or the "simplest" FSK. I'm quite sure we can do something like what was used in the sotware modem library for Arduino:

http://code.google.com/p/arms22/downloads/detail?name=SoftModem-004.zip

Thanks!

Hi Marco,

assuming a system over 10 nodes rated at 24V and 100 m of bus for 1 mm2, at the end of the line we have lost 4V (4 Ohm/100m). Its enought to operate the coils (>16V) and power the boards. I was thinking that a single cable with two twisted pairs maybe one way to power the boards and get the signal.

Unfortunately cable with two pairs doesn't have size larger than 0.5 mm2, at least on eBay. That for sure are too small cables to carry out the power, and may create us problems in case of larger boards (with more relays).

Have you some suggestion?

In the while I'm looking to the library SoftModem.

Regards,
Dario.

Hi Marco,

I've looked a bit into SoftModem and I've to say that is really a nice library. It build a binary-FSK modulator/demodulator in hardware, using the analog comparator and an internal timer. Is interrupt driven and so isn't so heavy for the uC.

In attachment you can found the electrical sheme that I've used to build a bus of AVRs without any additional hardware (out of wires and resistors). I was able to readback what was written on the bus and find out collision on the bus.

I would like to build a library based on SoftModem, it will use a different managment of the buffer and include CRC and collision detection. This library will be a base option that shall be included in Souliss/vNet also.

Now the problem is find out a way to move the data over a powered bus, thats no so simple. Now I'm using a floating bus (see the attachment) that offers less realibility of a open-drain one, because the resistor split the voltage and so, the noise can create more problem rather than a solution without voltage splitting.

Now the question is how to insert a low 3.3/5V voltage over a 24V bus. I've always seen the capacitve coupling used to filter a DC signal and I'm not sure on how the same can be injected in.
Looking to some scheme in internet, looks that capacitive coupling shall be enough (with maybe a smith trigger in between), but I'm not sure about this. I will try to study the problem.

Let me say that with this library we can read back what we write, that means have an easy way to detect the collision. So we shall try to retain this capability.

Regards,
Dario.

In the while of the development of the library for the FSK (it will require a bit, because I've a planned release of Souliss in short time), I'm studying the circuit with a SPICE simulator (I'm using LTIspice) to learn more about a singnal over the power line.

As now I've cleared some of my dobuts, the first was how I can inject a low voltage over a cable that has a bigger one, the answer was the internal generator resistance.
The simulation has highlighted a point that I've forget, also if we use a FSK wave that is always >0V, after the filtering it will have a wave above and below the zero, so an offset is required.

Now the interesting matter is find what happen in case of collision, what I mean, I've studied (in my previous attachment) what happen on the electrical side in case of time-invariant bits. Now the goal is understand what happen when a bit is no longer a time invariant voltage, but a modulated one.

I will try to post some result as soon.

Regards,
Dario.